Merge remote-tracking branch 'stable/linux-5.15.y' into rpi-5.15.y
This commit is contained in:
@@ -107,13 +107,14 @@ Description:
|
||||
described in ATA8 7.16 and 7.17. Only valid if
|
||||
the device is not a PM.
|
||||
|
||||
pio_mode: (RO) Transfer modes supported by the device when
|
||||
in PIO mode. Mostly used by PATA device.
|
||||
pio_mode: (RO) PIO transfer mode used by the device.
|
||||
Mostly used by PATA devices.
|
||||
|
||||
xfer_mode: (RO) Current transfer mode
|
||||
xfer_mode: (RO) Current transfer mode. Mostly used by
|
||||
PATA devices.
|
||||
|
||||
dma_mode: (RO) Transfer modes supported by the device when
|
||||
in DMA mode. Mostly used by PATA device.
|
||||
dma_mode: (RO) DMA transfer mode used by the device.
|
||||
Mostly used by PATA devices.
|
||||
|
||||
class: (RO) Device class. Can be "ata" for disk,
|
||||
"atapi" for packet device, "pmp" for PM, or
|
||||
|
||||
@@ -520,6 +520,7 @@ What: /sys/devices/system/cpu/vulnerabilities
|
||||
/sys/devices/system/cpu/vulnerabilities/srbds
|
||||
/sys/devices/system/cpu/vulnerabilities/tsx_async_abort
|
||||
/sys/devices/system/cpu/vulnerabilities/itlb_multihit
|
||||
/sys/devices/system/cpu/vulnerabilities/mmio_stale_data
|
||||
Date: January 2018
|
||||
Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
|
||||
Description: Information about CPU vulnerabilities
|
||||
|
||||
@@ -37,11 +37,7 @@ Pressure interface
|
||||
Pressure information for each resource is exported through the
|
||||
respective file in /proc/pressure/ -- cpu, memory, and io.
|
||||
|
||||
The format for CPU is as such::
|
||||
|
||||
some avg10=0.00 avg60=0.00 avg300=0.00 total=0
|
||||
|
||||
and for memory and IO::
|
||||
The format is as such::
|
||||
|
||||
some avg10=0.00 avg60=0.00 avg300=0.00 total=0
|
||||
full avg10=0.00 avg60=0.00 avg300=0.00 total=0
|
||||
@@ -58,6 +54,9 @@ situation from a state where some tasks are stalled but the CPU is
|
||||
still doing productive work. As such, time spent in this subset of the
|
||||
stall state is tracked separately and exported in the "full" averages.
|
||||
|
||||
CPU full is undefined at the system level, but has been reported
|
||||
since 5.13, so it is set to zero for backward compatibility.
|
||||
|
||||
The ratios (in %) are tracked as recent trends over ten, sixty, and
|
||||
three hundred second windows, which gives insight into short term events
|
||||
as well as medium and long term trends. The total absolute stall time
|
||||
|
||||
@@ -17,3 +17,4 @@ are configurable at compile, boot or run time.
|
||||
special-register-buffer-data-sampling.rst
|
||||
core-scheduling.rst
|
||||
l1d_flush.rst
|
||||
processor_mmio_stale_data.rst
|
||||
|
||||
246
Documentation/admin-guide/hw-vuln/processor_mmio_stale_data.rst
Normal file
246
Documentation/admin-guide/hw-vuln/processor_mmio_stale_data.rst
Normal file
@@ -0,0 +1,246 @@
|
||||
=========================================
|
||||
Processor MMIO Stale Data Vulnerabilities
|
||||
=========================================
|
||||
|
||||
Processor MMIO Stale Data Vulnerabilities are a class of memory-mapped I/O
|
||||
(MMIO) vulnerabilities that can expose data. The sequences of operations for
|
||||
exposing data range from simple to very complex. Because most of the
|
||||
vulnerabilities require the attacker to have access to MMIO, many environments
|
||||
are not affected. System environments using virtualization where MMIO access is
|
||||
provided to untrusted guests may need mitigation. These vulnerabilities are
|
||||
not transient execution attacks. However, these vulnerabilities may propagate
|
||||
stale data into core fill buffers where the data can subsequently be inferred
|
||||
by an unmitigated transient execution attack. Mitigation for these
|
||||
vulnerabilities includes a combination of microcode update and software
|
||||
changes, depending on the platform and usage model. Some of these mitigations
|
||||
are similar to those used to mitigate Microarchitectural Data Sampling (MDS) or
|
||||
those used to mitigate Special Register Buffer Data Sampling (SRBDS).
|
||||
|
||||
Data Propagators
|
||||
================
|
||||
Propagators are operations that result in stale data being copied or moved from
|
||||
one microarchitectural buffer or register to another. Processor MMIO Stale Data
|
||||
Vulnerabilities are operations that may result in stale data being directly
|
||||
read into an architectural, software-visible state or sampled from a buffer or
|
||||
register.
|
||||
|
||||
Fill Buffer Stale Data Propagator (FBSDP)
|
||||
-----------------------------------------
|
||||
Stale data may propagate from fill buffers (FB) into the non-coherent portion
|
||||
of the uncore on some non-coherent writes. Fill buffer propagation by itself
|
||||
does not make stale data architecturally visible. Stale data must be propagated
|
||||
to a location where it is subject to reading or sampling.
|
||||
|
||||
Sideband Stale Data Propagator (SSDP)
|
||||
-------------------------------------
|
||||
The sideband stale data propagator (SSDP) is limited to the client (including
|
||||
Intel Xeon server E3) uncore implementation. The sideband response buffer is
|
||||
shared by all client cores. For non-coherent reads that go to sideband
|
||||
destinations, the uncore logic returns 64 bytes of data to the core, including
|
||||
both requested data and unrequested stale data, from a transaction buffer and
|
||||
the sideband response buffer. As a result, stale data from the sideband
|
||||
response and transaction buffers may now reside in a core fill buffer.
|
||||
|
||||
Primary Stale Data Propagator (PSDP)
|
||||
------------------------------------
|
||||
The primary stale data propagator (PSDP) is limited to the client (including
|
||||
Intel Xeon server E3) uncore implementation. Similar to the sideband response
|
||||
buffer, the primary response buffer is shared by all client cores. For some
|
||||
processors, MMIO primary reads will return 64 bytes of data to the core fill
|
||||
buffer including both requested data and unrequested stale data. This is
|
||||
similar to the sideband stale data propagator.
|
||||
|
||||
Vulnerabilities
|
||||
===============
|
||||
Device Register Partial Write (DRPW) (CVE-2022-21166)
|
||||
-----------------------------------------------------
|
||||
Some endpoint MMIO registers incorrectly handle writes that are smaller than
|
||||
the register size. Instead of aborting the write or only copying the correct
|
||||
subset of bytes (for example, 2 bytes for a 2-byte write), more bytes than
|
||||
specified by the write transaction may be written to the register. On
|
||||
processors affected by FBSDP, this may expose stale data from the fill buffers
|
||||
of the core that created the write transaction.
|
||||
|
||||
Shared Buffers Data Sampling (SBDS) (CVE-2022-21125)
|
||||
----------------------------------------------------
|
||||
After propagators may have moved data around the uncore and copied stale data
|
||||
into client core fill buffers, processors affected by MFBDS can leak data from
|
||||
the fill buffer. It is limited to the client (including Intel Xeon server E3)
|
||||
uncore implementation.
|
||||
|
||||
Shared Buffers Data Read (SBDR) (CVE-2022-21123)
|
||||
------------------------------------------------
|
||||
It is similar to Shared Buffer Data Sampling (SBDS) except that the data is
|
||||
directly read into the architectural software-visible state. It is limited to
|
||||
the client (including Intel Xeon server E3) uncore implementation.
|
||||
|
||||
Affected Processors
|
||||
===================
|
||||
Not all the CPUs are affected by all the variants. For instance, most
|
||||
processors for the server market (excluding Intel Xeon E3 processors) are
|
||||
impacted by only Device Register Partial Write (DRPW).
|
||||
|
||||
Below is the list of affected Intel processors [#f1]_:
|
||||
|
||||
=================== ============ =========
|
||||
Common name Family_Model Steppings
|
||||
=================== ============ =========
|
||||
HASWELL_X 06_3FH 2,4
|
||||
SKYLAKE_L 06_4EH 3
|
||||
BROADWELL_X 06_4FH All
|
||||
SKYLAKE_X 06_55H 3,4,6,7,11
|
||||
BROADWELL_D 06_56H 3,4,5
|
||||
SKYLAKE 06_5EH 3
|
||||
ICELAKE_X 06_6AH 4,5,6
|
||||
ICELAKE_D 06_6CH 1
|
||||
ICELAKE_L 06_7EH 5
|
||||
ATOM_TREMONT_D 06_86H All
|
||||
LAKEFIELD 06_8AH 1
|
||||
KABYLAKE_L 06_8EH 9 to 12
|
||||
ATOM_TREMONT 06_96H 1
|
||||
ATOM_TREMONT_L 06_9CH 0
|
||||
KABYLAKE 06_9EH 9 to 13
|
||||
COMETLAKE 06_A5H 2,3,5
|
||||
COMETLAKE_L 06_A6H 0,1
|
||||
ROCKETLAKE 06_A7H 1
|
||||
=================== ============ =========
|
||||
|
||||
If a CPU is in the affected processor list, but not affected by a variant, it
|
||||
is indicated by new bits in MSR IA32_ARCH_CAPABILITIES. As described in a later
|
||||
section, mitigation largely remains the same for all the variants, i.e. to
|
||||
clear the CPU fill buffers via VERW instruction.
|
||||
|
||||
New bits in MSRs
|
||||
================
|
||||
Newer processors and microcode update on existing affected processors added new
|
||||
bits to IA32_ARCH_CAPABILITIES MSR. These bits can be used to enumerate
|
||||
specific variants of Processor MMIO Stale Data vulnerabilities and mitigation
|
||||
capability.
|
||||
|
||||
MSR IA32_ARCH_CAPABILITIES
|
||||
--------------------------
|
||||
Bit 13 - SBDR_SSDP_NO - When set, processor is not affected by either the
|
||||
Shared Buffers Data Read (SBDR) vulnerability or the sideband stale
|
||||
data propagator (SSDP).
|
||||
Bit 14 - FBSDP_NO - When set, processor is not affected by the Fill Buffer
|
||||
Stale Data Propagator (FBSDP).
|
||||
Bit 15 - PSDP_NO - When set, processor is not affected by Primary Stale Data
|
||||
Propagator (PSDP).
|
||||
Bit 17 - FB_CLEAR - When set, VERW instruction will overwrite CPU fill buffer
|
||||
values as part of MD_CLEAR operations. Processors that do not
|
||||
enumerate MDS_NO (meaning they are affected by MDS) but that do
|
||||
enumerate support for both L1D_FLUSH and MD_CLEAR implicitly enumerate
|
||||
FB_CLEAR as part of their MD_CLEAR support.
|
||||
Bit 18 - FB_CLEAR_CTRL - Processor supports read and write to MSR
|
||||
IA32_MCU_OPT_CTRL[FB_CLEAR_DIS]. On such processors, the FB_CLEAR_DIS
|
||||
bit can be set to cause the VERW instruction to not perform the
|
||||
FB_CLEAR action. Not all processors that support FB_CLEAR will support
|
||||
FB_CLEAR_CTRL.
|
||||
|
||||
MSR IA32_MCU_OPT_CTRL
|
||||
---------------------
|
||||
Bit 3 - FB_CLEAR_DIS - When set, VERW instruction does not perform the FB_CLEAR
|
||||
action. This may be useful to reduce the performance impact of FB_CLEAR in
|
||||
cases where system software deems it warranted (for example, when performance
|
||||
is more critical, or the untrusted software has no MMIO access). Note that
|
||||
FB_CLEAR_DIS has no impact on enumeration (for example, it does not change
|
||||
FB_CLEAR or MD_CLEAR enumeration) and it may not be supported on all processors
|
||||
that enumerate FB_CLEAR.
|
||||
|
||||
Mitigation
|
||||
==========
|
||||
Like MDS, all variants of Processor MMIO Stale Data vulnerabilities have the
|
||||
same mitigation strategy to force the CPU to clear the affected buffers before
|
||||
an attacker can extract the secrets.
|
||||
|
||||
This is achieved by using the otherwise unused and obsolete VERW instruction in
|
||||
combination with a microcode update. The microcode clears the affected CPU
|
||||
buffers when the VERW instruction is executed.
|
||||
|
||||
Kernel reuses the MDS function to invoke the buffer clearing:
|
||||
|
||||
mds_clear_cpu_buffers()
|
||||
|
||||
On MDS affected CPUs, the kernel already invokes CPU buffer clear on
|
||||
kernel/userspace, hypervisor/guest and C-state (idle) transitions. No
|
||||
additional mitigation is needed on such CPUs.
|
||||
|
||||
For CPUs not affected by MDS or TAA, mitigation is needed only for the attacker
|
||||
with MMIO capability. Therefore, VERW is not required for kernel/userspace. For
|
||||
virtualization case, VERW is only needed at VMENTER for a guest with MMIO
|
||||
capability.
|
||||
|
||||
Mitigation points
|
||||
-----------------
|
||||
Return to user space
|
||||
^^^^^^^^^^^^^^^^^^^^
|
||||
Same mitigation as MDS when affected by MDS/TAA, otherwise no mitigation
|
||||
needed.
|
||||
|
||||
C-State transition
|
||||
^^^^^^^^^^^^^^^^^^
|
||||
Control register writes by CPU during C-state transition can propagate data
|
||||
from fill buffer to uncore buffers. Execute VERW before C-state transition to
|
||||
clear CPU fill buffers.
|
||||
|
||||
Guest entry point
|
||||
^^^^^^^^^^^^^^^^^
|
||||
Same mitigation as MDS when processor is also affected by MDS/TAA, otherwise
|
||||
execute VERW at VMENTER only for MMIO capable guests. On CPUs not affected by
|
||||
MDS/TAA, guest without MMIO access cannot extract secrets using Processor MMIO
|
||||
Stale Data vulnerabilities, so there is no need to execute VERW for such guests.
|
||||
|
||||
Mitigation control on the kernel command line
|
||||
---------------------------------------------
|
||||
The kernel command line allows to control the Processor MMIO Stale Data
|
||||
mitigations at boot time with the option "mmio_stale_data=". The valid
|
||||
arguments for this option are:
|
||||
|
||||
========== =================================================================
|
||||
full If the CPU is vulnerable, enable mitigation; CPU buffer clearing
|
||||
on exit to userspace and when entering a VM. Idle transitions are
|
||||
protected as well. It does not automatically disable SMT.
|
||||
full,nosmt Same as full, with SMT disabled on vulnerable CPUs. This is the
|
||||
complete mitigation.
|
||||
off Disables mitigation completely.
|
||||
========== =================================================================
|
||||
|
||||
If the CPU is affected and mmio_stale_data=off is not supplied on the kernel
|
||||
command line, then the kernel selects the appropriate mitigation.
|
||||
|
||||
Mitigation status information
|
||||
-----------------------------
|
||||
The Linux kernel provides a sysfs interface to enumerate the current
|
||||
vulnerability status of the system: whether the system is vulnerable, and
|
||||
which mitigations are active. The relevant sysfs file is:
|
||||
|
||||
/sys/devices/system/cpu/vulnerabilities/mmio_stale_data
|
||||
|
||||
The possible values in this file are:
|
||||
|
||||
.. list-table::
|
||||
|
||||
* - 'Not affected'
|
||||
- The processor is not vulnerable
|
||||
* - 'Vulnerable'
|
||||
- The processor is vulnerable, but no mitigation enabled
|
||||
* - 'Vulnerable: Clear CPU buffers attempted, no microcode'
|
||||
- The processor is vulnerable, but microcode is not updated. The
|
||||
mitigation is enabled on a best effort basis.
|
||||
* - 'Mitigation: Clear CPU buffers'
|
||||
- The processor is vulnerable and the CPU buffer clearing mitigation is
|
||||
enabled.
|
||||
|
||||
If the processor is vulnerable then the following information is appended to
|
||||
the above information:
|
||||
|
||||
======================== ===========================================
|
||||
'SMT vulnerable' SMT is enabled
|
||||
'SMT disabled' SMT is disabled
|
||||
'SMT Host state unknown' Kernel runs in a VM, Host SMT state unknown
|
||||
======================== ===========================================
|
||||
|
||||
References
|
||||
----------
|
||||
.. [#f1] Affected Processors
|
||||
https://www.intel.com/content/www/us/en/developer/topic-technology/software-security-guidance/processors-affected-consolidated-product-cpu-model.html
|
||||
@@ -3019,6 +3019,7 @@
|
||||
kvm.nx_huge_pages=off [X86]
|
||||
no_entry_flush [PPC]
|
||||
no_uaccess_flush [PPC]
|
||||
mmio_stale_data=off [X86]
|
||||
|
||||
Exceptions:
|
||||
This does not have any effect on
|
||||
@@ -3040,6 +3041,7 @@
|
||||
Equivalent to: l1tf=flush,nosmt [X86]
|
||||
mds=full,nosmt [X86]
|
||||
tsx_async_abort=full,nosmt [X86]
|
||||
mmio_stale_data=full,nosmt [X86]
|
||||
|
||||
mminit_loglevel=
|
||||
[KNL] When CONFIG_DEBUG_MEMORY_INIT is set, this
|
||||
@@ -3049,6 +3051,40 @@
|
||||
log everything. Information is printed at KERN_DEBUG
|
||||
so loglevel=8 may also need to be specified.
|
||||
|
||||
mmio_stale_data=
|
||||
[X86,INTEL] Control mitigation for the Processor
|
||||
MMIO Stale Data vulnerabilities.
|
||||
|
||||
Processor MMIO Stale Data is a class of
|
||||
vulnerabilities that may expose data after an MMIO
|
||||
operation. Exposed data could originate or end in
|
||||
the same CPU buffers as affected by MDS and TAA.
|
||||
Therefore, similar to MDS and TAA, the mitigation
|
||||
is to clear the affected CPU buffers.
|
||||
|
||||
This parameter controls the mitigation. The
|
||||
options are:
|
||||
|
||||
full - Enable mitigation on vulnerable CPUs
|
||||
|
||||
full,nosmt - Enable mitigation and disable SMT on
|
||||
vulnerable CPUs.
|
||||
|
||||
off - Unconditionally disable mitigation
|
||||
|
||||
On MDS or TAA affected machines,
|
||||
mmio_stale_data=off can be prevented by an active
|
||||
MDS or TAA mitigation as these vulnerabilities are
|
||||
mitigated with the same mechanism so in order to
|
||||
disable this mitigation, you need to specify
|
||||
mds=off and tsx_async_abort=off too.
|
||||
|
||||
Not specifying this option is equivalent to
|
||||
mmio_stale_data=full.
|
||||
|
||||
For details see:
|
||||
Documentation/admin-guide/hw-vuln/processor_mmio_stale_data.rst
|
||||
|
||||
module.sig_enforce
|
||||
[KNL] When CONFIG_MODULE_SIG is set, this means that
|
||||
modules without (valid) signatures will fail to load.
|
||||
|
||||
@@ -161,7 +161,7 @@ finally:
|
||||
#
|
||||
# This is also used if you do content translation via gettext catalogs.
|
||||
# Usually you set "language" from the command line for these cases.
|
||||
language = None
|
||||
language = 'en'
|
||||
|
||||
# There are two options for replacing |today|: either, you set today to some
|
||||
# non-false value, then it is used:
|
||||
|
||||
@@ -72,6 +72,7 @@ examples:
|
||||
dc-gpios = <&gpio 43 GPIO_ACTIVE_HIGH>;
|
||||
reset-gpios = <&gpio 80 GPIO_ACTIVE_HIGH>;
|
||||
rotation = <270>;
|
||||
backlight = <&backlight>;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -9,8 +9,9 @@ Required properties:
|
||||
- The second cell is reserved and is currently unused.
|
||||
- gpio-controller : Marks the device node as a GPIO controller.
|
||||
- interrupt-controller: Mark the device node as an interrupt controller
|
||||
- #interrupt-cells : Should be 1. The interrupt type is fixed in the hardware.
|
||||
- #interrupt-cells : Should be 2. The interrupt type is fixed in the hardware.
|
||||
- The first cell is the GPIO offset number within the GPIO controller.
|
||||
- The second cell is the interrupt trigger type and level flags.
|
||||
- interrupts: Specify the interrupt.
|
||||
- altr,interrupt-type: Specifies the interrupt trigger type the GPIO
|
||||
hardware is synthesized. This field is required if the Altera GPIO controller
|
||||
@@ -38,6 +39,6 @@ gpio_altr: gpio@ff200000 {
|
||||
altr,interrupt-type = <IRQ_TYPE_EDGE_RISING>;
|
||||
#gpio-cells = <2>;
|
||||
gpio-controller;
|
||||
#interrupt-cells = <1>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupt-controller;
|
||||
};
|
||||
|
||||
@@ -31,7 +31,7 @@ properties:
|
||||
$ref: "regulator.yaml#"
|
||||
|
||||
properties:
|
||||
regulator-name:
|
||||
regulator-compatible:
|
||||
pattern: "^vbuck[1-4]$"
|
||||
|
||||
additionalProperties: false
|
||||
@@ -55,7 +55,7 @@ examples:
|
||||
regulator-min-microvolt = <300000>;
|
||||
regulator-max-microvolt = <1193750>;
|
||||
regulator-enable-ramp-delay = <256>;
|
||||
regulator-allowed-modes = <0 1 2 4>;
|
||||
regulator-allowed-modes = <0 1 2>;
|
||||
};
|
||||
|
||||
vbuck3 {
|
||||
@@ -63,7 +63,7 @@ examples:
|
||||
regulator-min-microvolt = <300000>;
|
||||
regulator-max-microvolt = <1193750>;
|
||||
regulator-enable-ramp-delay = <256>;
|
||||
regulator-allowed-modes = <0 1 2 4>;
|
||||
regulator-allowed-modes = <0 1 2>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -45,6 +45,7 @@ properties:
|
||||
maxItems: 2
|
||||
|
||||
interconnect-names:
|
||||
minItems: 1
|
||||
items:
|
||||
- const: qspi-config
|
||||
- const: qspi-memory
|
||||
|
||||
@@ -197,6 +197,7 @@ fault_type=%d Support configuring fault injection type, should be
|
||||
FAULT_DISCARD 0x000002000
|
||||
FAULT_WRITE_IO 0x000004000
|
||||
FAULT_SLAB_ALLOC 0x000008000
|
||||
FAULT_DQUOT_INIT 0x000010000
|
||||
=================== ===========
|
||||
mode=%s Control block allocation mode which supports "adaptive"
|
||||
and "lfs". In "lfs" mode, there should be no random
|
||||
|
||||
@@ -2237,7 +2237,7 @@ implicit_fb
|
||||
Apply the generic implicit feedback sync mode. When this is set
|
||||
and the playback stream sync mode is ASYNC, the driver tries to
|
||||
tie an adjacent ASYNC capture stream as the implicit feedback
|
||||
source.
|
||||
source. This is equivalent with quirk_flags bit 17.
|
||||
use_vmalloc
|
||||
Use vmalloc() for allocations of the PCM buffers (default: yes).
|
||||
For architectures with non-coherent memory like ARM or MIPS, the
|
||||
@@ -2279,6 +2279,8 @@ quirk_flags
|
||||
* bit 14: Ignore errors for mixer access
|
||||
* bit 15: Support generic DSD raw U32_BE format
|
||||
* bit 16: Set up the interface at first like UAC1
|
||||
* bit 17: Apply the generic implicit feedback sync mode
|
||||
* bit 18: Don't apply implicit feedback sync mode
|
||||
|
||||
This module supports multiple devices, autoprobe and hotplugging.
|
||||
|
||||
|
||||
@@ -267,8 +267,8 @@ restrict such paths with dedicated ruleset flags.
|
||||
Ruleset layers
|
||||
--------------
|
||||
|
||||
There is a limit of 64 layers of stacked rulesets. This can be an issue for a
|
||||
task willing to enforce a new ruleset in complement to its 64 inherited
|
||||
There is a limit of 16 layers of stacked rulesets. This can be an issue for a
|
||||
task willing to enforce a new ruleset in complement to its 16 inherited
|
||||
rulesets. Once this limit is reached, sys_landlock_restrict_self() returns
|
||||
E2BIG. It is then strongly suggested to carefully build rulesets once in the
|
||||
life of a thread, especially for applications able to launch other applications
|
||||
|
||||
2
Makefile
2
Makefile
@@ -1,7 +1,7 @@
|
||||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 15
|
||||
SUBLEVEL = 45
|
||||
SUBLEVEL = 48
|
||||
EXTRAVERSION =
|
||||
NAME = Trick or Treat
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@ extern void clear_page(void *page);
|
||||
#define clear_user_page(page, vaddr, pg) clear_page(page)
|
||||
|
||||
#define alloc_zeroed_user_highpage_movable(vma, vaddr) \
|
||||
alloc_page_vma(GFP_HIGHUSER_MOVABLE | __GFP_ZERO, vma, vmaddr)
|
||||
alloc_page_vma(GFP_HIGHUSER_MOVABLE | __GFP_ZERO, vma, vaddr)
|
||||
#define __HAVE_ARCH_ALLOC_ZEROED_USER_HIGHPAGE_MOVABLE
|
||||
|
||||
extern void copy_page(void * _to, void * _from);
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
&mac0 {
|
||||
status = "okay";
|
||||
|
||||
phy-mode = "rgmii";
|
||||
phy-mode = "rgmii-rxid";
|
||||
phy-handle = <ðphy0>;
|
||||
|
||||
pinctrl-names = "default";
|
||||
@@ -114,7 +114,7 @@
|
||||
&mac1 {
|
||||
status = "okay";
|
||||
|
||||
phy-mode = "rgmii";
|
||||
phy-mode = "rgmii-rxid";
|
||||
phy-handle = <ðphy1>;
|
||||
|
||||
pinctrl-names = "default";
|
||||
|
||||
@@ -53,18 +53,17 @@
|
||||
"GPIO18",
|
||||
"NC", /* GPIO19 */
|
||||
"NC", /* GPIO20 */
|
||||
"GPIO21",
|
||||
"CAM_GPIO0",
|
||||
"GPIO22",
|
||||
"GPIO23",
|
||||
"GPIO24",
|
||||
"GPIO25",
|
||||
"NC", /* GPIO26 */
|
||||
"CAM_GPIO0",
|
||||
/* Binary number representing build/revision */
|
||||
"CONFIG0",
|
||||
"CONFIG1",
|
||||
"CONFIG2",
|
||||
"CONFIG3",
|
||||
"GPIO27",
|
||||
"GPIO28",
|
||||
"GPIO29",
|
||||
"GPIO30",
|
||||
"GPIO31",
|
||||
"NC", /* GPIO32 */
|
||||
"NC", /* GPIO33 */
|
||||
"NC", /* GPIO34 */
|
||||
|
||||
@@ -74,16 +74,18 @@
|
||||
"GPIO27",
|
||||
"SDA0",
|
||||
"SCL0",
|
||||
"NC", /* GPIO30 */
|
||||
"NC", /* GPIO31 */
|
||||
"NC", /* GPIO32 */
|
||||
"NC", /* GPIO33 */
|
||||
"NC", /* GPIO34 */
|
||||
"NC", /* GPIO35 */
|
||||
"NC", /* GPIO36 */
|
||||
"NC", /* GPIO37 */
|
||||
"NC", /* GPIO38 */
|
||||
"NC", /* GPIO39 */
|
||||
/* Used by BT module */
|
||||
"CTS0",
|
||||
"RTS0",
|
||||
"TXD0",
|
||||
"RXD0",
|
||||
/* Used by Wifi */
|
||||
"SD1_CLK",
|
||||
"SD1_CMD",
|
||||
"SD1_DATA0",
|
||||
"SD1_DATA1",
|
||||
"SD1_DATA2",
|
||||
"SD1_DATA3",
|
||||
"CAM_GPIO1", /* GPIO40 */
|
||||
"WL_ON", /* GPIO41 */
|
||||
"NC", /* GPIO42 */
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#gpio-cells = <2>;
|
||||
gpio-line-names = "BT_ON",
|
||||
"WL_ON",
|
||||
"STATUS_LED_R",
|
||||
"PWR_LED_R",
|
||||
"LAN_RUN",
|
||||
"",
|
||||
"CAM_GPIO0",
|
||||
|
||||
@@ -63,8 +63,8 @@
|
||||
"GPIO43",
|
||||
"GPIO44",
|
||||
"GPIO45",
|
||||
"GPIO46",
|
||||
"GPIO47",
|
||||
"SMPS_SCL",
|
||||
"SMPS_SDA",
|
||||
/* Used by eMMC */
|
||||
"SD_CLK_R",
|
||||
"SD_CMD_R",
|
||||
|
||||
@@ -423,14 +423,14 @@
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
cru@100 {
|
||||
compatible = "simple-bus";
|
||||
cru-bus@100 {
|
||||
compatible = "brcm,ns-cru", "simple-mfd";
|
||||
reg = <0x100 0x1a4>;
|
||||
ranges;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
lcpll0: lcpll0@100 {
|
||||
lcpll0: clock-controller@100 {
|
||||
#clock-cells = <1>;
|
||||
compatible = "brcm,nsp-lcpll0";
|
||||
reg = <0x100 0x14>;
|
||||
@@ -439,7 +439,7 @@
|
||||
"sdio", "ddr_phy";
|
||||
};
|
||||
|
||||
genpll: genpll@140 {
|
||||
genpll: clock-controller@140 {
|
||||
#clock-cells = <1>;
|
||||
compatible = "brcm,nsp-genpll";
|
||||
reg = <0x140 0x24>;
|
||||
@@ -450,7 +450,12 @@
|
||||
"sata1", "sata2";
|
||||
};
|
||||
|
||||
pinctrl: pin-controller@1c0 {
|
||||
syscon@180 {
|
||||
compatible = "brcm,cru-clkset", "syscon";
|
||||
reg = <0x180 0x4>;
|
||||
};
|
||||
|
||||
pinctrl: pinctrl@1c0 {
|
||||
compatible = "brcm,bcm4708-pinmux";
|
||||
reg = <0x1c0 0x24>;
|
||||
reg-names = "cru_gpio_control";
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
samsung,i2c-max-bus-freq = <20000>;
|
||||
|
||||
eeprom@50 {
|
||||
compatible = "samsung,s524ad0xd1";
|
||||
compatible = "samsung,s524ad0xd1", "atmel,24c128";
|
||||
reg = <0x50>;
|
||||
};
|
||||
|
||||
@@ -289,7 +289,7 @@
|
||||
samsung,i2c-max-bus-freq = <20000>;
|
||||
|
||||
eeprom@51 {
|
||||
compatible = "samsung,s524ad0xd1";
|
||||
compatible = "samsung,s524ad0xd1", "atmel,24c128";
|
||||
reg = <0x51>;
|
||||
};
|
||||
|
||||
|
||||
@@ -297,7 +297,11 @@
|
||||
phy-mode = "rmii";
|
||||
phy-reset-gpios = <&gpio1 18 GPIO_ACTIVE_LOW>;
|
||||
phy-handle = <&phy>;
|
||||
clocks = <&clks IMX6QDL_CLK_ENET>, <&clks IMX6QDL_CLK_ENET>, <&rmii_clk>;
|
||||
clocks = <&clks IMX6QDL_CLK_ENET>,
|
||||
<&clks IMX6QDL_CLK_ENET>,
|
||||
<&rmii_clk>,
|
||||
<&clks IMX6QDL_CLK_ENET_REF>;
|
||||
clock-names = "ipg", "ahb", "ptp", "enet_out";
|
||||
status = "okay";
|
||||
|
||||
mdio {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// SPDX-License-Identifier: GPL-2.0+ OR MIT
|
||||
/*
|
||||
* Copyright 2014-2020 Toradex
|
||||
* Copyright 2014-2022 Toradex
|
||||
* Copyright 2012 Freescale Semiconductor, Inc.
|
||||
* Copyright 2011 Linaro Ltd.
|
||||
*/
|
||||
@@ -132,7 +132,7 @@
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default", "gpio";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
pinctrl-0 = <&pinctrl_i2c2_gpio>;
|
||||
pinctrl-1 = <&pinctrl_i2c2_gpio>;
|
||||
scl-gpios = <&gpio2 30 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
|
||||
sda-gpios = <&gpio3 16 (GPIO_ACTIVE_HIGH | GPIO_OPEN_DRAIN)>;
|
||||
status = "okay";
|
||||
@@ -488,7 +488,7 @@
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c2_gpio: i2c2grp {
|
||||
pinctrl_i2c2_gpio: i2c2gpiogrp {
|
||||
fsl,pins = <
|
||||
MX6QDL_PAD_EIM_EB2__GPIO2_IO30 0x4001b8b1
|
||||
MX6QDL_PAD_EIM_D16__GPIO3_IO16 0x4001b8b1
|
||||
|
||||
@@ -287,7 +287,7 @@
|
||||
clocks = <&armclk>;
|
||||
};
|
||||
|
||||
gic: gic@1000 {
|
||||
gic: interrupt-controller@1000 {
|
||||
compatible = "arm,arm11mp-gic";
|
||||
interrupt-controller;
|
||||
#interrupt-cells = <3>;
|
||||
|
||||
@@ -564,7 +564,6 @@
|
||||
reset-gpios = <&mp05 5 GPIO_ACTIVE_LOW>;
|
||||
vdd3-supply = <&ldo7_reg>;
|
||||
vci-supply = <&ldo17_reg>;
|
||||
spi-cs-high;
|
||||
spi-max-frequency = <1200000>;
|
||||
|
||||
pinctrl-names = "default";
|
||||
@@ -636,7 +635,7 @@
|
||||
};
|
||||
|
||||
&i2s0 {
|
||||
dmas = <&pdma0 9>, <&pdma0 10>, <&pdma0 11>;
|
||||
dmas = <&pdma0 10>, <&pdma0 9>, <&pdma0 11>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
|
||||
@@ -239,8 +239,8 @@
|
||||
reg = <0xeee30000 0x1000>;
|
||||
interrupt-parent = <&vic2>;
|
||||
interrupts = <16>;
|
||||
dma-names = "rx", "tx", "tx-sec";
|
||||
dmas = <&pdma1 9>, <&pdma1 10>, <&pdma1 11>;
|
||||
dma-names = "tx", "rx", "tx-sec";
|
||||
dmas = <&pdma1 10>, <&pdma1 9>, <&pdma1 11>;
|
||||
clock-names = "iis",
|
||||
"i2s_opclk0",
|
||||
"i2s_opclk1";
|
||||
@@ -259,8 +259,8 @@
|
||||
reg = <0xe2100000 0x1000>;
|
||||
interrupt-parent = <&vic2>;
|
||||
interrupts = <17>;
|
||||
dma-names = "rx", "tx";
|
||||
dmas = <&pdma1 12>, <&pdma1 13>;
|
||||
dma-names = "tx", "rx";
|
||||
dmas = <&pdma1 13>, <&pdma1 12>;
|
||||
clock-names = "iis", "i2s_opclk0";
|
||||
clocks = <&clocks CLK_I2S1>, <&clocks SCLK_AUDIO1>;
|
||||
pinctrl-names = "default";
|
||||
@@ -274,8 +274,8 @@
|
||||
reg = <0xe2a00000 0x1000>;
|
||||
interrupt-parent = <&vic2>;
|
||||
interrupts = <18>;
|
||||
dma-names = "rx", "tx";
|
||||
dmas = <&pdma1 14>, <&pdma1 15>;
|
||||
dma-names = "tx", "rx";
|
||||
dmas = <&pdma1 15>, <&pdma1 14>;
|
||||
clock-names = "iis", "i2s_opclk0";
|
||||
clocks = <&clocks CLK_I2S2>, <&clocks SCLK_AUDIO2>;
|
||||
pinctrl-names = "default";
|
||||
|
||||
@@ -553,7 +553,6 @@
|
||||
#interrupt-cells = <3>;
|
||||
#address-cells = <0>;
|
||||
interrupt-controller;
|
||||
interrupt-parent;
|
||||
reg = <0xe8c11000 0x1000>,
|
||||
<0xe8c12000 0x2000>;
|
||||
};
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
<0xff113000 0x1000>;
|
||||
};
|
||||
|
||||
intc: intc@fffed000 {
|
||||
intc: interrupt-controller@fffed000 {
|
||||
compatible = "arm,cortex-a9-gic";
|
||||
#interrupt-cells = <3>;
|
||||
interrupt-controller;
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
<0xff113000 0x1000>;
|
||||
};
|
||||
|
||||
intc: intc@ffffd000 {
|
||||
intc: interrupt-controller@ffffd000 {
|
||||
compatible = "arm,cortex-a9-gic";
|
||||
#interrupt-cells = <3>;
|
||||
interrupt-controller;
|
||||
|
||||
@@ -141,6 +141,7 @@
|
||||
compatible = "snps,dwmac-mdio";
|
||||
reset-gpios = <&gpioz 2 GPIO_ACTIVE_LOW>;
|
||||
reset-delay-us = <1000>;
|
||||
reset-post-delay-us = <1000>;
|
||||
|
||||
phy0: ethernet-phy@7 {
|
||||
reg = <7>;
|
||||
|
||||
@@ -104,8 +104,10 @@
|
||||
|
||||
wdt: watchdog@1c20ca0 {
|
||||
compatible = "allwinner,suniv-f1c100s-wdt",
|
||||
"allwinner,sun4i-a10-wdt";
|
||||
"allwinner,sun6i-a31-wdt";
|
||||
reg = <0x01c20ca0 0x20>;
|
||||
interrupts = <16>;
|
||||
clocks = <&osc32k>;
|
||||
};
|
||||
|
||||
uart0: serial@1c25000 {
|
||||
|
||||
@@ -708,6 +708,7 @@ static_assert(offsetof(siginfo_t, si_upper) == 0x18);
|
||||
static_assert(offsetof(siginfo_t, si_pkey) == 0x14);
|
||||
static_assert(offsetof(siginfo_t, si_perf_data) == 0x10);
|
||||
static_assert(offsetof(siginfo_t, si_perf_type) == 0x14);
|
||||
static_assert(offsetof(siginfo_t, si_perf_flags) == 0x18);
|
||||
static_assert(offsetof(siginfo_t, si_band) == 0x0c);
|
||||
static_assert(offsetof(siginfo_t, si_fd) == 0x10);
|
||||
static_assert(offsetof(siginfo_t, si_call_addr) == 0x0c);
|
||||
|
||||
@@ -67,14 +67,17 @@ static void __init hi3xxx_smp_prepare_cpus(unsigned int max_cpus)
|
||||
}
|
||||
ctrl_base = of_iomap(np, 0);
|
||||
if (!ctrl_base) {
|
||||
of_node_put(np);
|
||||
pr_err("failed to map address\n");
|
||||
return;
|
||||
}
|
||||
if (of_property_read_u32(np, "smp-offset", &offset) < 0) {
|
||||
of_node_put(np);
|
||||
pr_err("failed to find smp-offset property\n");
|
||||
return;
|
||||
}
|
||||
ctrl_base += offset;
|
||||
of_node_put(np);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -160,6 +163,7 @@ static int hip01_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
||||
if (WARN_ON(!node))
|
||||
return -1;
|
||||
ctrl_base = of_iomap(node, 0);
|
||||
of_node_put(node);
|
||||
|
||||
/* set the secondary core boot from DDR */
|
||||
remap_reg_value = readl_relaxed(ctrl_base + REG_SC_CTRL);
|
||||
|
||||
@@ -30,6 +30,7 @@ config MACH_MT7623
|
||||
config MACH_MT7629
|
||||
bool "MediaTek MT7629 SoCs support"
|
||||
default ARCH_MEDIATEK
|
||||
select HAVE_ARM_ARCH_TIMER
|
||||
|
||||
config MACH_MT8127
|
||||
bool "MediaTek MT8127 SoCs support"
|
||||
|
||||
@@ -41,7 +41,7 @@ static DEFINE_SPINLOCK(clockfw_lock);
|
||||
unsigned long omap1_uart_recalc(struct clk *clk)
|
||||
{
|
||||
unsigned int val = __raw_readl(clk->enable_reg);
|
||||
return val & clk->enable_bit ? 48000000 : 12000000;
|
||||
return val & 1 << clk->enable_bit ? 48000000 : 12000000;
|
||||
}
|
||||
|
||||
unsigned long omap1_sossi_recalc(struct clk *clk)
|
||||
|
||||
@@ -354,13 +354,13 @@ static struct platform_device cm_x300_spi_gpio = {
|
||||
static struct gpiod_lookup_table cm_x300_spi_gpiod_table = {
|
||||
.dev_id = "spi_gpio",
|
||||
.table = {
|
||||
GPIO_LOOKUP("gpio-pxa", GPIO_LCD_SCL,
|
||||
GPIO_LOOKUP("pca9555.1", GPIO_LCD_SCL - GPIO_LCD_BASE,
|
||||
"sck", GPIO_ACTIVE_HIGH),
|
||||
GPIO_LOOKUP("gpio-pxa", GPIO_LCD_DIN,
|
||||
GPIO_LOOKUP("pca9555.1", GPIO_LCD_DIN - GPIO_LCD_BASE,
|
||||
"mosi", GPIO_ACTIVE_HIGH),
|
||||
GPIO_LOOKUP("gpio-pxa", GPIO_LCD_DOUT,
|
||||
GPIO_LOOKUP("pca9555.1", GPIO_LCD_DOUT - GPIO_LCD_BASE,
|
||||
"miso", GPIO_ACTIVE_HIGH),
|
||||
GPIO_LOOKUP("gpio-pxa", GPIO_LCD_CS,
|
||||
GPIO_LOOKUP("pca9555.1", GPIO_LCD_CS - GPIO_LCD_BASE,
|
||||
"cs", GPIO_ACTIVE_HIGH),
|
||||
{ },
|
||||
},
|
||||
|
||||
@@ -681,7 +681,7 @@ static struct platform_device bq24022 = {
|
||||
static struct gpiod_lookup_table bq24022_gpiod_table = {
|
||||
.dev_id = "gpio-regulator",
|
||||
.table = {
|
||||
GPIO_LOOKUP("gpio-pxa", EGPIO_MAGICIAN_BQ24022_ISET2,
|
||||
GPIO_LOOKUP("htc-egpio-0", EGPIO_MAGICIAN_BQ24022_ISET2 - MAGICIAN_EGPIO_BASE,
|
||||
NULL, GPIO_ACTIVE_HIGH),
|
||||
GPIO_LOOKUP("gpio-pxa", GPIO30_MAGICIAN_BQ24022_nCHARGE_EN,
|
||||
"enable", GPIO_ACTIVE_LOW),
|
||||
|
||||
@@ -296,9 +296,9 @@ static struct gpiod_lookup_table tosa_mci_gpio_table = {
|
||||
.table = {
|
||||
GPIO_LOOKUP("gpio-pxa", TOSA_GPIO_nSD_DETECT,
|
||||
"cd", GPIO_ACTIVE_LOW),
|
||||
GPIO_LOOKUP("gpio-pxa", TOSA_GPIO_SD_WP,
|
||||
GPIO_LOOKUP("sharp-scoop.0", TOSA_GPIO_SD_WP - TOSA_SCOOP_GPIO_BASE,
|
||||
"wp", GPIO_ACTIVE_LOW),
|
||||
GPIO_LOOKUP("gpio-pxa", TOSA_GPIO_PWR_ON,
|
||||
GPIO_LOOKUP("sharp-scoop.0", TOSA_GPIO_PWR_ON - TOSA_SCOOP_GPIO_BASE,
|
||||
"power", GPIO_ACTIVE_HIGH),
|
||||
{ },
|
||||
},
|
||||
|
||||
@@ -144,6 +144,7 @@ static int __init dcscb_init(void)
|
||||
if (!node)
|
||||
return -ENODEV;
|
||||
dcscb_base = of_iomap(node, 0);
|
||||
of_node_put(node);
|
||||
if (!dcscb_base)
|
||||
return -EADDRNOTAVAIL;
|
||||
cfg = readl_relaxed(dcscb_base + DCS_CFG_R);
|
||||
|
||||
@@ -259,6 +259,7 @@ config ARCH_INTEL_SOCFPGA
|
||||
|
||||
config ARCH_SYNQUACER
|
||||
bool "Socionext SynQuacer SoC Family"
|
||||
select IRQ_FASTEOI_HIERARCHY_HANDLERS
|
||||
|
||||
config ARCH_TEGRA
|
||||
bool "NVIDIA Tegra SoC Family"
|
||||
|
||||
@@ -71,10 +71,6 @@
|
||||
|
||||
&spi0 {
|
||||
flash@0 {
|
||||
spi-max-frequency = <108000000>;
|
||||
spi-rx-bus-width = <4>;
|
||||
spi-tx-bus-width = <4>;
|
||||
|
||||
partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
@@ -112,7 +108,6 @@
|
||||
|
||||
&usb3 {
|
||||
usb-phy = <&usb3_phy>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&mdio {
|
||||
|
||||
@@ -433,7 +433,7 @@
|
||||
clock-names = "spi", "sf", "axi";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
status = "disable";
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
i2c3: i2c3@11cb0000 {
|
||||
|
||||
@@ -1355,8 +1355,9 @@
|
||||
<&tegra_car TEGRA210_CLK_DFLL_REF>,
|
||||
<&tegra_car TEGRA210_CLK_I2C5>;
|
||||
clock-names = "soc", "ref", "i2c";
|
||||
resets = <&tegra_car TEGRA210_RST_DFLL_DVCO>;
|
||||
reset-names = "dvco";
|
||||
resets = <&tegra_car TEGRA210_RST_DFLL_DVCO>,
|
||||
<&tegra_car 155>;
|
||||
reset-names = "dvco", "dfll";
|
||||
#clock-cells = <0>;
|
||||
clock-output-names = "dfllCPU_out";
|
||||
status = "disabled";
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
clocks {
|
||||
sleep_clk: sleep_clk {
|
||||
compatible = "fixed-clock";
|
||||
clock-frequency = <32000>;
|
||||
clock-frequency = <32768>;
|
||||
#clock-cells = <0>;
|
||||
};
|
||||
|
||||
|
||||
@@ -183,8 +183,8 @@
|
||||
no-map;
|
||||
};
|
||||
|
||||
cont_splash_mem: memory@3800000 {
|
||||
reg = <0 0x03800000 0 0x2400000>;
|
||||
cont_splash_mem: memory@3401000 {
|
||||
reg = <0 0x03401000 0 0x2200000>;
|
||||
no-map;
|
||||
};
|
||||
|
||||
@@ -498,7 +498,7 @@
|
||||
#dma-cells = <1>;
|
||||
qcom,ee = <0>;
|
||||
qcom,controlled-remotely;
|
||||
num-channels = <18>;
|
||||
num-channels = <24>;
|
||||
qcom,num-ees = <4>;
|
||||
};
|
||||
|
||||
@@ -634,7 +634,7 @@
|
||||
#dma-cells = <1>;
|
||||
qcom,ee = <0>;
|
||||
qcom,controlled-remotely;
|
||||
num-channels = <18>;
|
||||
num-channels = <24>;
|
||||
qcom,num-ees = <4>;
|
||||
};
|
||||
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
};
|
||||
|
||||
/* Fixed crystal oscillator dedicated to MCP2518FD */
|
||||
clk40M: can_clock {
|
||||
clk40M: can-clock {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
clock-frequency = <40000000>;
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
panel@0 {
|
||||
compatible = "tianma,fhd-video";
|
||||
reg = <0>;
|
||||
vddi0-supply = <&vreg_l14a_1p8>;
|
||||
vddio-supply = <&vreg_l14a_1p8>;
|
||||
vddpos-supply = <&lab>;
|
||||
vddneg-supply = <&ibb>;
|
||||
|
||||
|
||||
@@ -1477,6 +1477,7 @@
|
||||
reg = <0xf780 0x24>;
|
||||
clocks = <&sdhci>;
|
||||
clock-names = "emmcclk";
|
||||
drive-impedance-ohm = <50>;
|
||||
#phy-cells = <0>;
|
||||
status = "disabled";
|
||||
};
|
||||
@@ -1487,7 +1488,6 @@
|
||||
clock-names = "refclk";
|
||||
#phy-cells = <1>;
|
||||
resets = <&cru SRST_PCIEPHY>;
|
||||
drive-impedance-ohm = <50>;
|
||||
reset-names = "phy";
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
compatible = "ti,am64-uart", "ti,am654-uart";
|
||||
reg = <0x00 0x04a00000 0x00 0x100>;
|
||||
interrupts = <GIC_SPI 185 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clock-frequency = <48000000>;
|
||||
current-speed = <115200>;
|
||||
power-domains = <&k3_pds 149 TI_SCI_PD_EXCLUSIVE>;
|
||||
clocks = <&k3_clks 149 0>;
|
||||
@@ -21,7 +20,6 @@
|
||||
compatible = "ti,am64-uart", "ti,am654-uart";
|
||||
reg = <0x00 0x04a10000 0x00 0x100>;
|
||||
interrupts = <GIC_SPI 186 IRQ_TYPE_LEVEL_HIGH>;
|
||||
clock-frequency = <48000000>;
|
||||
current-speed = <115200>;
|
||||
power-domains = <&k3_pds 160 TI_SCI_PD_EXCLUSIVE>;
|
||||
clocks = <&k3_clks 160 0>;
|
||||
|
||||
@@ -335,12 +335,10 @@ long get_tagged_addr_ctrl(struct task_struct *task);
|
||||
* of header definitions for the use of task_stack_page.
|
||||
*/
|
||||
|
||||
#define current_top_of_stack() \
|
||||
({ \
|
||||
struct stack_info _info; \
|
||||
BUG_ON(!on_accessible_stack(current, current_stack_pointer, 1, &_info)); \
|
||||
_info.high; \
|
||||
})
|
||||
/*
|
||||
* The top of the current task's task stack
|
||||
*/
|
||||
#define current_top_of_stack() ((unsigned long)current->stack + THREAD_SIZE)
|
||||
#define on_thread_stack() (on_task_stack(current, current_stack_pointer, 1, NULL))
|
||||
|
||||
#endif /* __ASSEMBLY__ */
|
||||
|
||||
@@ -1012,6 +1012,7 @@ static_assert(offsetof(siginfo_t, si_upper) == 0x28);
|
||||
static_assert(offsetof(siginfo_t, si_pkey) == 0x20);
|
||||
static_assert(offsetof(siginfo_t, si_perf_data) == 0x18);
|
||||
static_assert(offsetof(siginfo_t, si_perf_type) == 0x20);
|
||||
static_assert(offsetof(siginfo_t, si_perf_flags) == 0x24);
|
||||
static_assert(offsetof(siginfo_t, si_band) == 0x10);
|
||||
static_assert(offsetof(siginfo_t, si_fd) == 0x18);
|
||||
static_assert(offsetof(siginfo_t, si_call_addr) == 0x10);
|
||||
|
||||
@@ -487,6 +487,7 @@ static_assert(offsetof(compat_siginfo_t, si_upper) == 0x18);
|
||||
static_assert(offsetof(compat_siginfo_t, si_pkey) == 0x14);
|
||||
static_assert(offsetof(compat_siginfo_t, si_perf_data) == 0x10);
|
||||
static_assert(offsetof(compat_siginfo_t, si_perf_type) == 0x14);
|
||||
static_assert(offsetof(compat_siginfo_t, si_perf_flags) == 0x18);
|
||||
static_assert(offsetof(compat_siginfo_t, si_band) == 0x0c);
|
||||
static_assert(offsetof(compat_siginfo_t, si_fd) == 0x10);
|
||||
static_assert(offsetof(compat_siginfo_t, si_call_addr) == 0x0c);
|
||||
|
||||
@@ -114,6 +114,6 @@ long compat_arm_syscall(struct pt_regs *regs, int scno)
|
||||
addr = instruction_pointer(regs) - (compat_thumb_mode(regs) ? 2 : 4);
|
||||
|
||||
arm64_notify_die("Oops - bad compat syscall(2)", regs,
|
||||
SIGILL, ILL_ILLTRP, addr, scno);
|
||||
SIGILL, ILL_ILLTRP, addr, 0);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
|
||||
void copy_highpage(struct page *to, struct page *from)
|
||||
{
|
||||
struct page *kto = page_address(to);
|
||||
struct page *kfrom = page_address(from);
|
||||
void *kto = page_address(to);
|
||||
void *kfrom = page_address(from);
|
||||
|
||||
copy_page(kto, kfrom);
|
||||
|
||||
|
||||
@@ -1113,6 +1113,7 @@ skip_init_ctx:
|
||||
bpf_jit_binary_free(header);
|
||||
prog->bpf_func = NULL;
|
||||
prog->jited = 0;
|
||||
prog->jited_len = 0;
|
||||
goto out_off;
|
||||
}
|
||||
bpf_jit_binary_lock_ro(header);
|
||||
|
||||
@@ -28,7 +28,7 @@ static int __kprobes patch_text_cb(void *priv)
|
||||
struct csky_insn_patch *param = priv;
|
||||
unsigned int addr = (unsigned int)param->addr;
|
||||
|
||||
if (atomic_inc_return(¶m->cpu_count) == 1) {
|
||||
if (atomic_inc_return(¶m->cpu_count) == num_online_cpus()) {
|
||||
*(u16 *) addr = cpu_to_le16(param->opcode);
|
||||
dcache_wb_range(addr, addr + 2);
|
||||
atomic_inc(¶m->cpu_count);
|
||||
|
||||
@@ -338,7 +338,7 @@ comment "Processor Specific Options"
|
||||
|
||||
config M68KFPU_EMU
|
||||
bool "Math emulation support"
|
||||
depends on MMU
|
||||
depends on M68KCLASSIC && FPU
|
||||
help
|
||||
At some point in the future, this will cause floating-point math
|
||||
instructions to be emulated by the kernel on machines that lack a
|
||||
|
||||
@@ -335,6 +335,7 @@ comment "Machine Options"
|
||||
|
||||
config UBOOT
|
||||
bool "Support for U-Boot command line parameters"
|
||||
depends on COLDFIRE
|
||||
help
|
||||
If you say Y here kernel will try to collect command
|
||||
line parameters from the initial u-boot stack.
|
||||
|
||||
@@ -42,7 +42,8 @@ extern void paging_init(void);
|
||||
* ZERO_PAGE is a global shared page that is always zero: used
|
||||
* for zero-mapped memory areas etc..
|
||||
*/
|
||||
#define ZERO_PAGE(vaddr) (virt_to_page(0))
|
||||
extern void *empty_zero_page;
|
||||
#define ZERO_PAGE(vaddr) (virt_to_page(empty_zero_page))
|
||||
|
||||
/*
|
||||
* All 32bit addresses are effectively valid for vmalloc...
|
||||
|
||||
@@ -80,14 +80,14 @@
|
||||
({ u16 __v = le16_to_cpu(*(__force volatile u16 *) (addr)); __v; })
|
||||
|
||||
#define rom_out_8(addr, b) \
|
||||
({u8 __maybe_unused __w, __v = (b); u32 _addr = ((u32) (addr)); \
|
||||
(void)({u8 __maybe_unused __w, __v = (b); u32 _addr = ((u32) (addr)); \
|
||||
__w = ((*(__force volatile u8 *) ((_addr | 0x10000) + (__v<<1)))); })
|
||||
#define rom_out_be16(addr, w) \
|
||||
({u16 __maybe_unused __w, __v = (w); u32 _addr = ((u32) (addr)); \
|
||||
(void)({u16 __maybe_unused __w, __v = (w); u32 _addr = ((u32) (addr)); \
|
||||
__w = ((*(__force volatile u16 *) ((_addr & 0xFFFF0000UL) + ((__v & 0xFF)<<1)))); \
|
||||
__w = ((*(__force volatile u16 *) ((_addr | 0x10000) + ((__v >> 8)<<1)))); })
|
||||
#define rom_out_le16(addr, w) \
|
||||
({u16 __maybe_unused __w, __v = (w); u32 _addr = ((u32) (addr)); \
|
||||
(void)({u16 __maybe_unused __w, __v = (w); u32 _addr = ((u32) (addr)); \
|
||||
__w = ((*(__force volatile u16 *) ((_addr & 0xFFFF0000UL) + ((__v >> 8)<<1)))); \
|
||||
__w = ((*(__force volatile u16 *) ((_addr | 0x10000) + ((__v & 0xFF)<<1)))); })
|
||||
|
||||
|
||||
@@ -87,15 +87,8 @@ void (*mach_sched_init) (void) __initdata = NULL;
|
||||
void (*mach_init_IRQ) (void) __initdata = NULL;
|
||||
void (*mach_get_model) (char *model);
|
||||
void (*mach_get_hardware_list) (struct seq_file *m);
|
||||
/* machine dependent timer functions */
|
||||
int (*mach_hwclk) (int, struct rtc_time*);
|
||||
EXPORT_SYMBOL(mach_hwclk);
|
||||
unsigned int (*mach_get_ss)(void);
|
||||
int (*mach_get_rtc_pll)(struct rtc_pll_info *);
|
||||
int (*mach_set_rtc_pll)(struct rtc_pll_info *);
|
||||
EXPORT_SYMBOL(mach_get_ss);
|
||||
EXPORT_SYMBOL(mach_get_rtc_pll);
|
||||
EXPORT_SYMBOL(mach_set_rtc_pll);
|
||||
void (*mach_reset)( void );
|
||||
void (*mach_halt)( void );
|
||||
void (*mach_power_off)( void );
|
||||
|
||||
@@ -50,7 +50,6 @@ char __initdata command_line[COMMAND_LINE_SIZE];
|
||||
|
||||
/* machine dependent timer functions */
|
||||
void (*mach_sched_init)(void) __initdata = NULL;
|
||||
int (*mach_hwclk) (int, struct rtc_time*);
|
||||
|
||||
/* machine dependent reboot functions */
|
||||
void (*mach_reset)(void);
|
||||
|
||||
@@ -625,6 +625,7 @@ static inline void siginfo_build_tests(void)
|
||||
/* _sigfault._perf */
|
||||
BUILD_BUG_ON(offsetof(siginfo_t, si_perf_data) != 0x10);
|
||||
BUILD_BUG_ON(offsetof(siginfo_t, si_perf_type) != 0x14);
|
||||
BUILD_BUG_ON(offsetof(siginfo_t, si_perf_flags) != 0x18);
|
||||
|
||||
/* _sigpoll */
|
||||
BUILD_BUG_ON(offsetof(siginfo_t, si_band) != 0x0c);
|
||||
|
||||
@@ -63,6 +63,15 @@ void timer_heartbeat(void)
|
||||
#endif /* CONFIG_HEARTBEAT */
|
||||
|
||||
#ifdef CONFIG_M68KCLASSIC
|
||||
/* machine dependent timer functions */
|
||||
int (*mach_hwclk) (int, struct rtc_time*);
|
||||
EXPORT_SYMBOL(mach_hwclk);
|
||||
|
||||
int (*mach_get_rtc_pll)(struct rtc_pll_info *);
|
||||
int (*mach_set_rtc_pll)(struct rtc_pll_info *);
|
||||
EXPORT_SYMBOL(mach_get_rtc_pll);
|
||||
EXPORT_SYMBOL(mach_set_rtc_pll);
|
||||
|
||||
#if !IS_BUILTIN(CONFIG_RTC_DRV_GENERIC)
|
||||
void read_persistent_clock64(struct timespec64 *ts)
|
||||
{
|
||||
|
||||
@@ -26,7 +26,6 @@
|
||||
#define cpu_has_3k_cache 0
|
||||
#define cpu_has_4k_cache 1
|
||||
#define cpu_has_tx39_cache 0
|
||||
#define cpu_has_fpu 1
|
||||
#define cpu_has_nofpuex 0
|
||||
#define cpu_has_32fpr 1
|
||||
#define cpu_has_counter 1
|
||||
|
||||
@@ -29,7 +29,6 @@
|
||||
#define cpu_has_3k_cache 0
|
||||
#define cpu_has_4k_cache 1
|
||||
#define cpu_has_tx39_cache 0
|
||||
#define cpu_has_fpu 1
|
||||
#define cpu_has_nofpuex 0
|
||||
#define cpu_has_32fpr 1
|
||||
#define cpu_has_counter 1
|
||||
|
||||
@@ -27,6 +27,7 @@ phys_addr_t __weak mips_cpc_default_phys_base(void)
|
||||
cpc_node = of_find_compatible_node(of_root, NULL, "mti,mips-cpc");
|
||||
if (cpc_node) {
|
||||
err = of_address_to_resource(cpc_node, 0, &res);
|
||||
of_node_put(cpc_node);
|
||||
if (!err)
|
||||
return res.start;
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ static inline cycles_t get_cycles(void)
|
||||
{
|
||||
return mfspr(SPR_TTCR);
|
||||
}
|
||||
#define get_cycles get_cycles
|
||||
|
||||
/* This isn't really used any more */
|
||||
#define CLOCK_TICK_RATE 1000
|
||||
|
||||
@@ -521,6 +521,15 @@ _start:
|
||||
l.ori r3,r0,0x1
|
||||
l.mtspr r0,r3,SPR_SR
|
||||
|
||||
/*
|
||||
* Start the TTCR as early as possible, so that the RNG can make use of
|
||||
* measurements of boot time from the earliest opportunity. Especially
|
||||
* important is that the TTCR does not return zero by the time we reach
|
||||
* rand_initialize().
|
||||
*/
|
||||
l.movhi r3,hi(SPR_TTMR_CR)
|
||||
l.mtspr r0,r3,SPR_TTMR
|
||||
|
||||
CLEAR_GPR(r1)
|
||||
CLEAR_GPR(r2)
|
||||
CLEAR_GPR(r3)
|
||||
|
||||
@@ -12,9 +12,13 @@ static inline void fb_pgprotect(struct file *file, struct vm_area_struct *vma,
|
||||
pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE;
|
||||
}
|
||||
|
||||
#if defined(CONFIG_STI_CONSOLE) || defined(CONFIG_FB_STI)
|
||||
int fb_is_primary_device(struct fb_info *info);
|
||||
#else
|
||||
static inline int fb_is_primary_device(struct fb_info *info)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _ASM_FB_H_ */
|
||||
|
||||
@@ -217,7 +217,6 @@ config PPC
|
||||
select HAVE_HARDLOCKUP_DETECTOR_PERF if PERF_EVENTS && HAVE_PERF_EVENTS_NMI && !HAVE_HARDLOCKUP_DETECTOR_ARCH
|
||||
select HAVE_HW_BREAKPOINT if PERF_EVENTS && (PPC_BOOK3S || PPC_8xx)
|
||||
select HAVE_IOREMAP_PROT
|
||||
select HAVE_IRQ_EXIT_ON_IRQ_STACK
|
||||
select HAVE_IRQ_TIME_ACCOUNTING
|
||||
select HAVE_KERNEL_GZIP
|
||||
select HAVE_KERNEL_LZMA if DEFAULT_UIMAGE
|
||||
@@ -768,7 +767,6 @@ config THREAD_SHIFT
|
||||
range 13 15
|
||||
default "15" if PPC_256K_PAGES
|
||||
default "14" if PPC64
|
||||
default "14" if KASAN
|
||||
default "13"
|
||||
help
|
||||
Used to define the stack size. The default is almost always what you
|
||||
|
||||
@@ -216,6 +216,9 @@ static inline bool pfn_valid(unsigned long pfn)
|
||||
#define __pa(x) ((phys_addr_t)(unsigned long)(x) - VIRT_PHYS_OFFSET)
|
||||
#else
|
||||
#ifdef CONFIG_PPC64
|
||||
|
||||
#define VIRTUAL_WARN_ON(x) WARN_ON(IS_ENABLED(CONFIG_DEBUG_VIRTUAL) && (x))
|
||||
|
||||
/*
|
||||
* gcc miscompiles (unsigned long)(&static_var) - PAGE_OFFSET
|
||||
* with -mcmodel=medium, so we use & and | instead of - and + on 64-bit.
|
||||
@@ -223,13 +226,13 @@ static inline bool pfn_valid(unsigned long pfn)
|
||||
*/
|
||||
#define __va(x) \
|
||||
({ \
|
||||
VIRTUAL_BUG_ON((unsigned long)(x) >= PAGE_OFFSET); \
|
||||
VIRTUAL_WARN_ON((unsigned long)(x) >= PAGE_OFFSET); \
|
||||
(void *)(unsigned long)((phys_addr_t)(x) | PAGE_OFFSET); \
|
||||
})
|
||||
|
||||
#define __pa(x) \
|
||||
({ \
|
||||
VIRTUAL_BUG_ON((unsigned long)(x) < PAGE_OFFSET); \
|
||||
VIRTUAL_WARN_ON((unsigned long)(x) < PAGE_OFFSET); \
|
||||
(unsigned long)(x) & 0x0fffffffffffffffUL; \
|
||||
})
|
||||
|
||||
|
||||
@@ -249,6 +249,7 @@
|
||||
#define PPC_INST_COPY 0x7c20060c
|
||||
#define PPC_INST_DCBA 0x7c0005ec
|
||||
#define PPC_INST_DCBA_MASK 0xfc0007fe
|
||||
#define PPC_INST_DSSALL 0x7e00066c
|
||||
#define PPC_INST_ISEL 0x7c00001e
|
||||
#define PPC_INST_ISEL_MASK 0xfc00003e
|
||||
#define PPC_INST_LSWI 0x7c0004aa
|
||||
@@ -576,6 +577,7 @@
|
||||
#define PPC_DCBZL(a, b) stringify_in_c(.long PPC_RAW_DCBZL(a, b))
|
||||
#define PPC_DIVDE(t, a, b) stringify_in_c(.long PPC_RAW_DIVDE(t, a, b))
|
||||
#define PPC_DIVDEU(t, a, b) stringify_in_c(.long PPC_RAW_DIVDEU(t, a, b))
|
||||
#define PPC_DSSALL stringify_in_c(.long PPC_INST_DSSALL)
|
||||
#define PPC_LQARX(t, a, b, eh) stringify_in_c(.long PPC_RAW_LQARX(t, a, b, eh))
|
||||
#define PPC_STQCX(t, a, b) stringify_in_c(.long PPC_RAW_STQCX(t, a, b))
|
||||
#define PPC_MADDHD(t, a, b, c) stringify_in_c(.long PPC_RAW_MADDHD(t, a, b, c))
|
||||
|
||||
@@ -14,10 +14,16 @@
|
||||
|
||||
#ifdef __KERNEL__
|
||||
|
||||
#if defined(CONFIG_VMAP_STACK) && CONFIG_THREAD_SHIFT < PAGE_SHIFT
|
||||
#ifdef CONFIG_KASAN
|
||||
#define MIN_THREAD_SHIFT (CONFIG_THREAD_SHIFT + 1)
|
||||
#else
|
||||
#define MIN_THREAD_SHIFT CONFIG_THREAD_SHIFT
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_VMAP_STACK) && MIN_THREAD_SHIFT < PAGE_SHIFT
|
||||
#define THREAD_SHIFT PAGE_SHIFT
|
||||
#else
|
||||
#define THREAD_SHIFT CONFIG_THREAD_SHIFT
|
||||
#define THREAD_SHIFT MIN_THREAD_SHIFT
|
||||
#endif
|
||||
|
||||
#define THREAD_SIZE (1 << THREAD_SHIFT)
|
||||
|
||||
@@ -112,7 +112,7 @@ static inline void vas_user_win_add_mm_context(struct vas_user_win_ref *ref)
|
||||
* Receive window attributes specified by the (in-kernel) owner of window.
|
||||
*/
|
||||
struct vas_rx_win_attr {
|
||||
void *rx_fifo;
|
||||
u64 rx_fifo;
|
||||
int rx_fifo_size;
|
||||
int wcreds_max;
|
||||
|
||||
|
||||
@@ -330,23 +330,23 @@ _GLOBAL(enter_rtas)
|
||||
clrldi r4,r4,2 /* convert to realmode address */
|
||||
mtlr r4
|
||||
|
||||
li r0,0
|
||||
ori r0,r0,MSR_EE|MSR_SE|MSR_BE|MSR_RI
|
||||
andc r0,r6,r0
|
||||
|
||||
li r9,1
|
||||
rldicr r9,r9,MSR_SF_LG,(63-MSR_SF_LG)
|
||||
ori r9,r9,MSR_IR|MSR_DR|MSR_FE0|MSR_FE1|MSR_FP|MSR_RI|MSR_LE
|
||||
andc r6,r0,r9
|
||||
|
||||
__enter_rtas:
|
||||
sync /* disable interrupts so SRR0/1 */
|
||||
mtmsrd r0 /* don't get trashed */
|
||||
|
||||
LOAD_REG_ADDR(r4, rtas)
|
||||
ld r5,RTASENTRY(r4) /* get the rtas->entry value */
|
||||
ld r4,RTASBASE(r4) /* get the rtas->base value */
|
||||
|
||||
/*
|
||||
* RTAS runs in 32-bit big endian real mode, but leave MSR[RI] on as we
|
||||
* may hit NMI (SRESET or MCE) while in RTAS. RTAS should disable RI in
|
||||
* its critical regions (as specified in PAPR+ section 7.2.1). MSR[S]
|
||||
* is not impacted by RFI_TO_KERNEL (only urfid can unset it). So if
|
||||
* MSR[S] is set, it will remain when entering RTAS.
|
||||
*/
|
||||
LOAD_REG_IMMEDIATE(r6, MSR_ME | MSR_RI)
|
||||
|
||||
li r0,0
|
||||
mtmsrd r0,1 /* disable RI before using SRR0/1 */
|
||||
|
||||
mtspr SPRN_SRR0,r5
|
||||
mtspr SPRN_SRR1,r6
|
||||
RFI_TO_KERNEL
|
||||
|
||||
@@ -861,7 +861,6 @@ static int fadump_alloc_mem_ranges(struct fadump_mrange_info *mrange_info)
|
||||
sizeof(struct fadump_memory_range));
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline int fadump_add_mem_range(struct fadump_mrange_info *mrange_info,
|
||||
u64 base, u64 end)
|
||||
{
|
||||
@@ -880,7 +879,12 @@ static inline int fadump_add_mem_range(struct fadump_mrange_info *mrange_info,
|
||||
start = mem_ranges[mrange_info->mem_range_cnt - 1].base;
|
||||
size = mem_ranges[mrange_info->mem_range_cnt - 1].size;
|
||||
|
||||
if ((start + size) == base)
|
||||
/*
|
||||
* Boot memory area needs separate PT_LOAD segment(s) as it
|
||||
* is moved to a different location at the time of crash.
|
||||
* So, fold only if the region is not boot memory area.
|
||||
*/
|
||||
if ((start + size) == base && start >= fw_dump.boot_mem_top)
|
||||
is_adjacent = true;
|
||||
}
|
||||
if (!is_adjacent) {
|
||||
|
||||
@@ -37,7 +37,7 @@ static int __init powersave_off(char *arg)
|
||||
{
|
||||
ppc_md.power_save = NULL;
|
||||
cpuidle_disable = IDLE_POWERSAVE_OFF;
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
__setup("powersave=off", powersave_off);
|
||||
|
||||
@@ -82,7 +82,7 @@ void power4_idle(void)
|
||||
return;
|
||||
|
||||
if (cpu_has_feature(CPU_FTR_ALTIVEC))
|
||||
asm volatile("DSSALL ; sync" ::: "memory");
|
||||
asm volatile(PPC_DSSALL " ; sync" ::: "memory");
|
||||
|
||||
power4_idle_nap();
|
||||
|
||||
|
||||
@@ -129,7 +129,7 @@ BEGIN_FTR_SECTION
|
||||
END_FTR_SECTION_IFCLR(CPU_FTR_NO_DPM)
|
||||
mtspr SPRN_HID0,r4
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
sync
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
lwz r8,TI_LOCAL_FLAGS(r2) /* set napping bit */
|
||||
|
||||
@@ -96,7 +96,7 @@ END_FTR_SECTION_IFCLR(CPU_FTR_L2CR)
|
||||
|
||||
/* Stop DST streams */
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
sync
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
|
||||
@@ -292,7 +292,7 @@ END_FTR_SECTION_IFCLR(CPU_FTR_L3CR)
|
||||
isync
|
||||
|
||||
/* Stop DST streams */
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
sync
|
||||
|
||||
/* Get the current enable bit of the L3CR into r4 */
|
||||
@@ -401,7 +401,7 @@ END_FTR_SECTION_IFSET(CPU_FTR_L3CR)
|
||||
_GLOBAL(__flush_disable_L1)
|
||||
/* Stop pending alitvec streams and memory accesses */
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
sync
|
||||
|
||||
|
||||
@@ -17,9 +17,13 @@ int ptrace_get_fpr(struct task_struct *child, int index, unsigned long *data)
|
||||
|
||||
#ifdef CONFIG_PPC_FPU_REGS
|
||||
flush_fp_to_thread(child);
|
||||
if (fpidx < (PT_FPSCR - PT_FPR0))
|
||||
memcpy(data, &child->thread.TS_FPR(fpidx), sizeof(long));
|
||||
if (fpidx < (PT_FPSCR - PT_FPR0)) {
|
||||
if (IS_ENABLED(CONFIG_PPC32))
|
||||
// On 32-bit the index we are passed refers to 32-bit words
|
||||
*data = ((u32 *)child->thread.fp_state.fpr)[fpidx];
|
||||
else
|
||||
memcpy(data, &child->thread.TS_FPR(fpidx), sizeof(long));
|
||||
} else
|
||||
*data = child->thread.fp_state.fpscr;
|
||||
#else
|
||||
*data = 0;
|
||||
@@ -39,9 +43,13 @@ int ptrace_put_fpr(struct task_struct *child, int index, unsigned long data)
|
||||
|
||||
#ifdef CONFIG_PPC_FPU_REGS
|
||||
flush_fp_to_thread(child);
|
||||
if (fpidx < (PT_FPSCR - PT_FPR0))
|
||||
memcpy(&child->thread.TS_FPR(fpidx), &data, sizeof(long));
|
||||
if (fpidx < (PT_FPSCR - PT_FPR0)) {
|
||||
if (IS_ENABLED(CONFIG_PPC32))
|
||||
// On 32-bit the index we are passed refers to 32-bit words
|
||||
((u32 *)child->thread.fp_state.fpr)[fpidx] = data;
|
||||
else
|
||||
memcpy(&child->thread.TS_FPR(fpidx), &data, sizeof(long));
|
||||
} else
|
||||
child->thread.fp_state.fpscr = data;
|
||||
#endif
|
||||
|
||||
|
||||
@@ -446,4 +446,7 @@ void __init pt_regs_check(void)
|
||||
* real registers.
|
||||
*/
|
||||
BUILD_BUG_ON(PT_DSCR < sizeof(struct user_pt_regs) / sizeof(unsigned long));
|
||||
|
||||
// ptrace_get/put_fpr() rely on PPC32 and VSX being incompatible
|
||||
BUILD_BUG_ON(IS_ENABLED(CONFIG_PPC32) && IS_ENABLED(CONFIG_VSX));
|
||||
}
|
||||
|
||||
@@ -49,6 +49,15 @@ void enter_rtas(unsigned long);
|
||||
|
||||
static inline void do_enter_rtas(unsigned long args)
|
||||
{
|
||||
unsigned long msr;
|
||||
|
||||
/*
|
||||
* Make sure MSR[RI] is currently enabled as it will be forced later
|
||||
* in enter_rtas.
|
||||
*/
|
||||
msr = mfmsr();
|
||||
BUG_ON(!(msr & MSR_RI));
|
||||
|
||||
enter_rtas(args);
|
||||
|
||||
srr_regs_clobbered(); /* rtas uses SRRs, invalidate */
|
||||
|
||||
@@ -181,7 +181,7 @@ _GLOBAL(swsusp_arch_resume)
|
||||
#ifdef CONFIG_ALTIVEC
|
||||
/* Stop pending alitvec streams and memory accesses */
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
#endif
|
||||
sync
|
||||
|
||||
@@ -142,7 +142,7 @@ END_FW_FTR_SECTION_IFCLR(FW_FEATURE_LPAR)
|
||||
_GLOBAL(swsusp_arch_resume)
|
||||
/* Stop pending alitvec streams and memory accesses */
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
sync
|
||||
|
||||
|
||||
@@ -5235,6 +5235,10 @@ static int kvmppc_core_init_vm_hv(struct kvm *kvm)
|
||||
kvm->arch.host_lpcr = lpcr = mfspr(SPRN_LPCR);
|
||||
lpcr &= LPCR_PECE | LPCR_LPES;
|
||||
} else {
|
||||
/*
|
||||
* The L2 LPES mode will be set by the L0 according to whether
|
||||
* or not it needs to take external interrupts in HV mode.
|
||||
*/
|
||||
lpcr = 0;
|
||||
}
|
||||
lpcr |= (4UL << LPCR_DPFD_SH) | LPCR_HDICE |
|
||||
|
||||
@@ -261,8 +261,7 @@ static void load_l2_hv_regs(struct kvm_vcpu *vcpu,
|
||||
/*
|
||||
* Don't let L1 change LPCR bits for the L2 except these:
|
||||
*/
|
||||
mask = LPCR_DPFD | LPCR_ILE | LPCR_TC | LPCR_AIL | LPCR_LD |
|
||||
LPCR_LPES | LPCR_MER;
|
||||
mask = LPCR_DPFD | LPCR_ILE | LPCR_TC | LPCR_AIL | LPCR_LD | LPCR_MER;
|
||||
|
||||
/*
|
||||
* Additional filtering is required depending on hardware
|
||||
|
||||
@@ -81,7 +81,7 @@ void switch_mm_irqs_off(struct mm_struct *prev, struct mm_struct *next,
|
||||
* context
|
||||
*/
|
||||
if (cpu_has_feature(CPU_FTR_ALTIVEC))
|
||||
asm volatile ("dssall");
|
||||
asm volatile (PPC_DSSALL);
|
||||
|
||||
if (!new_on_cpu)
|
||||
membarrier_arch_switch_mm(prev, next, tsk);
|
||||
|
||||
@@ -108,7 +108,7 @@ static void mmcra_sdar_mode(u64 event, unsigned long *mmcra)
|
||||
*mmcra |= MMCRA_SDAR_MODE_TLB;
|
||||
}
|
||||
|
||||
static u64 p10_thresh_cmp_val(u64 value)
|
||||
static int p10_thresh_cmp_val(u64 value)
|
||||
{
|
||||
int exp = 0;
|
||||
u64 result = value;
|
||||
@@ -139,7 +139,7 @@ static u64 p10_thresh_cmp_val(u64 value)
|
||||
* exponent is also zero.
|
||||
*/
|
||||
if (!(value & 0xC0) && exp)
|
||||
result = 0;
|
||||
result = -1;
|
||||
else
|
||||
result = (exp << 8) | value;
|
||||
}
|
||||
@@ -187,7 +187,7 @@ static bool is_thresh_cmp_valid(u64 event)
|
||||
unsigned int cmp, exp;
|
||||
|
||||
if (cpu_has_feature(CPU_FTR_ARCH_31))
|
||||
return p10_thresh_cmp_val(event) != 0;
|
||||
return p10_thresh_cmp_val(event) >= 0;
|
||||
|
||||
/*
|
||||
* Check the mantissa upper two bits are not zero, unless the
|
||||
@@ -456,12 +456,14 @@ int isa207_get_constraint(u64 event, unsigned long *maskp, unsigned long *valp,
|
||||
value |= CNST_THRESH_CTL_SEL_VAL(event >> EVENT_THRESH_SHIFT);
|
||||
mask |= p10_CNST_THRESH_CMP_MASK;
|
||||
value |= p10_CNST_THRESH_CMP_VAL(p10_thresh_cmp_val(event_config1));
|
||||
}
|
||||
} else if (event_is_threshold(event))
|
||||
return -1;
|
||||
} else if (cpu_has_feature(CPU_FTR_ARCH_300)) {
|
||||
if (event_is_threshold(event) && is_thresh_cmp_valid(event)) {
|
||||
mask |= CNST_THRESH_MASK;
|
||||
value |= CNST_THRESH_VAL(event >> EVENT_THRESH_SHIFT);
|
||||
}
|
||||
} else if (event_is_threshold(event))
|
||||
return -1;
|
||||
} else {
|
||||
/*
|
||||
* Special case for PM_MRK_FAB_RSP_MATCH and PM_MRK_FAB_RSP_MATCH_CYC,
|
||||
|
||||
@@ -327,6 +327,6 @@ late_initcall(cpm_init);
|
||||
static int __init cpm_powersave_off(char *arg)
|
||||
{
|
||||
cpm.powersave_off = 1;
|
||||
return 0;
|
||||
return 1;
|
||||
}
|
||||
__setup("powersave=off", cpm_powersave_off);
|
||||
|
||||
@@ -280,6 +280,7 @@ cpm_setbrg(uint brg, uint rate)
|
||||
out_be32(bp, (((BRG_UART_CLK_DIV16 / rate) - 1) << 1) |
|
||||
CPM_BRG_EN | CPM_BRG_DIV16);
|
||||
}
|
||||
EXPORT_SYMBOL(cpm_setbrg);
|
||||
|
||||
struct cpm_ioport16 {
|
||||
__be16 dir, par, odr_sor, dat, intr;
|
||||
|
||||
@@ -48,7 +48,7 @@ flush_disable_75x:
|
||||
|
||||
/* Stop DST streams */
|
||||
BEGIN_FTR_SECTION
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
sync
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC)
|
||||
|
||||
@@ -197,7 +197,7 @@ flush_disable_745x:
|
||||
isync
|
||||
|
||||
/* Stop prefetch streams */
|
||||
DSSALL
|
||||
PPC_DSSALL
|
||||
sync
|
||||
|
||||
/* Disable L2 prefetching */
|
||||
|
||||
@@ -60,7 +60,7 @@ void __init opal_fadump_dt_scan(struct fw_dump *fadump_conf, u64 node)
|
||||
addr = be64_to_cpu(addr);
|
||||
pr_debug("Kernel metadata addr: %llx\n", addr);
|
||||
opal_fdm_active = (void *)addr;
|
||||
if (opal_fdm_active->registered_regions == 0)
|
||||
if (be16_to_cpu(opal_fdm_active->registered_regions) == 0)
|
||||
return;
|
||||
|
||||
ret = opal_mpipl_query_tag(OPAL_MPIPL_TAG_BOOT_MEM, &addr);
|
||||
@@ -95,17 +95,17 @@ static int opal_fadump_unregister(struct fw_dump *fadump_conf);
|
||||
static void opal_fadump_update_config(struct fw_dump *fadump_conf,
|
||||
const struct opal_fadump_mem_struct *fdm)
|
||||
{
|
||||
pr_debug("Boot memory regions count: %d\n", fdm->region_cnt);
|
||||
pr_debug("Boot memory regions count: %d\n", be16_to_cpu(fdm->region_cnt));
|
||||
|
||||
/*
|
||||
* The destination address of the first boot memory region is the
|
||||
* destination address of boot memory regions.
|
||||
*/
|
||||
fadump_conf->boot_mem_dest_addr = fdm->rgn[0].dest;
|
||||
fadump_conf->boot_mem_dest_addr = be64_to_cpu(fdm->rgn[0].dest);
|
||||
pr_debug("Destination address of boot memory regions: %#016llx\n",
|
||||
fadump_conf->boot_mem_dest_addr);
|
||||
|
||||
fadump_conf->fadumphdr_addr = fdm->fadumphdr_addr;
|
||||
fadump_conf->fadumphdr_addr = be64_to_cpu(fdm->fadumphdr_addr);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -126,9 +126,9 @@ static void opal_fadump_get_config(struct fw_dump *fadump_conf,
|
||||
fadump_conf->boot_memory_size = 0;
|
||||
|
||||
pr_debug("Boot memory regions:\n");
|
||||
for (i = 0; i < fdm->region_cnt; i++) {
|
||||
base = fdm->rgn[i].src;
|
||||
size = fdm->rgn[i].size;
|
||||
for (i = 0; i < be16_to_cpu(fdm->region_cnt); i++) {
|
||||
base = be64_to_cpu(fdm->rgn[i].src);
|
||||
size = be64_to_cpu(fdm->rgn[i].size);
|
||||
pr_debug("\t[%03d] base: 0x%lx, size: 0x%lx\n", i, base, size);
|
||||
|
||||
fadump_conf->boot_mem_addr[i] = base;
|
||||
@@ -143,7 +143,7 @@ static void opal_fadump_get_config(struct fw_dump *fadump_conf,
|
||||
* Start address of reserve dump area (permanent reservation) for
|
||||
* re-registering FADump after dump capture.
|
||||
*/
|
||||
fadump_conf->reserve_dump_area_start = fdm->rgn[0].dest;
|
||||
fadump_conf->reserve_dump_area_start = be64_to_cpu(fdm->rgn[0].dest);
|
||||
|
||||
/*
|
||||
* Rarely, but it can so happen that system crashes before all
|
||||
@@ -155,13 +155,14 @@ static void opal_fadump_get_config(struct fw_dump *fadump_conf,
|
||||
* Hope the memory that could not be preserved only has pages
|
||||
* that are usually filtered out while saving the vmcore.
|
||||
*/
|
||||
if (fdm->region_cnt > fdm->registered_regions) {
|
||||
if (be16_to_cpu(fdm->region_cnt) > be16_to_cpu(fdm->registered_regions)) {
|
||||
pr_warn("Not all memory regions were saved!!!\n");
|
||||
pr_warn(" Unsaved memory regions:\n");
|
||||
i = fdm->registered_regions;
|
||||
while (i < fdm->region_cnt) {
|
||||
i = be16_to_cpu(fdm->registered_regions);
|
||||
while (i < be16_to_cpu(fdm->region_cnt)) {
|
||||
pr_warn("\t[%03d] base: 0x%llx, size: 0x%llx\n",
|
||||
i, fdm->rgn[i].src, fdm->rgn[i].size);
|
||||
i, be64_to_cpu(fdm->rgn[i].src),
|
||||
be64_to_cpu(fdm->rgn[i].size));
|
||||
i++;
|
||||
}
|
||||
|
||||
@@ -170,7 +171,7 @@ static void opal_fadump_get_config(struct fw_dump *fadump_conf,
|
||||
}
|
||||
|
||||
fadump_conf->boot_mem_top = (fadump_conf->boot_memory_size + hole_size);
|
||||
fadump_conf->boot_mem_regs_cnt = fdm->region_cnt;
|
||||
fadump_conf->boot_mem_regs_cnt = be16_to_cpu(fdm->region_cnt);
|
||||
opal_fadump_update_config(fadump_conf, fdm);
|
||||
}
|
||||
|
||||
@@ -178,34 +179,37 @@ static void opal_fadump_get_config(struct fw_dump *fadump_conf,
|
||||
static void opal_fadump_init_metadata(struct opal_fadump_mem_struct *fdm)
|
||||
{
|
||||
fdm->version = OPAL_FADUMP_VERSION;
|
||||
fdm->region_cnt = 0;
|
||||
fdm->registered_regions = 0;
|
||||
fdm->fadumphdr_addr = 0;
|
||||
fdm->region_cnt = cpu_to_be16(0);
|
||||
fdm->registered_regions = cpu_to_be16(0);
|
||||
fdm->fadumphdr_addr = cpu_to_be64(0);
|
||||
}
|
||||
|
||||
static u64 opal_fadump_init_mem_struct(struct fw_dump *fadump_conf)
|
||||
{
|
||||
u64 addr = fadump_conf->reserve_dump_area_start;
|
||||
u16 reg_cnt;
|
||||
int i;
|
||||
|
||||
opal_fdm = __va(fadump_conf->kernel_metadata);
|
||||
opal_fadump_init_metadata(opal_fdm);
|
||||
|
||||
/* Boot memory regions */
|
||||
reg_cnt = be16_to_cpu(opal_fdm->region_cnt);
|
||||
for (i = 0; i < fadump_conf->boot_mem_regs_cnt; i++) {
|
||||
opal_fdm->rgn[i].src = fadump_conf->boot_mem_addr[i];
|
||||
opal_fdm->rgn[i].dest = addr;
|
||||
opal_fdm->rgn[i].size = fadump_conf->boot_mem_sz[i];
|
||||
opal_fdm->rgn[i].src = cpu_to_be64(fadump_conf->boot_mem_addr[i]);
|
||||
opal_fdm->rgn[i].dest = cpu_to_be64(addr);
|
||||
opal_fdm->rgn[i].size = cpu_to_be64(fadump_conf->boot_mem_sz[i]);
|
||||
|
||||
opal_fdm->region_cnt++;
|
||||
reg_cnt++;
|
||||
addr += fadump_conf->boot_mem_sz[i];
|
||||
}
|
||||
opal_fdm->region_cnt = cpu_to_be16(reg_cnt);
|
||||
|
||||
/*
|
||||
* Kernel metadata is passed to f/w and retrieved in capture kerenl.
|
||||
* So, use it to save fadump header address instead of calculating it.
|
||||
*/
|
||||
opal_fdm->fadumphdr_addr = (opal_fdm->rgn[0].dest +
|
||||
opal_fdm->fadumphdr_addr = cpu_to_be64(be64_to_cpu(opal_fdm->rgn[0].dest) +
|
||||
fadump_conf->boot_memory_size);
|
||||
|
||||
opal_fadump_update_config(fadump_conf, opal_fdm);
|
||||
@@ -269,18 +273,21 @@ static u64 opal_fadump_get_bootmem_min(void)
|
||||
static int opal_fadump_register(struct fw_dump *fadump_conf)
|
||||
{
|
||||
s64 rc = OPAL_PARAMETER;
|
||||
u16 registered_regs;
|
||||
int i, err = -EIO;
|
||||
|
||||
for (i = 0; i < opal_fdm->region_cnt; i++) {
|
||||
registered_regs = be16_to_cpu(opal_fdm->registered_regions);
|
||||
for (i = 0; i < be16_to_cpu(opal_fdm->region_cnt); i++) {
|
||||
rc = opal_mpipl_update(OPAL_MPIPL_ADD_RANGE,
|
||||
opal_fdm->rgn[i].src,
|
||||
opal_fdm->rgn[i].dest,
|
||||
opal_fdm->rgn[i].size);
|
||||
be64_to_cpu(opal_fdm->rgn[i].src),
|
||||
be64_to_cpu(opal_fdm->rgn[i].dest),
|
||||
be64_to_cpu(opal_fdm->rgn[i].size));
|
||||
if (rc != OPAL_SUCCESS)
|
||||
break;
|
||||
|
||||
opal_fdm->registered_regions++;
|
||||
registered_regs++;
|
||||
}
|
||||
opal_fdm->registered_regions = cpu_to_be16(registered_regs);
|
||||
|
||||
switch (rc) {
|
||||
case OPAL_SUCCESS:
|
||||
@@ -291,7 +298,8 @@ static int opal_fadump_register(struct fw_dump *fadump_conf)
|
||||
case OPAL_RESOURCE:
|
||||
/* If MAX regions limit in f/w is hit, warn and proceed. */
|
||||
pr_warn("%d regions could not be registered for MPIPL as MAX limit is reached!\n",
|
||||
(opal_fdm->region_cnt - opal_fdm->registered_regions));
|
||||
(be16_to_cpu(opal_fdm->region_cnt) -
|
||||
be16_to_cpu(opal_fdm->registered_regions)));
|
||||
fadump_conf->dump_registered = 1;
|
||||
err = 0;
|
||||
break;
|
||||
@@ -312,7 +320,7 @@ static int opal_fadump_register(struct fw_dump *fadump_conf)
|
||||
* If some regions were registered before OPAL_MPIPL_ADD_RANGE
|
||||
* OPAL call failed, unregister all regions.
|
||||
*/
|
||||
if ((err < 0) && (opal_fdm->registered_regions > 0))
|
||||
if ((err < 0) && (be16_to_cpu(opal_fdm->registered_regions) > 0))
|
||||
opal_fadump_unregister(fadump_conf);
|
||||
|
||||
return err;
|
||||
@@ -328,7 +336,7 @@ static int opal_fadump_unregister(struct fw_dump *fadump_conf)
|
||||
return -EIO;
|
||||
}
|
||||
|
||||
opal_fdm->registered_regions = 0;
|
||||
opal_fdm->registered_regions = cpu_to_be16(0);
|
||||
fadump_conf->dump_registered = 0;
|
||||
return 0;
|
||||
}
|
||||
@@ -563,19 +571,20 @@ static void opal_fadump_region_show(struct fw_dump *fadump_conf,
|
||||
else
|
||||
fdm_ptr = opal_fdm;
|
||||
|
||||
for (i = 0; i < fdm_ptr->region_cnt; i++) {
|
||||
for (i = 0; i < be16_to_cpu(fdm_ptr->region_cnt); i++) {
|
||||
/*
|
||||
* Only regions that are registered for MPIPL
|
||||
* would have dump data.
|
||||
*/
|
||||
if ((fadump_conf->dump_active) &&
|
||||
(i < fdm_ptr->registered_regions))
|
||||
dumped_bytes = fdm_ptr->rgn[i].size;
|
||||
(i < be16_to_cpu(fdm_ptr->registered_regions)))
|
||||
dumped_bytes = be64_to_cpu(fdm_ptr->rgn[i].size);
|
||||
|
||||
seq_printf(m, "DUMP: Src: %#016llx, Dest: %#016llx, ",
|
||||
fdm_ptr->rgn[i].src, fdm_ptr->rgn[i].dest);
|
||||
be64_to_cpu(fdm_ptr->rgn[i].src),
|
||||
be64_to_cpu(fdm_ptr->rgn[i].dest));
|
||||
seq_printf(m, "Size: %#llx, Dumped: %#llx bytes\n",
|
||||
fdm_ptr->rgn[i].size, dumped_bytes);
|
||||
be64_to_cpu(fdm_ptr->rgn[i].size), dumped_bytes);
|
||||
}
|
||||
|
||||
/* Dump is active. Show reserved area start address. */
|
||||
@@ -624,6 +633,7 @@ void __init opal_fadump_dt_scan(struct fw_dump *fadump_conf, u64 node)
|
||||
{
|
||||
const __be32 *prop;
|
||||
unsigned long dn;
|
||||
__be64 be_addr;
|
||||
u64 addr = 0;
|
||||
int i, len;
|
||||
s64 ret;
|
||||
@@ -680,13 +690,13 @@ void __init opal_fadump_dt_scan(struct fw_dump *fadump_conf, u64 node)
|
||||
if (!prop)
|
||||
return;
|
||||
|
||||
ret = opal_mpipl_query_tag(OPAL_MPIPL_TAG_KERNEL, &addr);
|
||||
if ((ret != OPAL_SUCCESS) || !addr) {
|
||||
ret = opal_mpipl_query_tag(OPAL_MPIPL_TAG_KERNEL, &be_addr);
|
||||
if ((ret != OPAL_SUCCESS) || !be_addr) {
|
||||
pr_err("Failed to get Kernel metadata (%lld)\n", ret);
|
||||
return;
|
||||
}
|
||||
|
||||
addr = be64_to_cpu(addr);
|
||||
addr = be64_to_cpu(be_addr);
|
||||
pr_debug("Kernel metadata addr: %llx\n", addr);
|
||||
|
||||
opal_fdm_active = __va(addr);
|
||||
@@ -697,14 +707,14 @@ void __init opal_fadump_dt_scan(struct fw_dump *fadump_conf, u64 node)
|
||||
}
|
||||
|
||||
/* Kernel regions not registered with f/w for MPIPL */
|
||||
if (opal_fdm_active->registered_regions == 0) {
|
||||
if (be16_to_cpu(opal_fdm_active->registered_regions) == 0) {
|
||||
opal_fdm_active = NULL;
|
||||
return;
|
||||
}
|
||||
|
||||
ret = opal_mpipl_query_tag(OPAL_MPIPL_TAG_CPU, &addr);
|
||||
if (addr) {
|
||||
addr = be64_to_cpu(addr);
|
||||
ret = opal_mpipl_query_tag(OPAL_MPIPL_TAG_CPU, &be_addr);
|
||||
if (be_addr) {
|
||||
addr = be64_to_cpu(be_addr);
|
||||
pr_debug("CPU metadata addr: %llx\n", addr);
|
||||
opal_cpu_metadata = __va(addr);
|
||||
}
|
||||
|
||||
@@ -31,14 +31,14 @@
|
||||
* OPAL FADump kernel metadata
|
||||
*
|
||||
* The address of this structure will be registered with f/w for retrieving
|
||||
* and processing during crash dump.
|
||||
* in the capture kernel to process the crash dump.
|
||||
*/
|
||||
struct opal_fadump_mem_struct {
|
||||
u8 version;
|
||||
u8 reserved[3];
|
||||
u16 region_cnt; /* number of regions */
|
||||
u16 registered_regions; /* Regions registered for MPIPL */
|
||||
u64 fadumphdr_addr;
|
||||
__be16 region_cnt; /* number of regions */
|
||||
__be16 registered_regions; /* Regions registered for MPIPL */
|
||||
__be64 fadumphdr_addr;
|
||||
struct opal_mpipl_region rgn[FADUMP_MAX_MEM_REGS];
|
||||
} __packed;
|
||||
|
||||
@@ -135,7 +135,7 @@ static inline void opal_fadump_read_regs(char *bufp, unsigned int regs_cnt,
|
||||
for (i = 0; i < regs_cnt; i++, bufp += reg_entry_size) {
|
||||
reg_entry = (struct hdat_fadump_reg_entry *)bufp;
|
||||
val = (cpu_endian ? be64_to_cpu(reg_entry->reg_val) :
|
||||
reg_entry->reg_val);
|
||||
(u64)(reg_entry->reg_val));
|
||||
opal_fadump_set_regval_regnum(regs,
|
||||
be32_to_cpu(reg_entry->reg_type),
|
||||
be32_to_cpu(reg_entry->reg_num),
|
||||
|
||||
@@ -55,6 +55,7 @@ static int __init uv_init(void)
|
||||
return -ENODEV;
|
||||
|
||||
uv_memcons = memcons_init(node, "memcons");
|
||||
of_node_put(node);
|
||||
if (!uv_memcons)
|
||||
return -ENOENT;
|
||||
|
||||
|
||||
@@ -216,7 +216,7 @@ int vas_setup_fault_window(struct vas_instance *vinst)
|
||||
vas_init_rx_win_attr(&attr, VAS_COP_TYPE_FAULT);
|
||||
|
||||
attr.rx_fifo_size = vinst->fault_fifo_size;
|
||||
attr.rx_fifo = vinst->fault_fifo;
|
||||
attr.rx_fifo = __pa(vinst->fault_fifo);
|
||||
|
||||
/*
|
||||
* Max creds is based on number of CRBs can fit in the FIFO.
|
||||
|
||||
@@ -404,7 +404,7 @@ static void init_winctx_regs(struct pnv_vas_window *window,
|
||||
*
|
||||
* See also: Design note in function header.
|
||||
*/
|
||||
val = __pa(winctx->rx_fifo);
|
||||
val = winctx->rx_fifo;
|
||||
val = SET_FIELD(VAS_PAGE_MIGRATION_SELECT, val, 0);
|
||||
write_hvwc_reg(window, VREG(LFIFO_BAR), val);
|
||||
|
||||
@@ -739,7 +739,7 @@ static void init_winctx_for_rxwin(struct pnv_vas_window *rxwin,
|
||||
*/
|
||||
winctx->fifo_disable = true;
|
||||
winctx->intr_disable = true;
|
||||
winctx->rx_fifo = NULL;
|
||||
winctx->rx_fifo = 0;
|
||||
}
|
||||
|
||||
winctx->lnotify_lpid = rxattr->lnotify_lpid;
|
||||
|
||||
@@ -376,7 +376,7 @@ struct pnv_vas_window {
|
||||
* is a container for the register fields in the window context.
|
||||
*/
|
||||
struct vas_winctx {
|
||||
void *rx_fifo;
|
||||
u64 rx_fifo;
|
||||
int rx_fifo_size;
|
||||
int wcreds_max;
|
||||
int rsvd_txbuf_count;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user