mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-08 19:09:57 +00:00
Compare commits
1 Commits
raspberryp
...
pull/2638/
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9e4aa51491 |
@@ -379,7 +379,6 @@ What: /sys/devices/system/cpu/vulnerabilities
|
|||||||
/sys/devices/system/cpu/vulnerabilities/spectre_v1
|
/sys/devices/system/cpu/vulnerabilities/spectre_v1
|
||||||
/sys/devices/system/cpu/vulnerabilities/spectre_v2
|
/sys/devices/system/cpu/vulnerabilities/spectre_v2
|
||||||
/sys/devices/system/cpu/vulnerabilities/spec_store_bypass
|
/sys/devices/system/cpu/vulnerabilities/spec_store_bypass
|
||||||
/sys/devices/system/cpu/vulnerabilities/l1tf
|
|
||||||
Date: January 2018
|
Date: January 2018
|
||||||
Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
|
Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
|
||||||
Description: Information about CPU vulnerabilities
|
Description: Information about CPU vulnerabilities
|
||||||
@@ -391,26 +390,3 @@ Description: Information about CPU vulnerabilities
|
|||||||
"Not affected" CPU is not affected by the vulnerability
|
"Not affected" CPU is not affected by the vulnerability
|
||||||
"Vulnerable" CPU is affected and no mitigation in effect
|
"Vulnerable" CPU is affected and no mitigation in effect
|
||||||
"Mitigation: $M" CPU is affected and mitigation $M is in effect
|
"Mitigation: $M" CPU is affected and mitigation $M is in effect
|
||||||
|
|
||||||
Details about the l1tf file can be found in
|
|
||||||
Documentation/admin-guide/l1tf.rst
|
|
||||||
|
|
||||||
What: /sys/devices/system/cpu/smt
|
|
||||||
/sys/devices/system/cpu/smt/active
|
|
||||||
/sys/devices/system/cpu/smt/control
|
|
||||||
Date: June 2018
|
|
||||||
Contact: Linux kernel mailing list <linux-kernel@vger.kernel.org>
|
|
||||||
Description: Control Symetric Multi Threading (SMT)
|
|
||||||
|
|
||||||
active: Tells whether SMT is active (enabled and siblings online)
|
|
||||||
|
|
||||||
control: Read/write interface to control SMT. Possible
|
|
||||||
values:
|
|
||||||
|
|
||||||
"on" SMT is enabled
|
|
||||||
"off" SMT is disabled
|
|
||||||
"forceoff" SMT is force disabled. Cannot be changed.
|
|
||||||
"notsupported" SMT is not supported by the CPU
|
|
||||||
|
|
||||||
If control status is "forceoff" or "notsupported" writes
|
|
||||||
are rejected.
|
|
||||||
|
|||||||
@@ -17,15 +17,6 @@ etc.
|
|||||||
kernel-parameters
|
kernel-parameters
|
||||||
devices
|
devices
|
||||||
|
|
||||||
This section describes CPU vulnerabilities and provides an overview of the
|
|
||||||
possible mitigations along with guidance for selecting mitigations if they
|
|
||||||
are configurable at compile, boot or run time.
|
|
||||||
|
|
||||||
.. toctree::
|
|
||||||
:maxdepth: 1
|
|
||||||
|
|
||||||
l1tf
|
|
||||||
|
|
||||||
Here is a set of documents aimed at users who are trying to track down
|
Here is a set of documents aimed at users who are trying to track down
|
||||||
problems and bugs in particular.
|
problems and bugs in particular.
|
||||||
|
|
||||||
|
|||||||
@@ -1888,84 +1888,10 @@
|
|||||||
(virtualized real and unpaged mode) on capable
|
(virtualized real and unpaged mode) on capable
|
||||||
Intel chips. Default is 1 (enabled)
|
Intel chips. Default is 1 (enabled)
|
||||||
|
|
||||||
kvm-intel.vmentry_l1d_flush=[KVM,Intel] Mitigation for L1 Terminal Fault
|
|
||||||
CVE-2018-3620.
|
|
||||||
|
|
||||||
Valid arguments: never, cond, always
|
|
||||||
|
|
||||||
always: L1D cache flush on every VMENTER.
|
|
||||||
cond: Flush L1D on VMENTER only when the code between
|
|
||||||
VMEXIT and VMENTER can leak host memory.
|
|
||||||
never: Disables the mitigation
|
|
||||||
|
|
||||||
Default is cond (do L1 cache flush in specific instances)
|
|
||||||
|
|
||||||
kvm-intel.vpid= [KVM,Intel] Disable Virtual Processor Identification
|
kvm-intel.vpid= [KVM,Intel] Disable Virtual Processor Identification
|
||||||
feature (tagged TLBs) on capable Intel chips.
|
feature (tagged TLBs) on capable Intel chips.
|
||||||
Default is 1 (enabled)
|
Default is 1 (enabled)
|
||||||
|
|
||||||
l1tf= [X86] Control mitigation of the L1TF vulnerability on
|
|
||||||
affected CPUs
|
|
||||||
|
|
||||||
The kernel PTE inversion protection is unconditionally
|
|
||||||
enabled and cannot be disabled.
|
|
||||||
|
|
||||||
full
|
|
||||||
Provides all available mitigations for the
|
|
||||||
L1TF vulnerability. Disables SMT and
|
|
||||||
enables all mitigations in the
|
|
||||||
hypervisors, i.e. unconditional L1D flush.
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the
|
|
||||||
sysfs interface is still possible after
|
|
||||||
boot. Hypervisors will issue a warning
|
|
||||||
when the first VM is started in a
|
|
||||||
potentially insecure configuration,
|
|
||||||
i.e. SMT enabled or L1D flush disabled.
|
|
||||||
|
|
||||||
full,force
|
|
||||||
Same as 'full', but disables SMT and L1D
|
|
||||||
flush runtime control. Implies the
|
|
||||||
'nosmt=force' command line option.
|
|
||||||
(i.e. sysfs control of SMT is disabled.)
|
|
||||||
|
|
||||||
flush
|
|
||||||
Leaves SMT enabled and enables the default
|
|
||||||
hypervisor mitigation, i.e. conditional
|
|
||||||
L1D flush.
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the
|
|
||||||
sysfs interface is still possible after
|
|
||||||
boot. Hypervisors will issue a warning
|
|
||||||
when the first VM is started in a
|
|
||||||
potentially insecure configuration,
|
|
||||||
i.e. SMT enabled or L1D flush disabled.
|
|
||||||
|
|
||||||
flush,nosmt
|
|
||||||
|
|
||||||
Disables SMT and enables the default
|
|
||||||
hypervisor mitigation.
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the
|
|
||||||
sysfs interface is still possible after
|
|
||||||
boot. Hypervisors will issue a warning
|
|
||||||
when the first VM is started in a
|
|
||||||
potentially insecure configuration,
|
|
||||||
i.e. SMT enabled or L1D flush disabled.
|
|
||||||
|
|
||||||
flush,nowarn
|
|
||||||
Same as 'flush', but hypervisors will not
|
|
||||||
warn when a VM is started in a potentially
|
|
||||||
insecure configuration.
|
|
||||||
|
|
||||||
off
|
|
||||||
Disables hypervisor mitigations and doesn't
|
|
||||||
emit any warnings.
|
|
||||||
|
|
||||||
Default is 'flush'.
|
|
||||||
|
|
||||||
For details see: Documentation/admin-guide/l1tf.rst
|
|
||||||
|
|
||||||
l2cr= [PPC]
|
l2cr= [PPC]
|
||||||
|
|
||||||
l3cr= [PPC]
|
l3cr= [PPC]
|
||||||
@@ -2669,10 +2595,6 @@
|
|||||||
nosmt [KNL,S390] Disable symmetric multithreading (SMT).
|
nosmt [KNL,S390] Disable symmetric multithreading (SMT).
|
||||||
Equivalent to smt=1.
|
Equivalent to smt=1.
|
||||||
|
|
||||||
[KNL,x86] Disable symmetric multithreading (SMT).
|
|
||||||
nosmt=force: Force disable SMT, cannot be undone
|
|
||||||
via the sysfs control file.
|
|
||||||
|
|
||||||
nospectre_v2 [X86] Disable all mitigations for the Spectre variant 2
|
nospectre_v2 [X86] Disable all mitigations for the Spectre variant 2
|
||||||
(indirect branch prediction) vulnerability. System may
|
(indirect branch prediction) vulnerability. System may
|
||||||
allow data leaks with this option, which is equivalent
|
allow data leaks with this option, which is equivalent
|
||||||
|
|||||||
@@ -1,610 +0,0 @@
|
|||||||
L1TF - L1 Terminal Fault
|
|
||||||
========================
|
|
||||||
|
|
||||||
L1 Terminal Fault is a hardware vulnerability which allows unprivileged
|
|
||||||
speculative access to data which is available in the Level 1 Data Cache
|
|
||||||
when the page table entry controlling the virtual address, which is used
|
|
||||||
for the access, has the Present bit cleared or other reserved bits set.
|
|
||||||
|
|
||||||
Affected processors
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
This vulnerability affects a wide range of Intel processors. The
|
|
||||||
vulnerability is not present on:
|
|
||||||
|
|
||||||
- Processors from AMD, Centaur and other non Intel vendors
|
|
||||||
|
|
||||||
- Older processor models, where the CPU family is < 6
|
|
||||||
|
|
||||||
- A range of Intel ATOM processors (Cedarview, Cloverview, Lincroft,
|
|
||||||
Penwell, Pineview, Silvermont, Airmont, Merrifield)
|
|
||||||
|
|
||||||
- The Intel XEON PHI family
|
|
||||||
|
|
||||||
- Intel processors which have the ARCH_CAP_RDCL_NO bit set in the
|
|
||||||
IA32_ARCH_CAPABILITIES MSR. If the bit is set the CPU is not affected
|
|
||||||
by the Meltdown vulnerability either. These CPUs should become
|
|
||||||
available by end of 2018.
|
|
||||||
|
|
||||||
Whether a processor is affected or not can be read out from the L1TF
|
|
||||||
vulnerability file in sysfs. See :ref:`l1tf_sys_info`.
|
|
||||||
|
|
||||||
Related CVEs
|
|
||||||
------------
|
|
||||||
|
|
||||||
The following CVE entries are related to the L1TF vulnerability:
|
|
||||||
|
|
||||||
============= ================= ==============================
|
|
||||||
CVE-2018-3615 L1 Terminal Fault SGX related aspects
|
|
||||||
CVE-2018-3620 L1 Terminal Fault OS, SMM related aspects
|
|
||||||
CVE-2018-3646 L1 Terminal Fault Virtualization related aspects
|
|
||||||
============= ================= ==============================
|
|
||||||
|
|
||||||
Problem
|
|
||||||
-------
|
|
||||||
|
|
||||||
If an instruction accesses a virtual address for which the relevant page
|
|
||||||
table entry (PTE) has the Present bit cleared or other reserved bits set,
|
|
||||||
then speculative execution ignores the invalid PTE and loads the referenced
|
|
||||||
data if it is present in the Level 1 Data Cache, as if the page referenced
|
|
||||||
by the address bits in the PTE was still present and accessible.
|
|
||||||
|
|
||||||
While this is a purely speculative mechanism and the instruction will raise
|
|
||||||
a page fault when it is retired eventually, the pure act of loading the
|
|
||||||
data and making it available to other speculative instructions opens up the
|
|
||||||
opportunity for side channel attacks to unprivileged malicious code,
|
|
||||||
similar to the Meltdown attack.
|
|
||||||
|
|
||||||
While Meltdown breaks the user space to kernel space protection, L1TF
|
|
||||||
allows to attack any physical memory address in the system and the attack
|
|
||||||
works across all protection domains. It allows an attack of SGX and also
|
|
||||||
works from inside virtual machines because the speculation bypasses the
|
|
||||||
extended page table (EPT) protection mechanism.
|
|
||||||
|
|
||||||
|
|
||||||
Attack scenarios
|
|
||||||
----------------
|
|
||||||
|
|
||||||
1. Malicious user space
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
Operating Systems store arbitrary information in the address bits of a
|
|
||||||
PTE which is marked non present. This allows a malicious user space
|
|
||||||
application to attack the physical memory to which these PTEs resolve.
|
|
||||||
In some cases user-space can maliciously influence the information
|
|
||||||
encoded in the address bits of the PTE, thus making attacks more
|
|
||||||
deterministic and more practical.
|
|
||||||
|
|
||||||
The Linux kernel contains a mitigation for this attack vector, PTE
|
|
||||||
inversion, which is permanently enabled and has no performance
|
|
||||||
impact. The kernel ensures that the address bits of PTEs, which are not
|
|
||||||
marked present, never point to cacheable physical memory space.
|
|
||||||
|
|
||||||
A system with an up to date kernel is protected against attacks from
|
|
||||||
malicious user space applications.
|
|
||||||
|
|
||||||
2. Malicious guest in a virtual machine
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
The fact that L1TF breaks all domain protections allows malicious guest
|
|
||||||
OSes, which can control the PTEs directly, and malicious guest user
|
|
||||||
space applications, which run on an unprotected guest kernel lacking the
|
|
||||||
PTE inversion mitigation for L1TF, to attack physical host memory.
|
|
||||||
|
|
||||||
A special aspect of L1TF in the context of virtualization is symmetric
|
|
||||||
multi threading (SMT). The Intel implementation of SMT is called
|
|
||||||
HyperThreading. The fact that Hyperthreads on the affected processors
|
|
||||||
share the L1 Data Cache (L1D) is important for this. As the flaw allows
|
|
||||||
only to attack data which is present in L1D, a malicious guest running
|
|
||||||
on one Hyperthread can attack the data which is brought into the L1D by
|
|
||||||
the context which runs on the sibling Hyperthread of the same physical
|
|
||||||
core. This context can be host OS, host user space or a different guest.
|
|
||||||
|
|
||||||
If the processor does not support Extended Page Tables, the attack is
|
|
||||||
only possible, when the hypervisor does not sanitize the content of the
|
|
||||||
effective (shadow) page tables.
|
|
||||||
|
|
||||||
While solutions exist to mitigate these attack vectors fully, these
|
|
||||||
mitigations are not enabled by default in the Linux kernel because they
|
|
||||||
can affect performance significantly. The kernel provides several
|
|
||||||
mechanisms which can be utilized to address the problem depending on the
|
|
||||||
deployment scenario. The mitigations, their protection scope and impact
|
|
||||||
are described in the next sections.
|
|
||||||
|
|
||||||
The default mitigations and the rationale for choosing them are explained
|
|
||||||
at the end of this document. See :ref:`default_mitigations`.
|
|
||||||
|
|
||||||
.. _l1tf_sys_info:
|
|
||||||
|
|
||||||
L1TF system information
|
|
||||||
-----------------------
|
|
||||||
|
|
||||||
The Linux kernel provides a sysfs interface to enumerate the current L1TF
|
|
||||||
status of the system: whether the system is vulnerable, and which
|
|
||||||
mitigations are active. The relevant sysfs file is:
|
|
||||||
|
|
||||||
/sys/devices/system/cpu/vulnerabilities/l1tf
|
|
||||||
|
|
||||||
The possible values in this file are:
|
|
||||||
|
|
||||||
=========================== ===============================
|
|
||||||
'Not affected' The processor is not vulnerable
|
|
||||||
'Mitigation: PTE Inversion' The host protection is active
|
|
||||||
=========================== ===============================
|
|
||||||
|
|
||||||
If KVM/VMX is enabled and the processor is vulnerable then the following
|
|
||||||
information is appended to the 'Mitigation: PTE Inversion' part:
|
|
||||||
|
|
||||||
- SMT status:
|
|
||||||
|
|
||||||
===================== ================
|
|
||||||
'VMX: SMT vulnerable' SMT is enabled
|
|
||||||
'VMX: SMT disabled' SMT is disabled
|
|
||||||
===================== ================
|
|
||||||
|
|
||||||
- L1D Flush mode:
|
|
||||||
|
|
||||||
================================ ====================================
|
|
||||||
'L1D vulnerable' L1D flushing is disabled
|
|
||||||
|
|
||||||
'L1D conditional cache flushes' L1D flush is conditionally enabled
|
|
||||||
|
|
||||||
'L1D cache flushes' L1D flush is unconditionally enabled
|
|
||||||
================================ ====================================
|
|
||||||
|
|
||||||
The resulting grade of protection is discussed in the following sections.
|
|
||||||
|
|
||||||
|
|
||||||
Host mitigation mechanism
|
|
||||||
-------------------------
|
|
||||||
|
|
||||||
The kernel is unconditionally protected against L1TF attacks from malicious
|
|
||||||
user space running on the host.
|
|
||||||
|
|
||||||
|
|
||||||
Guest mitigation mechanisms
|
|
||||||
---------------------------
|
|
||||||
|
|
||||||
.. _l1d_flush:
|
|
||||||
|
|
||||||
1. L1D flush on VMENTER
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
To make sure that a guest cannot attack data which is present in the L1D
|
|
||||||
the hypervisor flushes the L1D before entering the guest.
|
|
||||||
|
|
||||||
Flushing the L1D evicts not only the data which should not be accessed
|
|
||||||
by a potentially malicious guest, it also flushes the guest
|
|
||||||
data. Flushing the L1D has a performance impact as the processor has to
|
|
||||||
bring the flushed guest data back into the L1D. Depending on the
|
|
||||||
frequency of VMEXIT/VMENTER and the type of computations in the guest
|
|
||||||
performance degradation in the range of 1% to 50% has been observed. For
|
|
||||||
scenarios where guest VMEXIT/VMENTER are rare the performance impact is
|
|
||||||
minimal. Virtio and mechanisms like posted interrupts are designed to
|
|
||||||
confine the VMEXITs to a bare minimum, but specific configurations and
|
|
||||||
application scenarios might still suffer from a high VMEXIT rate.
|
|
||||||
|
|
||||||
The kernel provides two L1D flush modes:
|
|
||||||
- conditional ('cond')
|
|
||||||
- unconditional ('always')
|
|
||||||
|
|
||||||
The conditional mode avoids L1D flushing after VMEXITs which execute
|
|
||||||
only audited code paths before the corresponding VMENTER. These code
|
|
||||||
paths have been verified that they cannot expose secrets or other
|
|
||||||
interesting data to an attacker, but they can leak information about the
|
|
||||||
address space layout of the hypervisor.
|
|
||||||
|
|
||||||
Unconditional mode flushes L1D on all VMENTER invocations and provides
|
|
||||||
maximum protection. It has a higher overhead than the conditional
|
|
||||||
mode. The overhead cannot be quantified correctly as it depends on the
|
|
||||||
workload scenario and the resulting number of VMEXITs.
|
|
||||||
|
|
||||||
The general recommendation is to enable L1D flush on VMENTER. The kernel
|
|
||||||
defaults to conditional mode on affected processors.
|
|
||||||
|
|
||||||
**Note**, that L1D flush does not prevent the SMT problem because the
|
|
||||||
sibling thread will also bring back its data into the L1D which makes it
|
|
||||||
attackable again.
|
|
||||||
|
|
||||||
L1D flush can be controlled by the administrator via the kernel command
|
|
||||||
line and sysfs control files. See :ref:`mitigation_control_command_line`
|
|
||||||
and :ref:`mitigation_control_kvm`.
|
|
||||||
|
|
||||||
.. _guest_confinement:
|
|
||||||
|
|
||||||
2. Guest VCPU confinement to dedicated physical cores
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
To address the SMT problem, it is possible to make a guest or a group of
|
|
||||||
guests affine to one or more physical cores. The proper mechanism for
|
|
||||||
that is to utilize exclusive cpusets to ensure that no other guest or
|
|
||||||
host tasks can run on these cores.
|
|
||||||
|
|
||||||
If only a single guest or related guests run on sibling SMT threads on
|
|
||||||
the same physical core then they can only attack their own memory and
|
|
||||||
restricted parts of the host memory.
|
|
||||||
|
|
||||||
Host memory is attackable, when one of the sibling SMT threads runs in
|
|
||||||
host OS (hypervisor) context and the other in guest context. The amount
|
|
||||||
of valuable information from the host OS context depends on the context
|
|
||||||
which the host OS executes, i.e. interrupts, soft interrupts and kernel
|
|
||||||
threads. The amount of valuable data from these contexts cannot be
|
|
||||||
declared as non-interesting for an attacker without deep inspection of
|
|
||||||
the code.
|
|
||||||
|
|
||||||
**Note**, that assigning guests to a fixed set of physical cores affects
|
|
||||||
the ability of the scheduler to do load balancing and might have
|
|
||||||
negative effects on CPU utilization depending on the hosting
|
|
||||||
scenario. Disabling SMT might be a viable alternative for particular
|
|
||||||
scenarios.
|
|
||||||
|
|
||||||
For further information about confining guests to a single or to a group
|
|
||||||
of cores consult the cpusets documentation:
|
|
||||||
|
|
||||||
https://www.kernel.org/doc/Documentation/cgroup-v1/cpusets.txt
|
|
||||||
|
|
||||||
.. _interrupt_isolation:
|
|
||||||
|
|
||||||
3. Interrupt affinity
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
Interrupts can be made affine to logical CPUs. This is not universally
|
|
||||||
true because there are types of interrupts which are truly per CPU
|
|
||||||
interrupts, e.g. the local timer interrupt. Aside of that multi queue
|
|
||||||
devices affine their interrupts to single CPUs or groups of CPUs per
|
|
||||||
queue without allowing the administrator to control the affinities.
|
|
||||||
|
|
||||||
Moving the interrupts, which can be affinity controlled, away from CPUs
|
|
||||||
which run untrusted guests, reduces the attack vector space.
|
|
||||||
|
|
||||||
Whether the interrupts with are affine to CPUs, which run untrusted
|
|
||||||
guests, provide interesting data for an attacker depends on the system
|
|
||||||
configuration and the scenarios which run on the system. While for some
|
|
||||||
of the interrupts it can be assumed that they won't expose interesting
|
|
||||||
information beyond exposing hints about the host OS memory layout, there
|
|
||||||
is no way to make general assumptions.
|
|
||||||
|
|
||||||
Interrupt affinity can be controlled by the administrator via the
|
|
||||||
/proc/irq/$NR/smp_affinity[_list] files. Limited documentation is
|
|
||||||
available at:
|
|
||||||
|
|
||||||
https://www.kernel.org/doc/Documentation/IRQ-affinity.txt
|
|
||||||
|
|
||||||
.. _smt_control:
|
|
||||||
|
|
||||||
4. SMT control
|
|
||||||
^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
To prevent the SMT issues of L1TF it might be necessary to disable SMT
|
|
||||||
completely. Disabling SMT can have a significant performance impact, but
|
|
||||||
the impact depends on the hosting scenario and the type of workloads.
|
|
||||||
The impact of disabling SMT needs also to be weighted against the impact
|
|
||||||
of other mitigation solutions like confining guests to dedicated cores.
|
|
||||||
|
|
||||||
The kernel provides a sysfs interface to retrieve the status of SMT and
|
|
||||||
to control it. It also provides a kernel command line interface to
|
|
||||||
control SMT.
|
|
||||||
|
|
||||||
The kernel command line interface consists of the following options:
|
|
||||||
|
|
||||||
=========== ==========================================================
|
|
||||||
nosmt Affects the bring up of the secondary CPUs during boot. The
|
|
||||||
kernel tries to bring all present CPUs online during the
|
|
||||||
boot process. "nosmt" makes sure that from each physical
|
|
||||||
core only one - the so called primary (hyper) thread is
|
|
||||||
activated. Due to a design flaw of Intel processors related
|
|
||||||
to Machine Check Exceptions the non primary siblings have
|
|
||||||
to be brought up at least partially and are then shut down
|
|
||||||
again. "nosmt" can be undone via the sysfs interface.
|
|
||||||
|
|
||||||
nosmt=force Has the same effect as "nosmt" but it does not allow to
|
|
||||||
undo the SMT disable via the sysfs interface.
|
|
||||||
=========== ==========================================================
|
|
||||||
|
|
||||||
The sysfs interface provides two files:
|
|
||||||
|
|
||||||
- /sys/devices/system/cpu/smt/control
|
|
||||||
- /sys/devices/system/cpu/smt/active
|
|
||||||
|
|
||||||
/sys/devices/system/cpu/smt/control:
|
|
||||||
|
|
||||||
This file allows to read out the SMT control state and provides the
|
|
||||||
ability to disable or (re)enable SMT. The possible states are:
|
|
||||||
|
|
||||||
============== ===================================================
|
|
||||||
on SMT is supported by the CPU and enabled. All
|
|
||||||
logical CPUs can be onlined and offlined without
|
|
||||||
restrictions.
|
|
||||||
|
|
||||||
off SMT is supported by the CPU and disabled. Only
|
|
||||||
the so called primary SMT threads can be onlined
|
|
||||||
and offlined without restrictions. An attempt to
|
|
||||||
online a non-primary sibling is rejected
|
|
||||||
|
|
||||||
forceoff Same as 'off' but the state cannot be controlled.
|
|
||||||
Attempts to write to the control file are rejected.
|
|
||||||
|
|
||||||
notsupported The processor does not support SMT. It's therefore
|
|
||||||
not affected by the SMT implications of L1TF.
|
|
||||||
Attempts to write to the control file are rejected.
|
|
||||||
============== ===================================================
|
|
||||||
|
|
||||||
The possible states which can be written into this file to control SMT
|
|
||||||
state are:
|
|
||||||
|
|
||||||
- on
|
|
||||||
- off
|
|
||||||
- forceoff
|
|
||||||
|
|
||||||
/sys/devices/system/cpu/smt/active:
|
|
||||||
|
|
||||||
This file reports whether SMT is enabled and active, i.e. if on any
|
|
||||||
physical core two or more sibling threads are online.
|
|
||||||
|
|
||||||
SMT control is also possible at boot time via the l1tf kernel command
|
|
||||||
line parameter in combination with L1D flush control. See
|
|
||||||
:ref:`mitigation_control_command_line`.
|
|
||||||
|
|
||||||
5. Disabling EPT
|
|
||||||
^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
Disabling EPT for virtual machines provides full mitigation for L1TF even
|
|
||||||
with SMT enabled, because the effective page tables for guests are
|
|
||||||
managed and sanitized by the hypervisor. Though disabling EPT has a
|
|
||||||
significant performance impact especially when the Meltdown mitigation
|
|
||||||
KPTI is enabled.
|
|
||||||
|
|
||||||
EPT can be disabled in the hypervisor via the 'kvm-intel.ept' parameter.
|
|
||||||
|
|
||||||
There is ongoing research and development for new mitigation mechanisms to
|
|
||||||
address the performance impact of disabling SMT or EPT.
|
|
||||||
|
|
||||||
.. _mitigation_control_command_line:
|
|
||||||
|
|
||||||
Mitigation control on the kernel command line
|
|
||||||
---------------------------------------------
|
|
||||||
|
|
||||||
The kernel command line allows to control the L1TF mitigations at boot
|
|
||||||
time with the option "l1tf=". The valid arguments for this option are:
|
|
||||||
|
|
||||||
============ =============================================================
|
|
||||||
full Provides all available mitigations for the L1TF
|
|
||||||
vulnerability. Disables SMT and enables all mitigations in
|
|
||||||
the hypervisors, i.e. unconditional L1D flushing
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the sysfs interface
|
|
||||||
is still possible after boot. Hypervisors will issue a
|
|
||||||
warning when the first VM is started in a potentially
|
|
||||||
insecure configuration, i.e. SMT enabled or L1D flush
|
|
||||||
disabled.
|
|
||||||
|
|
||||||
full,force Same as 'full', but disables SMT and L1D flush runtime
|
|
||||||
control. Implies the 'nosmt=force' command line option.
|
|
||||||
(i.e. sysfs control of SMT is disabled.)
|
|
||||||
|
|
||||||
flush Leaves SMT enabled and enables the default hypervisor
|
|
||||||
mitigation, i.e. conditional L1D flushing
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the sysfs interface
|
|
||||||
is still possible after boot. Hypervisors will issue a
|
|
||||||
warning when the first VM is started in a potentially
|
|
||||||
insecure configuration, i.e. SMT enabled or L1D flush
|
|
||||||
disabled.
|
|
||||||
|
|
||||||
flush,nosmt Disables SMT and enables the default hypervisor mitigation,
|
|
||||||
i.e. conditional L1D flushing.
|
|
||||||
|
|
||||||
SMT control and L1D flush control via the sysfs interface
|
|
||||||
is still possible after boot. Hypervisors will issue a
|
|
||||||
warning when the first VM is started in a potentially
|
|
||||||
insecure configuration, i.e. SMT enabled or L1D flush
|
|
||||||
disabled.
|
|
||||||
|
|
||||||
flush,nowarn Same as 'flush', but hypervisors will not warn when a VM is
|
|
||||||
started in a potentially insecure configuration.
|
|
||||||
|
|
||||||
off Disables hypervisor mitigations and doesn't emit any
|
|
||||||
warnings.
|
|
||||||
============ =============================================================
|
|
||||||
|
|
||||||
The default is 'flush'. For details about L1D flushing see :ref:`l1d_flush`.
|
|
||||||
|
|
||||||
|
|
||||||
.. _mitigation_control_kvm:
|
|
||||||
|
|
||||||
Mitigation control for KVM - module parameter
|
|
||||||
-------------------------------------------------------------
|
|
||||||
|
|
||||||
The KVM hypervisor mitigation mechanism, flushing the L1D cache when
|
|
||||||
entering a guest, can be controlled with a module parameter.
|
|
||||||
|
|
||||||
The option/parameter is "kvm-intel.vmentry_l1d_flush=". It takes the
|
|
||||||
following arguments:
|
|
||||||
|
|
||||||
============ ==============================================================
|
|
||||||
always L1D cache flush on every VMENTER.
|
|
||||||
|
|
||||||
cond Flush L1D on VMENTER only when the code between VMEXIT and
|
|
||||||
VMENTER can leak host memory which is considered
|
|
||||||
interesting for an attacker. This still can leak host memory
|
|
||||||
which allows e.g. to determine the hosts address space layout.
|
|
||||||
|
|
||||||
never Disables the mitigation
|
|
||||||
============ ==============================================================
|
|
||||||
|
|
||||||
The parameter can be provided on the kernel command line, as a module
|
|
||||||
parameter when loading the modules and at runtime modified via the sysfs
|
|
||||||
file:
|
|
||||||
|
|
||||||
/sys/module/kvm_intel/parameters/vmentry_l1d_flush
|
|
||||||
|
|
||||||
The default is 'cond'. If 'l1tf=full,force' is given on the kernel command
|
|
||||||
line, then 'always' is enforced and the kvm-intel.vmentry_l1d_flush
|
|
||||||
module parameter is ignored and writes to the sysfs file are rejected.
|
|
||||||
|
|
||||||
|
|
||||||
Mitigation selection guide
|
|
||||||
--------------------------
|
|
||||||
|
|
||||||
1. No virtualization in use
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
The system is protected by the kernel unconditionally and no further
|
|
||||||
action is required.
|
|
||||||
|
|
||||||
2. Virtualization with trusted guests
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
If the guest comes from a trusted source and the guest OS kernel is
|
|
||||||
guaranteed to have the L1TF mitigations in place the system is fully
|
|
||||||
protected against L1TF and no further action is required.
|
|
||||||
|
|
||||||
To avoid the overhead of the default L1D flushing on VMENTER the
|
|
||||||
administrator can disable the flushing via the kernel command line and
|
|
||||||
sysfs control files. See :ref:`mitigation_control_command_line` and
|
|
||||||
:ref:`mitigation_control_kvm`.
|
|
||||||
|
|
||||||
|
|
||||||
3. Virtualization with untrusted guests
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
3.1. SMT not supported or disabled
|
|
||||||
""""""""""""""""""""""""""""""""""
|
|
||||||
|
|
||||||
If SMT is not supported by the processor or disabled in the BIOS or by
|
|
||||||
the kernel, it's only required to enforce L1D flushing on VMENTER.
|
|
||||||
|
|
||||||
Conditional L1D flushing is the default behaviour and can be tuned. See
|
|
||||||
:ref:`mitigation_control_command_line` and :ref:`mitigation_control_kvm`.
|
|
||||||
|
|
||||||
3.2. EPT not supported or disabled
|
|
||||||
""""""""""""""""""""""""""""""""""
|
|
||||||
|
|
||||||
If EPT is not supported by the processor or disabled in the hypervisor,
|
|
||||||
the system is fully protected. SMT can stay enabled and L1D flushing on
|
|
||||||
VMENTER is not required.
|
|
||||||
|
|
||||||
EPT can be disabled in the hypervisor via the 'kvm-intel.ept' parameter.
|
|
||||||
|
|
||||||
3.3. SMT and EPT supported and active
|
|
||||||
"""""""""""""""""""""""""""""""""""""
|
|
||||||
|
|
||||||
If SMT and EPT are supported and active then various degrees of
|
|
||||||
mitigations can be employed:
|
|
||||||
|
|
||||||
- L1D flushing on VMENTER:
|
|
||||||
|
|
||||||
L1D flushing on VMENTER is the minimal protection requirement, but it
|
|
||||||
is only potent in combination with other mitigation methods.
|
|
||||||
|
|
||||||
Conditional L1D flushing is the default behaviour and can be tuned. See
|
|
||||||
:ref:`mitigation_control_command_line` and :ref:`mitigation_control_kvm`.
|
|
||||||
|
|
||||||
- Guest confinement:
|
|
||||||
|
|
||||||
Confinement of guests to a single or a group of physical cores which
|
|
||||||
are not running any other processes, can reduce the attack surface
|
|
||||||
significantly, but interrupts, soft interrupts and kernel threads can
|
|
||||||
still expose valuable data to a potential attacker. See
|
|
||||||
:ref:`guest_confinement`.
|
|
||||||
|
|
||||||
- Interrupt isolation:
|
|
||||||
|
|
||||||
Isolating the guest CPUs from interrupts can reduce the attack surface
|
|
||||||
further, but still allows a malicious guest to explore a limited amount
|
|
||||||
of host physical memory. This can at least be used to gain knowledge
|
|
||||||
about the host address space layout. The interrupts which have a fixed
|
|
||||||
affinity to the CPUs which run the untrusted guests can depending on
|
|
||||||
the scenario still trigger soft interrupts and schedule kernel threads
|
|
||||||
which might expose valuable information. See
|
|
||||||
:ref:`interrupt_isolation`.
|
|
||||||
|
|
||||||
The above three mitigation methods combined can provide protection to a
|
|
||||||
certain degree, but the risk of the remaining attack surface has to be
|
|
||||||
carefully analyzed. For full protection the following methods are
|
|
||||||
available:
|
|
||||||
|
|
||||||
- Disabling SMT:
|
|
||||||
|
|
||||||
Disabling SMT and enforcing the L1D flushing provides the maximum
|
|
||||||
amount of protection. This mitigation is not depending on any of the
|
|
||||||
above mitigation methods.
|
|
||||||
|
|
||||||
SMT control and L1D flushing can be tuned by the command line
|
|
||||||
parameters 'nosmt', 'l1tf', 'kvm-intel.vmentry_l1d_flush' and at run
|
|
||||||
time with the matching sysfs control files. See :ref:`smt_control`,
|
|
||||||
:ref:`mitigation_control_command_line` and
|
|
||||||
:ref:`mitigation_control_kvm`.
|
|
||||||
|
|
||||||
- Disabling EPT:
|
|
||||||
|
|
||||||
Disabling EPT provides the maximum amount of protection as well. It is
|
|
||||||
not depending on any of the above mitigation methods. SMT can stay
|
|
||||||
enabled and L1D flushing is not required, but the performance impact is
|
|
||||||
significant.
|
|
||||||
|
|
||||||
EPT can be disabled in the hypervisor via the 'kvm-intel.ept'
|
|
||||||
parameter.
|
|
||||||
|
|
||||||
3.4. Nested virtual machines
|
|
||||||
""""""""""""""""""""""""""""
|
|
||||||
|
|
||||||
When nested virtualization is in use, three operating systems are involved:
|
|
||||||
the bare metal hypervisor, the nested hypervisor and the nested virtual
|
|
||||||
machine. VMENTER operations from the nested hypervisor into the nested
|
|
||||||
guest will always be processed by the bare metal hypervisor. If KVM is the
|
|
||||||
bare metal hypervisor it wiil:
|
|
||||||
|
|
||||||
- Flush the L1D cache on every switch from the nested hypervisor to the
|
|
||||||
nested virtual machine, so that the nested hypervisor's secrets are not
|
|
||||||
exposed to the nested virtual machine;
|
|
||||||
|
|
||||||
- Flush the L1D cache on every switch from the nested virtual machine to
|
|
||||||
the nested hypervisor; this is a complex operation, and flushing the L1D
|
|
||||||
cache avoids that the bare metal hypervisor's secrets are exposed to the
|
|
||||||
nested virtual machine;
|
|
||||||
|
|
||||||
- Instruct the nested hypervisor to not perform any L1D cache flush. This
|
|
||||||
is an optimization to avoid double L1D flushing.
|
|
||||||
|
|
||||||
|
|
||||||
.. _default_mitigations:
|
|
||||||
|
|
||||||
Default mitigations
|
|
||||||
-------------------
|
|
||||||
|
|
||||||
The kernel default mitigations for vulnerable processors are:
|
|
||||||
|
|
||||||
- PTE inversion to protect against malicious user space. This is done
|
|
||||||
unconditionally and cannot be controlled.
|
|
||||||
|
|
||||||
- L1D conditional flushing on VMENTER when EPT is enabled for
|
|
||||||
a guest.
|
|
||||||
|
|
||||||
The kernel does not by default enforce the disabling of SMT, which leaves
|
|
||||||
SMT systems vulnerable when running untrusted guests with EPT enabled.
|
|
||||||
|
|
||||||
The rationale for this choice is:
|
|
||||||
|
|
||||||
- Force disabling SMT can break existing setups, especially with
|
|
||||||
unattended updates.
|
|
||||||
|
|
||||||
- If regular users run untrusted guests on their machine, then L1TF is
|
|
||||||
just an add on to other malware which might be embedded in an untrusted
|
|
||||||
guest, e.g. spam-bots or attacks on the local network.
|
|
||||||
|
|
||||||
There is no technical way to prevent a user from running untrusted code
|
|
||||||
on their machines blindly.
|
|
||||||
|
|
||||||
- It's technically extremely unlikely and from today's knowledge even
|
|
||||||
impossible that L1TF can be exploited via the most popular attack
|
|
||||||
mechanisms like JavaScript because these mechanisms have no way to
|
|
||||||
control PTEs. If this would be possible and not other mitigation would
|
|
||||||
be possible, then the default might be different.
|
|
||||||
|
|
||||||
- The administrators of cloud and hosting setups have to carefully
|
|
||||||
analyze the risk for their scenarios and make the appropriate
|
|
||||||
mitigation choices, which might even vary across their deployed
|
|
||||||
machines and also result in other changes of their overall setup.
|
|
||||||
There is no way for the kernel to provide a sensible default for this
|
|
||||||
kind of scenarios.
|
|
||||||
@@ -1,55 +0,0 @@
|
|||||||
Bindings for the Raspberry Pi PoE HAT fan
|
|
||||||
|
|
||||||
Required properties:
|
|
||||||
- compatible : "raspberrypi,rpi-poe-fan"
|
|
||||||
- firmware : Reference to the RPi firmware device node
|
|
||||||
- pwms : the PWM that is used to control the PWM fan
|
|
||||||
- cooling-levels : PWM duty cycle values in a range from 0 to 255
|
|
||||||
which correspond to thermal cooling states
|
|
||||||
|
|
||||||
Example:
|
|
||||||
fan0: rpi-poe-fan@0 {
|
|
||||||
compatible = "raspberrypi,rpi-poe-fan";
|
|
||||||
firmware = <&firmware>;
|
|
||||||
cooling-min-state = <0>;
|
|
||||||
cooling-max-state = <3>;
|
|
||||||
#cooling-cells = <2>;
|
|
||||||
cooling-levels = <0 50 150 255>;
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
thermal-zones {
|
|
||||||
cpu_thermal: cpu-thermal {
|
|
||||||
trips {
|
|
||||||
threshold: trip-point@0 {
|
|
||||||
temperature = <45000>;
|
|
||||||
hysteresis = <5000>;
|
|
||||||
type = "active";
|
|
||||||
};
|
|
||||||
target: trip-point@1 {
|
|
||||||
temperature = <50000>;
|
|
||||||
hysteresis = <2000>;
|
|
||||||
type = "active";
|
|
||||||
};
|
|
||||||
cpu_hot: cpu_hot@0 {
|
|
||||||
temperature = <55000>;
|
|
||||||
hysteresis = <2000>;
|
|
||||||
type = "active";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
cooling-maps {
|
|
||||||
map0 {
|
|
||||||
trip = <&threshold>;
|
|
||||||
cooling-device = <&fan0 0 1>;
|
|
||||||
};
|
|
||||||
map1 {
|
|
||||||
trip = <&target>;
|
|
||||||
cooling-device = <&fan0 1 2>;
|
|
||||||
};
|
|
||||||
map2 {
|
|
||||||
trip = <&cpu_hot>;
|
|
||||||
cooling-device = <&fan0 2 3>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
@@ -2,10 +2,7 @@
|
|||||||
|
|
||||||
Required properties:
|
Required properties:
|
||||||
|
|
||||||
- compatible: should be one of:
|
- compatible: should be "qca,qca8337"
|
||||||
"qca,qca8334"
|
|
||||||
"qca,qca8337"
|
|
||||||
|
|
||||||
- #size-cells: must be 0
|
- #size-cells: must be 0
|
||||||
- #address-cells: must be 1
|
- #address-cells: must be 1
|
||||||
|
|
||||||
@@ -17,20 +14,6 @@ port and PHY id, each subnode describing a port needs to have a valid phandle
|
|||||||
referencing the internal PHY connected to it. The CPU port of this switch is
|
referencing the internal PHY connected to it. The CPU port of this switch is
|
||||||
always port 0.
|
always port 0.
|
||||||
|
|
||||||
A CPU port node has the following optional node:
|
|
||||||
|
|
||||||
- fixed-link : Fixed-link subnode describing a link to a non-MDIO
|
|
||||||
managed entity. See
|
|
||||||
Documentation/devicetree/bindings/net/fixed-link.txt
|
|
||||||
for details.
|
|
||||||
|
|
||||||
For QCA8K the 'fixed-link' sub-node supports only the following properties:
|
|
||||||
|
|
||||||
- 'speed' (integer, mandatory), to indicate the link speed. Accepted
|
|
||||||
values are 10, 100 and 1000
|
|
||||||
- 'full-duplex' (boolean, optional), to indicate that full duplex is
|
|
||||||
used. When absent, half duplex is assumed.
|
|
||||||
|
|
||||||
Example:
|
Example:
|
||||||
|
|
||||||
|
|
||||||
@@ -70,10 +53,6 @@ Example:
|
|||||||
label = "cpu";
|
label = "cpu";
|
||||||
ethernet = <&gmac1>;
|
ethernet = <&gmac1>;
|
||||||
phy-mode = "rgmii";
|
phy-mode = "rgmii";
|
||||||
fixed-link {
|
|
||||||
speed = 1000;
|
|
||||||
full-duplex;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
port@1 {
|
port@1 {
|
||||||
|
|||||||
@@ -10,7 +10,6 @@ Required properties on all platforms:
|
|||||||
- "amlogic,meson6-dwmac"
|
- "amlogic,meson6-dwmac"
|
||||||
- "amlogic,meson8b-dwmac"
|
- "amlogic,meson8b-dwmac"
|
||||||
- "amlogic,meson-gxbb-dwmac"
|
- "amlogic,meson-gxbb-dwmac"
|
||||||
- "amlogic,meson-axg-dwmac"
|
|
||||||
Additionally "snps,dwmac" and any applicable more
|
Additionally "snps,dwmac" and any applicable more
|
||||||
detailed version number described in net/stmmac.txt
|
detailed version number described in net/stmmac.txt
|
||||||
should be used.
|
should be used.
|
||||||
|
|||||||
@@ -3,10 +3,8 @@
|
|||||||
Required properties for the root node:
|
Required properties for the root node:
|
||||||
- compatible: one of "amlogic,meson8-cbus-pinctrl"
|
- compatible: one of "amlogic,meson8-cbus-pinctrl"
|
||||||
"amlogic,meson8b-cbus-pinctrl"
|
"amlogic,meson8b-cbus-pinctrl"
|
||||||
"amlogic,meson8m2-cbus-pinctrl"
|
|
||||||
"amlogic,meson8-aobus-pinctrl"
|
"amlogic,meson8-aobus-pinctrl"
|
||||||
"amlogic,meson8b-aobus-pinctrl"
|
"amlogic,meson8b-aobus-pinctrl"
|
||||||
"amlogic,meson8m2-aobus-pinctrl"
|
|
||||||
"amlogic,meson-gxbb-periphs-pinctrl"
|
"amlogic,meson-gxbb-periphs-pinctrl"
|
||||||
"amlogic,meson-gxbb-aobus-pinctrl"
|
"amlogic,meson-gxbb-aobus-pinctrl"
|
||||||
"amlogic,meson-gxl-periphs-pinctrl"
|
"amlogic,meson-gxl-periphs-pinctrl"
|
||||||
|
|||||||
@@ -1,15 +0,0 @@
|
|||||||
Kernel driver rpi-poe-fan
|
|
||||||
=====================
|
|
||||||
|
|
||||||
This driver enables the use of the Raspberry Pi PoE HAT fan.
|
|
||||||
|
|
||||||
Author: Serge Schneider <serge@raspberrypi.org>
|
|
||||||
|
|
||||||
Description
|
|
||||||
-----------
|
|
||||||
|
|
||||||
The driver implements a simple interface for driving the Raspberry Pi PoE
|
|
||||||
(Power over Ethernet) HAT fan. The driver passes commands to the Raspberry Pi
|
|
||||||
firmware through the mailbox property interface. The firmware then forwards
|
|
||||||
the commands to the board over I2C on the ID_EEPROM pins. The driver exposes
|
|
||||||
the fan to the user space through the hwmon sysfs interface.
|
|
||||||
@@ -133,11 +133,14 @@ min_adv_mss - INTEGER
|
|||||||
|
|
||||||
IP Fragmentation:
|
IP Fragmentation:
|
||||||
|
|
||||||
ipfrag_high_thresh - LONG INTEGER
|
ipfrag_high_thresh - INTEGER
|
||||||
Maximum memory used to reassemble IP fragments.
|
Maximum memory used to reassemble IP fragments. When
|
||||||
|
ipfrag_high_thresh bytes of memory is allocated for this purpose,
|
||||||
|
the fragment handler will toss packets until ipfrag_low_thresh
|
||||||
|
is reached. This also serves as a maximum limit to namespaces
|
||||||
|
different from the initial one.
|
||||||
|
|
||||||
ipfrag_low_thresh - LONG INTEGER
|
ipfrag_low_thresh - INTEGER
|
||||||
(Obsolete since linux-4.17)
|
|
||||||
Maximum memory used to reassemble IP fragments before the kernel
|
Maximum memory used to reassemble IP fragments before the kernel
|
||||||
begins to remove incomplete fragment queues to free up resources.
|
begins to remove incomplete fragment queues to free up resources.
|
||||||
The kernel still accepts new fragments for defragmentation.
|
The kernel still accepts new fragments for defragmentation.
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ GNU C 3.2 gcc --version
|
|||||||
GNU make 3.81 make --version
|
GNU make 3.81 make --version
|
||||||
binutils 2.20 ld -v
|
binutils 2.20 ld -v
|
||||||
util-linux 2.10o fdformat --version
|
util-linux 2.10o fdformat --version
|
||||||
kmod 13 depmod -V
|
module-init-tools 0.9.10 depmod -V
|
||||||
e2fsprogs 1.41.4 e2fsck -V
|
e2fsprogs 1.41.4 e2fsck -V
|
||||||
jfsutils 1.1.3 fsck.jfs -V
|
jfsutils 1.1.3 fsck.jfs -V
|
||||||
reiserfsprogs 3.6.3 reiserfsck -V
|
reiserfsprogs 3.6.3 reiserfsck -V
|
||||||
@@ -141,6 +141,12 @@ is not build with ``CONFIG_KALLSYMS`` and you have no way to rebuild and
|
|||||||
reproduce the Oops with that option, then you can still decode that Oops
|
reproduce the Oops with that option, then you can still decode that Oops
|
||||||
with ksymoops.
|
with ksymoops.
|
||||||
|
|
||||||
|
Module-Init-Tools
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
A new module loader is now in the kernel that requires ``module-init-tools``
|
||||||
|
to use. It is backward compatible with the 2.4.x series kernels.
|
||||||
|
|
||||||
Mkinitrd
|
Mkinitrd
|
||||||
--------
|
--------
|
||||||
|
|
||||||
@@ -340,17 +346,16 @@ Util-linux
|
|||||||
|
|
||||||
- <https://www.kernel.org/pub/linux/utils/util-linux/>
|
- <https://www.kernel.org/pub/linux/utils/util-linux/>
|
||||||
|
|
||||||
Kmod
|
|
||||||
----
|
|
||||||
|
|
||||||
- <https://www.kernel.org/pub/linux/utils/kernel/kmod/>
|
|
||||||
- <https://git.kernel.org/pub/scm/utils/kernel/kmod/kmod.git>
|
|
||||||
|
|
||||||
Ksymoops
|
Ksymoops
|
||||||
--------
|
--------
|
||||||
|
|
||||||
- <https://www.kernel.org/pub/linux/utils/kernel/ksymoops/v2.4/>
|
- <https://www.kernel.org/pub/linux/utils/kernel/ksymoops/v2.4/>
|
||||||
|
|
||||||
|
Module-Init-Tools
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
- <https://www.kernel.org/pub/linux/utils/kernel/module-init-tools/>
|
||||||
|
|
||||||
Mkinitrd
|
Mkinitrd
|
||||||
--------
|
--------
|
||||||
|
|
||||||
|
|||||||
@@ -145,11 +145,6 @@ The functions in the mdev_parent_ops structure are as follows:
|
|||||||
* create: allocate basic resources in a driver for a mediated device
|
* create: allocate basic resources in a driver for a mediated device
|
||||||
* remove: free resources in a driver when a mediated device is destroyed
|
* remove: free resources in a driver when a mediated device is destroyed
|
||||||
|
|
||||||
(Note that mdev-core provides no implicit serialization of create/remove
|
|
||||||
callbacks per mdev parent device, per mdev type, or any other categorization.
|
|
||||||
Vendor drivers are expected to be fully asynchronous in this respect or
|
|
||||||
provide their own internal resource protection.)
|
|
||||||
|
|
||||||
The callbacks in the mdev_parent_ops structure are as follows:
|
The callbacks in the mdev_parent_ops structure are as follows:
|
||||||
|
|
||||||
* open: open callback of mediated device
|
* open: open callback of mediated device
|
||||||
|
|||||||
@@ -123,15 +123,14 @@ memory layout to fit in user mode), check KVM_CAP_MIPS_VZ and use the
|
|||||||
flag KVM_VM_MIPS_VZ.
|
flag KVM_VM_MIPS_VZ.
|
||||||
|
|
||||||
|
|
||||||
4.3 KVM_GET_MSR_INDEX_LIST, KVM_GET_MSR_FEATURE_INDEX_LIST
|
4.3 KVM_GET_MSR_INDEX_LIST
|
||||||
|
|
||||||
Capability: basic, KVM_CAP_GET_MSR_FEATURES for KVM_GET_MSR_FEATURE_INDEX_LIST
|
Capability: basic
|
||||||
Architectures: x86
|
Architectures: x86
|
||||||
Type: system ioctl
|
Type: system
|
||||||
Parameters: struct kvm_msr_list (in/out)
|
Parameters: struct kvm_msr_list (in/out)
|
||||||
Returns: 0 on success; -1 on error
|
Returns: 0 on success; -1 on error
|
||||||
Errors:
|
Errors:
|
||||||
EFAULT: the msr index list cannot be read from or written to
|
|
||||||
E2BIG: the msr index list is to be to fit in the array specified by
|
E2BIG: the msr index list is to be to fit in the array specified by
|
||||||
the user.
|
the user.
|
||||||
|
|
||||||
@@ -140,23 +139,16 @@ struct kvm_msr_list {
|
|||||||
__u32 indices[0];
|
__u32 indices[0];
|
||||||
};
|
};
|
||||||
|
|
||||||
The user fills in the size of the indices array in nmsrs, and in return
|
This ioctl returns the guest msrs that are supported. The list varies
|
||||||
kvm adjusts nmsrs to reflect the actual number of msrs and fills in the
|
by kvm version and host processor, but does not change otherwise. The
|
||||||
indices array with their numbers.
|
user fills in the size of the indices array in nmsrs, and in return
|
||||||
|
kvm adjusts nmsrs to reflect the actual number of msrs and fills in
|
||||||
KVM_GET_MSR_INDEX_LIST returns the guest msrs that are supported. The list
|
the indices array with their numbers.
|
||||||
varies by kvm version and host processor, but does not change otherwise.
|
|
||||||
|
|
||||||
Note: if kvm indicates supports MCE (KVM_CAP_MCE), then the MCE bank MSRs are
|
Note: if kvm indicates supports MCE (KVM_CAP_MCE), then the MCE bank MSRs are
|
||||||
not returned in the MSR list, as different vcpus can have a different number
|
not returned in the MSR list, as different vcpus can have a different number
|
||||||
of banks, as set via the KVM_X86_SETUP_MCE ioctl.
|
of banks, as set via the KVM_X86_SETUP_MCE ioctl.
|
||||||
|
|
||||||
KVM_GET_MSR_FEATURE_INDEX_LIST returns the list of MSRs that can be passed
|
|
||||||
to the KVM_GET_MSRS system ioctl. This lets userspace probe host capabilities
|
|
||||||
and processor features that are exposed via MSRs (e.g., VMX capabilities).
|
|
||||||
This list also varies by kvm version and host processor, but does not change
|
|
||||||
otherwise.
|
|
||||||
|
|
||||||
|
|
||||||
4.4 KVM_CHECK_EXTENSION
|
4.4 KVM_CHECK_EXTENSION
|
||||||
|
|
||||||
@@ -483,22 +475,14 @@ Support for this has been removed. Use KVM_SET_GUEST_DEBUG instead.
|
|||||||
|
|
||||||
4.18 KVM_GET_MSRS
|
4.18 KVM_GET_MSRS
|
||||||
|
|
||||||
Capability: basic (vcpu), KVM_CAP_GET_MSR_FEATURES (system)
|
Capability: basic
|
||||||
Architectures: x86
|
Architectures: x86
|
||||||
Type: system ioctl, vcpu ioctl
|
Type: vcpu ioctl
|
||||||
Parameters: struct kvm_msrs (in/out)
|
Parameters: struct kvm_msrs (in/out)
|
||||||
Returns: number of msrs successfully returned;
|
Returns: 0 on success, -1 on error
|
||||||
-1 on error
|
|
||||||
|
|
||||||
When used as a system ioctl:
|
|
||||||
Reads the values of MSR-based features that are available for the VM. This
|
|
||||||
is similar to KVM_GET_SUPPORTED_CPUID, but it returns MSR indices and values.
|
|
||||||
The list of msr-based features can be obtained using KVM_GET_MSR_FEATURE_INDEX_LIST
|
|
||||||
in a system ioctl.
|
|
||||||
|
|
||||||
When used as a vcpu ioctl:
|
|
||||||
Reads model-specific registers from the vcpu. Supported msr indices can
|
Reads model-specific registers from the vcpu. Supported msr indices can
|
||||||
be obtained using KVM_GET_MSR_INDEX_LIST in a system ioctl.
|
be obtained using KVM_GET_MSR_INDEX_LIST.
|
||||||
|
|
||||||
struct kvm_msrs {
|
struct kvm_msrs {
|
||||||
__u32 nmsrs; /* number of msrs in entries */
|
__u32 nmsrs; /* number of msrs in entries */
|
||||||
|
|||||||
12
Makefile
12
Makefile
@@ -1,7 +1,7 @@
|
|||||||
# SPDX-License-Identifier: GPL-2.0
|
# SPDX-License-Identifier: GPL-2.0
|
||||||
VERSION = 4
|
VERSION = 4
|
||||||
PATCHLEVEL = 14
|
PATCHLEVEL = 14
|
||||||
SUBLEVEL = 71
|
SUBLEVEL = 59
|
||||||
EXTRAVERSION =
|
EXTRAVERSION =
|
||||||
NAME = Petit Gorille
|
NAME = Petit Gorille
|
||||||
|
|
||||||
@@ -357,9 +357,9 @@ CONFIG_SHELL := $(shell if [ -x "$$BASH" ]; then echo $$BASH; \
|
|||||||
else if [ -x /bin/bash ]; then echo /bin/bash; \
|
else if [ -x /bin/bash ]; then echo /bin/bash; \
|
||||||
else echo sh; fi ; fi)
|
else echo sh; fi ; fi)
|
||||||
|
|
||||||
HOST_LFS_CFLAGS := $(shell getconf LFS_CFLAGS 2>/dev/null)
|
HOST_LFS_CFLAGS := $(shell getconf LFS_CFLAGS)
|
||||||
HOST_LFS_LDFLAGS := $(shell getconf LFS_LDFLAGS 2>/dev/null)
|
HOST_LFS_LDFLAGS := $(shell getconf LFS_LDFLAGS)
|
||||||
HOST_LFS_LIBS := $(shell getconf LFS_LIBS 2>/dev/null)
|
HOST_LFS_LIBS := $(shell getconf LFS_LIBS)
|
||||||
|
|
||||||
HOSTCC = gcc
|
HOSTCC = gcc
|
||||||
HOSTCXX = g++
|
HOSTCXX = g++
|
||||||
@@ -490,13 +490,9 @@ KBUILD_AFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
RETPOLINE_CFLAGS_GCC := -mindirect-branch=thunk-extern -mindirect-branch-register
|
RETPOLINE_CFLAGS_GCC := -mindirect-branch=thunk-extern -mindirect-branch-register
|
||||||
RETPOLINE_VDSO_CFLAGS_GCC := -mindirect-branch=thunk-inline -mindirect-branch-register
|
|
||||||
RETPOLINE_CFLAGS_CLANG := -mretpoline-external-thunk
|
RETPOLINE_CFLAGS_CLANG := -mretpoline-external-thunk
|
||||||
RETPOLINE_VDSO_CFLAGS_CLANG := -mretpoline
|
|
||||||
RETPOLINE_CFLAGS := $(call cc-option,$(RETPOLINE_CFLAGS_GCC),$(call cc-option,$(RETPOLINE_CFLAGS_CLANG)))
|
RETPOLINE_CFLAGS := $(call cc-option,$(RETPOLINE_CFLAGS_GCC),$(call cc-option,$(RETPOLINE_CFLAGS_CLANG)))
|
||||||
RETPOLINE_VDSO_CFLAGS := $(call cc-option,$(RETPOLINE_VDSO_CFLAGS_GCC),$(call cc-option,$(RETPOLINE_VDSO_CFLAGS_CLANG)))
|
|
||||||
export RETPOLINE_CFLAGS
|
export RETPOLINE_CFLAGS
|
||||||
export RETPOLINE_VDSO_CFLAGS
|
|
||||||
|
|
||||||
ifeq ($(config-targets),1)
|
ifeq ($(config-targets),1)
|
||||||
# ===========================================================================
|
# ===========================================================================
|
||||||
|
|||||||
@@ -13,9 +13,6 @@ config KEXEC_CORE
|
|||||||
config HAVE_IMA_KEXEC
|
config HAVE_IMA_KEXEC
|
||||||
bool
|
bool
|
||||||
|
|
||||||
config HOTPLUG_SMT
|
|
||||||
bool
|
|
||||||
|
|
||||||
config OPROFILE
|
config OPROFILE
|
||||||
tristate "OProfile system profiling"
|
tristate "OProfile system profiling"
|
||||||
depends on PROFILING
|
depends on PROFILING
|
||||||
@@ -336,9 +333,6 @@ config HAVE_ARCH_JUMP_LABEL
|
|||||||
config HAVE_RCU_TABLE_FREE
|
config HAVE_RCU_TABLE_FREE
|
||||||
bool
|
bool
|
||||||
|
|
||||||
config HAVE_RCU_TABLE_INVALIDATE
|
|
||||||
bool
|
|
||||||
|
|
||||||
config ARCH_HAVE_NMI_SAFE_CMPXCHG
|
config ARCH_HAVE_NMI_SAFE_CMPXCHG
|
||||||
bool
|
bool
|
||||||
|
|
||||||
|
|||||||
@@ -530,19 +530,24 @@ SYSCALL_DEFINE4(osf_mount, unsigned long, typenr, const char __user *, path,
|
|||||||
SYSCALL_DEFINE1(osf_utsname, char __user *, name)
|
SYSCALL_DEFINE1(osf_utsname, char __user *, name)
|
||||||
{
|
{
|
||||||
int error;
|
int error;
|
||||||
char tmp[5 * 32];
|
|
||||||
|
|
||||||
down_read(&uts_sem);
|
down_read(&uts_sem);
|
||||||
memcpy(tmp + 0 * 32, utsname()->sysname, 32);
|
error = -EFAULT;
|
||||||
memcpy(tmp + 1 * 32, utsname()->nodename, 32);
|
if (copy_to_user(name + 0, utsname()->sysname, 32))
|
||||||
memcpy(tmp + 2 * 32, utsname()->release, 32);
|
goto out;
|
||||||
memcpy(tmp + 3 * 32, utsname()->version, 32);
|
if (copy_to_user(name + 32, utsname()->nodename, 32))
|
||||||
memcpy(tmp + 4 * 32, utsname()->machine, 32);
|
goto out;
|
||||||
up_read(&uts_sem);
|
if (copy_to_user(name + 64, utsname()->release, 32))
|
||||||
|
goto out;
|
||||||
|
if (copy_to_user(name + 96, utsname()->version, 32))
|
||||||
|
goto out;
|
||||||
|
if (copy_to_user(name + 128, utsname()->machine, 32))
|
||||||
|
goto out;
|
||||||
|
|
||||||
if (copy_to_user(name, tmp, sizeof(tmp)))
|
error = 0;
|
||||||
return -EFAULT;
|
out:
|
||||||
return 0;
|
up_read(&uts_sem);
|
||||||
|
return error;
|
||||||
}
|
}
|
||||||
|
|
||||||
SYSCALL_DEFINE0(getpagesize)
|
SYSCALL_DEFINE0(getpagesize)
|
||||||
@@ -562,21 +567,18 @@ SYSCALL_DEFINE2(osf_getdomainname, char __user *, name, int, namelen)
|
|||||||
{
|
{
|
||||||
int len, err = 0;
|
int len, err = 0;
|
||||||
char *kname;
|
char *kname;
|
||||||
char tmp[32];
|
|
||||||
|
|
||||||
if (namelen < 0 || namelen > 32)
|
if (namelen > 32)
|
||||||
namelen = 32;
|
namelen = 32;
|
||||||
|
|
||||||
down_read(&uts_sem);
|
down_read(&uts_sem);
|
||||||
kname = utsname()->domainname;
|
kname = utsname()->domainname;
|
||||||
len = strnlen(kname, namelen);
|
len = strnlen(kname, namelen);
|
||||||
len = min(len + 1, namelen);
|
if (copy_to_user(name, kname, min(len + 1, namelen)))
|
||||||
memcpy(tmp, kname, len);
|
err = -EFAULT;
|
||||||
up_read(&uts_sem);
|
up_read(&uts_sem);
|
||||||
|
|
||||||
if (copy_to_user(name, tmp, len))
|
return err;
|
||||||
return -EFAULT;
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -737,14 +739,13 @@ SYSCALL_DEFINE3(osf_sysinfo, int, command, char __user *, buf, long, count)
|
|||||||
};
|
};
|
||||||
unsigned long offset;
|
unsigned long offset;
|
||||||
const char *res;
|
const char *res;
|
||||||
long len;
|
long len, err = -EINVAL;
|
||||||
char tmp[__NEW_UTS_LEN + 1];
|
|
||||||
|
|
||||||
offset = command-1;
|
offset = command-1;
|
||||||
if (offset >= ARRAY_SIZE(sysinfo_table)) {
|
if (offset >= ARRAY_SIZE(sysinfo_table)) {
|
||||||
/* Digital UNIX has a few unpublished interfaces here */
|
/* Digital UNIX has a few unpublished interfaces here */
|
||||||
printk("sysinfo(%d)", command);
|
printk("sysinfo(%d)", command);
|
||||||
return -EINVAL;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
down_read(&uts_sem);
|
down_read(&uts_sem);
|
||||||
@@ -752,11 +753,13 @@ SYSCALL_DEFINE3(osf_sysinfo, int, command, char __user *, buf, long, count)
|
|||||||
len = strlen(res)+1;
|
len = strlen(res)+1;
|
||||||
if ((unsigned long)len > (unsigned long)count)
|
if ((unsigned long)len > (unsigned long)count)
|
||||||
len = count;
|
len = count;
|
||||||
memcpy(tmp, res, len);
|
if (copy_to_user(buf, res, len))
|
||||||
|
err = -EFAULT;
|
||||||
|
else
|
||||||
|
err = 0;
|
||||||
up_read(&uts_sem);
|
up_read(&uts_sem);
|
||||||
if (copy_to_user(buf, tmp, len))
|
out:
|
||||||
return -EFAULT;
|
return err;
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SYSCALL_DEFINE5(osf_getsysinfo, unsigned long, op, void __user *, buffer,
|
SYSCALL_DEFINE5(osf_getsysinfo, unsigned long, op, void __user *, buffer,
|
||||||
|
|||||||
@@ -45,9 +45,6 @@ config ARC
|
|||||||
select HAVE_KERNEL_GZIP
|
select HAVE_KERNEL_GZIP
|
||||||
select HAVE_KERNEL_LZMA
|
select HAVE_KERNEL_LZMA
|
||||||
|
|
||||||
config ARCH_HAS_CACHE_LINE_SIZE
|
|
||||||
def_bool y
|
|
||||||
|
|
||||||
config MIGHT_HAVE_PCI
|
config MIGHT_HAVE_PCI
|
||||||
bool
|
bool
|
||||||
|
|
||||||
|
|||||||
@@ -16,7 +16,7 @@ endif
|
|||||||
|
|
||||||
KBUILD_DEFCONFIG := nsim_700_defconfig
|
KBUILD_DEFCONFIG := nsim_700_defconfig
|
||||||
|
|
||||||
cflags-y += -fno-common -pipe -fno-builtin -mmedium-calls -D__linux__
|
cflags-y += -fno-common -pipe -fno-builtin -D__linux__
|
||||||
cflags-$(CONFIG_ISA_ARCOMPACT) += -mA7
|
cflags-$(CONFIG_ISA_ARCOMPACT) += -mA7
|
||||||
cflags-$(CONFIG_ISA_ARCV2) += -mcpu=archs
|
cflags-$(CONFIG_ISA_ARCV2) += -mcpu=archs
|
||||||
|
|
||||||
@@ -140,3 +140,16 @@ dtbs: scripts
|
|||||||
|
|
||||||
archclean:
|
archclean:
|
||||||
$(Q)$(MAKE) $(clean)=$(boot)
|
$(Q)$(MAKE) $(clean)=$(boot)
|
||||||
|
|
||||||
|
# Hacks to enable final link due to absence of link-time branch relexation
|
||||||
|
# and gcc choosing optimal(shorter) branches at -O3
|
||||||
|
#
|
||||||
|
# vineetg Feb 2010: -mlong-calls switched off for overall kernel build
|
||||||
|
# However lib/decompress_inflate.o (.init.text) calls
|
||||||
|
# zlib_inflate_workspacesize (.text) causing relocation errors.
|
||||||
|
# Thus forcing all exten calls in this file to be long calls
|
||||||
|
export CFLAGS_decompress_inflate.o = -mmedium-calls
|
||||||
|
export CFLAGS_initramfs.o = -mmedium-calls
|
||||||
|
ifdef CONFIG_SMP
|
||||||
|
export CFLAGS_core.o = -mmedium-calls
|
||||||
|
endif
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
||||||
|
# CONFIG_SWAP is not set
|
||||||
CONFIG_SYSVIPC=y
|
CONFIG_SYSVIPC=y
|
||||||
CONFIG_POSIX_MQUEUE=y
|
CONFIG_POSIX_MQUEUE=y
|
||||||
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
||||||
|
# CONFIG_SWAP is not set
|
||||||
CONFIG_SYSVIPC=y
|
CONFIG_SYSVIPC=y
|
||||||
CONFIG_POSIX_MQUEUE=y
|
CONFIG_POSIX_MQUEUE=y
|
||||||
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
CONFIG_DEFAULT_HOSTNAME="ARCLinux"
|
||||||
|
# CONFIG_SWAP is not set
|
||||||
CONFIG_SYSVIPC=y
|
CONFIG_SYSVIPC=y
|
||||||
CONFIG_POSIX_MQUEUE=y
|
CONFIG_POSIX_MQUEUE=y
|
||||||
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
# CONFIG_CROSS_MEMORY_ATTACH is not set
|
||||||
|
|||||||
@@ -48,9 +48,7 @@
|
|||||||
})
|
})
|
||||||
|
|
||||||
/* Largest line length for either L1 or L2 is 128 bytes */
|
/* Largest line length for either L1 or L2 is 128 bytes */
|
||||||
#define SMP_CACHE_BYTES 128
|
#define ARCH_DMA_MINALIGN 128
|
||||||
#define cache_line_size() SMP_CACHE_BYTES
|
|
||||||
#define ARCH_DMA_MINALIGN SMP_CACHE_BYTES
|
|
||||||
|
|
||||||
extern void arc_cache_init(void);
|
extern void arc_cache_init(void);
|
||||||
extern char *arc_cache_mumbojumbo(int cpu_id, char *buf, int len);
|
extern char *arc_cache_mumbojumbo(int cpu_id, char *buf, int len);
|
||||||
|
|||||||
@@ -17,11 +17,8 @@
|
|||||||
#ifndef __ASM_ARC_UDELAY_H
|
#ifndef __ASM_ARC_UDELAY_H
|
||||||
#define __ASM_ARC_UDELAY_H
|
#define __ASM_ARC_UDELAY_H
|
||||||
|
|
||||||
#include <asm-generic/types.h>
|
|
||||||
#include <asm/param.h> /* HZ */
|
#include <asm/param.h> /* HZ */
|
||||||
|
|
||||||
extern unsigned long loops_per_jiffy;
|
|
||||||
|
|
||||||
static inline void __delay(unsigned long loops)
|
static inline void __delay(unsigned long loops)
|
||||||
{
|
{
|
||||||
__asm__ __volatile__(
|
__asm__ __volatile__(
|
||||||
|
|||||||
@@ -34,7 +34,9 @@ struct machine_desc {
|
|||||||
const char *name;
|
const char *name;
|
||||||
const char **dt_compat;
|
const char **dt_compat;
|
||||||
void (*init_early)(void);
|
void (*init_early)(void);
|
||||||
|
#ifdef CONFIG_SMP
|
||||||
void (*init_per_cpu)(unsigned int);
|
void (*init_per_cpu)(unsigned int);
|
||||||
|
#endif
|
||||||
void (*init_machine)(void);
|
void (*init_machine)(void);
|
||||||
void (*init_late)(void);
|
void (*init_late)(void);
|
||||||
|
|
||||||
|
|||||||
@@ -31,10 +31,10 @@ void __init init_IRQ(void)
|
|||||||
/* a SMP H/w block could do IPI IRQ request here */
|
/* a SMP H/w block could do IPI IRQ request here */
|
||||||
if (plat_smp_ops.init_per_cpu)
|
if (plat_smp_ops.init_per_cpu)
|
||||||
plat_smp_ops.init_per_cpu(smp_processor_id());
|
plat_smp_ops.init_per_cpu(smp_processor_id());
|
||||||
#endif
|
|
||||||
|
|
||||||
if (machine_desc->init_per_cpu)
|
if (machine_desc->init_per_cpu)
|
||||||
machine_desc->init_per_cpu(smp_processor_id());
|
machine_desc->init_per_cpu(smp_processor_id());
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -47,8 +47,7 @@ SYSCALL_DEFINE0(arc_gettls)
|
|||||||
SYSCALL_DEFINE3(arc_usr_cmpxchg, int *, uaddr, int, expected, int, new)
|
SYSCALL_DEFINE3(arc_usr_cmpxchg, int *, uaddr, int, expected, int, new)
|
||||||
{
|
{
|
||||||
struct pt_regs *regs = current_pt_regs();
|
struct pt_regs *regs = current_pt_regs();
|
||||||
u32 uval;
|
int uval = -EFAULT;
|
||||||
int ret;
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* This is only for old cores lacking LLOCK/SCOND, which by defintion
|
* This is only for old cores lacking LLOCK/SCOND, which by defintion
|
||||||
@@ -61,47 +60,23 @@ SYSCALL_DEFINE3(arc_usr_cmpxchg, int *, uaddr, int, expected, int, new)
|
|||||||
/* Z indicates to userspace if operation succeded */
|
/* Z indicates to userspace if operation succeded */
|
||||||
regs->status32 &= ~STATUS_Z_MASK;
|
regs->status32 &= ~STATUS_Z_MASK;
|
||||||
|
|
||||||
ret = access_ok(VERIFY_WRITE, uaddr, sizeof(*uaddr));
|
if (!access_ok(VERIFY_WRITE, uaddr, sizeof(int)))
|
||||||
if (!ret)
|
return -EFAULT;
|
||||||
goto fail;
|
|
||||||
|
|
||||||
again:
|
|
||||||
preempt_disable();
|
preempt_disable();
|
||||||
|
|
||||||
ret = __get_user(uval, uaddr);
|
if (__get_user(uval, uaddr))
|
||||||
if (ret)
|
goto done;
|
||||||
goto fault;
|
|
||||||
|
|
||||||
if (uval != expected)
|
if (uval == expected) {
|
||||||
goto out;
|
if (!__put_user(new, uaddr))
|
||||||
|
regs->status32 |= STATUS_Z_MASK;
|
||||||
|
}
|
||||||
|
|
||||||
ret = __put_user(new, uaddr);
|
done:
|
||||||
if (ret)
|
|
||||||
goto fault;
|
|
||||||
|
|
||||||
regs->status32 |= STATUS_Z_MASK;
|
|
||||||
|
|
||||||
out:
|
|
||||||
preempt_enable();
|
preempt_enable();
|
||||||
|
|
||||||
return uval;
|
return uval;
|
||||||
|
|
||||||
fault:
|
|
||||||
preempt_enable();
|
|
||||||
|
|
||||||
if (unlikely(ret != -EFAULT))
|
|
||||||
goto fail;
|
|
||||||
|
|
||||||
down_read(¤t->mm->mmap_sem);
|
|
||||||
ret = fixup_user_fault(current, current->mm, (unsigned long) uaddr,
|
|
||||||
FAULT_FLAG_WRITE, NULL);
|
|
||||||
up_read(¤t->mm->mmap_sem);
|
|
||||||
|
|
||||||
if (likely(!ret))
|
|
||||||
goto again;
|
|
||||||
|
|
||||||
fail:
|
|
||||||
force_sig(SIGSEGV, current);
|
|
||||||
return ret;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_ISA_ARCV2
|
#ifdef CONFIG_ISA_ARCV2
|
||||||
|
|||||||
@@ -1035,7 +1035,7 @@ void flush_cache_mm(struct mm_struct *mm)
|
|||||||
void flush_cache_page(struct vm_area_struct *vma, unsigned long u_vaddr,
|
void flush_cache_page(struct vm_area_struct *vma, unsigned long u_vaddr,
|
||||||
unsigned long pfn)
|
unsigned long pfn)
|
||||||
{
|
{
|
||||||
phys_addr_t paddr = pfn << PAGE_SHIFT;
|
unsigned int paddr = pfn << PAGE_SHIFT;
|
||||||
|
|
||||||
u_vaddr &= PAGE_MASK;
|
u_vaddr &= PAGE_MASK;
|
||||||
|
|
||||||
@@ -1055,9 +1055,8 @@ void flush_anon_page(struct vm_area_struct *vma, struct page *page,
|
|||||||
unsigned long u_vaddr)
|
unsigned long u_vaddr)
|
||||||
{
|
{
|
||||||
/* TBD: do we really need to clear the kernel mapping */
|
/* TBD: do we really need to clear the kernel mapping */
|
||||||
__flush_dcache_page((phys_addr_t)page_address(page), u_vaddr);
|
__flush_dcache_page(page_address(page), u_vaddr);
|
||||||
__flush_dcache_page((phys_addr_t)page_address(page),
|
__flush_dcache_page(page_address(page), page_address(page));
|
||||||
(phys_addr_t)page_address(page));
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,6 @@
|
|||||||
#error "Incorrect ctop.h include"
|
#error "Incorrect ctop.h include"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <linux/types.h>
|
|
||||||
#include <soc/nps/common.h>
|
#include <soc/nps/common.h>
|
||||||
|
|
||||||
/* core auxiliary registers */
|
/* core auxiliary registers */
|
||||||
@@ -144,15 +143,6 @@ struct nps_host_reg_gim_p_int_dst {
|
|||||||
};
|
};
|
||||||
|
|
||||||
/* AUX registers definition */
|
/* AUX registers definition */
|
||||||
struct nps_host_reg_aux_dpc {
|
|
||||||
union {
|
|
||||||
struct {
|
|
||||||
u32 ien:1, men:1, hen:1, reserved:29;
|
|
||||||
};
|
|
||||||
u32 value;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
struct nps_host_reg_aux_udmc {
|
struct nps_host_reg_aux_udmc {
|
||||||
union {
|
union {
|
||||||
struct {
|
struct {
|
||||||
|
|||||||
@@ -15,8 +15,6 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <linux/smp.h>
|
#include <linux/smp.h>
|
||||||
#include <linux/init.h>
|
|
||||||
#include <linux/kernel.h>
|
|
||||||
#include <linux/io.h>
|
#include <linux/io.h>
|
||||||
#include <linux/log2.h>
|
#include <linux/log2.h>
|
||||||
#include <asm/arcregs.h>
|
#include <asm/arcregs.h>
|
||||||
@@ -159,10 +157,10 @@ void mtm_enable_core(unsigned int cpu)
|
|||||||
/* Verify and set the value of the mtm hs counter */
|
/* Verify and set the value of the mtm hs counter */
|
||||||
static int __init set_mtm_hs_ctr(char *ctr_str)
|
static int __init set_mtm_hs_ctr(char *ctr_str)
|
||||||
{
|
{
|
||||||
int hs_ctr;
|
long hs_ctr;
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
ret = kstrtoint(ctr_str, 0, &hs_ctr);
|
ret = kstrtol(ctr_str, 0, &hs_ctr);
|
||||||
|
|
||||||
if (ret || hs_ctr > MT_HS_CNT_MAX || hs_ctr < MT_HS_CNT_MIN) {
|
if (ret || hs_ctr > MT_HS_CNT_MAX || hs_ctr < MT_HS_CNT_MIN) {
|
||||||
pr_err("** Invalid @nps_mtm_hs_ctr [%d] needs to be [%d:%d] (incl)\n",
|
pr_err("** Invalid @nps_mtm_hs_ctr [%d] needs to be [%d:%d] (incl)\n",
|
||||||
|
|||||||
@@ -87,11 +87,6 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Table Table 5-79 of the TRM shows 480ab000 is reserved */
|
|
||||||
&usb_otg_hs {
|
|
||||||
status = "disabled";
|
|
||||||
};
|
|
||||||
|
|
||||||
&iva {
|
&iva {
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -535,8 +535,6 @@
|
|||||||
|
|
||||||
touchscreen-size-x = <480>;
|
touchscreen-size-x = <480>;
|
||||||
touchscreen-size-y = <272>;
|
touchscreen-size-y = <272>;
|
||||||
|
|
||||||
wakeup-source;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
tlv320aic3106: tlv320aic3106@1b {
|
tlv320aic3106: tlv320aic3106@1b {
|
||||||
|
|||||||
@@ -170,7 +170,7 @@
|
|||||||
3700 5
|
3700 5
|
||||||
3900 6
|
3900 6
|
||||||
4000 7>;
|
4000 7>;
|
||||||
#cooling-cells = <2>;
|
cooling-cells = <2>;
|
||||||
};
|
};
|
||||||
|
|
||||||
gpio-leds {
|
gpio-leds {
|
||||||
|
|||||||
@@ -216,7 +216,7 @@
|
|||||||
reg = <0x18008000 0x100>;
|
reg = <0x18008000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 85 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 85 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
@@ -245,7 +245,7 @@
|
|||||||
reg = <0x1800b000 0x100>;
|
reg = <0x1800b000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 86 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
@@ -256,7 +256,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic GIC_SPI 100 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic GIC_SPI 100 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <0>;
|
linux,pci-domain = <0>;
|
||||||
|
|
||||||
@@ -278,10 +278,10 @@
|
|||||||
compatible = "brcm,iproc-msi";
|
compatible = "brcm,iproc-msi";
|
||||||
msi-controller;
|
msi-controller;
|
||||||
interrupt-parent = <&gic>;
|
interrupt-parent = <&gic>;
|
||||||
interrupts = <GIC_SPI 96 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 96 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 97 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 97 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 98 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 98 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 99 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 99 IRQ_TYPE_NONE>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -291,7 +291,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic GIC_SPI 106 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic GIC_SPI 106 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <1>;
|
linux,pci-domain = <1>;
|
||||||
|
|
||||||
@@ -313,10 +313,10 @@
|
|||||||
compatible = "brcm,iproc-msi";
|
compatible = "brcm,iproc-msi";
|
||||||
msi-controller;
|
msi-controller;
|
||||||
interrupt-parent = <&gic>;
|
interrupt-parent = <&gic>;
|
||||||
interrupts = <GIC_SPI 102 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 102 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 103 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 104 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 104 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 105 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 105 IRQ_TYPE_NONE>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -391,7 +391,7 @@
|
|||||||
reg = <0x38000 0x50>;
|
reg = <0x38000 0x50>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 89 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
dma-coherent;
|
dma-coherent;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
@@ -496,7 +496,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic GIC_SPI 131 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic GIC_SPI 131 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <0>;
|
linux,pci-domain = <0>;
|
||||||
|
|
||||||
@@ -519,10 +519,10 @@
|
|||||||
compatible = "brcm,iproc-msi";
|
compatible = "brcm,iproc-msi";
|
||||||
msi-controller;
|
msi-controller;
|
||||||
interrupt-parent = <&gic>;
|
interrupt-parent = <&gic>;
|
||||||
interrupts = <GIC_SPI 127 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 127 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 128 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 128 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 129 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 129 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 130 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 130 IRQ_TYPE_NONE>;
|
||||||
brcm,pcie-msi-inten;
|
brcm,pcie-msi-inten;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -533,7 +533,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic GIC_SPI 137 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic GIC_SPI 137 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <1>;
|
linux,pci-domain = <1>;
|
||||||
|
|
||||||
@@ -556,10 +556,10 @@
|
|||||||
compatible = "brcm,iproc-msi";
|
compatible = "brcm,iproc-msi";
|
||||||
msi-controller;
|
msi-controller;
|
||||||
interrupt-parent = <&gic>;
|
interrupt-parent = <&gic>;
|
||||||
interrupts = <GIC_SPI 133 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 133 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 134 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 134 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 135 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 136 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 136 IRQ_TYPE_NONE>;
|
||||||
brcm,pcie-msi-inten;
|
brcm,pcie-msi-inten;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -570,7 +570,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic GIC_SPI 143 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic GIC_SPI 143 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <2>;
|
linux,pci-domain = <2>;
|
||||||
|
|
||||||
@@ -593,10 +593,10 @@
|
|||||||
compatible = "brcm,iproc-msi";
|
compatible = "brcm,iproc-msi";
|
||||||
msi-controller;
|
msi-controller;
|
||||||
interrupt-parent = <&gic>;
|
interrupt-parent = <&gic>;
|
||||||
interrupts = <GIC_SPI 139 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 139 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 140 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 140 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 141 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 141 IRQ_TYPE_NONE>,
|
||||||
<GIC_SPI 142 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 142 IRQ_TYPE_NONE>;
|
||||||
brcm,pcie-msi-inten;
|
brcm,pcie-msi-inten;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -152,13 +152,6 @@
|
|||||||
regulator-max-microvolt = <3300000>;
|
regulator-max-microvolt = <3300000>;
|
||||||
regulator-always-on;
|
regulator-always-on;
|
||||||
};
|
};
|
||||||
|
|
||||||
__overrides__ {
|
|
||||||
cam0-pwdn-ctrl;
|
|
||||||
cam0-pwdn;
|
|
||||||
cam0-led-ctrl;
|
|
||||||
cam0-led;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Configure and use the auxilliary interrupt controller */
|
/* Configure and use the auxilliary interrupt controller */
|
||||||
|
|||||||
@@ -365,7 +365,7 @@
|
|||||||
i2c0: i2c@18009000 {
|
i2c0: i2c@18009000 {
|
||||||
compatible = "brcm,iproc-i2c";
|
compatible = "brcm,iproc-i2c";
|
||||||
reg = <0x18009000 0x50>;
|
reg = <0x18009000 0x50>;
|
||||||
interrupts = <GIC_SPI 121 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 121 IRQ_TYPE_NONE>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
|
|||||||
@@ -518,7 +518,11 @@
|
|||||||
gpio-controller;
|
gpio-controller;
|
||||||
#gpio-cells = <2>;
|
#gpio-cells = <2>;
|
||||||
reg = <0x226000 0x1000>;
|
reg = <0x226000 0x1000>;
|
||||||
interrupts = <42 43 44 45 46 47 48 49 50>;
|
interrupts = <42 IRQ_TYPE_EDGE_BOTH
|
||||||
|
43 IRQ_TYPE_EDGE_BOTH 44 IRQ_TYPE_EDGE_BOTH
|
||||||
|
45 IRQ_TYPE_EDGE_BOTH 46 IRQ_TYPE_EDGE_BOTH
|
||||||
|
47 IRQ_TYPE_EDGE_BOTH 48 IRQ_TYPE_EDGE_BOTH
|
||||||
|
49 IRQ_TYPE_EDGE_BOTH 50 IRQ_TYPE_EDGE_BOTH>;
|
||||||
ti,ngpio = <144>;
|
ti,ngpio = <144>;
|
||||||
ti,davinci-gpio-unbanked = <0>;
|
ti,davinci-gpio-unbanked = <0>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
|
|||||||
@@ -31,13 +31,13 @@
|
|||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
|
|
||||||
cpu0: cpu@0 {
|
cpu@0 {
|
||||||
device_type = "cpu";
|
device_type = "cpu";
|
||||||
compatible = "arm,cortex-a9";
|
compatible = "arm,cortex-a9";
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
clock-frequency = <533000000>;
|
clock-frequency = <533000000>;
|
||||||
};
|
};
|
||||||
cpu1: cpu@1 {
|
cpu@1 {
|
||||||
device_type = "cpu";
|
device_type = "cpu";
|
||||||
compatible = "arm,cortex-a9";
|
compatible = "arm,cortex-a9";
|
||||||
reg = <1>;
|
reg = <1>;
|
||||||
@@ -57,7 +57,6 @@
|
|||||||
compatible = "arm,cortex-a9-pmu";
|
compatible = "arm,cortex-a9-pmu";
|
||||||
interrupts = <GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>,
|
||||||
<GIC_SPI 121 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 121 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
interrupt-affinity = <&cpu0>, <&cpu1>;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
clocks@e0110000 {
|
clocks@e0110000 {
|
||||||
|
|||||||
@@ -644,7 +644,7 @@
|
|||||||
dsa,member = <0 0>;
|
dsa,member = <0 0>;
|
||||||
eeprom-length = <512>;
|
eeprom-length = <512>;
|
||||||
interrupt-parent = <&gpio6>;
|
interrupt-parent = <&gpio6>;
|
||||||
interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
|
interrupts = <3 IRQ_TYPE_EDGE_FALLING>;
|
||||||
interrupt-controller;
|
interrupt-controller;
|
||||||
#interrupt-cells = <2>;
|
#interrupt-cells = <2>;
|
||||||
|
|
||||||
|
|||||||
@@ -1305,7 +1305,7 @@
|
|||||||
0x82000000 0 0x08000000 0x08000000 0 0x00f00000>;
|
0x82000000 0 0x08000000 0x08000000 0 0x00f00000>;
|
||||||
bus-range = <0x00 0xff>;
|
bus-range = <0x00 0xff>;
|
||||||
num-lanes = <1>;
|
num-lanes = <1>;
|
||||||
interrupts = <GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 123 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
clocks = <&clks IMX6SX_CLK_PCIE_REF_125M>,
|
clocks = <&clks IMX6SX_CLK_PCIE_REF_125M>,
|
||||||
<&clks IMX6SX_CLK_PCIE_AXI>,
|
<&clks IMX6SX_CLK_PCIE_AXI>,
|
||||||
<&clks IMX6SX_CLK_LVDS1_OUT>,
|
<&clks IMX6SX_CLK_LVDS1_OUT>,
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
|
|||||||
ads1115.dtbo \
|
ads1115.dtbo \
|
||||||
ads7846.dtbo \
|
ads7846.dtbo \
|
||||||
adv7282m.dtbo \
|
adv7282m.dtbo \
|
||||||
adv728x-m.dtbo \
|
|
||||||
akkordion-iqdacplus.dtbo \
|
akkordion-iqdacplus.dtbo \
|
||||||
allo-boss-dac-pcm512x-audio.dtbo \
|
allo-boss-dac-pcm512x-audio.dtbo \
|
||||||
allo-digione.dtbo \
|
allo-digione.dtbo \
|
||||||
@@ -17,7 +16,6 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
|
|||||||
applepi-dac.dtbo \
|
applepi-dac.dtbo \
|
||||||
at86rf233.dtbo \
|
at86rf233.dtbo \
|
||||||
audioinjector-addons.dtbo \
|
audioinjector-addons.dtbo \
|
||||||
audioinjector-ultra.dtbo \
|
|
||||||
audioinjector-wm8731-audio.dtbo \
|
audioinjector-wm8731-audio.dtbo \
|
||||||
audremap.dtbo \
|
audremap.dtbo \
|
||||||
balena-fin.dtbo \
|
balena-fin.dtbo \
|
||||||
@@ -35,7 +33,6 @@ dtbo-$(CONFIG_ARCH_BCM2835) += \
|
|||||||
fe-pi-audio.dtbo \
|
fe-pi-audio.dtbo \
|
||||||
goodix.dtbo \
|
goodix.dtbo \
|
||||||
googlevoicehat-soundcard.dtbo \
|
googlevoicehat-soundcard.dtbo \
|
||||||
gpio-fan.dtbo \
|
|
||||||
gpio-ir.dtbo \
|
gpio-ir.dtbo \
|
||||||
gpio-ir-tx.dtbo \
|
gpio-ir-tx.dtbo \
|
||||||
gpio-key.dtbo \
|
gpio-key.dtbo \
|
||||||
|
|||||||
@@ -274,19 +274,6 @@ Info: Analog Devices ADV7282M analogue video to CSI2 bridge.
|
|||||||
Load: dtoverlay=adv7282m,<param>=<val>
|
Load: dtoverlay=adv7282m,<param>=<val>
|
||||||
Params: i2c_pins_28_29 Use pins 28&29 for the I2C instead of 44&45.
|
Params: i2c_pins_28_29 Use pins 28&29 for the I2C instead of 44&45.
|
||||||
This is required for Pi B+, 2, 0, and 0W.
|
This is required for Pi B+, 2, 0, and 0W.
|
||||||
addr Overrides the I2C address (default 0x21)
|
|
||||||
|
|
||||||
|
|
||||||
Name: adv728x-m
|
|
||||||
Info: Analog Devices ADV728[0|1|2]-M analogue video to CSI2 bridges.
|
|
||||||
This is a wrapper for adv7282m, and defaults to ADV7282M.
|
|
||||||
Load: dtoverlay=adv728x-m,<param>=<val>
|
|
||||||
Params: i2c_pins_28_29 Use pins 28&29 for the I2C instead of 44&45.
|
|
||||||
This is required for Pi B+, 2, 0, and 0W.
|
|
||||||
addr Overrides the I2C address (default 0x21)
|
|
||||||
adv7280m Select ADV7280-M.
|
|
||||||
adv7281m Select ADV7281-M.
|
|
||||||
adv7281ma Select ADV7281-MA.
|
|
||||||
|
|
||||||
|
|
||||||
Name: akkordion-iqdacplus
|
Name: akkordion-iqdacplus
|
||||||
@@ -411,12 +398,6 @@ Params: non-stop-clocks Keeps the clocks running even when the stream
|
|||||||
is paused or stopped (default off)
|
is paused or stopped (default off)
|
||||||
|
|
||||||
|
|
||||||
Name: audioinjector-ultra
|
|
||||||
Info: Configures the audioinjector.net ultra soundcard
|
|
||||||
Load: dtoverlay=audioinjector-ultra
|
|
||||||
Params: <None>
|
|
||||||
|
|
||||||
|
|
||||||
Name: audioinjector-wm8731-audio
|
Name: audioinjector-wm8731-audio
|
||||||
Info: Configures the audioinjector.net audio add on soundcard
|
Info: Configures the audioinjector.net audio add on soundcard
|
||||||
Load: dtoverlay=audioinjector-wm8731-audio
|
Load: dtoverlay=audioinjector-wm8731-audio
|
||||||
@@ -563,14 +544,6 @@ Load: dtoverlay=googlevoicehat-soundcard
|
|||||||
Params: <None>
|
Params: <None>
|
||||||
|
|
||||||
|
|
||||||
Name: gpio-fan
|
|
||||||
Info: Configure a GPIO pin to control a cooling fan.
|
|
||||||
Load: dtoverlay=gpio-fan,<param>=<val>
|
|
||||||
Params: gpiopin GPIO used to control the fan (default 12)
|
|
||||||
temp Temperature at which the fan switches on, in
|
|
||||||
millicelcius (default 55000)
|
|
||||||
|
|
||||||
|
|
||||||
Name: gpio-ir
|
Name: gpio-ir
|
||||||
Info: Use GPIO pin as rc-core style infrared receiver input. The rc-core-
|
Info: Use GPIO pin as rc-core style infrared receiver input. The rc-core-
|
||||||
based gpio_ir_recv driver maps received keys directly to a
|
based gpio_ir_recv driver maps received keys directly to a
|
||||||
@@ -1283,7 +1256,15 @@ Info: Omnivision OV5647 camera module.
|
|||||||
Uses Unicam 1, which is the standard camera connector on most Pi
|
Uses Unicam 1, which is the standard camera connector on most Pi
|
||||||
variants.
|
variants.
|
||||||
Load: dtoverlay=ov5647,<param>=<val>
|
Load: dtoverlay=ov5647,<param>=<val>
|
||||||
Params: i2c_pins_28_29 Use pins 28&29 for the I2C instead of 44&45.
|
Params: cam0-pwdn GPIO used to control the sensor powerdown line.
|
||||||
|
|
||||||
|
cam0-led GPIO used to control the sensor led
|
||||||
|
Both these fields should be automatically filled
|
||||||
|
in by the firmware to reflect the default GPIO
|
||||||
|
configuration of the particular Pi variant in
|
||||||
|
use.
|
||||||
|
|
||||||
|
i2c_pins_28_29 Use pins 28&29 for the I2C instead of 44&45.
|
||||||
This is required for Pi B+, 2, 0, and 0W.
|
This is required for Pi B+, 2, 0, and 0W.
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -12,13 +12,13 @@
|
|||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
|
|
||||||
adv728x: adv728x@21 {
|
adv7282: adv7282@21 {
|
||||||
compatible = "adi,adv7282-m";
|
compatible = "adi,adv7282-m";
|
||||||
reg = <0x21>;
|
reg = <0x21>;
|
||||||
status = "okay";
|
status = "okay";
|
||||||
clock-frequency = <24000000>;
|
clock-frequency = <24000000>;
|
||||||
port {
|
port {
|
||||||
adv728x_0: endpoint {
|
adv7282_0: endpoint {
|
||||||
remote-endpoint = <&csi1_ep>;
|
remote-endpoint = <&csi1_ep>;
|
||||||
clock-lanes = <0>;
|
clock-lanes = <0>;
|
||||||
data-lanes = <1>;
|
data-lanes = <1>;
|
||||||
@@ -42,7 +42,7 @@
|
|||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
csi1_ep: endpoint {
|
csi1_ep: endpoint {
|
||||||
remote-endpoint = <&adv728x_0>;
|
remote-endpoint = <&adv7282_0>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
@@ -70,7 +70,6 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
__overrides__ {
|
__overrides__ {
|
||||||
i2c_pins_28_29 = <0>,"+2-3";
|
i2c_pins_28_29 = <0>,"+2-3";
|
||||||
addr = <&adv728x>,"reg:0";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,36 +0,0 @@
|
|||||||
// Definitions for Analog Devices ADV728[0|1|2]-M video to CSI2 bridges on VC
|
|
||||||
// I2C bus
|
|
||||||
|
|
||||||
#include "adv7282m-overlay.dts"
|
|
||||||
|
|
||||||
/{
|
|
||||||
compatible = "brcm,bcm2708";
|
|
||||||
|
|
||||||
// Fragment numbers deliberately high to avoid conflicts with the
|
|
||||||
// included adv7282m overlay file.
|
|
||||||
|
|
||||||
fragment@101 {
|
|
||||||
target = <&adv728x>;
|
|
||||||
__dormant__ {
|
|
||||||
compatible = "adi,adv7280-m";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
fragment@102 {
|
|
||||||
target = <&adv728x>;
|
|
||||||
__dormant__ {
|
|
||||||
compatible = "adi,adv7281-m";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
fragment@103 {
|
|
||||||
target = <&adv728x>;
|
|
||||||
__dormant__ {
|
|
||||||
compatible = "adi,adv7281-ma";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
__overrides__ {
|
|
||||||
adv7280m = <0>, "+101";
|
|
||||||
adv7281m = <0>, "+102";
|
|
||||||
adv7281ma = <0>, "+103";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
@@ -1,71 +0,0 @@
|
|||||||
// Definitions for audioinjector.net audio add on soundcard
|
|
||||||
/dts-v1/;
|
|
||||||
/plugin/;
|
|
||||||
|
|
||||||
/ {
|
|
||||||
compatible = "brcm,bcm2708";
|
|
||||||
|
|
||||||
fragment@0 {
|
|
||||||
target = <&i2s>;
|
|
||||||
__overlay__ {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
fragment@1 {
|
|
||||||
target = <&i2c1>;
|
|
||||||
__overlay__ {
|
|
||||||
#address-cells = <1>;
|
|
||||||
#size-cells = <0>;
|
|
||||||
status = "okay";
|
|
||||||
|
|
||||||
cs4265: cs4265@4e {
|
|
||||||
#sound-dai-cells = <0>;
|
|
||||||
compatible = "cirrus,cs4265";
|
|
||||||
reg = <0x4e>;
|
|
||||||
reset-gpios = <&gpio 5 0>;
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
fragment@2 {
|
|
||||||
target = <&sound>;
|
|
||||||
__overlay__ {
|
|
||||||
compatible = "simple-audio-card";
|
|
||||||
i2s-controller = <&i2s>;
|
|
||||||
status = "okay";
|
|
||||||
|
|
||||||
simple-audio-card,name = "audioinjector-ultra";
|
|
||||||
|
|
||||||
simple-audio-card,widgets =
|
|
||||||
"Line", "OUTPUTS",
|
|
||||||
"Line", "INPUTS";
|
|
||||||
|
|
||||||
simple-audio-card,routing =
|
|
||||||
"OUTPUTS","LINEOUTL",
|
|
||||||
"OUTPUTS","LINEOUTR",
|
|
||||||
"OUTPUTS","SPDIFOUT",
|
|
||||||
"LINEINL","INPUTS",
|
|
||||||
"LINEINR","INPUTS",
|
|
||||||
"MICL","INPUTS",
|
|
||||||
"MICR","INPUTS";
|
|
||||||
|
|
||||||
simple-audio-card,format = "i2s";
|
|
||||||
|
|
||||||
simple-audio-card,bitclock-master = <&sound_master>;
|
|
||||||
simple-audio-card,frame-master = <&sound_master>;
|
|
||||||
|
|
||||||
simple-audio-card,cpu {
|
|
||||||
sound-dai = <&i2s>;
|
|
||||||
dai-tdm-slot-num = <2>;
|
|
||||||
dai-tdm-slot-width = <32>;
|
|
||||||
};
|
|
||||||
|
|
||||||
sound_master: simple-audio-card,codec {
|
|
||||||
sound-dai = <&cs4265>;
|
|
||||||
system-clock-frequency = <12288000>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
@@ -1,71 +0,0 @@
|
|||||||
/*
|
|
||||||
* Overlay for the Raspberry Pi GPIO Fan @ BCM GPIO12.
|
|
||||||
* Optional parameters:
|
|
||||||
* - "gpiopin" - default GPIO12
|
|
||||||
* - "temp" - default 55000
|
|
||||||
* Requires:
|
|
||||||
* - kernel configurations: CONFIG_SENSORS_GPIO_FAN=m and CONFIG_SENSORS_PWM_FAN=m;
|
|
||||||
* - kernel rebuid;
|
|
||||||
* - DC Fan connected to GPIO via a N-MOSFET (2N7002)
|
|
||||||
*
|
|
||||||
* ┌─────────────────────┐
|
|
||||||
* │Fan negative terminal│
|
|
||||||
* └┬────────────────────┘
|
|
||||||
* │
|
|
||||||
* │──┘
|
|
||||||
* [GPIO12]──────┤ │<─┐ 2N7002
|
|
||||||
* │──┤
|
|
||||||
* │
|
|
||||||
* ─┴─
|
|
||||||
* GND
|
|
||||||
*
|
|
||||||
* sudo dtc -W no-unit_address_vs_reg -@ -I dts -O dtb -o /boot/overlays/gpio-fan.dtbo gpio-fan.dts
|
|
||||||
* sudo nano /boot/config.txt add "dtoverlay=gpio-fan" or "dtoverlay=gpio-fan,gpiopin=12,temp=45000"
|
|
||||||
* or
|
|
||||||
* sudo sh -c "echo '\n# Enable PI GPIO-Fan\ndtoverlay=gpio-fan\n' >> /boot/config.txt"
|
|
||||||
* sudo sh -c "echo '\n# Enable PI GPIO-Fan\ndtoverlay=gpio-fan,gpiopin=12\n' >> /boot/config.txt"
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
/dts-v1/;
|
|
||||||
/plugin/;
|
|
||||||
|
|
||||||
/ {
|
|
||||||
compatible = "brcm,bcm2708";
|
|
||||||
|
|
||||||
fragment@0 {
|
|
||||||
target-path = "/";
|
|
||||||
__overlay__ {
|
|
||||||
fan0: gpio-fan@0 {
|
|
||||||
compatible = "gpio-fan";
|
|
||||||
gpios = <&gpio 12 1>;
|
|
||||||
gpio-fan,speed-map = <0 0>,
|
|
||||||
<5000 1>;
|
|
||||||
#cooling-cells = <2>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
fragment@1 {
|
|
||||||
target = <&cpu_thermal>;
|
|
||||||
polling-delay = <2000>; /* milliseconds */
|
|
||||||
__overlay__ {
|
|
||||||
trips {
|
|
||||||
cpu_hot: trip-point@0 {
|
|
||||||
temperature = <55000>; /* (millicelsius) Fan started at 55°C */
|
|
||||||
hysteresis = <5000>; /* (millicelsius) Fan stopped at 50°C */
|
|
||||||
type = "active";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
cooling-maps {
|
|
||||||
map0 {
|
|
||||||
trip = <&cpu_hot>;
|
|
||||||
cooling-device = <&fan0 1 1>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
__overrides__ {
|
|
||||||
gpiopin = <&fan0>,"gpios:4", <&fan0>,"brcm,pins:0";
|
|
||||||
temp = <&cpu_hot>,"temperature:0";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
@@ -78,17 +78,9 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
fragment@5 {
|
|
||||||
target-path="/__overrides__";
|
|
||||||
__overlay__ {
|
|
||||||
cam0-pwdn-ctrl = <&ov5647>,"pwdn-gpios:0";
|
|
||||||
cam0-pwdn = <&ov5647>,"pwdn-gpios:4";
|
|
||||||
cam0-led-ctrl = <&ov5647>,"pwdn-gpios:12";
|
|
||||||
cam0-led = <&ov5647>,"pwdn-gpios:16";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
__overrides__ {
|
__overrides__ {
|
||||||
i2c_pins_28_29 = <0>,"+4-5";
|
i2c_pins_28_29 = <0>,"+4-5";
|
||||||
|
cam0-pwdn = <&ov5647>,"pwdn-gpios:4";
|
||||||
|
cam0-led = <&ov5647>,"pwdn-gpios:16";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
target-path = "/";
|
target-path = "/";
|
||||||
__overlay__ {
|
__overlay__ {
|
||||||
fan0: rpi-poe-fan@0 {
|
fan0: rpi-poe-fan@0 {
|
||||||
compatible = "raspberrypi,rpi-poe-fan";
|
compatible = "rpi-poe-fan";
|
||||||
firmware = <&firmware>;
|
firmware = <&firmware>;
|
||||||
cooling-min-state = <0>;
|
cooling-min-state = <0>;
|
||||||
cooling-max-state = <3>;
|
cooling-max-state = <3>;
|
||||||
|
|||||||
@@ -22,7 +22,7 @@
|
|||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
|
|
||||||
cpu0: cpu@0 {
|
cpu@0 {
|
||||||
device_type = "cpu";
|
device_type = "cpu";
|
||||||
compatible = "arm,cortex-a9";
|
compatible = "arm,cortex-a9";
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
@@ -30,7 +30,7 @@
|
|||||||
power-domains = <&pd_a2sl>;
|
power-domains = <&pd_a2sl>;
|
||||||
next-level-cache = <&L2>;
|
next-level-cache = <&L2>;
|
||||||
};
|
};
|
||||||
cpu1: cpu@1 {
|
cpu@1 {
|
||||||
device_type = "cpu";
|
device_type = "cpu";
|
||||||
compatible = "arm,cortex-a9";
|
compatible = "arm,cortex-a9";
|
||||||
reg = <1>;
|
reg = <1>;
|
||||||
@@ -89,7 +89,6 @@
|
|||||||
compatible = "arm,cortex-a9-pmu";
|
compatible = "arm,cortex-a9-pmu";
|
||||||
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>,
|
||||||
<GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
|
<GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
interrupt-affinity = <&cpu0>, <&cpu1>;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
cmt1: timer@e6138000 {
|
cmt1: timer@e6138000 {
|
||||||
|
|||||||
@@ -52,7 +52,7 @@
|
|||||||
st,syscfg = <&syscfg_sbc>;
|
st,syscfg = <&syscfg_sbc>;
|
||||||
reg = <0x0961f080 0x4>;
|
reg = <0x0961f080 0x4>;
|
||||||
reg-names = "irqmux";
|
reg-names = "irqmux";
|
||||||
interrupts = <GIC_SPI 188 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 188 IRQ_TYPE_NONE>;
|
||||||
interrupt-names = "irqmux";
|
interrupt-names = "irqmux";
|
||||||
ranges = <0 0x09610000 0x6000>;
|
ranges = <0 0x09610000 0x6000>;
|
||||||
|
|
||||||
@@ -376,7 +376,7 @@
|
|||||||
st,syscfg = <&syscfg_front>;
|
st,syscfg = <&syscfg_front>;
|
||||||
reg = <0x0920f080 0x4>;
|
reg = <0x0920f080 0x4>;
|
||||||
reg-names = "irqmux";
|
reg-names = "irqmux";
|
||||||
interrupts = <GIC_SPI 189 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 189 IRQ_TYPE_NONE>;
|
||||||
interrupt-names = "irqmux";
|
interrupt-names = "irqmux";
|
||||||
ranges = <0 0x09200000 0x10000>;
|
ranges = <0 0x09200000 0x10000>;
|
||||||
|
|
||||||
@@ -936,7 +936,7 @@
|
|||||||
st,syscfg = <&syscfg_front>;
|
st,syscfg = <&syscfg_front>;
|
||||||
reg = <0x0921f080 0x4>;
|
reg = <0x0921f080 0x4>;
|
||||||
reg-names = "irqmux";
|
reg-names = "irqmux";
|
||||||
interrupts = <GIC_SPI 190 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 190 IRQ_TYPE_NONE>;
|
||||||
interrupt-names = "irqmux";
|
interrupt-names = "irqmux";
|
||||||
ranges = <0 0x09210000 0x10000>;
|
ranges = <0 0x09210000 0x10000>;
|
||||||
|
|
||||||
@@ -969,7 +969,7 @@
|
|||||||
st,syscfg = <&syscfg_rear>;
|
st,syscfg = <&syscfg_rear>;
|
||||||
reg = <0x0922f080 0x4>;
|
reg = <0x0922f080 0x4>;
|
||||||
reg-names = "irqmux";
|
reg-names = "irqmux";
|
||||||
interrupts = <GIC_SPI 191 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 191 IRQ_TYPE_NONE>;
|
||||||
interrupt-names = "irqmux";
|
interrupt-names = "irqmux";
|
||||||
ranges = <0 0x09220000 0x6000>;
|
ranges = <0 0x09220000 0x6000>;
|
||||||
|
|
||||||
@@ -1164,7 +1164,7 @@
|
|||||||
st,syscfg = <&syscfg_flash>;
|
st,syscfg = <&syscfg_flash>;
|
||||||
reg = <0x0923f080 0x4>;
|
reg = <0x0923f080 0x4>;
|
||||||
reg-names = "irqmux";
|
reg-names = "irqmux";
|
||||||
interrupts = <GIC_SPI 192 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 192 IRQ_TYPE_NONE>;
|
||||||
interrupt-names = "irqmux";
|
interrupt-names = "irqmux";
|
||||||
ranges = <0 0x09230000 0x3000>;
|
ranges = <0 0x09230000 0x3000>;
|
||||||
|
|
||||||
|
|||||||
@@ -206,7 +206,6 @@
|
|||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
reg = <0x70>;
|
reg = <0x70>;
|
||||||
reset-gpio = <&gpio TEGRA_GPIO(BB, 0) GPIO_ACTIVE_LOW>;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -656,7 +656,6 @@ CONFIG_BATTERY_DS2760=m
|
|||||||
CONFIG_BATTERY_GAUGE_LTC2941=m
|
CONFIG_BATTERY_GAUGE_LTC2941=m
|
||||||
CONFIG_HWMON=m
|
CONFIG_HWMON=m
|
||||||
CONFIG_SENSORS_DS1621=m
|
CONFIG_SENSORS_DS1621=m
|
||||||
CONFIG_SENSORS_GPIO_FAN=m
|
|
||||||
CONFIG_SENSORS_JC42=m
|
CONFIG_SENSORS_JC42=m
|
||||||
CONFIG_SENSORS_LM75=m
|
CONFIG_SENSORS_LM75=m
|
||||||
CONFIG_SENSORS_RPI_POE_FAN=m
|
CONFIG_SENSORS_RPI_POE_FAN=m
|
||||||
@@ -915,7 +914,6 @@ CONFIG_SND_PISOUND=m
|
|||||||
CONFIG_SND_SOC_ADAU1701=m
|
CONFIG_SND_SOC_ADAU1701=m
|
||||||
CONFIG_SND_SOC_ADAU7002=m
|
CONFIG_SND_SOC_ADAU7002=m
|
||||||
CONFIG_SND_SOC_AK4554=m
|
CONFIG_SND_SOC_AK4554=m
|
||||||
CONFIG_SND_SOC_CS4265=m
|
|
||||||
CONFIG_SND_SOC_CS4271_I2C=m
|
CONFIG_SND_SOC_CS4271_I2C=m
|
||||||
CONFIG_SND_SOC_SPDIF=m
|
CONFIG_SND_SOC_SPDIF=m
|
||||||
CONFIG_SND_SOC_WM8804_I2C=m
|
CONFIG_SND_SOC_WM8804_I2C=m
|
||||||
|
|||||||
@@ -649,7 +649,6 @@ CONFIG_BATTERY_DS2760=m
|
|||||||
CONFIG_BATTERY_GAUGE_LTC2941=m
|
CONFIG_BATTERY_GAUGE_LTC2941=m
|
||||||
CONFIG_HWMON=m
|
CONFIG_HWMON=m
|
||||||
CONFIG_SENSORS_DS1621=m
|
CONFIG_SENSORS_DS1621=m
|
||||||
CONFIG_SENSORS_GPIO_FAN=m
|
|
||||||
CONFIG_SENSORS_JC42=m
|
CONFIG_SENSORS_JC42=m
|
||||||
CONFIG_SENSORS_LM75=m
|
CONFIG_SENSORS_LM75=m
|
||||||
CONFIG_SENSORS_RPI_POE_FAN=m
|
CONFIG_SENSORS_RPI_POE_FAN=m
|
||||||
@@ -908,7 +907,6 @@ CONFIG_SND_PISOUND=m
|
|||||||
CONFIG_SND_SOC_ADAU1701=m
|
CONFIG_SND_SOC_ADAU1701=m
|
||||||
CONFIG_SND_SOC_ADAU7002=m
|
CONFIG_SND_SOC_ADAU7002=m
|
||||||
CONFIG_SND_SOC_AK4554=m
|
CONFIG_SND_SOC_AK4554=m
|
||||||
CONFIG_SND_SOC_CS4265=m
|
|
||||||
CONFIG_SND_SOC_CS4271_I2C=m
|
CONFIG_SND_SOC_CS4271_I2C=m
|
||||||
CONFIG_SND_SOC_SPDIF=m
|
CONFIG_SND_SOC_SPDIF=m
|
||||||
CONFIG_SND_SOC_WM8804_I2C=m
|
CONFIG_SND_SOC_WM8804_I2C=m
|
||||||
|
|||||||
@@ -144,11 +144,9 @@ CONFIG_USB_STORAGE=y
|
|||||||
CONFIG_USB_CHIPIDEA=y
|
CONFIG_USB_CHIPIDEA=y
|
||||||
CONFIG_USB_CHIPIDEA_UDC=y
|
CONFIG_USB_CHIPIDEA_UDC=y
|
||||||
CONFIG_USB_CHIPIDEA_HOST=y
|
CONFIG_USB_CHIPIDEA_HOST=y
|
||||||
CONFIG_USB_CHIPIDEA_ULPI=y
|
|
||||||
CONFIG_NOP_USB_XCEIV=y
|
CONFIG_NOP_USB_XCEIV=y
|
||||||
CONFIG_USB_GADGET=y
|
CONFIG_USB_GADGET=y
|
||||||
CONFIG_USB_ETH=m
|
CONFIG_USB_ETH=m
|
||||||
CONFIG_USB_ULPI_BUS=y
|
|
||||||
CONFIG_MMC=y
|
CONFIG_MMC=y
|
||||||
CONFIG_MMC_SDHCI=y
|
CONFIG_MMC_SDHCI=y
|
||||||
CONFIG_MMC_SDHCI_PLTFM=y
|
CONFIG_MMC_SDHCI_PLTFM=y
|
||||||
|
|||||||
@@ -773,7 +773,7 @@ static struct gpiod_lookup_table mmc_gpios_table = {
|
|||||||
GPIO_LOOKUP("davinci_gpio.0", DA850_MMCSD_CD_PIN, "cd",
|
GPIO_LOOKUP("davinci_gpio.0", DA850_MMCSD_CD_PIN, "cd",
|
||||||
GPIO_ACTIVE_LOW),
|
GPIO_ACTIVE_LOW),
|
||||||
GPIO_LOOKUP("davinci_gpio.0", DA850_MMCSD_WP_PIN, "wp",
|
GPIO_LOOKUP("davinci_gpio.0", DA850_MMCSD_WP_PIN, "wp",
|
||||||
GPIO_ACTIVE_HIGH),
|
GPIO_ACTIVE_LOW),
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -109,45 +109,6 @@ void omap5_erratum_workaround_801819(void)
|
|||||||
static inline void omap5_erratum_workaround_801819(void) { }
|
static inline void omap5_erratum_workaround_801819(void) { }
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_HARDEN_BRANCH_PREDICTOR
|
|
||||||
/*
|
|
||||||
* Configure ACR and enable ACTLR[0] (Enable invalidates of BTB with
|
|
||||||
* ICIALLU) to activate the workaround for secondary Core.
|
|
||||||
* NOTE: it is assumed that the primary core's configuration is done
|
|
||||||
* by the boot loader (kernel will detect a misconfiguration and complain
|
|
||||||
* if this is not done).
|
|
||||||
*
|
|
||||||
* In General Purpose(GP) devices, ACR bit settings can only be done
|
|
||||||
* by ROM code in "secure world" using the smc call and there is no
|
|
||||||
* option to update the "firmware" on such devices. This also works for
|
|
||||||
* High security(HS) devices, as a backup option in case the
|
|
||||||
* "update" is not done in the "security firmware".
|
|
||||||
*/
|
|
||||||
static void omap5_secondary_harden_predictor(void)
|
|
||||||
{
|
|
||||||
u32 acr, acr_mask;
|
|
||||||
|
|
||||||
asm volatile ("mrc p15, 0, %0, c1, c0, 1" : "=r" (acr));
|
|
||||||
|
|
||||||
/*
|
|
||||||
* ACTLR[0] (Enable invalidates of BTB with ICIALLU)
|
|
||||||
*/
|
|
||||||
acr_mask = BIT(0);
|
|
||||||
|
|
||||||
/* Do we already have it done.. if yes, skip expensive smc */
|
|
||||||
if ((acr & acr_mask) == acr_mask)
|
|
||||||
return;
|
|
||||||
|
|
||||||
acr |= acr_mask;
|
|
||||||
omap_smc1(OMAP5_DRA7_MON_SET_ACR_INDEX, acr);
|
|
||||||
|
|
||||||
pr_debug("%s: ARM ACR setup for CVE_2017_5715 applied on CPU%d\n",
|
|
||||||
__func__, smp_processor_id());
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
static inline void omap5_secondary_harden_predictor(void) { }
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static void omap4_secondary_init(unsigned int cpu)
|
static void omap4_secondary_init(unsigned int cpu)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
@@ -170,8 +131,6 @@ static void omap4_secondary_init(unsigned int cpu)
|
|||||||
set_cntfreq();
|
set_cntfreq();
|
||||||
/* Configure ACR to disable streaming WA for 801819 */
|
/* Configure ACR to disable streaming WA for 801819 */
|
||||||
omap5_erratum_workaround_801819();
|
omap5_erratum_workaround_801819();
|
||||||
/* Enable ACR to allow for ICUALLU workaround */
|
|
||||||
omap5_secondary_harden_predictor();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@@ -185,7 +185,7 @@ static int pxa_irq_suspend(void)
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < DIV_ROUND_UP(pxa_internal_irq_nr, 32); i++) {
|
for (i = 0; i < pxa_internal_irq_nr / 32; i++) {
|
||||||
void __iomem *base = irq_base(i);
|
void __iomem *base = irq_base(i);
|
||||||
|
|
||||||
saved_icmr[i] = __raw_readl(base + ICMR);
|
saved_icmr[i] = __raw_readl(base + ICMR);
|
||||||
@@ -204,7 +204,7 @@ static void pxa_irq_resume(void)
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
for (i = 0; i < DIV_ROUND_UP(pxa_internal_irq_nr, 32); i++) {
|
for (i = 0; i < pxa_internal_irq_nr / 32; i++) {
|
||||||
void __iomem *base = irq_base(i);
|
void __iomem *base = irq_base(i);
|
||||||
|
|
||||||
__raw_writel(saved_icmr[i], base + ICMR);
|
__raw_writel(saved_icmr[i], base + ICMR);
|
||||||
|
|||||||
@@ -18,7 +18,6 @@ config ARCH_ROCKCHIP
|
|||||||
select ARM_GLOBAL_TIMER
|
select ARM_GLOBAL_TIMER
|
||||||
select CLKSRC_ARM_GLOBAL_TIMER_SCHED_CLOCK
|
select CLKSRC_ARM_GLOBAL_TIMER_SCHED_CLOCK
|
||||||
select ZONE_DMA if ARM_LPAE
|
select ZONE_DMA if ARM_LPAE
|
||||||
select PM
|
|
||||||
help
|
help
|
||||||
Support for Rockchip's Cortex-A9 Single-to-Quad-Core-SoCs
|
Support for Rockchip's Cortex-A9 Single-to-Quad-Core-SoCs
|
||||||
containing the RK2928, RK30xx and RK31xx series.
|
containing the RK2928, RK30xx and RK31xx series.
|
||||||
|
|||||||
@@ -718,7 +718,7 @@ static inline void emit_a32_arsh_r64(const u8 dst[], const u8 src[], bool dstk,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* dst = dst >> src */
|
/* dst = dst >> src */
|
||||||
static inline void emit_a32_rsh_r64(const u8 dst[], const u8 src[], bool dstk,
|
static inline void emit_a32_lsr_r64(const u8 dst[], const u8 src[], bool dstk,
|
||||||
bool sstk, struct jit_ctx *ctx) {
|
bool sstk, struct jit_ctx *ctx) {
|
||||||
const u8 *tmp = bpf2a32[TMP_REG_1];
|
const u8 *tmp = bpf2a32[TMP_REG_1];
|
||||||
const u8 *tmp2 = bpf2a32[TMP_REG_2];
|
const u8 *tmp2 = bpf2a32[TMP_REG_2];
|
||||||
@@ -734,7 +734,7 @@ static inline void emit_a32_rsh_r64(const u8 dst[], const u8 src[], bool dstk,
|
|||||||
emit(ARM_LDR_I(rm, ARM_SP, STACK_VAR(dst_hi)), ctx);
|
emit(ARM_LDR_I(rm, ARM_SP, STACK_VAR(dst_hi)), ctx);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Do RSH operation */
|
/* Do LSH operation */
|
||||||
emit(ARM_RSB_I(ARM_IP, rt, 32), ctx);
|
emit(ARM_RSB_I(ARM_IP, rt, 32), ctx);
|
||||||
emit(ARM_SUBS_I(tmp2[0], rt, 32), ctx);
|
emit(ARM_SUBS_I(tmp2[0], rt, 32), ctx);
|
||||||
emit(ARM_MOV_SR(ARM_LR, rd, SRTYPE_LSR, rt), ctx);
|
emit(ARM_MOV_SR(ARM_LR, rd, SRTYPE_LSR, rt), ctx);
|
||||||
@@ -784,7 +784,7 @@ static inline void emit_a32_lsh_i64(const u8 dst[], bool dstk,
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* dst = dst >> val */
|
/* dst = dst >> val */
|
||||||
static inline void emit_a32_rsh_i64(const u8 dst[], bool dstk,
|
static inline void emit_a32_lsr_i64(const u8 dst[], bool dstk,
|
||||||
const u32 val, struct jit_ctx *ctx) {
|
const u32 val, struct jit_ctx *ctx) {
|
||||||
const u8 *tmp = bpf2a32[TMP_REG_1];
|
const u8 *tmp = bpf2a32[TMP_REG_1];
|
||||||
const u8 *tmp2 = bpf2a32[TMP_REG_2];
|
const u8 *tmp2 = bpf2a32[TMP_REG_2];
|
||||||
@@ -1340,7 +1340,7 @@ static int build_insn(const struct bpf_insn *insn, struct jit_ctx *ctx)
|
|||||||
case BPF_ALU64 | BPF_RSH | BPF_K:
|
case BPF_ALU64 | BPF_RSH | BPF_K:
|
||||||
if (unlikely(imm > 63))
|
if (unlikely(imm > 63))
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
emit_a32_rsh_i64(dst, dstk, imm, ctx);
|
emit_a32_lsr_i64(dst, dstk, imm, ctx);
|
||||||
break;
|
break;
|
||||||
/* dst = dst << src */
|
/* dst = dst << src */
|
||||||
case BPF_ALU64 | BPF_LSH | BPF_X:
|
case BPF_ALU64 | BPF_LSH | BPF_X:
|
||||||
@@ -1348,7 +1348,7 @@ static int build_insn(const struct bpf_insn *insn, struct jit_ctx *ctx)
|
|||||||
break;
|
break;
|
||||||
/* dst = dst >> src */
|
/* dst = dst >> src */
|
||||||
case BPF_ALU64 | BPF_RSH | BPF_X:
|
case BPF_ALU64 | BPF_RSH | BPF_X:
|
||||||
emit_a32_rsh_r64(dst, src, dstk, sstk, ctx);
|
emit_a32_lsr_r64(dst, src, dstk, sstk, ctx);
|
||||||
break;
|
break;
|
||||||
/* dst = dst >> src (signed) */
|
/* dst = dst >> src (signed) */
|
||||||
case BPF_ALU64 | BPF_ARSH | BPF_X:
|
case BPF_ALU64 | BPF_ARSH | BPF_X:
|
||||||
|
|||||||
@@ -291,8 +291,8 @@ void __kprobes kprobe_handler(struct pt_regs *regs)
|
|||||||
break;
|
break;
|
||||||
case KPROBE_REENTER:
|
case KPROBE_REENTER:
|
||||||
/* A nested probe was hit in FIQ, it is a BUG */
|
/* A nested probe was hit in FIQ, it is a BUG */
|
||||||
pr_warn("Unrecoverable kprobe detected.\n");
|
pr_warn("Unrecoverable kprobe detected at %p.\n",
|
||||||
dump_kprobe(p);
|
p->addr);
|
||||||
/* fall through */
|
/* fall through */
|
||||||
default:
|
default:
|
||||||
/* impossible cases */
|
/* impossible cases */
|
||||||
|
|||||||
@@ -1517,6 +1517,7 @@ fail:
|
|||||||
print_registers(&result_regs);
|
print_registers(&result_regs);
|
||||||
|
|
||||||
if (mem) {
|
if (mem) {
|
||||||
|
pr_err("current_stack=%p\n", current_stack);
|
||||||
pr_err("expected_memory:\n");
|
pr_err("expected_memory:\n");
|
||||||
print_memory(expected_memory, mem_size);
|
print_memory(expected_memory, mem_size);
|
||||||
pr_err("result_memory:\n");
|
pr_err("result_memory:\n");
|
||||||
|
|||||||
@@ -693,6 +693,7 @@ config NEED_PER_CPU_EMBED_FIRST_CHUNK
|
|||||||
|
|
||||||
config HOLES_IN_ZONE
|
config HOLES_IN_ZONE
|
||||||
def_bool y
|
def_bool y
|
||||||
|
depends on NUMA
|
||||||
|
|
||||||
source kernel/Kconfig.preempt
|
source kernel/Kconfig.preempt
|
||||||
source kernel/Kconfig.hz
|
source kernel/Kconfig.hz
|
||||||
|
|||||||
@@ -142,7 +142,6 @@ config ARCH_ROCKCHIP
|
|||||||
select GPIOLIB
|
select GPIOLIB
|
||||||
select PINCTRL
|
select PINCTRL
|
||||||
select PINCTRL_ROCKCHIP
|
select PINCTRL_ROCKCHIP
|
||||||
select PM
|
|
||||||
select ROCKCHIP_TIMER
|
select ROCKCHIP_TIMER
|
||||||
help
|
help
|
||||||
This enables support for the ARMv8 based Rockchip chipsets,
|
This enables support for the ARMv8 based Rockchip chipsets,
|
||||||
|
|||||||
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
&apb {
|
&apb {
|
||||||
mali: gpu@c0000 {
|
mali: gpu@c0000 {
|
||||||
compatible = "amlogic,meson-gxl-mali", "arm,mali-450";
|
compatible = "amlogic,meson-gxbb-mali", "arm,mali-450";
|
||||||
reg = <0x0 0xc0000 0x0 0x40000>;
|
reg = <0x0 0xc0000 0x0 0x40000>;
|
||||||
interrupts = <GIC_SPI 160 IRQ_TYPE_LEVEL_HIGH>,
|
interrupts = <GIC_SPI 160 IRQ_TYPE_LEVEL_HIGH>,
|
||||||
<GIC_SPI 161 IRQ_TYPE_LEVEL_HIGH>,
|
<GIC_SPI 161 IRQ_TYPE_LEVEL_HIGH>,
|
||||||
|
|||||||
@@ -9,8 +9,6 @@ dtb-$(CONFIG_ARCH_BCM2835) += bcm2837-rpi-3-b.dtb
|
|||||||
dtb-$(CONFIG_ARCH_BCM2709) += bcm2710-rpi-3-b.dtb
|
dtb-$(CONFIG_ARCH_BCM2709) += bcm2710-rpi-3-b.dtb
|
||||||
dtb-$(CONFIG_ARCH_BCM2835) += bcm2710-rpi-3-b.dtb
|
dtb-$(CONFIG_ARCH_BCM2835) += bcm2710-rpi-3-b.dtb
|
||||||
dtb-$(CONFIG_ARCH_BCM2835) += bcm2710-rpi-3-b-plus.dtb
|
dtb-$(CONFIG_ARCH_BCM2835) += bcm2710-rpi-3-b-plus.dtb
|
||||||
dtb-$(CONFIG_ARCH_BCM2709) += bcm2710-rpi-cm3.dtb
|
|
||||||
dtb-$(CONFIG_ARCH_BCM2835) += bcm2710-rpi-cm3.dtb
|
|
||||||
|
|
||||||
dts-dirs += ../overlays
|
dts-dirs += ../overlays
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +0,0 @@
|
|||||||
#define RPI364
|
|
||||||
|
|
||||||
#include "../../../../arm/boot/dts/bcm2710-rpi-cm3.dts"
|
|
||||||
@@ -118,7 +118,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 281 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 281 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <0>;
|
linux,pci-domain = <0>;
|
||||||
|
|
||||||
@@ -149,7 +149,7 @@
|
|||||||
|
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
interrupt-map-mask = <0 0 0 0>;
|
interrupt-map-mask = <0 0 0 0>;
|
||||||
interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 305 IRQ_TYPE_LEVEL_HIGH>;
|
interrupt-map = <0 0 0 0 &gic 0 GIC_SPI 305 IRQ_TYPE_NONE>;
|
||||||
|
|
||||||
linux,pci-domain = <4>;
|
linux,pci-domain = <4>;
|
||||||
|
|
||||||
@@ -566,7 +566,7 @@
|
|||||||
reg = <0x66080000 0x100>;
|
reg = <0x66080000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 394 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 394 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
@@ -594,7 +594,7 @@
|
|||||||
reg = <0x660b0000 0x100>;
|
reg = <0x660b0000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 395 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 395 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -43,10 +43,6 @@
|
|||||||
enet-phy-lane-swap;
|
enet-phy-lane-swap;
|
||||||
};
|
};
|
||||||
|
|
||||||
&sdio0 {
|
|
||||||
mmc-ddr-1_8v;
|
|
||||||
};
|
|
||||||
|
|
||||||
&uart2 {
|
&uart2 {
|
||||||
status = "okay";
|
status = "okay";
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -42,7 +42,3 @@
|
|||||||
&gphy0 {
|
&gphy0 {
|
||||||
enet-phy-lane-swap;
|
enet-phy-lane-swap;
|
||||||
};
|
};
|
||||||
|
|
||||||
&sdio0 {
|
|
||||||
mmc-ddr-1_8v;
|
|
||||||
};
|
|
||||||
|
|||||||
@@ -409,7 +409,7 @@
|
|||||||
reg = <0x000b0000 0x100>;
|
reg = <0x000b0000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 177 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 177 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
@@ -453,7 +453,7 @@
|
|||||||
reg = <0x000e0000 0x100>;
|
reg = <0x000e0000 0x100>;
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
interrupts = <GIC_SPI 178 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 178 IRQ_TYPE_NONE>;
|
||||||
clock-frequency = <100000>;
|
clock-frequency = <100000>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1132,14 +1132,14 @@
|
|||||||
|
|
||||||
port@0 {
|
port@0 {
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
etf_in: endpoint {
|
etf_out: endpoint {
|
||||||
slave-mode;
|
slave-mode;
|
||||||
remote-endpoint = <&funnel0_out>;
|
remote-endpoint = <&funnel0_out>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
port@1 {
|
port@1 {
|
||||||
reg = <0>;
|
reg = <0>;
|
||||||
etf_out: endpoint {
|
etf_in: endpoint {
|
||||||
remote-endpoint = <&replicator_in>;
|
remote-endpoint = <&replicator_in>;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -93,12 +93,20 @@
|
|||||||
regulator-always-on;
|
regulator-always-on;
|
||||||
};
|
};
|
||||||
|
|
||||||
sound_card: sound {
|
rsnd_ak4613: sound {
|
||||||
compatible = "audio-graph-card";
|
compatible = "simple-audio-card";
|
||||||
|
|
||||||
label = "rcar-sound";
|
simple-audio-card,format = "left_j";
|
||||||
|
simple-audio-card,bitclock-master = <&sndcpu>;
|
||||||
|
simple-audio-card,frame-master = <&sndcpu>;
|
||||||
|
|
||||||
dais = <&rsnd_port0>;
|
sndcpu: simple-audio-card,cpu {
|
||||||
|
sound-dai = <&rcar_sound>;
|
||||||
|
};
|
||||||
|
|
||||||
|
sndcodec: simple-audio-card,codec {
|
||||||
|
sound-dai = <&ak4613>;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
vbus0_usb2: regulator-vbus0-usb2 {
|
vbus0_usb2: regulator-vbus0-usb2 {
|
||||||
@@ -312,12 +320,6 @@
|
|||||||
asahi-kasei,out4-single-end;
|
asahi-kasei,out4-single-end;
|
||||||
asahi-kasei,out5-single-end;
|
asahi-kasei,out5-single-end;
|
||||||
asahi-kasei,out6-single-end;
|
asahi-kasei,out6-single-end;
|
||||||
|
|
||||||
port {
|
|
||||||
ak4613_endpoint: endpoint {
|
|
||||||
remote-endpoint = <&rsnd_endpoint0>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
|
||||||
cs2000: clk_multiplier@4f {
|
cs2000: clk_multiplier@4f {
|
||||||
@@ -536,18 +538,10 @@
|
|||||||
<&audio_clk_c>,
|
<&audio_clk_c>,
|
||||||
<&cpg CPG_CORE CPG_AUDIO_CLK_I>;
|
<&cpg CPG_CORE CPG_AUDIO_CLK_I>;
|
||||||
|
|
||||||
ports {
|
rcar_sound,dai {
|
||||||
rsnd_port0: port@0 {
|
dai0 {
|
||||||
rsnd_endpoint0: endpoint {
|
playback = <&ssi0 &src0 &dvc0>;
|
||||||
remote-endpoint = <&ak4613_endpoint>;
|
capture = <&ssi1 &src1 &dvc1>;
|
||||||
|
|
||||||
dai-format = "left_j";
|
|
||||||
bitclock-master = <&rsnd_endpoint0>;
|
|
||||||
frame-master = <&rsnd_endpoint0>;
|
|
||||||
|
|
||||||
playback = <&ssi0 &src0 &dvc0>;
|
|
||||||
capture = <&ssi1 &src1 &dvc1>;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -331,7 +331,7 @@
|
|||||||
reg = <0x0 0xff120000 0x0 0x100>;
|
reg = <0x0 0xff120000 0x0 0x100>;
|
||||||
interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>;
|
clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>;
|
||||||
clock-names = "baudclk", "apb_pclk";
|
clock-names = "sclk_uart", "pclk_uart";
|
||||||
dmas = <&dmac 4>, <&dmac 5>;
|
dmas = <&dmac 4>, <&dmac 5>;
|
||||||
#dma-cells = <2>;
|
#dma-cells = <2>;
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
|
|||||||
@@ -302,8 +302,6 @@ CONFIG_GPIO_XGENE_SB=y
|
|||||||
CONFIG_GPIO_PCA953X=y
|
CONFIG_GPIO_PCA953X=y
|
||||||
CONFIG_GPIO_PCA953X_IRQ=y
|
CONFIG_GPIO_PCA953X_IRQ=y
|
||||||
CONFIG_GPIO_MAX77620=y
|
CONFIG_GPIO_MAX77620=y
|
||||||
CONFIG_POWER_AVS=y
|
|
||||||
CONFIG_ROCKCHIP_IODOMAIN=y
|
|
||||||
CONFIG_POWER_RESET_MSM=y
|
CONFIG_POWER_RESET_MSM=y
|
||||||
CONFIG_POWER_RESET_XGENE=y
|
CONFIG_POWER_RESET_XGENE=y
|
||||||
CONFIG_POWER_RESET_SYSCON=y
|
CONFIG_POWER_RESET_SYSCON=y
|
||||||
|
|||||||
@@ -20,14 +20,9 @@
|
|||||||
|
|
||||||
#define CTR_L1IP_SHIFT 14
|
#define CTR_L1IP_SHIFT 14
|
||||||
#define CTR_L1IP_MASK 3
|
#define CTR_L1IP_MASK 3
|
||||||
#define CTR_DMINLINE_SHIFT 16
|
|
||||||
#define CTR_IMINLINE_SHIFT 0
|
|
||||||
#define CTR_CWG_SHIFT 24
|
#define CTR_CWG_SHIFT 24
|
||||||
#define CTR_CWG_MASK 15
|
#define CTR_CWG_MASK 15
|
||||||
|
|
||||||
#define CTR_CACHE_MINLINE_MASK \
|
|
||||||
(0xf << CTR_DMINLINE_SHIFT | 0xf << CTR_IMINLINE_SHIFT)
|
|
||||||
|
|
||||||
#define CTR_L1IP(ctr) (((ctr) >> CTR_L1IP_SHIFT) & CTR_L1IP_MASK)
|
#define CTR_L1IP(ctr) (((ctr) >> CTR_L1IP_SHIFT) & CTR_L1IP_MASK)
|
||||||
|
|
||||||
#define ICACHE_POLICY_VPIPT 0
|
#define ICACHE_POLICY_VPIPT 0
|
||||||
|
|||||||
@@ -229,9 +229,7 @@ static inline void __cmpwait_case_##name(volatile void *ptr, \
|
|||||||
unsigned long tmp; \
|
unsigned long tmp; \
|
||||||
\
|
\
|
||||||
asm volatile( \
|
asm volatile( \
|
||||||
" sevl\n" \
|
" ldxr" #sz "\t%" #w "[tmp], %[v]\n" \
|
||||||
" wfe\n" \
|
|
||||||
" ldxr" #sz "\t%" #w "[tmp], %[v]\n" \
|
|
||||||
" eor %" #w "[tmp], %" #w "[tmp], %" #w "[val]\n" \
|
" eor %" #w "[tmp], %" #w "[tmp], %" #w "[val]\n" \
|
||||||
" cbnz %" #w "[tmp], 1f\n" \
|
" cbnz %" #w "[tmp], 1f\n" \
|
||||||
" wfe\n" \
|
" wfe\n" \
|
||||||
|
|||||||
@@ -44,8 +44,7 @@
|
|||||||
#define ARM64_HARDEN_BRANCH_PREDICTOR 24
|
#define ARM64_HARDEN_BRANCH_PREDICTOR 24
|
||||||
#define ARM64_HARDEN_BP_POST_GUEST_EXIT 25
|
#define ARM64_HARDEN_BP_POST_GUEST_EXIT 25
|
||||||
#define ARM64_SSBD 26
|
#define ARM64_SSBD 26
|
||||||
#define ARM64_MISMATCHED_CACHE_TYPE 27
|
|
||||||
|
|
||||||
#define ARM64_NCAPS 28
|
#define ARM64_NCAPS 27
|
||||||
|
|
||||||
#endif /* __ASM_CPUCAPS_H */
|
#endif /* __ASM_CPUCAPS_H */
|
||||||
|
|||||||
@@ -16,8 +16,6 @@
|
|||||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <linux/arm-smccc.h>
|
|
||||||
#include <linux/psci.h>
|
|
||||||
#include <linux/types.h>
|
#include <linux/types.h>
|
||||||
#include <asm/cpu.h>
|
#include <asm/cpu.h>
|
||||||
#include <asm/cputype.h>
|
#include <asm/cputype.h>
|
||||||
@@ -47,18 +45,12 @@ is_kryo_midr(const struct arm64_cpu_capabilities *entry, int scope)
|
|||||||
}
|
}
|
||||||
|
|
||||||
static bool
|
static bool
|
||||||
has_mismatched_cache_type(const struct arm64_cpu_capabilities *entry,
|
has_mismatched_cache_line_size(const struct arm64_cpu_capabilities *entry,
|
||||||
int scope)
|
int scope)
|
||||||
{
|
{
|
||||||
u64 mask = CTR_CACHE_MINLINE_MASK;
|
|
||||||
|
|
||||||
/* Skip matching the min line sizes for cache type check */
|
|
||||||
if (entry->capability == ARM64_MISMATCHED_CACHE_TYPE)
|
|
||||||
mask ^= arm64_ftr_reg_ctrel0.strict_mask;
|
|
||||||
|
|
||||||
WARN_ON(scope != SCOPE_LOCAL_CPU || preemptible());
|
WARN_ON(scope != SCOPE_LOCAL_CPU || preemptible());
|
||||||
return (read_cpuid_cachetype() & mask) !=
|
return (read_cpuid_cachetype() & arm64_ftr_reg_ctrel0.strict_mask) !=
|
||||||
(arm64_ftr_reg_ctrel0.sys_val & mask);
|
(arm64_ftr_reg_ctrel0.sys_val & arm64_ftr_reg_ctrel0.strict_mask);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int cpu_enable_trap_ctr_access(void *__unused)
|
static int cpu_enable_trap_ctr_access(void *__unused)
|
||||||
@@ -519,14 +511,7 @@ const struct arm64_cpu_capabilities arm64_errata[] = {
|
|||||||
{
|
{
|
||||||
.desc = "Mismatched cache line size",
|
.desc = "Mismatched cache line size",
|
||||||
.capability = ARM64_MISMATCHED_CACHE_LINE_SIZE,
|
.capability = ARM64_MISMATCHED_CACHE_LINE_SIZE,
|
||||||
.matches = has_mismatched_cache_type,
|
.matches = has_mismatched_cache_line_size,
|
||||||
.def_scope = SCOPE_LOCAL_CPU,
|
|
||||||
.enable = cpu_enable_trap_ctr_access,
|
|
||||||
},
|
|
||||||
{
|
|
||||||
.desc = "Mismatched cache type",
|
|
||||||
.capability = ARM64_MISMATCHED_CACHE_TYPE,
|
|
||||||
.matches = has_mismatched_cache_type,
|
|
||||||
.def_scope = SCOPE_LOCAL_CPU,
|
.def_scope = SCOPE_LOCAL_CPU,
|
||||||
.enable = cpu_enable_trap_ctr_access,
|
.enable = cpu_enable_trap_ctr_access,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -180,14 +180,14 @@ static const struct arm64_ftr_bits ftr_ctr[] = {
|
|||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, 28, 1, 1), /* IDC */
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, 28, 1, 1), /* IDC */
|
||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_HIGHER_SAFE, 24, 4, 0), /* CWG */
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_HIGHER_SAFE, 24, 4, 0), /* CWG */
|
||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_HIGHER_SAFE, 20, 4, 0), /* ERG */
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_HIGHER_SAFE, 20, 4, 0), /* ERG */
|
||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, CTR_DMINLINE_SHIFT, 4, 1),
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, 16, 4, 1), /* DminLine */
|
||||||
/*
|
/*
|
||||||
* Linux can handle differing I-cache policies. Userspace JITs will
|
* Linux can handle differing I-cache policies. Userspace JITs will
|
||||||
* make use of *minLine.
|
* make use of *minLine.
|
||||||
* If we have differing I-cache policies, report it as the weakest - VIPT.
|
* If we have differing I-cache policies, report it as the weakest - VIPT.
|
||||||
*/
|
*/
|
||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_NONSTRICT, FTR_EXACT, 14, 2, ICACHE_POLICY_VIPT), /* L1Ip */
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_NONSTRICT, FTR_EXACT, 14, 2, ICACHE_POLICY_VIPT), /* L1Ip */
|
||||||
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, CTR_IMINLINE_SHIFT, 4, 0),
|
ARM64_FTR_BITS(FTR_VISIBLE, FTR_STRICT, FTR_LOWER_SAFE, 0, 4, 0), /* IminLine */
|
||||||
ARM64_FTR_END,
|
ARM64_FTR_END,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -275,7 +275,7 @@ static int __kprobes reenter_kprobe(struct kprobe *p,
|
|||||||
break;
|
break;
|
||||||
case KPROBE_HIT_SS:
|
case KPROBE_HIT_SS:
|
||||||
case KPROBE_REENTER:
|
case KPROBE_REENTER:
|
||||||
pr_warn("Unrecoverable kprobe detected.\n");
|
pr_warn("Unrecoverable kprobe detected at %p.\n", p->addr);
|
||||||
dump_kprobe(p);
|
dump_kprobe(p);
|
||||||
BUG();
|
BUG();
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -214,7 +214,7 @@ int __cpu_up(unsigned int cpu, struct task_struct *idle)
|
|||||||
* This is the secondary CPU boot entry. We're using this CPUs
|
* This is the secondary CPU boot entry. We're using this CPUs
|
||||||
* idle thread stack, but a set of temporary page tables.
|
* idle thread stack, but a set of temporary page tables.
|
||||||
*/
|
*/
|
||||||
asmlinkage notrace void secondary_start_kernel(void)
|
asmlinkage void secondary_start_kernel(void)
|
||||||
{
|
{
|
||||||
struct mm_struct *mm = &init_mm;
|
struct mm_struct *mm = &init_mm;
|
||||||
unsigned int cpu;
|
unsigned int cpu;
|
||||||
|
|||||||
@@ -629,14 +629,13 @@ static void *__iommu_alloc_attrs(struct device *dev, size_t size,
|
|||||||
size >> PAGE_SHIFT);
|
size >> PAGE_SHIFT);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
if (!coherent)
|
||||||
|
__dma_flush_area(page_to_virt(page), iosize);
|
||||||
|
|
||||||
addr = dma_common_contiguous_remap(page, size, VM_USERMAP,
|
addr = dma_common_contiguous_remap(page, size, VM_USERMAP,
|
||||||
prot,
|
prot,
|
||||||
__builtin_return_address(0));
|
__builtin_return_address(0));
|
||||||
if (addr) {
|
if (!addr) {
|
||||||
memset(addr, 0, size);
|
|
||||||
if (!coherent)
|
|
||||||
__dma_flush_area(page_to_virt(page), iosize);
|
|
||||||
} else {
|
|
||||||
iommu_dma_unmap_page(dev, *handle, iosize, 0, attrs);
|
iommu_dma_unmap_page(dev, *handle, iosize, 0, attrs);
|
||||||
dma_release_from_contiguous(dev, page,
|
dma_release_from_contiguous(dev, page,
|
||||||
size >> PAGE_SHIFT);
|
size >> PAGE_SHIFT);
|
||||||
|
|||||||
@@ -287,11 +287,7 @@ static void __init zone_sizes_init(unsigned long min, unsigned long max)
|
|||||||
#ifdef CONFIG_HAVE_ARCH_PFN_VALID
|
#ifdef CONFIG_HAVE_ARCH_PFN_VALID
|
||||||
int pfn_valid(unsigned long pfn)
|
int pfn_valid(unsigned long pfn)
|
||||||
{
|
{
|
||||||
phys_addr_t addr = pfn << PAGE_SHIFT;
|
return memblock_is_map_memory(pfn << PAGE_SHIFT);
|
||||||
|
|
||||||
if ((addr >> PAGE_SHIFT) != pfn)
|
|
||||||
return 0;
|
|
||||||
return memblock_is_map_memory(addr);
|
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(pfn_valid);
|
EXPORT_SYMBOL(pfn_valid);
|
||||||
#endif
|
#endif
|
||||||
@@ -655,13 +651,11 @@ void __init mem_init(void)
|
|||||||
BUILD_BUG_ON(TASK_SIZE_32 > TASK_SIZE_64);
|
BUILD_BUG_ON(TASK_SIZE_32 > TASK_SIZE_64);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_SPARSEMEM_VMEMMAP
|
|
||||||
/*
|
/*
|
||||||
* Make sure we chose the upper bound of sizeof(struct page)
|
* Make sure we chose the upper bound of sizeof(struct page)
|
||||||
* correctly when sizing the VMEMMAP array.
|
* correctly.
|
||||||
*/
|
*/
|
||||||
BUILD_BUG_ON(sizeof(struct page) > (1 << STRUCT_PAGE_MAX_SHIFT));
|
BUILD_BUG_ON(sizeof(struct page) > (1 << STRUCT_PAGE_MAX_SHIFT));
|
||||||
#endif
|
|
||||||
|
|
||||||
if (PAGE_SIZE >= 16384 && get_num_physpages() <= 128) {
|
if (PAGE_SIZE >= 16384 && get_num_physpages() <= 128) {
|
||||||
extern int sysctl_overcommit_memory;
|
extern int sysctl_overcommit_memory;
|
||||||
|
|||||||
@@ -938,12 +938,12 @@ int pmd_clear_huge(pmd_t *pmd)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int pud_free_pmd_page(pud_t *pud, unsigned long addr)
|
int pud_free_pmd_page(pud_t *pud)
|
||||||
{
|
{
|
||||||
return pud_none(*pud);
|
return pud_none(*pud);
|
||||||
}
|
}
|
||||||
|
|
||||||
int pmd_free_pte_page(pmd_t *pmd, unsigned long addr)
|
int pmd_free_pte_page(pmd_t *pmd)
|
||||||
{
|
{
|
||||||
return pmd_none(*pmd);
|
return pmd_none(*pmd);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -44,7 +44,6 @@ extern inline pmd_t *pmd_alloc_kernel(pgd_t *pgd, unsigned long address)
|
|||||||
static inline void __pte_free_tlb(struct mmu_gather *tlb, pgtable_t page,
|
static inline void __pte_free_tlb(struct mmu_gather *tlb, pgtable_t page,
|
||||||
unsigned long address)
|
unsigned long address)
|
||||||
{
|
{
|
||||||
pgtable_page_dtor(page);
|
|
||||||
__free_page(page);
|
__free_page(page);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -75,9 +74,8 @@ static inline struct page *pte_alloc_one(struct mm_struct *mm,
|
|||||||
return page;
|
return page;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void pte_free(struct mm_struct *mm, struct page *page)
|
extern inline void pte_free(struct mm_struct *mm, struct page *page)
|
||||||
{
|
{
|
||||||
pgtable_page_dtor(page);
|
|
||||||
__free_page(page);
|
__free_page(page);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -22,19 +22,17 @@ $(obj)/linux.bin.gz: $(obj)/linux.bin FORCE
|
|||||||
quiet_cmd_cp = CP $< $@$2
|
quiet_cmd_cp = CP $< $@$2
|
||||||
cmd_cp = cat $< >$@$2 || (rm -f $@ && echo false)
|
cmd_cp = cat $< >$@$2 || (rm -f $@ && echo false)
|
||||||
|
|
||||||
quiet_cmd_strip = STRIP $< $@$2
|
quiet_cmd_strip = STRIP $@
|
||||||
cmd_strip = $(STRIP) -K microblaze_start -K _end -K __log_buf \
|
cmd_strip = $(STRIP) -K microblaze_start -K _end -K __log_buf \
|
||||||
-K _fdt_start $< -o $@$2
|
-K _fdt_start vmlinux -o $@
|
||||||
|
|
||||||
UIMAGE_LOADADDR = $(CONFIG_KERNEL_BASE_ADDR)
|
UIMAGE_LOADADDR = $(CONFIG_KERNEL_BASE_ADDR)
|
||||||
UIMAGE_IN = $@
|
|
||||||
UIMAGE_OUT = $@.ub
|
|
||||||
|
|
||||||
$(obj)/simpleImage.%: vmlinux FORCE
|
$(obj)/simpleImage.%: vmlinux FORCE
|
||||||
$(call if_changed,cp,.unstrip)
|
$(call if_changed,cp,.unstrip)
|
||||||
$(call if_changed,objcopy)
|
$(call if_changed,objcopy)
|
||||||
$(call if_changed,uimage)
|
$(call if_changed,uimage)
|
||||||
$(call if_changed,strip,.strip)
|
$(call if_changed,strip)
|
||||||
@echo 'Kernel: $(UIMAGE_OUT) is ready' ' (#'`cat .version`')'
|
@echo 'Kernel: $@ is ready' ' (#'`cat .version`')'
|
||||||
|
|
||||||
clean-files += simpleImage.*.unstrip linux.bin.ub dts/*.dtb
|
clean-files += simpleImage.*.unstrip linux.bin.ub dts/*.dtb
|
||||||
|
|||||||
@@ -155,11 +155,15 @@ cflags-$(CONFIG_CPU_R4300) += -march=r4300 -Wa,--trap
|
|||||||
cflags-$(CONFIG_CPU_VR41XX) += -march=r4100 -Wa,--trap
|
cflags-$(CONFIG_CPU_VR41XX) += -march=r4100 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_R4X00) += -march=r4600 -Wa,--trap
|
cflags-$(CONFIG_CPU_R4X00) += -march=r4600 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_TX49XX) += -march=r4600 -Wa,--trap
|
cflags-$(CONFIG_CPU_TX49XX) += -march=r4600 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_MIPS32_R1) += -march=mips32 -Wa,--trap
|
cflags-$(CONFIG_CPU_MIPS32_R1) += $(call cc-option,-march=mips32,-mips32 -U_MIPS_ISA -D_MIPS_ISA=_MIPS_ISA_MIPS32) \
|
||||||
cflags-$(CONFIG_CPU_MIPS32_R2) += -march=mips32r2 -Wa,--trap
|
-Wa,-mips32 -Wa,--trap
|
||||||
|
cflags-$(CONFIG_CPU_MIPS32_R2) += $(call cc-option,-march=mips32r2,-mips32r2 -U_MIPS_ISA -D_MIPS_ISA=_MIPS_ISA_MIPS32) \
|
||||||
|
-Wa,-mips32r2 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_MIPS32_R6) += -march=mips32r6 -Wa,--trap -modd-spreg
|
cflags-$(CONFIG_CPU_MIPS32_R6) += -march=mips32r6 -Wa,--trap -modd-spreg
|
||||||
cflags-$(CONFIG_CPU_MIPS64_R1) += -march=mips64 -Wa,--trap
|
cflags-$(CONFIG_CPU_MIPS64_R1) += $(call cc-option,-march=mips64,-mips64 -U_MIPS_ISA -D_MIPS_ISA=_MIPS_ISA_MIPS64) \
|
||||||
cflags-$(CONFIG_CPU_MIPS64_R2) += -march=mips64r2 -Wa,--trap
|
-Wa,-mips64 -Wa,--trap
|
||||||
|
cflags-$(CONFIG_CPU_MIPS64_R2) += $(call cc-option,-march=mips64r2,-mips64r2 -U_MIPS_ISA -D_MIPS_ISA=_MIPS_ISA_MIPS64) \
|
||||||
|
-Wa,-mips64r2 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_MIPS64_R6) += -march=mips64r6 -Wa,--trap
|
cflags-$(CONFIG_CPU_MIPS64_R6) += -march=mips64r6 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_R5000) += -march=r5000 -Wa,--trap
|
cflags-$(CONFIG_CPU_R5000) += -march=r5000 -Wa,--trap
|
||||||
cflags-$(CONFIG_CPU_R5432) += $(call cc-option,-march=r5400,-march=r5000) \
|
cflags-$(CONFIG_CPU_R5432) += $(call cc-option,-march=r5400,-march=r5000) \
|
||||||
|
|||||||
@@ -212,6 +212,12 @@ static int __init bcm47xx_cpu_fixes(void)
|
|||||||
*/
|
*/
|
||||||
if (bcm47xx_bus.bcma.bus.chipinfo.id == BCMA_CHIP_ID_BCM4706)
|
if (bcm47xx_bus.bcma.bus.chipinfo.id == BCMA_CHIP_ID_BCM4706)
|
||||||
cpu_wait = NULL;
|
cpu_wait = NULL;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* BCM47XX Erratum "R10: PCIe Transactions Periodically Fail"
|
||||||
|
* Enable ExternalSync for sync instruction to take effect
|
||||||
|
*/
|
||||||
|
set_c0_config7(MIPS_CONF7_ES);
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -322,7 +322,6 @@ static int __init octeon_ehci_device_init(void)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
pd = of_find_device_by_node(ehci_node);
|
pd = of_find_device_by_node(ehci_node);
|
||||||
of_node_put(ehci_node);
|
|
||||||
if (!pd)
|
if (!pd)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
@@ -385,7 +384,6 @@ static int __init octeon_ohci_device_init(void)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
pd = of_find_device_by_node(ohci_node);
|
pd = of_find_device_by_node(ohci_node);
|
||||||
of_node_put(ohci_node);
|
|
||||||
if (!pd)
|
if (!pd)
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
|
|||||||
@@ -204,7 +204,6 @@ void __init arch_init_irq(void)
|
|||||||
"mti,cpu-interrupt-controller");
|
"mti,cpu-interrupt-controller");
|
||||||
if (!cpu_has_veic && !intc_node)
|
if (!cpu_has_veic && !intc_node)
|
||||||
mips_cpu_irq_init();
|
mips_cpu_irq_init();
|
||||||
of_node_put(intc_node);
|
|
||||||
|
|
||||||
irqchip_init();
|
irqchip_init();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -141,14 +141,14 @@ static inline void * phys_to_virt(unsigned long address)
|
|||||||
/*
|
/*
|
||||||
* ISA I/O bus memory addresses are 1:1 with the physical address.
|
* ISA I/O bus memory addresses are 1:1 with the physical address.
|
||||||
*/
|
*/
|
||||||
static inline unsigned long isa_virt_to_bus(volatile void *address)
|
static inline unsigned long isa_virt_to_bus(volatile void * address)
|
||||||
{
|
{
|
||||||
return virt_to_phys(address);
|
return (unsigned long)address - PAGE_OFFSET;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void *isa_bus_to_virt(unsigned long address)
|
static inline void * isa_bus_to_virt(unsigned long address)
|
||||||
{
|
{
|
||||||
return phys_to_virt(address);
|
return (void *)(address + PAGE_OFFSET);
|
||||||
}
|
}
|
||||||
|
|
||||||
#define isa_page_to_bus page_to_phys
|
#define isa_page_to_bus page_to_phys
|
||||||
|
|||||||
@@ -680,6 +680,8 @@
|
|||||||
#define MIPS_CONF7_WII (_ULCAST_(1) << 31)
|
#define MIPS_CONF7_WII (_ULCAST_(1) << 31)
|
||||||
|
|
||||||
#define MIPS_CONF7_RPS (_ULCAST_(1) << 2)
|
#define MIPS_CONF7_RPS (_ULCAST_(1) << 2)
|
||||||
|
/* ExternalSync */
|
||||||
|
#define MIPS_CONF7_ES (_ULCAST_(1) << 8)
|
||||||
|
|
||||||
#define MIPS_CONF7_IAR (_ULCAST_(1) << 10)
|
#define MIPS_CONF7_IAR (_ULCAST_(1) << 10)
|
||||||
#define MIPS_CONF7_AR (_ULCAST_(1) << 16)
|
#define MIPS_CONF7_AR (_ULCAST_(1) << 16)
|
||||||
@@ -2745,6 +2747,7 @@ __BUILD_SET_C0(status)
|
|||||||
__BUILD_SET_C0(cause)
|
__BUILD_SET_C0(cause)
|
||||||
__BUILD_SET_C0(config)
|
__BUILD_SET_C0(config)
|
||||||
__BUILD_SET_C0(config5)
|
__BUILD_SET_C0(config5)
|
||||||
|
__BUILD_SET_C0(config7)
|
||||||
__BUILD_SET_C0(intcontrol)
|
__BUILD_SET_C0(intcontrol)
|
||||||
__BUILD_SET_C0(intctl)
|
__BUILD_SET_C0(intctl)
|
||||||
__BUILD_SET_C0(srsmap)
|
__BUILD_SET_C0(srsmap)
|
||||||
|
|||||||
@@ -141,7 +141,7 @@ struct mips_fpu_struct {
|
|||||||
|
|
||||||
#define NUM_DSP_REGS 6
|
#define NUM_DSP_REGS 6
|
||||||
|
|
||||||
typedef unsigned long dspreg_t;
|
typedef __u32 dspreg_t;
|
||||||
|
|
||||||
struct mips_dsp_state {
|
struct mips_dsp_state {
|
||||||
dspreg_t dspr[NUM_DSP_REGS];
|
dspreg_t dspr[NUM_DSP_REGS];
|
||||||
@@ -388,20 +388,7 @@ unsigned long get_wchan(struct task_struct *p);
|
|||||||
#define KSTK_ESP(tsk) (task_pt_regs(tsk)->regs[29])
|
#define KSTK_ESP(tsk) (task_pt_regs(tsk)->regs[29])
|
||||||
#define KSTK_STATUS(tsk) (task_pt_regs(tsk)->cp0_status)
|
#define KSTK_STATUS(tsk) (task_pt_regs(tsk)->cp0_status)
|
||||||
|
|
||||||
#ifdef CONFIG_CPU_LOONGSON3
|
|
||||||
/*
|
|
||||||
* Loongson-3's SFB (Store-Fill-Buffer) may buffer writes indefinitely when a
|
|
||||||
* tight read loop is executed, because reads take priority over writes & the
|
|
||||||
* hardware (incorrectly) doesn't ensure that writes will eventually occur.
|
|
||||||
*
|
|
||||||
* Since spin loops of any kind should have a cpu_relax() in them, force an SFB
|
|
||||||
* flush from cpu_relax() such that any pending writes will become visible as
|
|
||||||
* expected.
|
|
||||||
*/
|
|
||||||
#define cpu_relax() smp_mb()
|
|
||||||
#else
|
|
||||||
#define cpu_relax() barrier()
|
#define cpu_relax() barrier()
|
||||||
#endif
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Return_address is a replacement for __builtin_return_address(count)
|
* Return_address is a replacement for __builtin_return_address(count)
|
||||||
|
|||||||
@@ -847,7 +847,7 @@ long arch_ptrace(struct task_struct *child, long request,
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
dregs = __get_dsp_regs(child);
|
dregs = __get_dsp_regs(child);
|
||||||
tmp = dregs[addr - DSP_BASE];
|
tmp = (unsigned long) (dregs[addr - DSP_BASE]);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case DSP_CONTROL:
|
case DSP_CONTROL:
|
||||||
|
|||||||
@@ -141,7 +141,7 @@ long compat_arch_ptrace(struct task_struct *child, compat_long_t request,
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
dregs = __get_dsp_regs(child);
|
dregs = __get_dsp_regs(child);
|
||||||
tmp = dregs[addr - DSP_BASE];
|
tmp = (unsigned long) (dregs[addr - DSP_BASE]);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case DSP_CONTROL:
|
case DSP_CONTROL:
|
||||||
|
|||||||
@@ -13,7 +13,6 @@
|
|||||||
#include <linux/err.h>
|
#include <linux/err.h>
|
||||||
#include <linux/init.h>
|
#include <linux/init.h>
|
||||||
#include <linux/ioport.h>
|
#include <linux/ioport.h>
|
||||||
#include <linux/kernel.h>
|
|
||||||
#include <linux/mm.h>
|
#include <linux/mm.h>
|
||||||
#include <linux/sched.h>
|
#include <linux/sched.h>
|
||||||
#include <linux/slab.h>
|
#include <linux/slab.h>
|
||||||
@@ -21,7 +20,6 @@
|
|||||||
|
|
||||||
#include <asm/abi.h>
|
#include <asm/abi.h>
|
||||||
#include <asm/mips-cps.h>
|
#include <asm/mips-cps.h>
|
||||||
#include <asm/page.h>
|
|
||||||
#include <asm/vdso.h>
|
#include <asm/vdso.h>
|
||||||
|
|
||||||
/* Kernel-provided data used by the VDSO. */
|
/* Kernel-provided data used by the VDSO. */
|
||||||
@@ -130,30 +128,12 @@ int arch_setup_additional_pages(struct linux_binprm *bprm, int uses_interp)
|
|||||||
vvar_size = gic_size + PAGE_SIZE;
|
vvar_size = gic_size + PAGE_SIZE;
|
||||||
size = vvar_size + image->size;
|
size = vvar_size + image->size;
|
||||||
|
|
||||||
/*
|
|
||||||
* Find a region that's large enough for us to perform the
|
|
||||||
* colour-matching alignment below.
|
|
||||||
*/
|
|
||||||
if (cpu_has_dc_aliases)
|
|
||||||
size += shm_align_mask + 1;
|
|
||||||
|
|
||||||
base = get_unmapped_area(NULL, 0, size, 0, 0);
|
base = get_unmapped_area(NULL, 0, size, 0, 0);
|
||||||
if (IS_ERR_VALUE(base)) {
|
if (IS_ERR_VALUE(base)) {
|
||||||
ret = base;
|
ret = base;
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* If we suffer from dcache aliasing, ensure that the VDSO data page
|
|
||||||
* mapping is coloured the same as the kernel's mapping of that memory.
|
|
||||||
* This ensures that when the kernel updates the VDSO data userland
|
|
||||||
* will observe it without requiring cache invalidations.
|
|
||||||
*/
|
|
||||||
if (cpu_has_dc_aliases) {
|
|
||||||
base = __ALIGN_MASK(base, shm_align_mask);
|
|
||||||
base += ((unsigned long)&vdso_data - gic_size) & shm_align_mask;
|
|
||||||
}
|
|
||||||
|
|
||||||
data_addr = base + gic_size;
|
data_addr = base + gic_size;
|
||||||
vdso_addr = data_addr + PAGE_SIZE;
|
vdso_addr = data_addr + PAGE_SIZE;
|
||||||
|
|
||||||
|
|||||||
@@ -4,12 +4,12 @@
|
|||||||
#include "libgcc.h"
|
#include "libgcc.h"
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* GCC 7 & older can suboptimally generate __multi3 calls for mips64r6, so for
|
* GCC 7 suboptimally generates __multi3 calls for mips64r6, so for that
|
||||||
* that specific case only we implement that intrinsic here.
|
* specific case only we'll implement it here.
|
||||||
*
|
*
|
||||||
* See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82981
|
* See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82981
|
||||||
*/
|
*/
|
||||||
#if defined(CONFIG_64BIT) && defined(CONFIG_CPU_MIPSR6) && (__GNUC__ < 8)
|
#if defined(CONFIG_64BIT) && defined(CONFIG_CPU_MIPSR6) && (__GNUC__ == 7)
|
||||||
|
|
||||||
/* multiply 64-bit values, low 64-bits returned */
|
/* multiply 64-bit values, low 64-bits returned */
|
||||||
static inline long long notrace dmulu(long long a, long long b)
|
static inline long long notrace dmulu(long long a, long long b)
|
||||||
|
|||||||
@@ -835,8 +835,7 @@ static void r4k_flush_icache_user_range(unsigned long start, unsigned long end)
|
|||||||
static void r4k_dma_cache_wback_inv(unsigned long addr, unsigned long size)
|
static void r4k_dma_cache_wback_inv(unsigned long addr, unsigned long size)
|
||||||
{
|
{
|
||||||
/* Catch bad driver code */
|
/* Catch bad driver code */
|
||||||
if (WARN_ON(size == 0))
|
BUG_ON(size == 0);
|
||||||
return;
|
|
||||||
|
|
||||||
preempt_disable();
|
preempt_disable();
|
||||||
if (cpu_has_inclusive_pcaches) {
|
if (cpu_has_inclusive_pcaches) {
|
||||||
@@ -872,8 +871,7 @@ static void r4k_dma_cache_wback_inv(unsigned long addr, unsigned long size)
|
|||||||
static void r4k_dma_cache_inv(unsigned long addr, unsigned long size)
|
static void r4k_dma_cache_inv(unsigned long addr, unsigned long size)
|
||||||
{
|
{
|
||||||
/* Catch bad driver code */
|
/* Catch bad driver code */
|
||||||
if (WARN_ON(size == 0))
|
BUG_ON(size == 0);
|
||||||
return;
|
|
||||||
|
|
||||||
preempt_disable();
|
preempt_disable();
|
||||||
if (cpu_has_inclusive_pcaches) {
|
if (cpu_has_inclusive_pcaches) {
|
||||||
|
|||||||
@@ -221,6 +221,12 @@ EXCEPTION_ENTRY(_data_page_fault_handler)
|
|||||||
l.addi r3,r1,0 // pt_regs
|
l.addi r3,r1,0 // pt_regs
|
||||||
/* r4 set be EXCEPTION_HANDLE */ // effective address of fault
|
/* r4 set be EXCEPTION_HANDLE */ // effective address of fault
|
||||||
|
|
||||||
|
/*
|
||||||
|
* __PHX__: TODO
|
||||||
|
*
|
||||||
|
* all this can be written much simpler. look at
|
||||||
|
* DTLB miss handler in the CONFIG_GUARD_PROTECTED_CORE part
|
||||||
|
*/
|
||||||
#ifdef CONFIG_OPENRISC_NO_SPR_SR_DSX
|
#ifdef CONFIG_OPENRISC_NO_SPR_SR_DSX
|
||||||
l.lwz r6,PT_PC(r3) // address of an offending insn
|
l.lwz r6,PT_PC(r3) // address of an offending insn
|
||||||
l.lwz r6,0(r6) // instruction that caused pf
|
l.lwz r6,0(r6) // instruction that caused pf
|
||||||
@@ -252,7 +258,7 @@ EXCEPTION_ENTRY(_data_page_fault_handler)
|
|||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
l.mfspr r6,r0,SPR_SR // SR
|
l.lwz r6,PT_SR(r3) // SR
|
||||||
l.andi r6,r6,SPR_SR_DSX // check for delay slot exception
|
l.andi r6,r6,SPR_SR_DSX // check for delay slot exception
|
||||||
l.sfne r6,r0 // exception happened in delay slot
|
l.sfne r6,r0 // exception happened in delay slot
|
||||||
l.bnf 7f
|
l.bnf 7f
|
||||||
|
|||||||
@@ -141,7 +141,8 @@
|
|||||||
* r4 - EEAR exception EA
|
* r4 - EEAR exception EA
|
||||||
* r10 - current pointing to current_thread_info struct
|
* r10 - current pointing to current_thread_info struct
|
||||||
* r12 - syscall 0, since we didn't come from syscall
|
* r12 - syscall 0, since we didn't come from syscall
|
||||||
* r30 - handler address of the handler we'll jump to
|
* r13 - temp it actually contains new SR, not needed anymore
|
||||||
|
* r31 - handler address of the handler we'll jump to
|
||||||
*
|
*
|
||||||
* handler has to save remaining registers to the exception
|
* handler has to save remaining registers to the exception
|
||||||
* ksp frame *before* tainting them!
|
* ksp frame *before* tainting them!
|
||||||
@@ -177,7 +178,6 @@
|
|||||||
/* r1 is KSP, r30 is __pa(KSP) */ ;\
|
/* r1 is KSP, r30 is __pa(KSP) */ ;\
|
||||||
tophys (r30,r1) ;\
|
tophys (r30,r1) ;\
|
||||||
l.sw PT_GPR12(r30),r12 ;\
|
l.sw PT_GPR12(r30),r12 ;\
|
||||||
/* r4 use for tmp before EA */ ;\
|
|
||||||
l.mfspr r12,r0,SPR_EPCR_BASE ;\
|
l.mfspr r12,r0,SPR_EPCR_BASE ;\
|
||||||
l.sw PT_PC(r30),r12 ;\
|
l.sw PT_PC(r30),r12 ;\
|
||||||
l.mfspr r12,r0,SPR_ESR_BASE ;\
|
l.mfspr r12,r0,SPR_ESR_BASE ;\
|
||||||
@@ -197,10 +197,7 @@
|
|||||||
/* r12 == 1 if we come from syscall */ ;\
|
/* r12 == 1 if we come from syscall */ ;\
|
||||||
CLEAR_GPR(r12) ;\
|
CLEAR_GPR(r12) ;\
|
||||||
/* ----- turn on MMU ----- */ ;\
|
/* ----- turn on MMU ----- */ ;\
|
||||||
/* Carry DSX into exception SR */ ;\
|
l.ori r30,r0,(EXCEPTION_SR) ;\
|
||||||
l.mfspr r30,r0,SPR_SR ;\
|
|
||||||
l.andi r30,r30,SPR_SR_DSX ;\
|
|
||||||
l.ori r30,r30,(EXCEPTION_SR) ;\
|
|
||||||
l.mtspr r0,r30,SPR_ESR_BASE ;\
|
l.mtspr r0,r30,SPR_ESR_BASE ;\
|
||||||
/* r30: EA address of handler */ ;\
|
/* r30: EA address of handler */ ;\
|
||||||
LOAD_SYMBOL_2_GPR(r30,handler) ;\
|
LOAD_SYMBOL_2_GPR(r30,handler) ;\
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user