Linux 5.19-rc4
-----BEGIN PGP SIGNATURE----- iQFRBAABCAA8FiEEq68RxlopcLEwq+PEeb4+QwBBGIYFAmK4zgIeHHRvcnZhbGRz QGxpbnV4LWZvdW5kYXRpb24ub3JnAAoJEHm+PkMAQRiGrI8H+MeIYPff1m9vh1rZ u1eCCtw/A+NqJ5l0Cq3Zj090crMb8zVkxr5QrdPxxJuxAK8AI/XzOUQivnNayp6v bvWcbj9e95ZoIQjbPakozo3KYnaHXMFfrq6JNdGIBJ5yt5pVHtJ3iZk25wUZEghD 8lxoz4Uiuo14ZbLnlLjbXr5OEVupOH1OoQPghkSoolD8JBe1coOIYbzzJ69HBwNg kCUyD0CsFCBpy0P7yBnPNrvQGOt+NVz9FLfEbYFj+ydQjzw3NNw7tyKTahqp7ScN BS5Ftt0kuHqOyWDO9OP6dG1kGmvIWQZkrEroz1TS4FfgrrPRr5r0N9+tGvr9+tpZ 1tjaBA== =L7lN -----END PGP SIGNATURE----- Merge 5.19-rc4 into usb-next We need the USB fixes in here as well. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
commit
e6aa42f937
4
.mailmap
4
.mailmap
@ -10,6 +10,8 @@
|
|||||||
# Please keep this list dictionary sorted.
|
# Please keep this list dictionary sorted.
|
||||||
#
|
#
|
||||||
Aaron Durbin <adurbin@google.com>
|
Aaron Durbin <adurbin@google.com>
|
||||||
|
Abel Vesa <abelvesa@kernel.org> <abel.vesa@nxp.com>
|
||||||
|
Abel Vesa <abelvesa@kernel.org> <abelvesa@gmail.com>
|
||||||
Abhinav Kumar <quic_abhinavk@quicinc.com> <abhinavk@codeaurora.org>
|
Abhinav Kumar <quic_abhinavk@quicinc.com> <abhinavk@codeaurora.org>
|
||||||
Adam Oldham <oldhamca@gmail.com>
|
Adam Oldham <oldhamca@gmail.com>
|
||||||
Adam Radford <aradford@gmail.com>
|
Adam Radford <aradford@gmail.com>
|
||||||
@ -85,6 +87,7 @@ Christian Borntraeger <borntraeger@linux.ibm.com> <borntrae@de.ibm.com>
|
|||||||
Christian Brauner <brauner@kernel.org> <christian@brauner.io>
|
Christian Brauner <brauner@kernel.org> <christian@brauner.io>
|
||||||
Christian Brauner <brauner@kernel.org> <christian.brauner@canonical.com>
|
Christian Brauner <brauner@kernel.org> <christian.brauner@canonical.com>
|
||||||
Christian Brauner <brauner@kernel.org> <christian.brauner@ubuntu.com>
|
Christian Brauner <brauner@kernel.org> <christian.brauner@ubuntu.com>
|
||||||
|
Christian Marangi <ansuelsmth@gmail.com>
|
||||||
Christophe Ricard <christophe.ricard@gmail.com>
|
Christophe Ricard <christophe.ricard@gmail.com>
|
||||||
Christoph Hellwig <hch@lst.de>
|
Christoph Hellwig <hch@lst.de>
|
||||||
Colin Ian King <colin.king@intel.com> <colin.king@canonical.com>
|
Colin Ian King <colin.king@intel.com> <colin.king@canonical.com>
|
||||||
@ -165,6 +168,7 @@ Jan Glauber <jan.glauber@gmail.com> <jang@de.ibm.com>
|
|||||||
Jan Glauber <jan.glauber@gmail.com> <jang@linux.vnet.ibm.com>
|
Jan Glauber <jan.glauber@gmail.com> <jang@linux.vnet.ibm.com>
|
||||||
Jan Glauber <jan.glauber@gmail.com> <jglauber@cavium.com>
|
Jan Glauber <jan.glauber@gmail.com> <jglauber@cavium.com>
|
||||||
Jarkko Sakkinen <jarkko@kernel.org> <jarkko.sakkinen@linux.intel.com>
|
Jarkko Sakkinen <jarkko@kernel.org> <jarkko.sakkinen@linux.intel.com>
|
||||||
|
Jarkko Sakkinen <jarkko@kernel.org> <jarkko@profian.com>
|
||||||
Jason Gunthorpe <jgg@ziepe.ca> <jgg@mellanox.com>
|
Jason Gunthorpe <jgg@ziepe.ca> <jgg@mellanox.com>
|
||||||
Jason Gunthorpe <jgg@ziepe.ca> <jgg@nvidia.com>
|
Jason Gunthorpe <jgg@ziepe.ca> <jgg@nvidia.com>
|
||||||
Jason Gunthorpe <jgg@ziepe.ca> <jgunthorpe@obsidianresearch.com>
|
Jason Gunthorpe <jgg@ziepe.ca> <jgunthorpe@obsidianresearch.com>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
What: /sys/bus/iio/devices/iio:deviceX/conversion_mode
|
What: /sys/bus/iio/devices/iio:deviceX/in_conversion_mode
|
||||||
KernelVersion: 4.2
|
KernelVersion: 4.2
|
||||||
Contact: linux-iio@vger.kernel.org
|
Contact: linux-iio@vger.kernel.org
|
||||||
Description:
|
Description:
|
||||||
|
@ -47,6 +47,5 @@ examples:
|
|||||||
clocks = <&clkcfg CLK_SPI0>;
|
clocks = <&clkcfg CLK_SPI0>;
|
||||||
interrupt-parent = <&plic>;
|
interrupt-parent = <&plic>;
|
||||||
interrupts = <54>;
|
interrupts = <54>;
|
||||||
spi-max-frequency = <25000000>;
|
|
||||||
};
|
};
|
||||||
...
|
...
|
||||||
|
@ -110,7 +110,6 @@ examples:
|
|||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&qup_spi1_default>;
|
pinctrl-0 = <&qup_spi1_default>;
|
||||||
interrupts = <GIC_SPI 602 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 602 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
spi-max-frequency = <50000000>;
|
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
};
|
};
|
||||||
|
@ -136,7 +136,8 @@ properties:
|
|||||||
Phandle of a companion.
|
Phandle of a companion.
|
||||||
|
|
||||||
phys:
|
phys:
|
||||||
maxItems: 1
|
minItems: 1
|
||||||
|
maxItems: 3
|
||||||
|
|
||||||
phy-names:
|
phy-names:
|
||||||
const: usb
|
const: usb
|
||||||
|
@ -103,7 +103,8 @@ properties:
|
|||||||
Overrides the detected port count
|
Overrides the detected port count
|
||||||
|
|
||||||
phys:
|
phys:
|
||||||
maxItems: 1
|
minItems: 1
|
||||||
|
maxItems: 3
|
||||||
|
|
||||||
phy-names:
|
phy-names:
|
||||||
const: usb
|
const: usb
|
||||||
|
@ -6,7 +6,7 @@ This document explains how GPIOs can be assigned to given devices and functions.
|
|||||||
|
|
||||||
Note that it only applies to the new descriptor-based interface. For a
|
Note that it only applies to the new descriptor-based interface. For a
|
||||||
description of the deprecated integer-based GPIO interface please refer to
|
description of the deprecated integer-based GPIO interface please refer to
|
||||||
gpio-legacy.txt (actually, there is no real mapping possible with the old
|
legacy.rst (actually, there is no real mapping possible with the old
|
||||||
interface; you just fetch an integer from somewhere and request the
|
interface; you just fetch an integer from somewhere and request the
|
||||||
corresponding GPIO).
|
corresponding GPIO).
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@ GPIO Descriptor Consumer Interface
|
|||||||
|
|
||||||
This document describes the consumer interface of the GPIO framework. Note that
|
This document describes the consumer interface of the GPIO framework. Note that
|
||||||
it describes the new descriptor-based interface. For a description of the
|
it describes the new descriptor-based interface. For a description of the
|
||||||
deprecated integer-based GPIO interface please refer to gpio-legacy.txt.
|
deprecated integer-based GPIO interface please refer to legacy.rst.
|
||||||
|
|
||||||
|
|
||||||
Guidelines for GPIOs consumers
|
Guidelines for GPIOs consumers
|
||||||
@ -78,7 +78,7 @@ whether the line is configured active high or active low (see
|
|||||||
|
|
||||||
The two last flags are used for use cases where open drain is mandatory, such
|
The two last flags are used for use cases where open drain is mandatory, such
|
||||||
as I2C: if the line is not already configured as open drain in the mappings
|
as I2C: if the line is not already configured as open drain in the mappings
|
||||||
(see board.txt), then open drain will be enforced anyway and a warning will be
|
(see board.rst), then open drain will be enforced anyway and a warning will be
|
||||||
printed that the board configuration needs to be updated to match the use case.
|
printed that the board configuration needs to be updated to match the use case.
|
||||||
|
|
||||||
Both functions return either a valid GPIO descriptor, or an error code checkable
|
Both functions return either a valid GPIO descriptor, or an error code checkable
|
||||||
@ -270,7 +270,7 @@ driven.
|
|||||||
The same is applicable for open drain or open source output lines: those do not
|
The same is applicable for open drain or open source output lines: those do not
|
||||||
actively drive their output high (open drain) or low (open source), they just
|
actively drive their output high (open drain) or low (open source), they just
|
||||||
switch their output to a high impedance value. The consumer should not need to
|
switch their output to a high impedance value. The consumer should not need to
|
||||||
care. (For details read about open drain in driver.txt.)
|
care. (For details read about open drain in driver.rst.)
|
||||||
|
|
||||||
With this, all the gpiod_set_(array)_value_xxx() functions interpret the
|
With this, all the gpiod_set_(array)_value_xxx() functions interpret the
|
||||||
parameter "value" as "asserted" ("1") or "de-asserted" ("0"). The physical line
|
parameter "value" as "asserted" ("1") or "de-asserted" ("0"). The physical line
|
||||||
|
@ -14,12 +14,12 @@ Due to the history of GPIO interfaces in the kernel, there are two different
|
|||||||
ways to obtain and use GPIOs:
|
ways to obtain and use GPIOs:
|
||||||
|
|
||||||
- The descriptor-based interface is the preferred way to manipulate GPIOs,
|
- The descriptor-based interface is the preferred way to manipulate GPIOs,
|
||||||
and is described by all the files in this directory excepted gpio-legacy.txt.
|
and is described by all the files in this directory excepted legacy.rst.
|
||||||
- The legacy integer-based interface which is considered deprecated (but still
|
- The legacy integer-based interface which is considered deprecated (but still
|
||||||
usable for compatibility reasons) is documented in gpio-legacy.txt.
|
usable for compatibility reasons) is documented in legacy.rst.
|
||||||
|
|
||||||
The remainder of this document applies to the new descriptor-based interface.
|
The remainder of this document applies to the new descriptor-based interface.
|
||||||
gpio-legacy.txt contains the same information applied to the legacy
|
legacy.rst contains the same information applied to the legacy
|
||||||
integer-based interface.
|
integer-based interface.
|
||||||
|
|
||||||
|
|
||||||
|
@ -19,13 +19,23 @@ The main Btrfs features include:
|
|||||||
* Subvolumes (separate internal filesystem roots)
|
* Subvolumes (separate internal filesystem roots)
|
||||||
* Object level mirroring and striping
|
* Object level mirroring and striping
|
||||||
* Checksums on data and metadata (multiple algorithms available)
|
* Checksums on data and metadata (multiple algorithms available)
|
||||||
* Compression
|
* Compression (multiple algorithms available)
|
||||||
|
* Reflink, deduplication
|
||||||
|
* Scrub (on-line checksum verification)
|
||||||
|
* Hierarchical quota groups (subvolume and snapshot support)
|
||||||
* Integrated multiple device support, with several raid algorithms
|
* Integrated multiple device support, with several raid algorithms
|
||||||
* Offline filesystem check
|
* Offline filesystem check
|
||||||
* Efficient incremental backup and FS mirroring
|
* Efficient incremental backup and FS mirroring (send/receive)
|
||||||
|
* Trim/discard
|
||||||
* Online filesystem defragmentation
|
* Online filesystem defragmentation
|
||||||
|
* Swapfile support
|
||||||
|
* Zoned mode
|
||||||
|
* Read/write metadata verification
|
||||||
|
* Online resize (shrink, grow)
|
||||||
|
|
||||||
For more information please refer to the wiki
|
For more information please refer to the documentation site or wiki
|
||||||
|
|
||||||
|
https://btrfs.readthedocs.io
|
||||||
|
|
||||||
https://btrfs.wiki.kernel.org
|
https://btrfs.wiki.kernel.org
|
||||||
|
|
||||||
|
@ -129,18 +129,24 @@ yet. Bug reports are always welcome at the issue tracker below!
|
|||||||
* - arm64
|
* - arm64
|
||||||
- Supported
|
- Supported
|
||||||
- ``LLVM=1``
|
- ``LLVM=1``
|
||||||
|
* - hexagon
|
||||||
|
- Maintained
|
||||||
|
- ``LLVM=1``
|
||||||
* - mips
|
* - mips
|
||||||
- Maintained
|
- Maintained
|
||||||
- ``CC=clang``
|
- ``LLVM=1``
|
||||||
* - powerpc
|
* - powerpc
|
||||||
- Maintained
|
- Maintained
|
||||||
- ``CC=clang``
|
- ``CC=clang``
|
||||||
* - riscv
|
* - riscv
|
||||||
- Maintained
|
- Maintained
|
||||||
- ``CC=clang``
|
- ``LLVM=1``
|
||||||
* - s390
|
* - s390
|
||||||
- Maintained
|
- Maintained
|
||||||
- ``CC=clang``
|
- ``CC=clang``
|
||||||
|
* - um (User Mode)
|
||||||
|
- Maintained
|
||||||
|
- ``LLVM=1``
|
||||||
* - x86
|
* - x86
|
||||||
- Supported
|
- Supported
|
||||||
- ``LLVM=1``
|
- ``LLVM=1``
|
||||||
|
@ -120,7 +120,8 @@ Testing
|
|||||||
unpoison-pfn
|
unpoison-pfn
|
||||||
Software-unpoison page at PFN echoed into this file. This way
|
Software-unpoison page at PFN echoed into this file. This way
|
||||||
a page can be reused again. This only works for Linux
|
a page can be reused again. This only works for Linux
|
||||||
injected failures, not for real memory failures.
|
injected failures, not for real memory failures. Once any hardware
|
||||||
|
memory failure happens, this feature is disabled.
|
||||||
|
|
||||||
Note these injection interfaces are not stable and might change between
|
Note these injection interfaces are not stable and might change between
|
||||||
kernel versions
|
kernel versions
|
||||||
|
127
MAINTAINERS
127
MAINTAINERS
@ -427,6 +427,7 @@ ACPI VIOT DRIVER
|
|||||||
M: Jean-Philippe Brucker <jean-philippe@linaro.org>
|
M: Jean-Philippe Brucker <jean-philippe@linaro.org>
|
||||||
L: linux-acpi@vger.kernel.org
|
L: linux-acpi@vger.kernel.org
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: drivers/acpi/viot.c
|
F: drivers/acpi/viot.c
|
||||||
F: include/linux/acpi_viot.h
|
F: include/linux/acpi_viot.h
|
||||||
@ -960,6 +961,7 @@ AMD IOMMU (AMD-VI)
|
|||||||
M: Joerg Roedel <joro@8bytes.org>
|
M: Joerg Roedel <joro@8bytes.org>
|
||||||
R: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
|
R: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Maintained
|
S: Maintained
|
||||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
||||||
F: drivers/iommu/amd/
|
F: drivers/iommu/amd/
|
||||||
@ -2467,6 +2469,7 @@ ARM/NXP S32G ARCHITECTURE
|
|||||||
M: Chester Lin <clin@suse.com>
|
M: Chester Lin <clin@suse.com>
|
||||||
R: Andreas Färber <afaerber@suse.de>
|
R: Andreas Färber <afaerber@suse.de>
|
||||||
R: Matthias Brugger <mbrugger@suse.com>
|
R: Matthias Brugger <mbrugger@suse.com>
|
||||||
|
R: NXP S32 Linux Team <s32@nxp.com>
|
||||||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: arch/arm64/boot/dts/freescale/s32g*.dts*
|
F: arch/arm64/boot/dts/freescale/s32g*.dts*
|
||||||
@ -3669,7 +3672,7 @@ BPF JIT for ARM
|
|||||||
M: Shubham Bansal <illusionist.neo@gmail.com>
|
M: Shubham Bansal <illusionist.neo@gmail.com>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Maintained
|
S: Odd Fixes
|
||||||
F: arch/arm/net/
|
F: arch/arm/net/
|
||||||
|
|
||||||
BPF JIT for ARM64
|
BPF JIT for ARM64
|
||||||
@ -3693,14 +3696,15 @@ BPF JIT for NFP NICs
|
|||||||
M: Jakub Kicinski <kuba@kernel.org>
|
M: Jakub Kicinski <kuba@kernel.org>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Supported
|
S: Odd Fixes
|
||||||
F: drivers/net/ethernet/netronome/nfp/bpf/
|
F: drivers/net/ethernet/netronome/nfp/bpf/
|
||||||
|
|
||||||
BPF JIT for POWERPC (32-BIT AND 64-BIT)
|
BPF JIT for POWERPC (32-BIT AND 64-BIT)
|
||||||
M: Naveen N. Rao <naveen.n.rao@linux.ibm.com>
|
M: Naveen N. Rao <naveen.n.rao@linux.ibm.com>
|
||||||
|
M: Michael Ellerman <mpe@ellerman.id.au>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Maintained
|
S: Supported
|
||||||
F: arch/powerpc/net/
|
F: arch/powerpc/net/
|
||||||
|
|
||||||
BPF JIT for RISC-V (32-bit)
|
BPF JIT for RISC-V (32-bit)
|
||||||
@ -3726,7 +3730,7 @@ M: Heiko Carstens <hca@linux.ibm.com>
|
|||||||
M: Vasily Gorbik <gor@linux.ibm.com>
|
M: Vasily Gorbik <gor@linux.ibm.com>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Maintained
|
S: Supported
|
||||||
F: arch/s390/net/
|
F: arch/s390/net/
|
||||||
X: arch/s390/net/pnet.c
|
X: arch/s390/net/pnet.c
|
||||||
|
|
||||||
@ -3734,14 +3738,14 @@ BPF JIT for SPARC (32-BIT AND 64-BIT)
|
|||||||
M: David S. Miller <davem@davemloft.net>
|
M: David S. Miller <davem@davemloft.net>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Maintained
|
S: Odd Fixes
|
||||||
F: arch/sparc/net/
|
F: arch/sparc/net/
|
||||||
|
|
||||||
BPF JIT for X86 32-BIT
|
BPF JIT for X86 32-BIT
|
||||||
M: Wang YanQing <udknight@gmail.com>
|
M: Wang YanQing <udknight@gmail.com>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
S: Maintained
|
S: Odd Fixes
|
||||||
F: arch/x86/net/bpf_jit_comp32.c
|
F: arch/x86/net/bpf_jit_comp32.c
|
||||||
|
|
||||||
BPF JIT for X86 64-BIT
|
BPF JIT for X86 64-BIT
|
||||||
@ -3764,6 +3768,19 @@ F: include/linux/bpf_lsm.h
|
|||||||
F: kernel/bpf/bpf_lsm.c
|
F: kernel/bpf/bpf_lsm.c
|
||||||
F: security/bpf/
|
F: security/bpf/
|
||||||
|
|
||||||
|
BPF L7 FRAMEWORK
|
||||||
|
M: John Fastabend <john.fastabend@gmail.com>
|
||||||
|
M: Jakub Sitnicki <jakub@cloudflare.com>
|
||||||
|
L: netdev@vger.kernel.org
|
||||||
|
L: bpf@vger.kernel.org
|
||||||
|
S: Maintained
|
||||||
|
F: include/linux/skmsg.h
|
||||||
|
F: net/core/skmsg.c
|
||||||
|
F: net/core/sock_map.c
|
||||||
|
F: net/ipv4/tcp_bpf.c
|
||||||
|
F: net/ipv4/udp_bpf.c
|
||||||
|
F: net/unix/unix_bpf.c
|
||||||
|
|
||||||
BPFTOOL
|
BPFTOOL
|
||||||
M: Quentin Monnet <quentin@isovalent.com>
|
M: Quentin Monnet <quentin@isovalent.com>
|
||||||
L: bpf@vger.kernel.org
|
L: bpf@vger.kernel.org
|
||||||
@ -3803,12 +3820,12 @@ N: bcmbca
|
|||||||
N: bcm[9]?47622
|
N: bcm[9]?47622
|
||||||
|
|
||||||
BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE
|
BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE
|
||||||
M: Nicolas Saenz Julienne <nsaenz@kernel.org>
|
M: Florian Fainelli <f.fainelli@gmail.com>
|
||||||
R: Broadcom internal kernel review list <bcm-kernel-feedback-list@broadcom.com>
|
R: Broadcom internal kernel review list <bcm-kernel-feedback-list@broadcom.com>
|
||||||
L: linux-rpi-kernel@lists.infradead.org (moderated for non-subscribers)
|
L: linux-rpi-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||||
S: Maintained
|
S: Maintained
|
||||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/nsaenz/linux-rpi.git
|
T: git git://github.com/broadcom/stblinux.git
|
||||||
F: Documentation/devicetree/bindings/pci/brcm,stb-pcie.yaml
|
F: Documentation/devicetree/bindings/pci/brcm,stb-pcie.yaml
|
||||||
F: drivers/pci/controller/pcie-brcmstb.c
|
F: drivers/pci/controller/pcie-brcmstb.c
|
||||||
F: drivers/staging/vc04_services
|
F: drivers/staging/vc04_services
|
||||||
@ -5969,6 +5986,7 @@ M: Christoph Hellwig <hch@lst.de>
|
|||||||
M: Marek Szyprowski <m.szyprowski@samsung.com>
|
M: Marek Szyprowski <m.szyprowski@samsung.com>
|
||||||
R: Robin Murphy <robin.murphy@arm.com>
|
R: Robin Murphy <robin.murphy@arm.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Supported
|
S: Supported
|
||||||
W: http://git.infradead.org/users/hch/dma-mapping.git
|
W: http://git.infradead.org/users/hch/dma-mapping.git
|
||||||
T: git git://git.infradead.org/users/hch/dma-mapping.git
|
T: git git://git.infradead.org/users/hch/dma-mapping.git
|
||||||
@ -5981,6 +5999,7 @@ F: kernel/dma/
|
|||||||
DMA MAPPING BENCHMARK
|
DMA MAPPING BENCHMARK
|
||||||
M: Xiang Chen <chenxiang66@hisilicon.com>
|
M: Xiang Chen <chenxiang66@hisilicon.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
F: kernel/dma/map_benchmark.c
|
F: kernel/dma/map_benchmark.c
|
||||||
F: tools/testing/selftests/dma/
|
F: tools/testing/selftests/dma/
|
||||||
|
|
||||||
@ -7565,6 +7584,7 @@ F: drivers/gpu/drm/exynos/exynos_dp*
|
|||||||
EXYNOS SYSMMU (IOMMU) driver
|
EXYNOS SYSMMU (IOMMU) driver
|
||||||
M: Marek Szyprowski <m.szyprowski@samsung.com>
|
M: Marek Szyprowski <m.szyprowski@samsung.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: drivers/iommu/exynos-iommu.c
|
F: drivers/iommu/exynos-iommu.c
|
||||||
|
|
||||||
@ -8486,6 +8506,7 @@ F: Documentation/devicetree/bindings/gpio/
|
|||||||
F: Documentation/driver-api/gpio/
|
F: Documentation/driver-api/gpio/
|
||||||
F: drivers/gpio/
|
F: drivers/gpio/
|
||||||
F: include/asm-generic/gpio.h
|
F: include/asm-generic/gpio.h
|
||||||
|
F: include/dt-bindings/gpio/
|
||||||
F: include/linux/gpio.h
|
F: include/linux/gpio.h
|
||||||
F: include/linux/gpio/
|
F: include/linux/gpio/
|
||||||
F: include/linux/of_gpio.h
|
F: include/linux/of_gpio.h
|
||||||
@ -9139,6 +9160,7 @@ F: drivers/media/platform/st/sti/hva
|
|||||||
|
|
||||||
HWPOISON MEMORY FAILURE HANDLING
|
HWPOISON MEMORY FAILURE HANDLING
|
||||||
M: Naoya Horiguchi <naoya.horiguchi@nec.com>
|
M: Naoya Horiguchi <naoya.horiguchi@nec.com>
|
||||||
|
R: Miaohe Lin <linmiaohe@huawei.com>
|
||||||
L: linux-mm@kvack.org
|
L: linux-mm@kvack.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: mm/hwpoison-inject.c
|
F: mm/hwpoison-inject.c
|
||||||
@ -9984,6 +10006,7 @@ INTEL IOMMU (VT-d)
|
|||||||
M: David Woodhouse <dwmw2@infradead.org>
|
M: David Woodhouse <dwmw2@infradead.org>
|
||||||
M: Lu Baolu <baolu.lu@linux.intel.com>
|
M: Lu Baolu <baolu.lu@linux.intel.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Supported
|
S: Supported
|
||||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
||||||
F: drivers/iommu/intel/
|
F: drivers/iommu/intel/
|
||||||
@ -10363,6 +10386,7 @@ IOMMU DRIVERS
|
|||||||
M: Joerg Roedel <joro@8bytes.org>
|
M: Joerg Roedel <joro@8bytes.org>
|
||||||
M: Will Deacon <will@kernel.org>
|
M: Will Deacon <will@kernel.org>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Maintained
|
S: Maintained
|
||||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git
|
||||||
F: Documentation/devicetree/bindings/iommu/
|
F: Documentation/devicetree/bindings/iommu/
|
||||||
@ -10839,6 +10863,7 @@ M: Marc Zyngier <maz@kernel.org>
|
|||||||
R: James Morse <james.morse@arm.com>
|
R: James Morse <james.morse@arm.com>
|
||||||
R: Alexandru Elisei <alexandru.elisei@arm.com>
|
R: Alexandru Elisei <alexandru.elisei@arm.com>
|
||||||
R: Suzuki K Poulose <suzuki.poulose@arm.com>
|
R: Suzuki K Poulose <suzuki.poulose@arm.com>
|
||||||
|
R: Oliver Upton <oliver.upton@linux.dev>
|
||||||
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers)
|
||||||
L: kvmarm@lists.cs.columbia.edu (moderated for non-subscribers)
|
L: kvmarm@lists.cs.columbia.edu (moderated for non-subscribers)
|
||||||
S: Maintained
|
S: Maintained
|
||||||
@ -10905,28 +10930,51 @@ F: tools/testing/selftests/kvm/*/s390x/
|
|||||||
F: tools/testing/selftests/kvm/s390x/
|
F: tools/testing/selftests/kvm/s390x/
|
||||||
|
|
||||||
KERNEL VIRTUAL MACHINE FOR X86 (KVM/x86)
|
KERNEL VIRTUAL MACHINE FOR X86 (KVM/x86)
|
||||||
|
M: Sean Christopherson <seanjc@google.com>
|
||||||
M: Paolo Bonzini <pbonzini@redhat.com>
|
M: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
R: Sean Christopherson <seanjc@google.com>
|
|
||||||
R: Vitaly Kuznetsov <vkuznets@redhat.com>
|
|
||||||
R: Wanpeng Li <wanpengli@tencent.com>
|
|
||||||
R: Jim Mattson <jmattson@google.com>
|
|
||||||
R: Joerg Roedel <joro@8bytes.org>
|
|
||||||
L: kvm@vger.kernel.org
|
L: kvm@vger.kernel.org
|
||||||
S: Supported
|
S: Supported
|
||||||
W: http://www.linux-kvm.org
|
|
||||||
T: git git://git.kernel.org/pub/scm/virt/kvm/kvm.git
|
T: git git://git.kernel.org/pub/scm/virt/kvm/kvm.git
|
||||||
F: arch/x86/include/asm/kvm*
|
F: arch/x86/include/asm/kvm*
|
||||||
F: arch/x86/include/asm/pvclock-abi.h
|
|
||||||
F: arch/x86/include/asm/svm.h
|
F: arch/x86/include/asm/svm.h
|
||||||
F: arch/x86/include/asm/vmx*.h
|
F: arch/x86/include/asm/vmx*.h
|
||||||
F: arch/x86/include/uapi/asm/kvm*
|
F: arch/x86/include/uapi/asm/kvm*
|
||||||
F: arch/x86/include/uapi/asm/svm.h
|
F: arch/x86/include/uapi/asm/svm.h
|
||||||
F: arch/x86/include/uapi/asm/vmx.h
|
F: arch/x86/include/uapi/asm/vmx.h
|
||||||
F: arch/x86/kernel/kvm.c
|
|
||||||
F: arch/x86/kernel/kvmclock.c
|
|
||||||
F: arch/x86/kvm/
|
F: arch/x86/kvm/
|
||||||
F: arch/x86/kvm/*/
|
F: arch/x86/kvm/*/
|
||||||
|
|
||||||
|
KVM PARAVIRT (KVM/paravirt)
|
||||||
|
M: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
R: Wanpeng Li <wanpengli@tencent.com>
|
||||||
|
R: Vitaly Kuznetsov <vkuznets@redhat.com>
|
||||||
|
L: kvm@vger.kernel.org
|
||||||
|
S: Supported
|
||||||
|
T: git git://git.kernel.org/pub/scm/virt/kvm/kvm.git
|
||||||
|
F: arch/x86/kernel/kvm.c
|
||||||
|
F: arch/x86/kernel/kvmclock.c
|
||||||
|
F: arch/x86/include/asm/pvclock-abi.h
|
||||||
|
F: include/linux/kvm_para.h
|
||||||
|
F: include/uapi/linux/kvm_para.h
|
||||||
|
F: include/uapi/asm-generic/kvm_para.h
|
||||||
|
F: include/asm-generic/kvm_para.h
|
||||||
|
F: arch/um/include/asm/kvm_para.h
|
||||||
|
F: arch/x86/include/asm/kvm_para.h
|
||||||
|
F: arch/x86/include/uapi/asm/kvm_para.h
|
||||||
|
|
||||||
|
KVM X86 HYPER-V (KVM/hyper-v)
|
||||||
|
M: Vitaly Kuznetsov <vkuznets@redhat.com>
|
||||||
|
M: Sean Christopherson <seanjc@google.com>
|
||||||
|
M: Paolo Bonzini <pbonzini@redhat.com>
|
||||||
|
L: kvm@vger.kernel.org
|
||||||
|
S: Supported
|
||||||
|
T: git git://git.kernel.org/pub/scm/virt/kvm/kvm.git
|
||||||
|
F: arch/x86/kvm/hyperv.*
|
||||||
|
F: arch/x86/kvm/kvm_onhyperv.*
|
||||||
|
F: arch/x86/kvm/svm/hyperv.*
|
||||||
|
F: arch/x86/kvm/svm/svm_onhyperv.*
|
||||||
|
F: arch/x86/kvm/vmx/evmcs.*
|
||||||
|
|
||||||
KERNFS
|
KERNFS
|
||||||
M: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|
M: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|
||||||
M: Tejun Heo <tj@kernel.org>
|
M: Tejun Heo <tj@kernel.org>
|
||||||
@ -11105,20 +11153,6 @@ S: Maintained
|
|||||||
F: include/net/l3mdev.h
|
F: include/net/l3mdev.h
|
||||||
F: net/l3mdev
|
F: net/l3mdev
|
||||||
|
|
||||||
L7 BPF FRAMEWORK
|
|
||||||
M: John Fastabend <john.fastabend@gmail.com>
|
|
||||||
M: Daniel Borkmann <daniel@iogearbox.net>
|
|
||||||
M: Jakub Sitnicki <jakub@cloudflare.com>
|
|
||||||
L: netdev@vger.kernel.org
|
|
||||||
L: bpf@vger.kernel.org
|
|
||||||
S: Maintained
|
|
||||||
F: include/linux/skmsg.h
|
|
||||||
F: net/core/skmsg.c
|
|
||||||
F: net/core/sock_map.c
|
|
||||||
F: net/ipv4/tcp_bpf.c
|
|
||||||
F: net/ipv4/udp_bpf.c
|
|
||||||
F: net/unix/unix_bpf.c
|
|
||||||
|
|
||||||
LANDLOCK SECURITY MODULE
|
LANDLOCK SECURITY MODULE
|
||||||
M: Mickaël Salaün <mic@digikod.net>
|
M: Mickaël Salaün <mic@digikod.net>
|
||||||
L: linux-security-module@vger.kernel.org
|
L: linux-security-module@vger.kernel.org
|
||||||
@ -11598,6 +11632,7 @@ F: drivers/gpu/drm/bridge/lontium-lt8912b.c
|
|||||||
LOONGARCH
|
LOONGARCH
|
||||||
M: Huacai Chen <chenhuacai@kernel.org>
|
M: Huacai Chen <chenhuacai@kernel.org>
|
||||||
R: WANG Xuerui <kernel@xen0n.name>
|
R: WANG Xuerui <kernel@xen0n.name>
|
||||||
|
L: loongarch@lists.linux.dev
|
||||||
S: Maintained
|
S: Maintained
|
||||||
T: git git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson.git
|
T: git git://git.kernel.org/pub/scm/linux/kernel/git/chenhuacai/linux-loongson.git
|
||||||
F: arch/loongarch/
|
F: arch/loongarch/
|
||||||
@ -12511,6 +12546,7 @@ F: drivers/i2c/busses/i2c-mt65xx.c
|
|||||||
MEDIATEK IOMMU DRIVER
|
MEDIATEK IOMMU DRIVER
|
||||||
M: Yong Wu <yong.wu@mediatek.com>
|
M: Yong Wu <yong.wu@mediatek.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
L: linux-mediatek@lists.infradead.org (moderated for non-subscribers)
|
L: linux-mediatek@lists.infradead.org (moderated for non-subscribers)
|
||||||
S: Supported
|
S: Supported
|
||||||
F: Documentation/devicetree/bindings/iommu/mediatek*
|
F: Documentation/devicetree/bindings/iommu/mediatek*
|
||||||
@ -12853,9 +12889,8 @@ M: Andrew Morton <akpm@linux-foundation.org>
|
|||||||
L: linux-mm@kvack.org
|
L: linux-mm@kvack.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
W: http://www.linux-mm.org
|
W: http://www.linux-mm.org
|
||||||
T: quilt https://ozlabs.org/~akpm/mmotm/
|
T: git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
|
||||||
T: quilt https://ozlabs.org/~akpm/mmots/
|
T: quilt git://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new
|
||||||
T: git git://github.com/hnaz/linux-mm.git
|
|
||||||
F: include/linux/gfp.h
|
F: include/linux/gfp.h
|
||||||
F: include/linux/memory_hotplug.h
|
F: include/linux/memory_hotplug.h
|
||||||
F: include/linux/mm.h
|
F: include/linux/mm.h
|
||||||
@ -12865,6 +12900,18 @@ F: include/linux/vmalloc.h
|
|||||||
F: mm/
|
F: mm/
|
||||||
F: tools/testing/selftests/vm/
|
F: tools/testing/selftests/vm/
|
||||||
|
|
||||||
|
MEMORY HOT(UN)PLUG
|
||||||
|
M: David Hildenbrand <david@redhat.com>
|
||||||
|
M: Oscar Salvador <osalvador@suse.de>
|
||||||
|
L: linux-mm@kvack.org
|
||||||
|
S: Maintained
|
||||||
|
F: Documentation/admin-guide/mm/memory-hotplug.rst
|
||||||
|
F: Documentation/core-api/memory-hotplug.rst
|
||||||
|
F: drivers/base/memory.c
|
||||||
|
F: include/linux/memory_hotplug.h
|
||||||
|
F: mm/memory_hotplug.c
|
||||||
|
F: tools/testing/selftests/memory-hotplug/
|
||||||
|
|
||||||
MEMORY TECHNOLOGY DEVICES (MTD)
|
MEMORY TECHNOLOGY DEVICES (MTD)
|
||||||
M: Miquel Raynal <miquel.raynal@bootlin.com>
|
M: Miquel Raynal <miquel.raynal@bootlin.com>
|
||||||
M: Richard Weinberger <richard@nod.at>
|
M: Richard Weinberger <richard@nod.at>
|
||||||
@ -13961,7 +14008,6 @@ F: net/ipv6/tcp*.c
|
|||||||
NETWORKING [TLS]
|
NETWORKING [TLS]
|
||||||
M: Boris Pismenny <borisp@nvidia.com>
|
M: Boris Pismenny <borisp@nvidia.com>
|
||||||
M: John Fastabend <john.fastabend@gmail.com>
|
M: John Fastabend <john.fastabend@gmail.com>
|
||||||
M: Daniel Borkmann <daniel@iogearbox.net>
|
|
||||||
M: Jakub Kicinski <kuba@kernel.org>
|
M: Jakub Kicinski <kuba@kernel.org>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
@ -14270,7 +14316,7 @@ F: drivers/iio/gyro/fxas21002c_i2c.c
|
|||||||
F: drivers/iio/gyro/fxas21002c_spi.c
|
F: drivers/iio/gyro/fxas21002c_spi.c
|
||||||
|
|
||||||
NXP i.MX CLOCK DRIVERS
|
NXP i.MX CLOCK DRIVERS
|
||||||
M: Abel Vesa <abel.vesa@nxp.com>
|
M: Abel Vesa <abelvesa@kernel.org>
|
||||||
L: linux-clk@vger.kernel.org
|
L: linux-clk@vger.kernel.org
|
||||||
L: linux-imx@nxp.com
|
L: linux-imx@nxp.com
|
||||||
S: Maintained
|
S: Maintained
|
||||||
@ -14878,6 +14924,7 @@ F: include/dt-bindings/
|
|||||||
|
|
||||||
OPENCOMPUTE PTP CLOCK DRIVER
|
OPENCOMPUTE PTP CLOCK DRIVER
|
||||||
M: Jonathan Lemon <jonathan.lemon@gmail.com>
|
M: Jonathan Lemon <jonathan.lemon@gmail.com>
|
||||||
|
M: Vadim Fedorenko <vadfed@fb.com>
|
||||||
L: netdev@vger.kernel.org
|
L: netdev@vger.kernel.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: drivers/ptp/ptp_ocp.c
|
F: drivers/ptp/ptp_ocp.c
|
||||||
@ -16497,7 +16544,7 @@ F: Documentation/devicetree/bindings/opp/opp-v2-kryo-cpu.yaml
|
|||||||
F: drivers/cpufreq/qcom-cpufreq-nvmem.c
|
F: drivers/cpufreq/qcom-cpufreq-nvmem.c
|
||||||
|
|
||||||
QUALCOMM CRYPTO DRIVERS
|
QUALCOMM CRYPTO DRIVERS
|
||||||
M: Thara Gopinath <thara.gopinath@linaro.org>
|
M: Thara Gopinath <thara.gopinath@gmail.com>
|
||||||
L: linux-crypto@vger.kernel.org
|
L: linux-crypto@vger.kernel.org
|
||||||
L: linux-arm-msm@vger.kernel.org
|
L: linux-arm-msm@vger.kernel.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
@ -16552,6 +16599,7 @@ F: drivers/i2c/busses/i2c-qcom-cci.c
|
|||||||
QUALCOMM IOMMU
|
QUALCOMM IOMMU
|
||||||
M: Rob Clark <robdclark@gmail.com>
|
M: Rob Clark <robdclark@gmail.com>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
L: linux-arm-msm@vger.kernel.org
|
L: linux-arm-msm@vger.kernel.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
F: drivers/iommu/arm/arm-smmu/qcom_iommu.c
|
F: drivers/iommu/arm/arm-smmu/qcom_iommu.c
|
||||||
@ -16607,7 +16655,7 @@ F: include/linux/if_rmnet.h
|
|||||||
|
|
||||||
QUALCOMM TSENS THERMAL DRIVER
|
QUALCOMM TSENS THERMAL DRIVER
|
||||||
M: Amit Kucheria <amitk@kernel.org>
|
M: Amit Kucheria <amitk@kernel.org>
|
||||||
M: Thara Gopinath <thara.gopinath@linaro.org>
|
M: Thara Gopinath <thara.gopinath@gmail.com>
|
||||||
L: linux-pm@vger.kernel.org
|
L: linux-pm@vger.kernel.org
|
||||||
L: linux-arm-msm@vger.kernel.org
|
L: linux-arm-msm@vger.kernel.org
|
||||||
S: Maintained
|
S: Maintained
|
||||||
@ -19178,6 +19226,7 @@ F: arch/x86/boot/video*
|
|||||||
SWIOTLB SUBSYSTEM
|
SWIOTLB SUBSYSTEM
|
||||||
M: Christoph Hellwig <hch@infradead.org>
|
M: Christoph Hellwig <hch@infradead.org>
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Supported
|
S: Supported
|
||||||
W: http://git.infradead.org/users/hch/dma-mapping.git
|
W: http://git.infradead.org/users/hch/dma-mapping.git
|
||||||
T: git git://git.infradead.org/users/hch/dma-mapping.git
|
T: git git://git.infradead.org/users/hch/dma-mapping.git
|
||||||
@ -20722,6 +20771,7 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb.git
|
|||||||
F: Documentation/devicetree/bindings/usb/
|
F: Documentation/devicetree/bindings/usb/
|
||||||
F: Documentation/usb/
|
F: Documentation/usb/
|
||||||
F: drivers/usb/
|
F: drivers/usb/
|
||||||
|
F: include/dt-bindings/usb/
|
||||||
F: include/linux/usb.h
|
F: include/linux/usb.h
|
||||||
F: include/linux/usb/
|
F: include/linux/usb/
|
||||||
|
|
||||||
@ -21852,6 +21902,7 @@ M: Juergen Gross <jgross@suse.com>
|
|||||||
M: Stefano Stabellini <sstabellini@kernel.org>
|
M: Stefano Stabellini <sstabellini@kernel.org>
|
||||||
L: xen-devel@lists.xenproject.org (moderated for non-subscribers)
|
L: xen-devel@lists.xenproject.org (moderated for non-subscribers)
|
||||||
L: iommu@lists.linux-foundation.org
|
L: iommu@lists.linux-foundation.org
|
||||||
|
L: iommu@lists.linux.dev
|
||||||
S: Supported
|
S: Supported
|
||||||
F: arch/x86/xen/*swiotlb*
|
F: arch/x86/xen/*swiotlb*
|
||||||
F: drivers/xen/*swiotlb*
|
F: drivers/xen/*swiotlb*
|
||||||
|
4
Makefile
4
Makefile
@ -2,7 +2,7 @@
|
|||||||
VERSION = 5
|
VERSION = 5
|
||||||
PATCHLEVEL = 19
|
PATCHLEVEL = 19
|
||||||
SUBLEVEL = 0
|
SUBLEVEL = 0
|
||||||
EXTRAVERSION = -rc3
|
EXTRAVERSION = -rc4
|
||||||
NAME = Superb Owl
|
NAME = Superb Owl
|
||||||
|
|
||||||
# *DOCUMENTATION*
|
# *DOCUMENTATION*
|
||||||
@ -1141,7 +1141,7 @@ KBUILD_MODULES := 1
|
|||||||
|
|
||||||
autoksyms_recursive: descend modules.order
|
autoksyms_recursive: descend modules.order
|
||||||
$(Q)$(CONFIG_SHELL) $(srctree)/scripts/adjust_autoksyms.sh \
|
$(Q)$(CONFIG_SHELL) $(srctree)/scripts/adjust_autoksyms.sh \
|
||||||
"$(MAKE) -f $(srctree)/Makefile vmlinux"
|
"$(MAKE) -f $(srctree)/Makefile autoksyms_recursive"
|
||||||
endif
|
endif
|
||||||
|
|
||||||
autoksyms_h := $(if $(CONFIG_TRIM_UNUSED_KSYMS), include/generated/autoksyms.h)
|
autoksyms_h := $(if $(CONFIG_TRIM_UNUSED_KSYMS), include/generated/autoksyms.h)
|
||||||
|
@ -1586,7 +1586,6 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
|
|||||||
aspeed-bmc-lenovo-hr630.dtb \
|
aspeed-bmc-lenovo-hr630.dtb \
|
||||||
aspeed-bmc-lenovo-hr855xg2.dtb \
|
aspeed-bmc-lenovo-hr855xg2.dtb \
|
||||||
aspeed-bmc-microsoft-olympus.dtb \
|
aspeed-bmc-microsoft-olympus.dtb \
|
||||||
aspeed-bmc-nuvia-dc-scm.dtb \
|
|
||||||
aspeed-bmc-opp-lanyang.dtb \
|
aspeed-bmc-opp-lanyang.dtb \
|
||||||
aspeed-bmc-opp-mihawk.dtb \
|
aspeed-bmc-opp-mihawk.dtb \
|
||||||
aspeed-bmc-opp-mowgli.dtb \
|
aspeed-bmc-opp-mowgli.dtb \
|
||||||
@ -1599,6 +1598,7 @@ dtb-$(CONFIG_ARCH_ASPEED) += \
|
|||||||
aspeed-bmc-opp-witherspoon.dtb \
|
aspeed-bmc-opp-witherspoon.dtb \
|
||||||
aspeed-bmc-opp-zaius.dtb \
|
aspeed-bmc-opp-zaius.dtb \
|
||||||
aspeed-bmc-portwell-neptune.dtb \
|
aspeed-bmc-portwell-neptune.dtb \
|
||||||
|
aspeed-bmc-qcom-dc-scm-v1.dtb \
|
||||||
aspeed-bmc-quanta-q71l.dtb \
|
aspeed-bmc-quanta-q71l.dtb \
|
||||||
aspeed-bmc-quanta-s6q.dtb \
|
aspeed-bmc-quanta-s6q.dtb \
|
||||||
aspeed-bmc-supermicro-x11spi.dtb \
|
aspeed-bmc-supermicro-x11spi.dtb \
|
||||||
|
@ -6,8 +6,8 @@
|
|||||||
#include "aspeed-g6.dtsi"
|
#include "aspeed-g6.dtsi"
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "Nuvia DC-SCM BMC";
|
model = "Qualcomm DC-SCM V1 BMC";
|
||||||
compatible = "nuvia,dc-scm-bmc", "aspeed,ast2600";
|
compatible = "qcom,dc-scm-v1-bmc", "aspeed,ast2600";
|
||||||
|
|
||||||
aliases {
|
aliases {
|
||||||
serial4 = &uart5;
|
serial4 = &uart5;
|
@ -28,12 +28,12 @@
|
|||||||
&expgpio {
|
&expgpio {
|
||||||
gpio-line-names = "BT_ON",
|
gpio-line-names = "BT_ON",
|
||||||
"WL_ON",
|
"WL_ON",
|
||||||
"",
|
"PWR_LED_OFF",
|
||||||
"GLOBAL_RESET",
|
"GLOBAL_RESET",
|
||||||
"VDD_SD_IO_SEL",
|
"VDD_SD_IO_SEL",
|
||||||
"CAM_GPIO",
|
"GLOBAL_SHUTDOWN",
|
||||||
"SD_PWR_ON",
|
"SD_PWR_ON",
|
||||||
"SD_OC_N";
|
"SHUTDOWN_REQUEST";
|
||||||
};
|
};
|
||||||
|
|
||||||
&genet_mdio {
|
&genet_mdio {
|
||||||
|
@ -593,7 +593,7 @@
|
|||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&pinctrl_atmel_conn>;
|
pinctrl-0 = <&pinctrl_atmel_conn>;
|
||||||
reg = <0x4a>;
|
reg = <0x4a>;
|
||||||
reset-gpios = <&gpio1 14 GPIO_ACTIVE_HIGH>; /* SODIMM 106 */
|
reset-gpios = <&gpio1 14 GPIO_ACTIVE_LOW>; /* SODIMM 106 */
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -762,7 +762,7 @@
|
|||||||
regulator-name = "vddpu";
|
regulator-name = "vddpu";
|
||||||
regulator-min-microvolt = <725000>;
|
regulator-min-microvolt = <725000>;
|
||||||
regulator-max-microvolt = <1450000>;
|
regulator-max-microvolt = <1450000>;
|
||||||
regulator-enable-ramp-delay = <150>;
|
regulator-enable-ramp-delay = <380>;
|
||||||
anatop-reg-offset = <0x140>;
|
anatop-reg-offset = <0x140>;
|
||||||
anatop-vol-bit-shift = <9>;
|
anatop-vol-bit-shift = <9>;
|
||||||
anatop-vol-bit-width = <5>;
|
anatop-vol-bit-width = <5>;
|
||||||
|
@ -120,6 +120,7 @@
|
|||||||
compatible = "usb-nop-xceiv";
|
compatible = "usb-nop-xceiv";
|
||||||
clocks = <&clks IMX7D_USB_HSIC_ROOT_CLK>;
|
clocks = <&clks IMX7D_USB_HSIC_ROOT_CLK>;
|
||||||
clock-names = "main_clk";
|
clock-names = "main_clk";
|
||||||
|
power-domains = <&pgc_hsic_phy>;
|
||||||
#phy-cells = <0>;
|
#phy-cells = <0>;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -1153,7 +1154,6 @@
|
|||||||
compatible = "fsl,imx7d-usb", "fsl,imx27-usb";
|
compatible = "fsl,imx7d-usb", "fsl,imx27-usb";
|
||||||
reg = <0x30b30000 0x200>;
|
reg = <0x30b30000 0x200>;
|
||||||
interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
power-domains = <&pgc_hsic_phy>;
|
|
||||||
clocks = <&clks IMX7D_USB_CTRL_CLK>;
|
clocks = <&clks IMX7D_USB_CTRL_CLK>;
|
||||||
fsl,usbphy = <&usbphynop3>;
|
fsl,usbphy = <&usbphynop3>;
|
||||||
fsl,usbmisc = <&usbmisc3 0>;
|
fsl,usbmisc = <&usbmisc3 0>;
|
||||||
|
47
arch/arm/boot/dts/stm32mp15-scmi.dtsi
Normal file
47
arch/arm/boot/dts/stm32mp15-scmi.dtsi
Normal file
@ -0,0 +1,47 @@
|
|||||||
|
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
|
||||||
|
/*
|
||||||
|
* Copyright (C) STMicroelectronics 2022 - All Rights Reserved
|
||||||
|
* Author: Alexandre Torgue <alexandre.torgue@foss.st.com> for STMicroelectronics.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/ {
|
||||||
|
firmware {
|
||||||
|
optee: optee {
|
||||||
|
compatible = "linaro,optee-tz";
|
||||||
|
method = "smc";
|
||||||
|
};
|
||||||
|
|
||||||
|
scmi: scmi {
|
||||||
|
compatible = "linaro,scmi-optee";
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <0>;
|
||||||
|
linaro,optee-channel-id = <0>;
|
||||||
|
shmem = <&scmi_shm>;
|
||||||
|
|
||||||
|
scmi_clk: protocol@14 {
|
||||||
|
reg = <0x14>;
|
||||||
|
#clock-cells = <1>;
|
||||||
|
};
|
||||||
|
|
||||||
|
scmi_reset: protocol@16 {
|
||||||
|
reg = <0x16>;
|
||||||
|
#reset-cells = <1>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
soc {
|
||||||
|
scmi_sram: sram@2ffff000 {
|
||||||
|
compatible = "mmio-sram";
|
||||||
|
reg = <0x2ffff000 0x1000>;
|
||||||
|
#address-cells = <1>;
|
||||||
|
#size-cells = <1>;
|
||||||
|
ranges = <0 0x2ffff000 0x1000>;
|
||||||
|
|
||||||
|
scmi_shm: scmi-sram@0 {
|
||||||
|
compatible = "arm,scmi-shmem";
|
||||||
|
reg = <0 0x80>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
@ -115,33 +115,6 @@
|
|||||||
status = "disabled";
|
status = "disabled";
|
||||||
};
|
};
|
||||||
|
|
||||||
firmware {
|
|
||||||
optee: optee {
|
|
||||||
compatible = "linaro,optee-tz";
|
|
||||||
method = "smc";
|
|
||||||
status = "disabled";
|
|
||||||
};
|
|
||||||
|
|
||||||
scmi: scmi {
|
|
||||||
compatible = "linaro,scmi-optee";
|
|
||||||
#address-cells = <1>;
|
|
||||||
#size-cells = <0>;
|
|
||||||
linaro,optee-channel-id = <0>;
|
|
||||||
shmem = <&scmi_shm>;
|
|
||||||
status = "disabled";
|
|
||||||
|
|
||||||
scmi_clk: protocol@14 {
|
|
||||||
reg = <0x14>;
|
|
||||||
#clock-cells = <1>;
|
|
||||||
};
|
|
||||||
|
|
||||||
scmi_reset: protocol@16 {
|
|
||||||
reg = <0x16>;
|
|
||||||
#reset-cells = <1>;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
soc {
|
soc {
|
||||||
compatible = "simple-bus";
|
compatible = "simple-bus";
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
@ -149,20 +122,6 @@
|
|||||||
interrupt-parent = <&intc>;
|
interrupt-parent = <&intc>;
|
||||||
ranges;
|
ranges;
|
||||||
|
|
||||||
scmi_sram: sram@2ffff000 {
|
|
||||||
compatible = "mmio-sram";
|
|
||||||
reg = <0x2ffff000 0x1000>;
|
|
||||||
#address-cells = <1>;
|
|
||||||
#size-cells = <1>;
|
|
||||||
ranges = <0 0x2ffff000 0x1000>;
|
|
||||||
|
|
||||||
scmi_shm: scmi-sram@0 {
|
|
||||||
compatible = "arm,scmi-shmem";
|
|
||||||
reg = <0 0x80>;
|
|
||||||
status = "disabled";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
timers2: timer@40000000 {
|
timers2: timer@40000000 {
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <0>;
|
#size-cells = <0>;
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
/dts-v1/;
|
/dts-v1/;
|
||||||
|
|
||||||
#include "stm32mp157a-dk1.dts"
|
#include "stm32mp157a-dk1.dts"
|
||||||
|
#include "stm32mp15-scmi.dtsi"
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "STMicroelectronics STM32MP157A-DK1 SCMI Discovery Board";
|
model = "STMicroelectronics STM32MP157A-DK1 SCMI Discovery Board";
|
||||||
@ -54,10 +55,6 @@
|
|||||||
resets = <&scmi_reset RST_SCMI_MCU>;
|
resets = <&scmi_reset RST_SCMI_MCU>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&optee {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&rcc {
|
&rcc {
|
||||||
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
||||||
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
||||||
@ -76,11 +73,3 @@
|
|||||||
&rtc {
|
&rtc {
|
||||||
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&scmi {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&scmi_shm {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
/dts-v1/;
|
/dts-v1/;
|
||||||
|
|
||||||
#include "stm32mp157c-dk2.dts"
|
#include "stm32mp157c-dk2.dts"
|
||||||
|
#include "stm32mp15-scmi.dtsi"
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "STMicroelectronics STM32MP157C-DK2 SCMI Discovery Board";
|
model = "STMicroelectronics STM32MP157C-DK2 SCMI Discovery Board";
|
||||||
@ -63,10 +64,6 @@
|
|||||||
resets = <&scmi_reset RST_SCMI_MCU>;
|
resets = <&scmi_reset RST_SCMI_MCU>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&optee {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&rcc {
|
&rcc {
|
||||||
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
||||||
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
||||||
@ -85,11 +82,3 @@
|
|||||||
&rtc {
|
&rtc {
|
||||||
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&scmi {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&scmi_shm {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
/dts-v1/;
|
/dts-v1/;
|
||||||
|
|
||||||
#include "stm32mp157c-ed1.dts"
|
#include "stm32mp157c-ed1.dts"
|
||||||
|
#include "stm32mp15-scmi.dtsi"
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "STMicroelectronics STM32MP157C-ED1 SCMI eval daughter";
|
model = "STMicroelectronics STM32MP157C-ED1 SCMI eval daughter";
|
||||||
@ -59,10 +60,6 @@
|
|||||||
resets = <&scmi_reset RST_SCMI_MCU>;
|
resets = <&scmi_reset RST_SCMI_MCU>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&optee {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&rcc {
|
&rcc {
|
||||||
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
||||||
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
||||||
@ -81,11 +78,3 @@
|
|||||||
&rtc {
|
&rtc {
|
||||||
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&scmi {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&scmi_shm {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
@ -7,6 +7,7 @@
|
|||||||
/dts-v1/;
|
/dts-v1/;
|
||||||
|
|
||||||
#include "stm32mp157c-ev1.dts"
|
#include "stm32mp157c-ev1.dts"
|
||||||
|
#include "stm32mp15-scmi.dtsi"
|
||||||
|
|
||||||
/ {
|
/ {
|
||||||
model = "STMicroelectronics STM32MP157C-EV1 SCMI eval daughter on eval mother";
|
model = "STMicroelectronics STM32MP157C-EV1 SCMI eval daughter on eval mother";
|
||||||
@ -68,10 +69,6 @@
|
|||||||
resets = <&scmi_reset RST_SCMI_MCU>;
|
resets = <&scmi_reset RST_SCMI_MCU>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&optee {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&rcc {
|
&rcc {
|
||||||
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
compatible = "st,stm32mp1-rcc-secure", "syscon";
|
||||||
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
clock-names = "hse", "hsi", "csi", "lse", "lsi";
|
||||||
@ -90,11 +87,3 @@
|
|||||||
&rtc {
|
&rtc {
|
||||||
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
clocks = <&scmi_clk CK_SCMI_RTCAPB>, <&scmi_clk CK_SCMI_RTC>;
|
||||||
};
|
};
|
||||||
|
|
||||||
&scmi {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
|
||||||
&scmi_shm {
|
|
||||||
status = "okay";
|
|
||||||
};
|
|
||||||
|
@ -39,6 +39,7 @@ static int axxia_boot_secondary(unsigned int cpu, struct task_struct *idle)
|
|||||||
return -ENOENT;
|
return -ENOENT;
|
||||||
|
|
||||||
syscon = of_iomap(syscon_np, 0);
|
syscon = of_iomap(syscon_np, 0);
|
||||||
|
of_node_put(syscon_np);
|
||||||
if (!syscon)
|
if (!syscon)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
|
@ -372,6 +372,7 @@ static void __init cns3xxx_init(void)
|
|||||||
/* De-Asscer SATA Reset */
|
/* De-Asscer SATA Reset */
|
||||||
cns3xxx_pwr_soft_rst(CNS3XXX_PWR_SOFTWARE_RST(SATA));
|
cns3xxx_pwr_soft_rst(CNS3XXX_PWR_SOFTWARE_RST(SATA));
|
||||||
}
|
}
|
||||||
|
of_node_put(dn);
|
||||||
|
|
||||||
dn = of_find_compatible_node(NULL, NULL, "cavium,cns3420-sdhci");
|
dn = of_find_compatible_node(NULL, NULL, "cavium,cns3420-sdhci");
|
||||||
if (of_device_is_available(dn)) {
|
if (of_device_is_available(dn)) {
|
||||||
@ -385,6 +386,7 @@ static void __init cns3xxx_init(void)
|
|||||||
cns3xxx_pwr_clk_en(CNS3XXX_PWR_CLK_EN(SDIO));
|
cns3xxx_pwr_clk_en(CNS3XXX_PWR_CLK_EN(SDIO));
|
||||||
cns3xxx_pwr_soft_rst(CNS3XXX_PWR_SOFTWARE_RST(SDIO));
|
cns3xxx_pwr_soft_rst(CNS3XXX_PWR_SOFTWARE_RST(SDIO));
|
||||||
}
|
}
|
||||||
|
of_node_put(dn);
|
||||||
|
|
||||||
pm_power_off = cns3xxx_power_off;
|
pm_power_off = cns3xxx_power_off;
|
||||||
|
|
||||||
|
@ -149,6 +149,7 @@ static void exynos_map_pmu(void)
|
|||||||
np = of_find_matching_node(NULL, exynos_dt_pmu_match);
|
np = of_find_matching_node(NULL, exynos_dt_pmu_match);
|
||||||
if (np)
|
if (np)
|
||||||
pmu_base_addr = of_iomap(np, 0);
|
pmu_base_addr = of_iomap(np, 0);
|
||||||
|
of_node_put(np);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void __init exynos_init_irq(void)
|
static void __init exynos_init_irq(void)
|
||||||
|
@ -218,13 +218,13 @@ void __init spear_setup_of_timer(void)
|
|||||||
irq = irq_of_parse_and_map(np, 0);
|
irq = irq_of_parse_and_map(np, 0);
|
||||||
if (!irq) {
|
if (!irq) {
|
||||||
pr_err("%s: No irq passed for timer via DT\n", __func__);
|
pr_err("%s: No irq passed for timer via DT\n", __func__);
|
||||||
return;
|
goto err_put_np;
|
||||||
}
|
}
|
||||||
|
|
||||||
gpt_base = of_iomap(np, 0);
|
gpt_base = of_iomap(np, 0);
|
||||||
if (!gpt_base) {
|
if (!gpt_base) {
|
||||||
pr_err("%s: of iomap failed\n", __func__);
|
pr_err("%s: of iomap failed\n", __func__);
|
||||||
return;
|
goto err_put_np;
|
||||||
}
|
}
|
||||||
|
|
||||||
gpt_clk = clk_get_sys("gpt0", NULL);
|
gpt_clk = clk_get_sys("gpt0", NULL);
|
||||||
@ -239,6 +239,8 @@ void __init spear_setup_of_timer(void)
|
|||||||
goto err_prepare_enable_clk;
|
goto err_prepare_enable_clk;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
of_node_put(np);
|
||||||
|
|
||||||
spear_clockevent_init(irq);
|
spear_clockevent_init(irq);
|
||||||
spear_clocksource_init();
|
spear_clocksource_init();
|
||||||
|
|
||||||
@ -248,4 +250,6 @@ err_prepare_enable_clk:
|
|||||||
clk_put(gpt_clk);
|
clk_put(gpt_clk);
|
||||||
err_iomap:
|
err_iomap:
|
||||||
iounmap(gpt_base);
|
iounmap(gpt_base);
|
||||||
|
err_put_np:
|
||||||
|
of_node_put(np);
|
||||||
}
|
}
|
||||||
|
@ -280,8 +280,8 @@
|
|||||||
interrupts = <GIC_SPI 246 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 246 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&uart0_bus>;
|
pinctrl-0 = <&uart0_bus>;
|
||||||
clocks = <&cmu_peri CLK_GOUT_UART0_EXT_UCLK>,
|
clocks = <&cmu_peri CLK_GOUT_UART0_PCLK>,
|
||||||
<&cmu_peri CLK_GOUT_UART0_PCLK>;
|
<&cmu_peri CLK_GOUT_UART0_EXT_UCLK>;
|
||||||
clock-names = "uart", "clk_uart_baud0";
|
clock-names = "uart", "clk_uart_baud0";
|
||||||
samsung,uart-fifosize = <64>;
|
samsung,uart-fifosize = <64>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
@ -293,8 +293,8 @@
|
|||||||
interrupts = <GIC_SPI 247 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 247 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&uart1_bus>;
|
pinctrl-0 = <&uart1_bus>;
|
||||||
clocks = <&cmu_peri CLK_GOUT_UART1_EXT_UCLK>,
|
clocks = <&cmu_peri CLK_GOUT_UART1_PCLK>,
|
||||||
<&cmu_peri CLK_GOUT_UART1_PCLK>;
|
<&cmu_peri CLK_GOUT_UART1_EXT_UCLK>;
|
||||||
clock-names = "uart", "clk_uart_baud0";
|
clock-names = "uart", "clk_uart_baud0";
|
||||||
samsung,uart-fifosize = <256>;
|
samsung,uart-fifosize = <256>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
@ -306,8 +306,8 @@
|
|||||||
interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>;
|
interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>;
|
||||||
pinctrl-names = "default";
|
pinctrl-names = "default";
|
||||||
pinctrl-0 = <&uart2_bus>;
|
pinctrl-0 = <&uart2_bus>;
|
||||||
clocks = <&cmu_peri CLK_GOUT_UART2_EXT_UCLK>,
|
clocks = <&cmu_peri CLK_GOUT_UART2_PCLK>,
|
||||||
<&cmu_peri CLK_GOUT_UART2_PCLK>;
|
<&cmu_peri CLK_GOUT_UART2_EXT_UCLK>;
|
||||||
clock-names = "uart", "clk_uart_baud0";
|
clock-names = "uart", "clk_uart_baud0";
|
||||||
samsung,uart-fifosize = <256>;
|
samsung,uart-fifosize = <256>;
|
||||||
status = "disabled";
|
status = "disabled";
|
||||||
|
@ -79,7 +79,7 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
soc {
|
soc@0 {
|
||||||
compatible = "simple-bus";
|
compatible = "simple-bus";
|
||||||
#address-cells = <1>;
|
#address-cells = <1>;
|
||||||
#size-cells = <1>;
|
#size-cells = <1>;
|
||||||
|
@ -456,13 +456,11 @@
|
|||||||
clock-names = "clk_ahb", "clk_xin";
|
clock-names = "clk_ahb", "clk_xin";
|
||||||
mmc-ddr-1_8v;
|
mmc-ddr-1_8v;
|
||||||
mmc-hs200-1_8v;
|
mmc-hs200-1_8v;
|
||||||
mmc-hs400-1_8v;
|
|
||||||
ti,trm-icp = <0x2>;
|
ti,trm-icp = <0x2>;
|
||||||
ti,otap-del-sel-legacy = <0x0>;
|
ti,otap-del-sel-legacy = <0x0>;
|
||||||
ti,otap-del-sel-mmc-hs = <0x0>;
|
ti,otap-del-sel-mmc-hs = <0x0>;
|
||||||
ti,otap-del-sel-ddr52 = <0x6>;
|
ti,otap-del-sel-ddr52 = <0x6>;
|
||||||
ti,otap-del-sel-hs200 = <0x7>;
|
ti,otap-del-sel-hs200 = <0x7>;
|
||||||
ti,otap-del-sel-hs400 = <0x4>;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
sdhci1: mmc@fa00000 {
|
sdhci1: mmc@fa00000 {
|
||||||
|
@ -33,7 +33,7 @@
|
|||||||
ranges;
|
ranges;
|
||||||
#interrupt-cells = <3>;
|
#interrupt-cells = <3>;
|
||||||
interrupt-controller;
|
interrupt-controller;
|
||||||
reg = <0x00 0x01800000 0x00 0x200000>, /* GICD */
|
reg = <0x00 0x01800000 0x00 0x100000>, /* GICD */
|
||||||
<0x00 0x01900000 0x00 0x100000>, /* GICR */
|
<0x00 0x01900000 0x00 0x100000>, /* GICR */
|
||||||
<0x00 0x6f000000 0x00 0x2000>, /* GICC */
|
<0x00 0x6f000000 0x00 0x2000>, /* GICC */
|
||||||
<0x00 0x6f010000 0x00 0x1000>, /* GICH */
|
<0x00 0x6f010000 0x00 0x1000>, /* GICH */
|
||||||
|
@ -2112,11 +2112,11 @@ static int finalize_hyp_mode(void)
|
|||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Exclude HYP BSS from kmemleak so that it doesn't get peeked
|
* Exclude HYP sections from kmemleak so that they don't get peeked
|
||||||
* at, which would end badly once the section is inaccessible.
|
* at, which would end badly once inaccessible.
|
||||||
* None of other sections should ever be introspected.
|
|
||||||
*/
|
*/
|
||||||
kmemleak_free_part(__hyp_bss_start, __hyp_bss_end - __hyp_bss_start);
|
kmemleak_free_part(__hyp_bss_start, __hyp_bss_end - __hyp_bss_start);
|
||||||
|
kmemleak_free_part(__va(hyp_mem_base), hyp_mem_size);
|
||||||
return pkvm_drop_host_privileges();
|
return pkvm_drop_host_privileges();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -12,10 +12,9 @@ static inline unsigned long exception_era(struct pt_regs *regs)
|
|||||||
return regs->csr_era;
|
return regs->csr_era;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline int compute_return_era(struct pt_regs *regs)
|
static inline void compute_return_era(struct pt_regs *regs)
|
||||||
{
|
{
|
||||||
regs->csr_era += 4;
|
regs->csr_era += 4;
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* _ASM_BRANCH_H */
|
#endif /* _ASM_BRANCH_H */
|
||||||
|
@ -426,6 +426,11 @@ static inline void update_mmu_cache_pmd(struct vm_area_struct *vma,
|
|||||||
|
|
||||||
#define kern_addr_valid(addr) (1)
|
#define kern_addr_valid(addr) (1)
|
||||||
|
|
||||||
|
static inline unsigned long pmd_pfn(pmd_t pmd)
|
||||||
|
{
|
||||||
|
return (pmd_val(pmd) & _PFN_MASK) >> _PFN_SHIFT;
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef CONFIG_TRANSPARENT_HUGEPAGE
|
#ifdef CONFIG_TRANSPARENT_HUGEPAGE
|
||||||
|
|
||||||
/* We don't have hardware dirty/accessed bits, generic_pmdp_establish is fine.*/
|
/* We don't have hardware dirty/accessed bits, generic_pmdp_establish is fine.*/
|
||||||
@ -497,11 +502,6 @@ static inline pmd_t pmd_mkyoung(pmd_t pmd)
|
|||||||
return pmd;
|
return pmd;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline unsigned long pmd_pfn(pmd_t pmd)
|
|
||||||
{
|
|
||||||
return (pmd_val(pmd) & _PFN_MASK) >> _PFN_SHIFT;
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline struct page *pmd_page(pmd_t pmd)
|
static inline struct page *pmd_page(pmd_t pmd)
|
||||||
{
|
{
|
||||||
if (pmd_trans_huge(pmd))
|
if (pmd_trans_huge(pmd))
|
||||||
|
@ -263,7 +263,7 @@ void cpu_probe(void)
|
|||||||
|
|
||||||
c->cputype = CPU_UNKNOWN;
|
c->cputype = CPU_UNKNOWN;
|
||||||
c->processor_id = read_cpucfg(LOONGARCH_CPUCFG0);
|
c->processor_id = read_cpucfg(LOONGARCH_CPUCFG0);
|
||||||
c->fpu_vers = (read_cpucfg(LOONGARCH_CPUCFG2) >> 3) & 0x3;
|
c->fpu_vers = (read_cpucfg(LOONGARCH_CPUCFG2) & CPUCFG2_FPVERS) >> 3;
|
||||||
|
|
||||||
c->fpu_csr0 = FPU_CSR_RN;
|
c->fpu_csr0 = FPU_CSR_RN;
|
||||||
c->fpu_mask = FPU_CSR_RSVD;
|
c->fpu_mask = FPU_CSR_RSVD;
|
||||||
|
@ -14,8 +14,6 @@
|
|||||||
|
|
||||||
__REF
|
__REF
|
||||||
|
|
||||||
SYM_ENTRY(_stext, SYM_L_GLOBAL, SYM_A_NONE)
|
|
||||||
|
|
||||||
SYM_CODE_START(kernel_entry) # kernel entry point
|
SYM_CODE_START(kernel_entry) # kernel entry point
|
||||||
|
|
||||||
/* Config direct window and set PG */
|
/* Config direct window and set PG */
|
||||||
|
@ -475,8 +475,7 @@ asmlinkage void noinstr do_ri(struct pt_regs *regs)
|
|||||||
|
|
||||||
die_if_kernel("Reserved instruction in kernel code", regs);
|
die_if_kernel("Reserved instruction in kernel code", regs);
|
||||||
|
|
||||||
if (unlikely(compute_return_era(regs) < 0))
|
compute_return_era(regs);
|
||||||
goto out;
|
|
||||||
|
|
||||||
if (unlikely(get_user(opcode, era) < 0)) {
|
if (unlikely(get_user(opcode, era) < 0)) {
|
||||||
status = SIGSEGV;
|
status = SIGSEGV;
|
||||||
|
@ -37,6 +37,7 @@ SECTIONS
|
|||||||
HEAD_TEXT_SECTION
|
HEAD_TEXT_SECTION
|
||||||
|
|
||||||
. = ALIGN(PECOFF_SEGMENT_ALIGN);
|
. = ALIGN(PECOFF_SEGMENT_ALIGN);
|
||||||
|
_stext = .;
|
||||||
.text : {
|
.text : {
|
||||||
TEXT_TEXT
|
TEXT_TEXT
|
||||||
SCHED_TEXT
|
SCHED_TEXT
|
||||||
|
@ -281,15 +281,16 @@ void setup_tlb_handler(int cpu)
|
|||||||
if (pcpu_handlers[cpu])
|
if (pcpu_handlers[cpu])
|
||||||
return;
|
return;
|
||||||
|
|
||||||
page = alloc_pages_node(cpu_to_node(cpu), GFP_KERNEL, get_order(vec_sz));
|
page = alloc_pages_node(cpu_to_node(cpu), GFP_ATOMIC, get_order(vec_sz));
|
||||||
if (!page)
|
if (!page)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
addr = page_address(page);
|
addr = page_address(page);
|
||||||
pcpu_handlers[cpu] = virt_to_phys(addr);
|
pcpu_handlers[cpu] = (unsigned long)addr;
|
||||||
memcpy((void *)addr, (void *)eentry, vec_sz);
|
memcpy((void *)addr, (void *)eentry, vec_sz);
|
||||||
local_flush_icache_range((unsigned long)addr, (unsigned long)addr + vec_sz);
|
local_flush_icache_range((unsigned long)addr, (unsigned long)addr + vec_sz);
|
||||||
csr_write64(pcpu_handlers[cpu], LOONGARCH_CSR_TLBRENTRY);
|
csr_write64(pcpu_handlers[cpu], LOONGARCH_CSR_EENTRY);
|
||||||
|
csr_write64(pcpu_handlers[cpu], LOONGARCH_CSR_MERRENTRY);
|
||||||
csr_write64(pcpu_handlers[cpu] + 80*VECSIZE, LOONGARCH_CSR_TLBRENTRY);
|
csr_write64(pcpu_handlers[cpu] + 80*VECSIZE, LOONGARCH_CSR_TLBRENTRY);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -111,8 +111,9 @@
|
|||||||
|
|
||||||
clocks = <&cgu X1000_CLK_RTCLK>,
|
clocks = <&cgu X1000_CLK_RTCLK>,
|
||||||
<&cgu X1000_CLK_EXCLK>,
|
<&cgu X1000_CLK_EXCLK>,
|
||||||
<&cgu X1000_CLK_PCLK>;
|
<&cgu X1000_CLK_PCLK>,
|
||||||
clock-names = "rtc", "ext", "pclk";
|
<&cgu X1000_CLK_TCU>;
|
||||||
|
clock-names = "rtc", "ext", "pclk", "tcu";
|
||||||
|
|
||||||
interrupt-controller;
|
interrupt-controller;
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
|
@ -104,8 +104,9 @@
|
|||||||
|
|
||||||
clocks = <&cgu X1830_CLK_RTCLK>,
|
clocks = <&cgu X1830_CLK_RTCLK>,
|
||||||
<&cgu X1830_CLK_EXCLK>,
|
<&cgu X1830_CLK_EXCLK>,
|
||||||
<&cgu X1830_CLK_PCLK>;
|
<&cgu X1830_CLK_PCLK>,
|
||||||
clock-names = "rtc", "ext", "pclk";
|
<&cgu X1830_CLK_TCU>;
|
||||||
|
clock-names = "rtc", "ext", "pclk", "tcu";
|
||||||
|
|
||||||
interrupt-controller;
|
interrupt-controller;
|
||||||
#interrupt-cells = <1>;
|
#interrupt-cells = <1>;
|
||||||
|
@ -44,6 +44,7 @@ static __init unsigned int ranchu_measure_hpt_freq(void)
|
|||||||
__func__);
|
__func__);
|
||||||
|
|
||||||
rtc_base = of_iomap(np, 0);
|
rtc_base = of_iomap(np, 0);
|
||||||
|
of_node_put(np);
|
||||||
if (!rtc_base)
|
if (!rtc_base)
|
||||||
panic("%s(): Failed to ioremap Goldfish RTC base!", __func__);
|
panic("%s(): Failed to ioremap Goldfish RTC base!", __func__);
|
||||||
|
|
||||||
|
@ -208,6 +208,12 @@ void __init ltq_soc_init(void)
|
|||||||
of_address_to_resource(np_sysgpe, 0, &res_sys[2]))
|
of_address_to_resource(np_sysgpe, 0, &res_sys[2]))
|
||||||
panic("Failed to get core resources");
|
panic("Failed to get core resources");
|
||||||
|
|
||||||
|
of_node_put(np_status);
|
||||||
|
of_node_put(np_ebu);
|
||||||
|
of_node_put(np_sys1);
|
||||||
|
of_node_put(np_syseth);
|
||||||
|
of_node_put(np_sysgpe);
|
||||||
|
|
||||||
if ((request_mem_region(res_status.start, resource_size(&res_status),
|
if ((request_mem_region(res_status.start, resource_size(&res_status),
|
||||||
res_status.name) < 0) ||
|
res_status.name) < 0) ||
|
||||||
(request_mem_region(res_ebu.start, resource_size(&res_ebu),
|
(request_mem_region(res_ebu.start, resource_size(&res_ebu),
|
||||||
|
@ -408,6 +408,7 @@ int __init icu_of_init(struct device_node *node, struct device_node *parent)
|
|||||||
if (!ltq_eiu_membase)
|
if (!ltq_eiu_membase)
|
||||||
panic("Failed to remap eiu memory");
|
panic("Failed to remap eiu memory");
|
||||||
}
|
}
|
||||||
|
of_node_put(eiu_node);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -441,6 +441,10 @@ void __init ltq_soc_init(void)
|
|||||||
of_address_to_resource(np_ebu, 0, &res_ebu))
|
of_address_to_resource(np_ebu, 0, &res_ebu))
|
||||||
panic("Failed to get core resources");
|
panic("Failed to get core resources");
|
||||||
|
|
||||||
|
of_node_put(np_pmu);
|
||||||
|
of_node_put(np_cgu);
|
||||||
|
of_node_put(np_ebu);
|
||||||
|
|
||||||
if (!request_mem_region(res_pmu.start, resource_size(&res_pmu),
|
if (!request_mem_region(res_pmu.start, resource_size(&res_pmu),
|
||||||
res_pmu.name) ||
|
res_pmu.name) ||
|
||||||
!request_mem_region(res_cgu.start, resource_size(&res_cgu),
|
!request_mem_region(res_cgu.start, resource_size(&res_cgu),
|
||||||
|
@ -214,6 +214,8 @@ static void update_gic_frequency_dt(void)
|
|||||||
|
|
||||||
if (of_update_property(node, &gic_frequency_prop) < 0)
|
if (of_update_property(node, &gic_frequency_prop) < 0)
|
||||||
pr_err("error updating gic frequency property\n");
|
pr_err("error updating gic frequency property\n");
|
||||||
|
|
||||||
|
of_node_put(node);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -98,13 +98,18 @@ static int __init pic32_of_prepare_platform_data(struct of_dev_auxdata *lookup)
|
|||||||
np = of_find_compatible_node(NULL, NULL, lookup->compatible);
|
np = of_find_compatible_node(NULL, NULL, lookup->compatible);
|
||||||
if (np) {
|
if (np) {
|
||||||
lookup->name = (char *)np->name;
|
lookup->name = (char *)np->name;
|
||||||
if (lookup->phys_addr)
|
if (lookup->phys_addr) {
|
||||||
|
of_node_put(np);
|
||||||
continue;
|
continue;
|
||||||
|
}
|
||||||
if (!of_address_to_resource(np, 0, &res))
|
if (!of_address_to_resource(np, 0, &res))
|
||||||
lookup->phys_addr = res.start;
|
lookup->phys_addr = res.start;
|
||||||
|
of_node_put(np);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
of_node_put(root);
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -32,6 +32,9 @@ static unsigned int pic32_xlate_core_timer_irq(void)
|
|||||||
goto default_map;
|
goto default_map;
|
||||||
|
|
||||||
irq = irq_of_parse_and_map(node, 0);
|
irq = irq_of_parse_and_map(node, 0);
|
||||||
|
|
||||||
|
of_node_put(node);
|
||||||
|
|
||||||
if (!irq)
|
if (!irq)
|
||||||
goto default_map;
|
goto default_map;
|
||||||
|
|
||||||
|
@ -40,6 +40,8 @@ __iomem void *plat_of_remap_node(const char *node)
|
|||||||
if (of_address_to_resource(np, 0, &res))
|
if (of_address_to_resource(np, 0, &res))
|
||||||
panic("Failed to get resource for %s", node);
|
panic("Failed to get resource for %s", node);
|
||||||
|
|
||||||
|
of_node_put(np);
|
||||||
|
|
||||||
if (!request_mem_region(res.start,
|
if (!request_mem_region(res.start,
|
||||||
resource_size(&res),
|
resource_size(&res),
|
||||||
res.name))
|
res.name))
|
||||||
|
@ -640,8 +640,6 @@ static int icu_get_irq(unsigned int irq)
|
|||||||
|
|
||||||
printk(KERN_ERR "spurious ICU interrupt: %04x,%04x\n", pend1, pend2);
|
printk(KERN_ERR "spurious ICU interrupt: %04x,%04x\n", pend1, pend2);
|
||||||
|
|
||||||
atomic_inc(&irq_err_count);
|
|
||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -10,6 +10,7 @@ config PARISC
|
|||||||
select ARCH_WANT_FRAME_POINTERS
|
select ARCH_WANT_FRAME_POINTERS
|
||||||
select ARCH_HAS_ELF_RANDOMIZE
|
select ARCH_HAS_ELF_RANDOMIZE
|
||||||
select ARCH_HAS_STRICT_KERNEL_RWX
|
select ARCH_HAS_STRICT_KERNEL_RWX
|
||||||
|
select ARCH_HAS_STRICT_MODULE_RWX
|
||||||
select ARCH_HAS_UBSAN_SANITIZE_ALL
|
select ARCH_HAS_UBSAN_SANITIZE_ALL
|
||||||
select ARCH_HAS_PTE_SPECIAL
|
select ARCH_HAS_PTE_SPECIAL
|
||||||
select ARCH_NO_SG_CHAIN
|
select ARCH_NO_SG_CHAIN
|
||||||
|
@ -12,7 +12,7 @@ static inline void fb_pgprotect(struct file *file, struct vm_area_struct *vma,
|
|||||||
pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE;
|
pgprot_val(vma->vm_page_prot) |= _PAGE_NO_CACHE;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(CONFIG_STI_CONSOLE) || defined(CONFIG_FB_STI)
|
#if defined(CONFIG_FB_STI)
|
||||||
int fb_is_primary_device(struct fb_info *info);
|
int fb_is_primary_device(struct fb_info *info);
|
||||||
#else
|
#else
|
||||||
static inline int fb_is_primary_device(struct fb_info *info)
|
static inline int fb_is_primary_device(struct fb_info *info)
|
||||||
|
@ -722,7 +722,10 @@ void flush_anon_page(struct vm_area_struct *vma, struct page *page, unsigned lon
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
if (parisc_requires_coherency()) {
|
if (parisc_requires_coherency()) {
|
||||||
flush_user_cache_page(vma, vmaddr);
|
if (vma->vm_flags & VM_SHARED)
|
||||||
|
flush_data_cache();
|
||||||
|
else
|
||||||
|
flush_user_cache_page(vma, vmaddr);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -102,7 +102,7 @@ decode_fpu(unsigned int Fpu_register[], unsigned int trap_counts[])
|
|||||||
* that happen. Want to keep this overhead low, but still provide
|
* that happen. Want to keep this overhead low, but still provide
|
||||||
* some information to the customer. All exits from this routine
|
* some information to the customer. All exits from this routine
|
||||||
* need to restore Fpu_register[0]
|
* need to restore Fpu_register[0]
|
||||||
*/
|
*/
|
||||||
|
|
||||||
bflags=(Fpu_register[0] & 0xf8000000);
|
bflags=(Fpu_register[0] & 0xf8000000);
|
||||||
Fpu_register[0] &= 0x07ffffff;
|
Fpu_register[0] &= 0x07ffffff;
|
||||||
|
@ -1855,7 +1855,7 @@ void start_thread(struct pt_regs *regs, unsigned long start, unsigned long sp)
|
|||||||
tm_reclaim_current(0);
|
tm_reclaim_current(0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
memset(regs->gpr, 0, sizeof(regs->gpr));
|
memset(®s->gpr[1], 0, sizeof(regs->gpr) - sizeof(regs->gpr[0]));
|
||||||
regs->ctr = 0;
|
regs->ctr = 0;
|
||||||
regs->link = 0;
|
regs->link = 0;
|
||||||
regs->xer = 0;
|
regs->xer = 0;
|
||||||
|
@ -2302,7 +2302,7 @@ static void __init prom_init_stdout(void)
|
|||||||
|
|
||||||
static int __init prom_find_machine_type(void)
|
static int __init prom_find_machine_type(void)
|
||||||
{
|
{
|
||||||
char compat[256];
|
static char compat[256] __prombss;
|
||||||
int len, i = 0;
|
int len, i = 0;
|
||||||
#ifdef CONFIG_PPC64
|
#ifdef CONFIG_PPC64
|
||||||
phandle rtas;
|
phandle rtas;
|
||||||
|
@ -1071,7 +1071,7 @@ static struct rtas_filter rtas_filters[] __ro_after_init = {
|
|||||||
{ "get-time-of-day", -1, -1, -1, -1, -1 },
|
{ "get-time-of-day", -1, -1, -1, -1, -1 },
|
||||||
{ "ibm,get-vpd", -1, 0, -1, 1, 2 },
|
{ "ibm,get-vpd", -1, 0, -1, 1, 2 },
|
||||||
{ "ibm,lpar-perftools", -1, 2, 3, -1, -1 },
|
{ "ibm,lpar-perftools", -1, 2, 3, -1, -1 },
|
||||||
{ "ibm,platform-dump", -1, 4, 5, -1, -1 },
|
{ "ibm,platform-dump", -1, 4, 5, -1, -1 }, /* Special cased */
|
||||||
{ "ibm,read-slot-reset-state", -1, -1, -1, -1, -1 },
|
{ "ibm,read-slot-reset-state", -1, -1, -1, -1, -1 },
|
||||||
{ "ibm,scan-log-dump", -1, 0, 1, -1, -1 },
|
{ "ibm,scan-log-dump", -1, 0, 1, -1, -1 },
|
||||||
{ "ibm,set-dynamic-indicator", -1, 2, -1, -1, -1 },
|
{ "ibm,set-dynamic-indicator", -1, 2, -1, -1, -1 },
|
||||||
@ -1120,6 +1120,15 @@ static bool block_rtas_call(int token, int nargs,
|
|||||||
size = 1;
|
size = 1;
|
||||||
|
|
||||||
end = base + size - 1;
|
end = base + size - 1;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Special case for ibm,platform-dump - NULL buffer
|
||||||
|
* address is used to indicate end of dump processing
|
||||||
|
*/
|
||||||
|
if (!strcmp(f->name, "ibm,platform-dump") &&
|
||||||
|
base == 0)
|
||||||
|
return false;
|
||||||
|
|
||||||
if (!in_rmo_buf(base, end))
|
if (!in_rmo_buf(base, end))
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
@ -935,12 +935,6 @@ void __init setup_arch(char **cmdline_p)
|
|||||||
/* Print various info about the machine that has been gathered so far. */
|
/* Print various info about the machine that has been gathered so far. */
|
||||||
print_system_info();
|
print_system_info();
|
||||||
|
|
||||||
/* Reserve large chunks of memory for use by CMA for KVM. */
|
|
||||||
kvm_cma_reserve();
|
|
||||||
|
|
||||||
/* Reserve large chunks of memory for us by CMA for hugetlb */
|
|
||||||
gigantic_hugetlb_cma_reserve();
|
|
||||||
|
|
||||||
klp_init_thread_info(&init_task);
|
klp_init_thread_info(&init_task);
|
||||||
|
|
||||||
setup_initial_init_mm(_stext, _etext, _edata, _end);
|
setup_initial_init_mm(_stext, _etext, _edata, _end);
|
||||||
@ -955,6 +949,13 @@ void __init setup_arch(char **cmdline_p)
|
|||||||
|
|
||||||
initmem_init();
|
initmem_init();
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Reserve large chunks of memory for use by CMA for KVM and hugetlb. These must
|
||||||
|
* be called after initmem_init(), so that pageblock_order is initialised.
|
||||||
|
*/
|
||||||
|
kvm_cma_reserve();
|
||||||
|
gigantic_hugetlb_cma_reserve();
|
||||||
|
|
||||||
early_memtest(min_low_pfn << PAGE_SHIFT, max_low_pfn << PAGE_SHIFT);
|
early_memtest(min_low_pfn << PAGE_SHIFT, max_low_pfn << PAGE_SHIFT);
|
||||||
|
|
||||||
if (ppc_md.setup_arch)
|
if (ppc_md.setup_arch)
|
||||||
|
7
arch/powerpc/platforms/microwatt/microwatt.h
Normal file
7
arch/powerpc/platforms/microwatt/microwatt.h
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
/* SPDX-License-Identifier: GPL-2.0 */
|
||||||
|
#ifndef _MICROWATT_H
|
||||||
|
#define _MICROWATT_H
|
||||||
|
|
||||||
|
void microwatt_rng_init(void);
|
||||||
|
|
||||||
|
#endif /* _MICROWATT_H */
|
@ -11,6 +11,7 @@
|
|||||||
#include <asm/archrandom.h>
|
#include <asm/archrandom.h>
|
||||||
#include <asm/cputable.h>
|
#include <asm/cputable.h>
|
||||||
#include <asm/machdep.h>
|
#include <asm/machdep.h>
|
||||||
|
#include "microwatt.h"
|
||||||
|
|
||||||
#define DARN_ERR 0xFFFFFFFFFFFFFFFFul
|
#define DARN_ERR 0xFFFFFFFFFFFFFFFFul
|
||||||
|
|
||||||
@ -29,7 +30,7 @@ static int microwatt_get_random_darn(unsigned long *v)
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
static __init int rng_init(void)
|
void __init microwatt_rng_init(void)
|
||||||
{
|
{
|
||||||
unsigned long val;
|
unsigned long val;
|
||||||
int i;
|
int i;
|
||||||
@ -37,12 +38,7 @@ static __init int rng_init(void)
|
|||||||
for (i = 0; i < 10; i++) {
|
for (i = 0; i < 10; i++) {
|
||||||
if (microwatt_get_random_darn(&val)) {
|
if (microwatt_get_random_darn(&val)) {
|
||||||
ppc_md.get_random_seed = microwatt_get_random_darn;
|
ppc_md.get_random_seed = microwatt_get_random_darn;
|
||||||
return 0;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pr_warn("Unable to use DARN for get_random_seed()\n");
|
|
||||||
|
|
||||||
return -EIO;
|
|
||||||
}
|
}
|
||||||
machine_subsys_initcall(, rng_init);
|
|
||||||
|
@ -16,6 +16,8 @@
|
|||||||
#include <asm/xics.h>
|
#include <asm/xics.h>
|
||||||
#include <asm/udbg.h>
|
#include <asm/udbg.h>
|
||||||
|
|
||||||
|
#include "microwatt.h"
|
||||||
|
|
||||||
static void __init microwatt_init_IRQ(void)
|
static void __init microwatt_init_IRQ(void)
|
||||||
{
|
{
|
||||||
xics_init();
|
xics_init();
|
||||||
@ -32,10 +34,16 @@ static int __init microwatt_populate(void)
|
|||||||
}
|
}
|
||||||
machine_arch_initcall(microwatt, microwatt_populate);
|
machine_arch_initcall(microwatt, microwatt_populate);
|
||||||
|
|
||||||
|
static void __init microwatt_setup_arch(void)
|
||||||
|
{
|
||||||
|
microwatt_rng_init();
|
||||||
|
}
|
||||||
|
|
||||||
define_machine(microwatt) {
|
define_machine(microwatt) {
|
||||||
.name = "microwatt",
|
.name = "microwatt",
|
||||||
.probe = microwatt_probe,
|
.probe = microwatt_probe,
|
||||||
.init_IRQ = microwatt_init_IRQ,
|
.init_IRQ = microwatt_init_IRQ,
|
||||||
|
.setup_arch = microwatt_setup_arch,
|
||||||
.progress = udbg_progress,
|
.progress = udbg_progress,
|
||||||
.calibrate_decr = generic_calibrate_decr,
|
.calibrate_decr = generic_calibrate_decr,
|
||||||
};
|
};
|
||||||
|
@ -42,4 +42,6 @@ ssize_t memcons_copy(struct memcons *mc, char *to, loff_t pos, size_t count);
|
|||||||
u32 __init memcons_get_size(struct memcons *mc);
|
u32 __init memcons_get_size(struct memcons *mc);
|
||||||
struct memcons *__init memcons_init(struct device_node *node, const char *mc_prop_name);
|
struct memcons *__init memcons_init(struct device_node *node, const char *mc_prop_name);
|
||||||
|
|
||||||
|
void pnv_rng_init(void);
|
||||||
|
|
||||||
#endif /* _POWERNV_H */
|
#endif /* _POWERNV_H */
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
#include <asm/prom.h>
|
#include <asm/prom.h>
|
||||||
#include <asm/machdep.h>
|
#include <asm/machdep.h>
|
||||||
#include <asm/smp.h>
|
#include <asm/smp.h>
|
||||||
|
#include "powernv.h"
|
||||||
|
|
||||||
#define DARN_ERR 0xFFFFFFFFFFFFFFFFul
|
#define DARN_ERR 0xFFFFFFFFFFFFFFFFul
|
||||||
|
|
||||||
@ -28,7 +29,6 @@ struct powernv_rng {
|
|||||||
|
|
||||||
static DEFINE_PER_CPU(struct powernv_rng *, powernv_rng);
|
static DEFINE_PER_CPU(struct powernv_rng *, powernv_rng);
|
||||||
|
|
||||||
|
|
||||||
int powernv_hwrng_present(void)
|
int powernv_hwrng_present(void)
|
||||||
{
|
{
|
||||||
struct powernv_rng *rng;
|
struct powernv_rng *rng;
|
||||||
@ -98,9 +98,6 @@ static int __init initialise_darn(void)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pr_warn("Unable to use DARN for get_random_seed()\n");
|
|
||||||
|
|
||||||
return -EIO;
|
return -EIO;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -163,32 +160,55 @@ static __init int rng_create(struct device_node *dn)
|
|||||||
|
|
||||||
rng_init_per_cpu(rng, dn);
|
rng_init_per_cpu(rng, dn);
|
||||||
|
|
||||||
pr_info_once("Registering arch random hook.\n");
|
|
||||||
|
|
||||||
ppc_md.get_random_seed = powernv_get_random_long;
|
ppc_md.get_random_seed = powernv_get_random_long;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static __init int rng_init(void)
|
static int __init pnv_get_random_long_early(unsigned long *v)
|
||||||
{
|
{
|
||||||
struct device_node *dn;
|
struct device_node *dn;
|
||||||
int rc;
|
|
||||||
|
if (!slab_is_available())
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
if (cmpxchg(&ppc_md.get_random_seed, pnv_get_random_long_early,
|
||||||
|
NULL) != pnv_get_random_long_early)
|
||||||
|
return 0;
|
||||||
|
|
||||||
for_each_compatible_node(dn, NULL, "ibm,power-rng") {
|
for_each_compatible_node(dn, NULL, "ibm,power-rng") {
|
||||||
rc = rng_create(dn);
|
if (rng_create(dn))
|
||||||
if (rc) {
|
|
||||||
pr_err("Failed creating rng for %pOF (%d).\n",
|
|
||||||
dn, rc);
|
|
||||||
continue;
|
continue;
|
||||||
}
|
|
||||||
|
|
||||||
/* Create devices for hwrng driver */
|
/* Create devices for hwrng driver */
|
||||||
of_platform_device_create(dn, NULL, NULL);
|
of_platform_device_create(dn, NULL, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
initialise_darn();
|
if (!ppc_md.get_random_seed)
|
||||||
|
return 0;
|
||||||
|
return ppc_md.get_random_seed(v);
|
||||||
|
}
|
||||||
|
|
||||||
|
void __init pnv_rng_init(void)
|
||||||
|
{
|
||||||
|
struct device_node *dn;
|
||||||
|
|
||||||
|
/* Prefer darn over the rest. */
|
||||||
|
if (!initialise_darn())
|
||||||
|
return;
|
||||||
|
|
||||||
|
dn = of_find_compatible_node(NULL, NULL, "ibm,power-rng");
|
||||||
|
if (dn)
|
||||||
|
ppc_md.get_random_seed = pnv_get_random_long_early;
|
||||||
|
|
||||||
|
of_node_put(dn);
|
||||||
|
}
|
||||||
|
|
||||||
|
static int __init pnv_rng_late_init(void)
|
||||||
|
{
|
||||||
|
unsigned long v;
|
||||||
|
/* In case it wasn't called during init for some other reason. */
|
||||||
|
if (ppc_md.get_random_seed == pnv_get_random_long_early)
|
||||||
|
pnv_get_random_long_early(&v);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
machine_subsys_initcall(powernv, rng_init);
|
machine_subsys_initcall(powernv, pnv_rng_late_init);
|
||||||
|
@ -203,6 +203,8 @@ static void __init pnv_setup_arch(void)
|
|||||||
pnv_check_guarded_cores();
|
pnv_check_guarded_cores();
|
||||||
|
|
||||||
/* XXX PMCS */
|
/* XXX PMCS */
|
||||||
|
|
||||||
|
pnv_rng_init();
|
||||||
}
|
}
|
||||||
|
|
||||||
static void __init pnv_init(void)
|
static void __init pnv_init(void)
|
||||||
|
@ -122,4 +122,6 @@ void pseries_lpar_read_hblkrm_characteristics(void);
|
|||||||
static inline void pseries_lpar_read_hblkrm_characteristics(void) { }
|
static inline void pseries_lpar_read_hblkrm_characteristics(void) { }
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
void pseries_rng_init(void);
|
||||||
|
|
||||||
#endif /* _PSERIES_PSERIES_H */
|
#endif /* _PSERIES_PSERIES_H */
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
#include <asm/archrandom.h>
|
#include <asm/archrandom.h>
|
||||||
#include <asm/machdep.h>
|
#include <asm/machdep.h>
|
||||||
#include <asm/plpar_wrappers.h>
|
#include <asm/plpar_wrappers.h>
|
||||||
|
#include "pseries.h"
|
||||||
|
|
||||||
|
|
||||||
static int pseries_get_random_long(unsigned long *v)
|
static int pseries_get_random_long(unsigned long *v)
|
||||||
@ -24,19 +25,13 @@ static int pseries_get_random_long(unsigned long *v)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static __init int rng_init(void)
|
void __init pseries_rng_init(void)
|
||||||
{
|
{
|
||||||
struct device_node *dn;
|
struct device_node *dn;
|
||||||
|
|
||||||
dn = of_find_compatible_node(NULL, NULL, "ibm,random");
|
dn = of_find_compatible_node(NULL, NULL, "ibm,random");
|
||||||
if (!dn)
|
if (!dn)
|
||||||
return -ENODEV;
|
return;
|
||||||
|
|
||||||
pr_info("Registering arch random hook.\n");
|
|
||||||
|
|
||||||
ppc_md.get_random_seed = pseries_get_random_long;
|
ppc_md.get_random_seed = pseries_get_random_long;
|
||||||
|
|
||||||
of_node_put(dn);
|
of_node_put(dn);
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
machine_subsys_initcall(pseries, rng_init);
|
|
||||||
|
@ -839,6 +839,7 @@ static void __init pSeries_setup_arch(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
ppc_md.pcibios_root_bridge_prepare = pseries_root_bridge_prepare;
|
ppc_md.pcibios_root_bridge_prepare = pseries_root_bridge_prepare;
|
||||||
|
pseries_rng_init();
|
||||||
}
|
}
|
||||||
|
|
||||||
static void pseries_panic(char *str)
|
static void pseries_panic(char *str)
|
||||||
|
@ -75,20 +75,20 @@ asm volatile(ALTERNATIVE( \
|
|||||||
"nop\n\t" \
|
"nop\n\t" \
|
||||||
"nop\n\t" \
|
"nop\n\t" \
|
||||||
"nop", \
|
"nop", \
|
||||||
"li t3, %2\n\t" \
|
"li t3, %1\n\t" \
|
||||||
"slli t3, t3, %4\n\t" \
|
"slli t3, t3, %3\n\t" \
|
||||||
"and t3, %0, t3\n\t" \
|
"and t3, %0, t3\n\t" \
|
||||||
"bne t3, zero, 2f\n\t" \
|
"bne t3, zero, 2f\n\t" \
|
||||||
"li t3, %3\n\t" \
|
"li t3, %2\n\t" \
|
||||||
"slli t3, t3, %4\n\t" \
|
"slli t3, t3, %3\n\t" \
|
||||||
"or %0, %0, t3\n\t" \
|
"or %0, %0, t3\n\t" \
|
||||||
"2:", THEAD_VENDOR_ID, \
|
"2:", THEAD_VENDOR_ID, \
|
||||||
ERRATA_THEAD_PBMT, CONFIG_ERRATA_THEAD_PBMT) \
|
ERRATA_THEAD_PBMT, CONFIG_ERRATA_THEAD_PBMT) \
|
||||||
: "+r"(_val) \
|
: "+r"(_val) \
|
||||||
: "0"(_val), \
|
: "I"(_PAGE_MTMASK_THEAD >> ALT_THEAD_PBMT_SHIFT), \
|
||||||
"I"(_PAGE_MTMASK_THEAD >> ALT_THEAD_PBMT_SHIFT), \
|
|
||||||
"I"(_PAGE_PMA_THEAD >> ALT_THEAD_PBMT_SHIFT), \
|
"I"(_PAGE_PMA_THEAD >> ALT_THEAD_PBMT_SHIFT), \
|
||||||
"I"(ALT_THEAD_PBMT_SHIFT))
|
"I"(ALT_THEAD_PBMT_SHIFT) \
|
||||||
|
: "t3")
|
||||||
#else
|
#else
|
||||||
#define ALT_THEAD_PMA(_val)
|
#define ALT_THEAD_PMA(_val)
|
||||||
#endif
|
#endif
|
||||||
|
@ -219,6 +219,11 @@ ssize_t copy_oldmem_page(struct iov_iter *iter, unsigned long pfn, size_t csize,
|
|||||||
unsigned long src;
|
unsigned long src;
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
|
if (!(iter_is_iovec(iter) || iov_iter_is_kvec(iter)))
|
||||||
|
return -EINVAL;
|
||||||
|
/* Multi-segment iterators are not supported */
|
||||||
|
if (iter->nr_segs > 1)
|
||||||
|
return -EINVAL;
|
||||||
if (!csize)
|
if (!csize)
|
||||||
return 0;
|
return 0;
|
||||||
src = pfn_to_phys(pfn) + offset;
|
src = pfn_to_phys(pfn) + offset;
|
||||||
@ -228,7 +233,10 @@ ssize_t copy_oldmem_page(struct iov_iter *iter, unsigned long pfn, size_t csize,
|
|||||||
rc = copy_oldmem_user(iter->iov->iov_base, src, csize);
|
rc = copy_oldmem_user(iter->iov->iov_base, src, csize);
|
||||||
else
|
else
|
||||||
rc = copy_oldmem_kernel(iter->kvec->iov_base, src, csize);
|
rc = copy_oldmem_kernel(iter->kvec->iov_base, src, csize);
|
||||||
return rc;
|
if (rc < 0)
|
||||||
|
return rc;
|
||||||
|
iov_iter_advance(iter, csize);
|
||||||
|
return csize;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -516,6 +516,26 @@ static int __hw_perf_event_init(struct perf_event *event, unsigned int type)
|
|||||||
return err;
|
return err;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Events CPU_CYLCES and INSTRUCTIONS can be submitted with two different
|
||||||
|
* attribute::type values:
|
||||||
|
* - PERF_TYPE_HARDWARE:
|
||||||
|
* - pmu->type:
|
||||||
|
* Handle both type of invocations identical. They address the same hardware.
|
||||||
|
* The result is different when event modifiers exclude_kernel and/or
|
||||||
|
* exclude_user are also set.
|
||||||
|
*/
|
||||||
|
static int cpumf_pmu_event_type(struct perf_event *event)
|
||||||
|
{
|
||||||
|
u64 ev = event->attr.config;
|
||||||
|
|
||||||
|
if (cpumf_generic_events_basic[PERF_COUNT_HW_CPU_CYCLES] == ev ||
|
||||||
|
cpumf_generic_events_basic[PERF_COUNT_HW_INSTRUCTIONS] == ev ||
|
||||||
|
cpumf_generic_events_user[PERF_COUNT_HW_CPU_CYCLES] == ev ||
|
||||||
|
cpumf_generic_events_user[PERF_COUNT_HW_INSTRUCTIONS] == ev)
|
||||||
|
return PERF_TYPE_HARDWARE;
|
||||||
|
return PERF_TYPE_RAW;
|
||||||
|
}
|
||||||
|
|
||||||
static int cpumf_pmu_event_init(struct perf_event *event)
|
static int cpumf_pmu_event_init(struct perf_event *event)
|
||||||
{
|
{
|
||||||
unsigned int type = event->attr.type;
|
unsigned int type = event->attr.type;
|
||||||
@ -525,7 +545,7 @@ static int cpumf_pmu_event_init(struct perf_event *event)
|
|||||||
err = __hw_perf_event_init(event, type);
|
err = __hw_perf_event_init(event, type);
|
||||||
else if (event->pmu->type == type)
|
else if (event->pmu->type == type)
|
||||||
/* Registered as unknown PMU */
|
/* Registered as unknown PMU */
|
||||||
err = __hw_perf_event_init(event, PERF_TYPE_RAW);
|
err = __hw_perf_event_init(event, cpumf_pmu_event_type(event));
|
||||||
else
|
else
|
||||||
return -ENOENT;
|
return -ENOENT;
|
||||||
|
|
||||||
|
@ -193,8 +193,9 @@ static int paicrypt_event_init(struct perf_event *event)
|
|||||||
/* PAI crypto PMU registered as PERF_TYPE_RAW, check event type */
|
/* PAI crypto PMU registered as PERF_TYPE_RAW, check event type */
|
||||||
if (a->type != PERF_TYPE_RAW && event->pmu->type != a->type)
|
if (a->type != PERF_TYPE_RAW && event->pmu->type != a->type)
|
||||||
return -ENOENT;
|
return -ENOENT;
|
||||||
/* PAI crypto event must be valid */
|
/* PAI crypto event must be in valid range */
|
||||||
if (a->config > PAI_CRYPTO_BASE + paicrypt_cnt)
|
if (a->config < PAI_CRYPTO_BASE ||
|
||||||
|
a->config > PAI_CRYPTO_BASE + paicrypt_cnt)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
/* Allow only CPU wide operation, no process context for now. */
|
/* Allow only CPU wide operation, no process context for now. */
|
||||||
if (event->hw.target || event->cpu == -1)
|
if (event->hw.target || event->cpu == -1)
|
||||||
@ -208,6 +209,12 @@ static int paicrypt_event_init(struct perf_event *event)
|
|||||||
if (rc)
|
if (rc)
|
||||||
return rc;
|
return rc;
|
||||||
|
|
||||||
|
/* Event initialization sets last_tag to 0. When later on the events
|
||||||
|
* are deleted and re-added, do not reset the event count value to zero.
|
||||||
|
* Events are added, deleted and re-added when 2 or more events
|
||||||
|
* are active at the same time.
|
||||||
|
*/
|
||||||
|
event->hw.last_tag = 0;
|
||||||
cpump->event = event;
|
cpump->event = event;
|
||||||
event->destroy = paicrypt_event_destroy;
|
event->destroy = paicrypt_event_destroy;
|
||||||
|
|
||||||
@ -242,9 +249,12 @@ static void paicrypt_start(struct perf_event *event, int flags)
|
|||||||
{
|
{
|
||||||
u64 sum;
|
u64 sum;
|
||||||
|
|
||||||
sum = paicrypt_getall(event); /* Get current value */
|
if (!event->hw.last_tag) {
|
||||||
local64_set(&event->hw.prev_count, sum);
|
event->hw.last_tag = 1;
|
||||||
local64_set(&event->count, 0);
|
sum = paicrypt_getall(event); /* Get current value */
|
||||||
|
local64_set(&event->count, 0);
|
||||||
|
local64_set(&event->hw.prev_count, sum);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static int paicrypt_add(struct perf_event *event, int flags)
|
static int paicrypt_add(struct perf_event *event, int flags)
|
||||||
|
@ -323,7 +323,7 @@ static inline u32 efi64_convert_status(efi_status_t status)
|
|||||||
#define __efi64_argmap_get_memory_space_descriptor(phys, desc) \
|
#define __efi64_argmap_get_memory_space_descriptor(phys, desc) \
|
||||||
(__efi64_split(phys), (desc))
|
(__efi64_split(phys), (desc))
|
||||||
|
|
||||||
#define __efi64_argmap_set_memory_space_descriptor(phys, size, flags) \
|
#define __efi64_argmap_set_memory_space_attributes(phys, size, flags) \
|
||||||
(__efi64_split(phys), __efi64_split(size), __efi64_split(flags))
|
(__efi64_split(phys), __efi64_split(size), __efi64_split(flags))
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -844,7 +844,7 @@ static int __sev_dbg_encrypt_user(struct kvm *kvm, unsigned long paddr,
|
|||||||
|
|
||||||
/* If source buffer is not aligned then use an intermediate buffer */
|
/* If source buffer is not aligned then use an intermediate buffer */
|
||||||
if (!IS_ALIGNED((unsigned long)vaddr, 16)) {
|
if (!IS_ALIGNED((unsigned long)vaddr, 16)) {
|
||||||
src_tpage = alloc_page(GFP_KERNEL);
|
src_tpage = alloc_page(GFP_KERNEL_ACCOUNT);
|
||||||
if (!src_tpage)
|
if (!src_tpage)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
@ -865,7 +865,7 @@ static int __sev_dbg_encrypt_user(struct kvm *kvm, unsigned long paddr,
|
|||||||
if (!IS_ALIGNED((unsigned long)dst_vaddr, 16) || !IS_ALIGNED(size, 16)) {
|
if (!IS_ALIGNED((unsigned long)dst_vaddr, 16) || !IS_ALIGNED(size, 16)) {
|
||||||
int dst_offset;
|
int dst_offset;
|
||||||
|
|
||||||
dst_tpage = alloc_page(GFP_KERNEL);
|
dst_tpage = alloc_page(GFP_KERNEL_ACCOUNT);
|
||||||
if (!dst_tpage) {
|
if (!dst_tpage) {
|
||||||
ret = -ENOMEM;
|
ret = -ENOMEM;
|
||||||
goto e_free;
|
goto e_free;
|
||||||
@ -1665,19 +1665,24 @@ static void sev_migrate_from(struct kvm *dst_kvm, struct kvm *src_kvm)
|
|||||||
{
|
{
|
||||||
struct kvm_sev_info *dst = &to_kvm_svm(dst_kvm)->sev_info;
|
struct kvm_sev_info *dst = &to_kvm_svm(dst_kvm)->sev_info;
|
||||||
struct kvm_sev_info *src = &to_kvm_svm(src_kvm)->sev_info;
|
struct kvm_sev_info *src = &to_kvm_svm(src_kvm)->sev_info;
|
||||||
|
struct kvm_vcpu *dst_vcpu, *src_vcpu;
|
||||||
|
struct vcpu_svm *dst_svm, *src_svm;
|
||||||
struct kvm_sev_info *mirror;
|
struct kvm_sev_info *mirror;
|
||||||
|
unsigned long i;
|
||||||
|
|
||||||
dst->active = true;
|
dst->active = true;
|
||||||
dst->asid = src->asid;
|
dst->asid = src->asid;
|
||||||
dst->handle = src->handle;
|
dst->handle = src->handle;
|
||||||
dst->pages_locked = src->pages_locked;
|
dst->pages_locked = src->pages_locked;
|
||||||
dst->enc_context_owner = src->enc_context_owner;
|
dst->enc_context_owner = src->enc_context_owner;
|
||||||
|
dst->es_active = src->es_active;
|
||||||
|
|
||||||
src->asid = 0;
|
src->asid = 0;
|
||||||
src->active = false;
|
src->active = false;
|
||||||
src->handle = 0;
|
src->handle = 0;
|
||||||
src->pages_locked = 0;
|
src->pages_locked = 0;
|
||||||
src->enc_context_owner = NULL;
|
src->enc_context_owner = NULL;
|
||||||
|
src->es_active = false;
|
||||||
|
|
||||||
list_cut_before(&dst->regions_list, &src->regions_list, &src->regions_list);
|
list_cut_before(&dst->regions_list, &src->regions_list, &src->regions_list);
|
||||||
|
|
||||||
@ -1704,27 +1709,22 @@ static void sev_migrate_from(struct kvm *dst_kvm, struct kvm *src_kvm)
|
|||||||
list_del(&src->mirror_entry);
|
list_del(&src->mirror_entry);
|
||||||
list_add_tail(&dst->mirror_entry, &owner_sev_info->mirror_vms);
|
list_add_tail(&dst->mirror_entry, &owner_sev_info->mirror_vms);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
static int sev_es_migrate_from(struct kvm *dst, struct kvm *src)
|
kvm_for_each_vcpu(i, dst_vcpu, dst_kvm) {
|
||||||
{
|
|
||||||
unsigned long i;
|
|
||||||
struct kvm_vcpu *dst_vcpu, *src_vcpu;
|
|
||||||
struct vcpu_svm *dst_svm, *src_svm;
|
|
||||||
|
|
||||||
if (atomic_read(&src->online_vcpus) != atomic_read(&dst->online_vcpus))
|
|
||||||
return -EINVAL;
|
|
||||||
|
|
||||||
kvm_for_each_vcpu(i, src_vcpu, src) {
|
|
||||||
if (!src_vcpu->arch.guest_state_protected)
|
|
||||||
return -EINVAL;
|
|
||||||
}
|
|
||||||
|
|
||||||
kvm_for_each_vcpu(i, src_vcpu, src) {
|
|
||||||
src_svm = to_svm(src_vcpu);
|
|
||||||
dst_vcpu = kvm_get_vcpu(dst, i);
|
|
||||||
dst_svm = to_svm(dst_vcpu);
|
dst_svm = to_svm(dst_vcpu);
|
||||||
|
|
||||||
|
sev_init_vmcb(dst_svm);
|
||||||
|
|
||||||
|
if (!dst->es_active)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Note, the source is not required to have the same number of
|
||||||
|
* vCPUs as the destination when migrating a vanilla SEV VM.
|
||||||
|
*/
|
||||||
|
src_vcpu = kvm_get_vcpu(dst_kvm, i);
|
||||||
|
src_svm = to_svm(src_vcpu);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Transfer VMSA and GHCB state to the destination. Nullify and
|
* Transfer VMSA and GHCB state to the destination. Nullify and
|
||||||
* clear source fields as appropriate, the state now belongs to
|
* clear source fields as appropriate, the state now belongs to
|
||||||
@ -1740,8 +1740,23 @@ static int sev_es_migrate_from(struct kvm *dst, struct kvm *src)
|
|||||||
src_svm->vmcb->control.vmsa_pa = INVALID_PAGE;
|
src_svm->vmcb->control.vmsa_pa = INVALID_PAGE;
|
||||||
src_vcpu->arch.guest_state_protected = false;
|
src_vcpu->arch.guest_state_protected = false;
|
||||||
}
|
}
|
||||||
to_kvm_svm(src)->sev_info.es_active = false;
|
}
|
||||||
to_kvm_svm(dst)->sev_info.es_active = true;
|
|
||||||
|
static int sev_check_source_vcpus(struct kvm *dst, struct kvm *src)
|
||||||
|
{
|
||||||
|
struct kvm_vcpu *src_vcpu;
|
||||||
|
unsigned long i;
|
||||||
|
|
||||||
|
if (!sev_es_guest(src))
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
if (atomic_read(&src->online_vcpus) != atomic_read(&dst->online_vcpus))
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
|
kvm_for_each_vcpu(i, src_vcpu, src) {
|
||||||
|
if (!src_vcpu->arch.guest_state_protected)
|
||||||
|
return -EINVAL;
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@ -1789,11 +1804,9 @@ int sev_vm_move_enc_context_from(struct kvm *kvm, unsigned int source_fd)
|
|||||||
if (ret)
|
if (ret)
|
||||||
goto out_dst_vcpu;
|
goto out_dst_vcpu;
|
||||||
|
|
||||||
if (sev_es_guest(source_kvm)) {
|
ret = sev_check_source_vcpus(kvm, source_kvm);
|
||||||
ret = sev_es_migrate_from(kvm, source_kvm);
|
if (ret)
|
||||||
if (ret)
|
goto out_source_vcpu;
|
||||||
goto out_source_vcpu;
|
|
||||||
}
|
|
||||||
|
|
||||||
sev_migrate_from(kvm, source_kvm);
|
sev_migrate_from(kvm, source_kvm);
|
||||||
kvm_vm_dead(source_kvm);
|
kvm_vm_dead(source_kvm);
|
||||||
@ -2914,7 +2927,7 @@ int sev_es_string_io(struct vcpu_svm *svm, int size, unsigned int port, int in)
|
|||||||
count, in);
|
count, in);
|
||||||
}
|
}
|
||||||
|
|
||||||
void sev_es_init_vmcb(struct vcpu_svm *svm)
|
static void sev_es_init_vmcb(struct vcpu_svm *svm)
|
||||||
{
|
{
|
||||||
struct kvm_vcpu *vcpu = &svm->vcpu;
|
struct kvm_vcpu *vcpu = &svm->vcpu;
|
||||||
|
|
||||||
@ -2967,6 +2980,15 @@ void sev_es_init_vmcb(struct vcpu_svm *svm)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void sev_init_vmcb(struct vcpu_svm *svm)
|
||||||
|
{
|
||||||
|
svm->vmcb->control.nested_ctl |= SVM_NESTED_CTL_SEV_ENABLE;
|
||||||
|
clr_exception_intercept(svm, UD_VECTOR);
|
||||||
|
|
||||||
|
if (sev_es_guest(svm->vcpu.kvm))
|
||||||
|
sev_es_init_vmcb(svm);
|
||||||
|
}
|
||||||
|
|
||||||
void sev_es_vcpu_reset(struct vcpu_svm *svm)
|
void sev_es_vcpu_reset(struct vcpu_svm *svm)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
|
@ -1212,15 +1212,8 @@ static void init_vmcb(struct kvm_vcpu *vcpu)
|
|||||||
svm->vmcb->control.int_ctl |= V_GIF_ENABLE_MASK;
|
svm->vmcb->control.int_ctl |= V_GIF_ENABLE_MASK;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sev_guest(vcpu->kvm)) {
|
if (sev_guest(vcpu->kvm))
|
||||||
svm->vmcb->control.nested_ctl |= SVM_NESTED_CTL_SEV_ENABLE;
|
sev_init_vmcb(svm);
|
||||||
clr_exception_intercept(svm, UD_VECTOR);
|
|
||||||
|
|
||||||
if (sev_es_guest(vcpu->kvm)) {
|
|
||||||
/* Perform SEV-ES specific VMCB updates */
|
|
||||||
sev_es_init_vmcb(svm);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
svm_hv_init_vmcb(vmcb);
|
svm_hv_init_vmcb(vmcb);
|
||||||
init_vmcb_after_set_cpuid(vcpu);
|
init_vmcb_after_set_cpuid(vcpu);
|
||||||
|
@ -649,10 +649,10 @@ void __init sev_set_cpu_caps(void);
|
|||||||
void __init sev_hardware_setup(void);
|
void __init sev_hardware_setup(void);
|
||||||
void sev_hardware_unsetup(void);
|
void sev_hardware_unsetup(void);
|
||||||
int sev_cpu_init(struct svm_cpu_data *sd);
|
int sev_cpu_init(struct svm_cpu_data *sd);
|
||||||
|
void sev_init_vmcb(struct vcpu_svm *svm);
|
||||||
void sev_free_vcpu(struct kvm_vcpu *vcpu);
|
void sev_free_vcpu(struct kvm_vcpu *vcpu);
|
||||||
int sev_handle_vmgexit(struct kvm_vcpu *vcpu);
|
int sev_handle_vmgexit(struct kvm_vcpu *vcpu);
|
||||||
int sev_es_string_io(struct vcpu_svm *svm, int size, unsigned int port, int in);
|
int sev_es_string_io(struct vcpu_svm *svm, int size, unsigned int port, int in);
|
||||||
void sev_es_init_vmcb(struct vcpu_svm *svm);
|
|
||||||
void sev_es_vcpu_reset(struct vcpu_svm *svm);
|
void sev_es_vcpu_reset(struct vcpu_svm *svm);
|
||||||
void sev_vcpu_deliver_sipi_vector(struct kvm_vcpu *vcpu, u8 vector);
|
void sev_vcpu_deliver_sipi_vector(struct kvm_vcpu *vcpu, u8 vector);
|
||||||
void sev_es_prepare_switch_to_guest(struct sev_es_save_area *hostsa);
|
void sev_es_prepare_switch_to_guest(struct sev_es_save_area *hostsa);
|
||||||
|
@ -1420,8 +1420,9 @@ st: if (is_imm8(insn->off))
|
|||||||
case BPF_JMP | BPF_CALL:
|
case BPF_JMP | BPF_CALL:
|
||||||
func = (u8 *) __bpf_call_base + imm32;
|
func = (u8 *) __bpf_call_base + imm32;
|
||||||
if (tail_call_reachable) {
|
if (tail_call_reachable) {
|
||||||
|
/* mov rax, qword ptr [rbp - rounded_stack_depth - 8] */
|
||||||
EMIT3_off32(0x48, 0x8B, 0x85,
|
EMIT3_off32(0x48, 0x8B, 0x85,
|
||||||
-(bpf_prog->aux->stack_depth + 8));
|
-round_up(bpf_prog->aux->stack_depth, 8) - 8);
|
||||||
if (!imm32 || emit_call(&prog, func, image + addrs[i - 1] + 7))
|
if (!imm32 || emit_call(&prog, func, image + addrs[i - 1] + 7))
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
} else {
|
} else {
|
||||||
|
@ -2173,7 +2173,7 @@ ENDPROC(ret_from_kernel_thread)
|
|||||||
|
|
||||||
#ifdef CONFIG_HIBERNATION
|
#ifdef CONFIG_HIBERNATION
|
||||||
|
|
||||||
.bss
|
.section .bss, "aw"
|
||||||
.align 4
|
.align 4
|
||||||
.Lsaved_regs:
|
.Lsaved_regs:
|
||||||
#if defined(__XTENSA_WINDOWED_ABI__)
|
#if defined(__XTENSA_WINDOWED_ABI__)
|
||||||
|
@ -154,6 +154,7 @@ static void __init calibrate_ccount(void)
|
|||||||
cpu = of_find_compatible_node(NULL, NULL, "cdns,xtensa-cpu");
|
cpu = of_find_compatible_node(NULL, NULL, "cdns,xtensa-cpu");
|
||||||
if (cpu) {
|
if (cpu) {
|
||||||
clk = of_clk_get(cpu, 0);
|
clk = of_clk_get(cpu, 0);
|
||||||
|
of_node_put(cpu);
|
||||||
if (!IS_ERR(clk)) {
|
if (!IS_ERR(clk)) {
|
||||||
ccount_freq = clk_get_rate(clk);
|
ccount_freq = clk_get_rate(clk);
|
||||||
return;
|
return;
|
||||||
|
@ -133,6 +133,7 @@ static int __init machine_setup(void)
|
|||||||
|
|
||||||
if ((eth = of_find_compatible_node(eth, NULL, "opencores,ethoc")))
|
if ((eth = of_find_compatible_node(eth, NULL, "opencores,ethoc")))
|
||||||
update_local_mac(eth);
|
update_local_mac(eth);
|
||||||
|
of_node_put(eth);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
arch_initcall(machine_setup);
|
arch_initcall(machine_setup);
|
||||||
|
@ -322,19 +322,6 @@ void blk_cleanup_queue(struct request_queue *q)
|
|||||||
blk_mq_exit_queue(q);
|
blk_mq_exit_queue(q);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* In theory, request pool of sched_tags belongs to request queue.
|
|
||||||
* However, the current implementation requires tag_set for freeing
|
|
||||||
* requests, so free the pool now.
|
|
||||||
*
|
|
||||||
* Queue has become frozen, there can't be any in-queue requests, so
|
|
||||||
* it is safe to free requests now.
|
|
||||||
*/
|
|
||||||
mutex_lock(&q->sysfs_lock);
|
|
||||||
if (q->elevator)
|
|
||||||
blk_mq_sched_free_rqs(q);
|
|
||||||
mutex_unlock(&q->sysfs_lock);
|
|
||||||
|
|
||||||
/* @q is and will stay empty, shutdown and put */
|
/* @q is and will stay empty, shutdown and put */
|
||||||
blk_put_queue(q);
|
blk_put_queue(q);
|
||||||
}
|
}
|
||||||
|
@ -144,7 +144,6 @@ int disk_register_independent_access_ranges(struct gendisk *disk,
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (i = 0; i < iars->nr_ia_ranges; i++) {
|
for (i = 0; i < iars->nr_ia_ranges; i++) {
|
||||||
iars->ia_range[i].queue = q;
|
|
||||||
ret = kobject_init_and_add(&iars->ia_range[i].kobj,
|
ret = kobject_init_and_add(&iars->ia_range[i].kobj,
|
||||||
&blk_ia_range_ktype, &iars->kobj,
|
&blk_ia_range_ktype, &iars->kobj,
|
||||||
"%d", i);
|
"%d", i);
|
||||||
|
@ -711,11 +711,6 @@ void blk_mq_debugfs_register(struct request_queue *q)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void blk_mq_debugfs_unregister(struct request_queue *q)
|
|
||||||
{
|
|
||||||
q->sched_debugfs_dir = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
static void blk_mq_debugfs_register_ctx(struct blk_mq_hw_ctx *hctx,
|
static void blk_mq_debugfs_register_ctx(struct blk_mq_hw_ctx *hctx,
|
||||||
struct blk_mq_ctx *ctx)
|
struct blk_mq_ctx *ctx)
|
||||||
{
|
{
|
||||||
@ -746,6 +741,8 @@ void blk_mq_debugfs_register_hctx(struct request_queue *q,
|
|||||||
|
|
||||||
void blk_mq_debugfs_unregister_hctx(struct blk_mq_hw_ctx *hctx)
|
void blk_mq_debugfs_unregister_hctx(struct blk_mq_hw_ctx *hctx)
|
||||||
{
|
{
|
||||||
|
if (!hctx->queue->debugfs_dir)
|
||||||
|
return;
|
||||||
debugfs_remove_recursive(hctx->debugfs_dir);
|
debugfs_remove_recursive(hctx->debugfs_dir);
|
||||||
hctx->sched_debugfs_dir = NULL;
|
hctx->sched_debugfs_dir = NULL;
|
||||||
hctx->debugfs_dir = NULL;
|
hctx->debugfs_dir = NULL;
|
||||||
@ -773,6 +770,8 @@ void blk_mq_debugfs_register_sched(struct request_queue *q)
|
|||||||
{
|
{
|
||||||
struct elevator_type *e = q->elevator->type;
|
struct elevator_type *e = q->elevator->type;
|
||||||
|
|
||||||
|
lockdep_assert_held(&q->debugfs_mutex);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If the parent directory has not been created yet, return, we will be
|
* If the parent directory has not been created yet, return, we will be
|
||||||
* called again later on and the directory/files will be created then.
|
* called again later on and the directory/files will be created then.
|
||||||
@ -790,6 +789,8 @@ void blk_mq_debugfs_register_sched(struct request_queue *q)
|
|||||||
|
|
||||||
void blk_mq_debugfs_unregister_sched(struct request_queue *q)
|
void blk_mq_debugfs_unregister_sched(struct request_queue *q)
|
||||||
{
|
{
|
||||||
|
lockdep_assert_held(&q->debugfs_mutex);
|
||||||
|
|
||||||
debugfs_remove_recursive(q->sched_debugfs_dir);
|
debugfs_remove_recursive(q->sched_debugfs_dir);
|
||||||
q->sched_debugfs_dir = NULL;
|
q->sched_debugfs_dir = NULL;
|
||||||
}
|
}
|
||||||
@ -811,6 +812,10 @@ static const char *rq_qos_id_to_name(enum rq_qos_id id)
|
|||||||
|
|
||||||
void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos)
|
void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos)
|
||||||
{
|
{
|
||||||
|
lockdep_assert_held(&rqos->q->debugfs_mutex);
|
||||||
|
|
||||||
|
if (!rqos->q->debugfs_dir)
|
||||||
|
return;
|
||||||
debugfs_remove_recursive(rqos->debugfs_dir);
|
debugfs_remove_recursive(rqos->debugfs_dir);
|
||||||
rqos->debugfs_dir = NULL;
|
rqos->debugfs_dir = NULL;
|
||||||
}
|
}
|
||||||
@ -820,6 +825,8 @@ void blk_mq_debugfs_register_rqos(struct rq_qos *rqos)
|
|||||||
struct request_queue *q = rqos->q;
|
struct request_queue *q = rqos->q;
|
||||||
const char *dir_name = rq_qos_id_to_name(rqos->id);
|
const char *dir_name = rq_qos_id_to_name(rqos->id);
|
||||||
|
|
||||||
|
lockdep_assert_held(&q->debugfs_mutex);
|
||||||
|
|
||||||
if (rqos->debugfs_dir || !rqos->ops->debugfs_attrs)
|
if (rqos->debugfs_dir || !rqos->ops->debugfs_attrs)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -833,17 +840,13 @@ void blk_mq_debugfs_register_rqos(struct rq_qos *rqos)
|
|||||||
debugfs_create_files(rqos->debugfs_dir, rqos, rqos->ops->debugfs_attrs);
|
debugfs_create_files(rqos->debugfs_dir, rqos, rqos->ops->debugfs_attrs);
|
||||||
}
|
}
|
||||||
|
|
||||||
void blk_mq_debugfs_unregister_queue_rqos(struct request_queue *q)
|
|
||||||
{
|
|
||||||
debugfs_remove_recursive(q->rqos_debugfs_dir);
|
|
||||||
q->rqos_debugfs_dir = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
void blk_mq_debugfs_register_sched_hctx(struct request_queue *q,
|
void blk_mq_debugfs_register_sched_hctx(struct request_queue *q,
|
||||||
struct blk_mq_hw_ctx *hctx)
|
struct blk_mq_hw_ctx *hctx)
|
||||||
{
|
{
|
||||||
struct elevator_type *e = q->elevator->type;
|
struct elevator_type *e = q->elevator->type;
|
||||||
|
|
||||||
|
lockdep_assert_held(&q->debugfs_mutex);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If the parent debugfs directory has not been created yet, return;
|
* If the parent debugfs directory has not been created yet, return;
|
||||||
* We will be called again later on with appropriate parent debugfs
|
* We will be called again later on with appropriate parent debugfs
|
||||||
@ -863,6 +866,10 @@ void blk_mq_debugfs_register_sched_hctx(struct request_queue *q,
|
|||||||
|
|
||||||
void blk_mq_debugfs_unregister_sched_hctx(struct blk_mq_hw_ctx *hctx)
|
void blk_mq_debugfs_unregister_sched_hctx(struct blk_mq_hw_ctx *hctx)
|
||||||
{
|
{
|
||||||
|
lockdep_assert_held(&hctx->queue->debugfs_mutex);
|
||||||
|
|
||||||
|
if (!hctx->queue->debugfs_dir)
|
||||||
|
return;
|
||||||
debugfs_remove_recursive(hctx->sched_debugfs_dir);
|
debugfs_remove_recursive(hctx->sched_debugfs_dir);
|
||||||
hctx->sched_debugfs_dir = NULL;
|
hctx->sched_debugfs_dir = NULL;
|
||||||
}
|
}
|
||||||
|
@ -21,7 +21,6 @@ int __blk_mq_debugfs_rq_show(struct seq_file *m, struct request *rq);
|
|||||||
int blk_mq_debugfs_rq_show(struct seq_file *m, void *v);
|
int blk_mq_debugfs_rq_show(struct seq_file *m, void *v);
|
||||||
|
|
||||||
void blk_mq_debugfs_register(struct request_queue *q);
|
void blk_mq_debugfs_register(struct request_queue *q);
|
||||||
void blk_mq_debugfs_unregister(struct request_queue *q);
|
|
||||||
void blk_mq_debugfs_register_hctx(struct request_queue *q,
|
void blk_mq_debugfs_register_hctx(struct request_queue *q,
|
||||||
struct blk_mq_hw_ctx *hctx);
|
struct blk_mq_hw_ctx *hctx);
|
||||||
void blk_mq_debugfs_unregister_hctx(struct blk_mq_hw_ctx *hctx);
|
void blk_mq_debugfs_unregister_hctx(struct blk_mq_hw_ctx *hctx);
|
||||||
@ -36,16 +35,11 @@ void blk_mq_debugfs_unregister_sched_hctx(struct blk_mq_hw_ctx *hctx);
|
|||||||
|
|
||||||
void blk_mq_debugfs_register_rqos(struct rq_qos *rqos);
|
void blk_mq_debugfs_register_rqos(struct rq_qos *rqos);
|
||||||
void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos);
|
void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos);
|
||||||
void blk_mq_debugfs_unregister_queue_rqos(struct request_queue *q);
|
|
||||||
#else
|
#else
|
||||||
static inline void blk_mq_debugfs_register(struct request_queue *q)
|
static inline void blk_mq_debugfs_register(struct request_queue *q)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void blk_mq_debugfs_unregister(struct request_queue *q)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
static inline void blk_mq_debugfs_register_hctx(struct request_queue *q,
|
static inline void blk_mq_debugfs_register_hctx(struct request_queue *q,
|
||||||
struct blk_mq_hw_ctx *hctx)
|
struct blk_mq_hw_ctx *hctx)
|
||||||
{
|
{
|
||||||
@ -87,10 +81,6 @@ static inline void blk_mq_debugfs_register_rqos(struct rq_qos *rqos)
|
|||||||
static inline void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos)
|
static inline void blk_mq_debugfs_unregister_rqos(struct rq_qos *rqos)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void blk_mq_debugfs_unregister_queue_rqos(struct request_queue *q)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef CONFIG_BLK_DEBUG_FS_ZONED
|
#ifdef CONFIG_BLK_DEBUG_FS_ZONED
|
||||||
|
@ -594,7 +594,9 @@ int blk_mq_init_sched(struct request_queue *q, struct elevator_type *e)
|
|||||||
if (ret)
|
if (ret)
|
||||||
goto err_free_map_and_rqs;
|
goto err_free_map_and_rqs;
|
||||||
|
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_register_sched(q);
|
blk_mq_debugfs_register_sched(q);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
|
||||||
queue_for_each_hw_ctx(q, hctx, i) {
|
queue_for_each_hw_ctx(q, hctx, i) {
|
||||||
if (e->ops.init_hctx) {
|
if (e->ops.init_hctx) {
|
||||||
@ -607,7 +609,9 @@ int blk_mq_init_sched(struct request_queue *q, struct elevator_type *e)
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_register_sched_hctx(q, hctx);
|
blk_mq_debugfs_register_sched_hctx(q, hctx);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
@ -648,14 +652,21 @@ void blk_mq_exit_sched(struct request_queue *q, struct elevator_queue *e)
|
|||||||
unsigned int flags = 0;
|
unsigned int flags = 0;
|
||||||
|
|
||||||
queue_for_each_hw_ctx(q, hctx, i) {
|
queue_for_each_hw_ctx(q, hctx, i) {
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_unregister_sched_hctx(hctx);
|
blk_mq_debugfs_unregister_sched_hctx(hctx);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
|
||||||
if (e->type->ops.exit_hctx && hctx->sched_data) {
|
if (e->type->ops.exit_hctx && hctx->sched_data) {
|
||||||
e->type->ops.exit_hctx(hctx, i);
|
e->type->ops.exit_hctx(hctx, i);
|
||||||
hctx->sched_data = NULL;
|
hctx->sched_data = NULL;
|
||||||
}
|
}
|
||||||
flags = hctx->flags;
|
flags = hctx->flags;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_unregister_sched(q);
|
blk_mq_debugfs_unregister_sched(q);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
|
||||||
if (e->type->ops.exit_sched)
|
if (e->type->ops.exit_sched)
|
||||||
e->type->ops.exit_sched(e);
|
e->type->ops.exit_sched(e);
|
||||||
blk_mq_sched_tags_teardown(q, flags);
|
blk_mq_sched_tags_teardown(q, flags);
|
||||||
|
@ -2765,15 +2765,20 @@ static inline struct request *blk_mq_get_cached_request(struct request_queue *q,
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
rq_qos_throttle(q, *bio);
|
|
||||||
|
|
||||||
if (blk_mq_get_hctx_type((*bio)->bi_opf) != rq->mq_hctx->type)
|
if (blk_mq_get_hctx_type((*bio)->bi_opf) != rq->mq_hctx->type)
|
||||||
return NULL;
|
return NULL;
|
||||||
if (op_is_flush(rq->cmd_flags) != op_is_flush((*bio)->bi_opf))
|
if (op_is_flush(rq->cmd_flags) != op_is_flush((*bio)->bi_opf))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
rq->cmd_flags = (*bio)->bi_opf;
|
/*
|
||||||
|
* If any qos ->throttle() end up blocking, we will have flushed the
|
||||||
|
* plug and hence killed the cached_rq list as well. Pop this entry
|
||||||
|
* before we throttle.
|
||||||
|
*/
|
||||||
plug->cached_rq = rq_list_next(rq);
|
plug->cached_rq = rq_list_next(rq);
|
||||||
|
rq_qos_throttle(q, *bio);
|
||||||
|
|
||||||
|
rq->cmd_flags = (*bio)->bi_opf;
|
||||||
INIT_LIST_HEAD(&rq->queuelist);
|
INIT_LIST_HEAD(&rq->queuelist);
|
||||||
return rq;
|
return rq;
|
||||||
}
|
}
|
||||||
|
@ -294,8 +294,6 @@ void rq_qos_wait(struct rq_wait *rqw, void *private_data,
|
|||||||
|
|
||||||
void rq_qos_exit(struct request_queue *q)
|
void rq_qos_exit(struct request_queue *q)
|
||||||
{
|
{
|
||||||
blk_mq_debugfs_unregister_queue_rqos(q);
|
|
||||||
|
|
||||||
while (q->rq_qos) {
|
while (q->rq_qos) {
|
||||||
struct rq_qos *rqos = q->rq_qos;
|
struct rq_qos *rqos = q->rq_qos;
|
||||||
q->rq_qos = rqos->next;
|
q->rq_qos = rqos->next;
|
||||||
|
@ -104,8 +104,11 @@ static inline void rq_qos_add(struct request_queue *q, struct rq_qos *rqos)
|
|||||||
|
|
||||||
blk_mq_unfreeze_queue(q);
|
blk_mq_unfreeze_queue(q);
|
||||||
|
|
||||||
if (rqos->ops->debugfs_attrs)
|
if (rqos->ops->debugfs_attrs) {
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_register_rqos(rqos);
|
blk_mq_debugfs_register_rqos(rqos);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void rq_qos_del(struct request_queue *q, struct rq_qos *rqos)
|
static inline void rq_qos_del(struct request_queue *q, struct rq_qos *rqos)
|
||||||
@ -129,7 +132,9 @@ static inline void rq_qos_del(struct request_queue *q, struct rq_qos *rqos)
|
|||||||
|
|
||||||
blk_mq_unfreeze_queue(q);
|
blk_mq_unfreeze_queue(q);
|
||||||
|
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
blk_mq_debugfs_unregister_rqos(rqos);
|
blk_mq_debugfs_unregister_rqos(rqos);
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
}
|
}
|
||||||
|
|
||||||
typedef bool (acquire_inflight_cb_t)(struct rq_wait *rqw, void *private_data);
|
typedef bool (acquire_inflight_cb_t)(struct rq_wait *rqw, void *private_data);
|
||||||
|
@ -779,14 +779,6 @@ static void blk_release_queue(struct kobject *kobj)
|
|||||||
if (queue_is_mq(q))
|
if (queue_is_mq(q))
|
||||||
blk_mq_release(q);
|
blk_mq_release(q);
|
||||||
|
|
||||||
blk_trace_shutdown(q);
|
|
||||||
mutex_lock(&q->debugfs_mutex);
|
|
||||||
debugfs_remove_recursive(q->debugfs_dir);
|
|
||||||
mutex_unlock(&q->debugfs_mutex);
|
|
||||||
|
|
||||||
if (queue_is_mq(q))
|
|
||||||
blk_mq_debugfs_unregister(q);
|
|
||||||
|
|
||||||
bioset_exit(&q->bio_split);
|
bioset_exit(&q->bio_split);
|
||||||
|
|
||||||
if (blk_queue_has_srcu(q))
|
if (blk_queue_has_srcu(q))
|
||||||
@ -836,17 +828,16 @@ int blk_register_queue(struct gendisk *disk)
|
|||||||
goto unlock;
|
goto unlock;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (queue_is_mq(q))
|
||||||
|
__blk_mq_register_dev(dev, q);
|
||||||
|
mutex_lock(&q->sysfs_lock);
|
||||||
|
|
||||||
mutex_lock(&q->debugfs_mutex);
|
mutex_lock(&q->debugfs_mutex);
|
||||||
q->debugfs_dir = debugfs_create_dir(kobject_name(q->kobj.parent),
|
q->debugfs_dir = debugfs_create_dir(kobject_name(q->kobj.parent),
|
||||||
blk_debugfs_root);
|
blk_debugfs_root);
|
||||||
mutex_unlock(&q->debugfs_mutex);
|
if (queue_is_mq(q))
|
||||||
|
|
||||||
if (queue_is_mq(q)) {
|
|
||||||
__blk_mq_register_dev(dev, q);
|
|
||||||
blk_mq_debugfs_register(q);
|
blk_mq_debugfs_register(q);
|
||||||
}
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
|
||||||
mutex_lock(&q->sysfs_lock);
|
|
||||||
|
|
||||||
ret = disk_register_independent_access_ranges(disk, NULL);
|
ret = disk_register_independent_access_ranges(disk, NULL);
|
||||||
if (ret)
|
if (ret)
|
||||||
@ -948,8 +939,15 @@ void blk_unregister_queue(struct gendisk *disk)
|
|||||||
/* Now that we've deleted all child objects, we can delete the queue. */
|
/* Now that we've deleted all child objects, we can delete the queue. */
|
||||||
kobject_uevent(&q->kobj, KOBJ_REMOVE);
|
kobject_uevent(&q->kobj, KOBJ_REMOVE);
|
||||||
kobject_del(&q->kobj);
|
kobject_del(&q->kobj);
|
||||||
|
|
||||||
mutex_unlock(&q->sysfs_dir_lock);
|
mutex_unlock(&q->sysfs_dir_lock);
|
||||||
|
|
||||||
|
mutex_lock(&q->debugfs_mutex);
|
||||||
|
blk_trace_shutdown(q);
|
||||||
|
debugfs_remove_recursive(q->debugfs_dir);
|
||||||
|
q->debugfs_dir = NULL;
|
||||||
|
q->sched_debugfs_dir = NULL;
|
||||||
|
q->rqos_debugfs_dir = NULL;
|
||||||
|
mutex_unlock(&q->debugfs_mutex);
|
||||||
|
|
||||||
kobject_put(&disk_to_dev(disk)->kobj);
|
kobject_put(&disk_to_dev(disk)->kobj);
|
||||||
}
|
}
|
||||||
|
@ -623,6 +623,7 @@ void del_gendisk(struct gendisk *disk)
|
|||||||
* Prevent new I/O from crossing bio_queue_enter().
|
* Prevent new I/O from crossing bio_queue_enter().
|
||||||
*/
|
*/
|
||||||
blk_queue_start_drain(q);
|
blk_queue_start_drain(q);
|
||||||
|
blk_mq_freeze_queue_wait(q);
|
||||||
|
|
||||||
if (!(disk->flags & GENHD_FL_HIDDEN)) {
|
if (!(disk->flags & GENHD_FL_HIDDEN)) {
|
||||||
sysfs_remove_link(&disk_to_dev(disk)->kobj, "bdi");
|
sysfs_remove_link(&disk_to_dev(disk)->kobj, "bdi");
|
||||||
@ -646,12 +647,21 @@ void del_gendisk(struct gendisk *disk)
|
|||||||
pm_runtime_set_memalloc_noio(disk_to_dev(disk), false);
|
pm_runtime_set_memalloc_noio(disk_to_dev(disk), false);
|
||||||
device_del(disk_to_dev(disk));
|
device_del(disk_to_dev(disk));
|
||||||
|
|
||||||
blk_mq_freeze_queue_wait(q);
|
|
||||||
|
|
||||||
blk_throtl_cancel_bios(disk->queue);
|
blk_throtl_cancel_bios(disk->queue);
|
||||||
|
|
||||||
blk_sync_queue(q);
|
blk_sync_queue(q);
|
||||||
blk_flush_integrity();
|
blk_flush_integrity();
|
||||||
|
blk_mq_cancel_work_sync(q);
|
||||||
|
|
||||||
|
blk_mq_quiesce_queue(q);
|
||||||
|
if (q->elevator) {
|
||||||
|
mutex_lock(&q->sysfs_lock);
|
||||||
|
elevator_exit(q);
|
||||||
|
mutex_unlock(&q->sysfs_lock);
|
||||||
|
}
|
||||||
|
rq_qos_exit(q);
|
||||||
|
blk_mq_unquiesce_queue(q);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Allow using passthrough request again after the queue is torn down.
|
* Allow using passthrough request again after the queue is torn down.
|
||||||
*/
|
*/
|
||||||
@ -1120,31 +1130,6 @@ static const struct attribute_group *disk_attr_groups[] = {
|
|||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
|
||||||
static void disk_release_mq(struct request_queue *q)
|
|
||||||
{
|
|
||||||
blk_mq_cancel_work_sync(q);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* There can't be any non non-passthrough bios in flight here, but
|
|
||||||
* requests stay around longer, including passthrough ones so we
|
|
||||||
* still need to freeze the queue here.
|
|
||||||
*/
|
|
||||||
blk_mq_freeze_queue(q);
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Since the I/O scheduler exit code may access cgroup information,
|
|
||||||
* perform I/O scheduler exit before disassociating from the block
|
|
||||||
* cgroup controller.
|
|
||||||
*/
|
|
||||||
if (q->elevator) {
|
|
||||||
mutex_lock(&q->sysfs_lock);
|
|
||||||
elevator_exit(q);
|
|
||||||
mutex_unlock(&q->sysfs_lock);
|
|
||||||
}
|
|
||||||
rq_qos_exit(q);
|
|
||||||
__blk_mq_unfreeze_queue(q, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* disk_release - releases all allocated resources of the gendisk
|
* disk_release - releases all allocated resources of the gendisk
|
||||||
* @dev: the device representing this disk
|
* @dev: the device representing this disk
|
||||||
@ -1166,9 +1151,6 @@ static void disk_release(struct device *dev)
|
|||||||
might_sleep();
|
might_sleep();
|
||||||
WARN_ON_ONCE(disk_live(disk));
|
WARN_ON_ONCE(disk_live(disk));
|
||||||
|
|
||||||
if (queue_is_mq(disk->queue))
|
|
||||||
disk_release_mq(disk->queue);
|
|
||||||
|
|
||||||
blkcg_exit_queue(disk->queue);
|
blkcg_exit_queue(disk->queue);
|
||||||
|
|
||||||
disk_release_events(disk);
|
disk_release_events(disk);
|
||||||
|
@ -79,10 +79,6 @@ int bd_link_disk_holder(struct block_device *bdev, struct gendisk *disk)
|
|||||||
|
|
||||||
WARN_ON_ONCE(!bdev->bd_holder);
|
WARN_ON_ONCE(!bdev->bd_holder);
|
||||||
|
|
||||||
/* FIXME: remove the following once add_disk() handles errors */
|
|
||||||
if (WARN_ON(!bdev->bd_holder_dir))
|
|
||||||
goto out_unlock;
|
|
||||||
|
|
||||||
holder = bd_find_holder_disk(bdev, disk);
|
holder = bd_find_holder_disk(bdev, disk);
|
||||||
if (holder) {
|
if (holder) {
|
||||||
holder->refcnt++;
|
holder->refcnt++;
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
# Makefile for the linux kernel signature checking certificates.
|
# Makefile for the linux kernel signature checking certificates.
|
||||||
#
|
#
|
||||||
|
|
||||||
obj-$(CONFIG_SYSTEM_TRUSTED_KEYRING) += system_keyring.o system_certificates.o common.o
|
obj-$(CONFIG_SYSTEM_TRUSTED_KEYRING) += system_keyring.o system_certificates.o
|
||||||
obj-$(CONFIG_SYSTEM_BLACKLIST_KEYRING) += blacklist.o common.o
|
obj-$(CONFIG_SYSTEM_BLACKLIST_KEYRING) += blacklist.o
|
||||||
obj-$(CONFIG_SYSTEM_REVOCATION_LIST) += revocation_certificates.o
|
obj-$(CONFIG_SYSTEM_REVOCATION_LIST) += revocation_certificates.o
|
||||||
ifneq ($(CONFIG_SYSTEM_BLACKLIST_HASH_LIST),)
|
ifneq ($(CONFIG_SYSTEM_BLACKLIST_HASH_LIST),)
|
||||||
|
|
||||||
|
@ -15,10 +15,9 @@
|
|||||||
#include <linux/err.h>
|
#include <linux/err.h>
|
||||||
#include <linux/seq_file.h>
|
#include <linux/seq_file.h>
|
||||||
#include <linux/uidgid.h>
|
#include <linux/uidgid.h>
|
||||||
#include <linux/verification.h>
|
#include <keys/asymmetric-type.h>
|
||||||
#include <keys/system_keyring.h>
|
#include <keys/system_keyring.h>
|
||||||
#include "blacklist.h"
|
#include "blacklist.h"
|
||||||
#include "common.h"
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* According to crypto/asymmetric_keys/x509_cert_parser.c:x509_note_pkey_algo(),
|
* According to crypto/asymmetric_keys/x509_cert_parser.c:x509_note_pkey_algo(),
|
||||||
@ -365,8 +364,9 @@ static __init int load_revocation_certificate_list(void)
|
|||||||
if (revocation_certificate_list_size)
|
if (revocation_certificate_list_size)
|
||||||
pr_notice("Loading compiled-in revocation X.509 certificates\n");
|
pr_notice("Loading compiled-in revocation X.509 certificates\n");
|
||||||
|
|
||||||
return load_certificate_list(revocation_certificate_list, revocation_certificate_list_size,
|
return x509_load_certificate_list(revocation_certificate_list,
|
||||||
blacklist_keyring);
|
revocation_certificate_list_size,
|
||||||
|
blacklist_keyring);
|
||||||
}
|
}
|
||||||
late_initcall(load_revocation_certificate_list);
|
late_initcall(load_revocation_certificate_list);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
/* SPDX-License-Identifier: GPL-2.0-or-later */
|
|
||||||
|
|
||||||
#ifndef _CERT_COMMON_H
|
|
||||||
#define _CERT_COMMON_H
|
|
||||||
|
|
||||||
int load_certificate_list(const u8 cert_list[], const unsigned long list_size,
|
|
||||||
const struct key *keyring);
|
|
||||||
|
|
||||||
#endif
|
|
@ -16,7 +16,6 @@
|
|||||||
#include <keys/asymmetric-type.h>
|
#include <keys/asymmetric-type.h>
|
||||||
#include <keys/system_keyring.h>
|
#include <keys/system_keyring.h>
|
||||||
#include <crypto/pkcs7.h>
|
#include <crypto/pkcs7.h>
|
||||||
#include "common.h"
|
|
||||||
|
|
||||||
static struct key *builtin_trusted_keys;
|
static struct key *builtin_trusted_keys;
|
||||||
#ifdef CONFIG_SECONDARY_TRUSTED_KEYRING
|
#ifdef CONFIG_SECONDARY_TRUSTED_KEYRING
|
||||||
@ -183,7 +182,8 @@ __init int load_module_cert(struct key *keyring)
|
|||||||
|
|
||||||
pr_notice("Loading compiled-in module X.509 certificates\n");
|
pr_notice("Loading compiled-in module X.509 certificates\n");
|
||||||
|
|
||||||
return load_certificate_list(system_certificate_list, module_cert_size, keyring);
|
return x509_load_certificate_list(system_certificate_list,
|
||||||
|
module_cert_size, keyring);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -204,7 +204,7 @@ static __init int load_system_certificate_list(void)
|
|||||||
size = system_certificate_list_size - module_cert_size;
|
size = system_certificate_list_size - module_cert_size;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return load_certificate_list(p, size, builtin_trusted_keys);
|
return x509_load_certificate_list(p, size, builtin_trusted_keys);
|
||||||
}
|
}
|
||||||
late_initcall(load_system_certificate_list);
|
late_initcall(load_system_certificate_list);
|
||||||
|
|
||||||
|
@ -75,4 +75,14 @@ config SIGNED_PE_FILE_VERIFICATION
|
|||||||
This option provides support for verifying the signature(s) on a
|
This option provides support for verifying the signature(s) on a
|
||||||
signed PE binary.
|
signed PE binary.
|
||||||
|
|
||||||
|
config FIPS_SIGNATURE_SELFTEST
|
||||||
|
bool "Run FIPS selftests on the X.509+PKCS7 signature verification"
|
||||||
|
help
|
||||||
|
This option causes some selftests to be run on the signature
|
||||||
|
verification code, using some built in data. This is required
|
||||||
|
for FIPS.
|
||||||
|
depends on KEYS
|
||||||
|
depends on ASYMMETRIC_KEY_TYPE
|
||||||
|
depends on PKCS7_MESSAGE_PARSER
|
||||||
|
|
||||||
endif # ASYMMETRIC_KEY_TYPE
|
endif # ASYMMETRIC_KEY_TYPE
|
||||||
|
@ -20,7 +20,9 @@ x509_key_parser-y := \
|
|||||||
x509.asn1.o \
|
x509.asn1.o \
|
||||||
x509_akid.asn1.o \
|
x509_akid.asn1.o \
|
||||||
x509_cert_parser.o \
|
x509_cert_parser.o \
|
||||||
|
x509_loader.o \
|
||||||
x509_public_key.o
|
x509_public_key.o
|
||||||
|
x509_key_parser-$(CONFIG_FIPS_SIGNATURE_SELFTEST) += selftest.o
|
||||||
|
|
||||||
$(obj)/x509_cert_parser.o: \
|
$(obj)/x509_cert_parser.o: \
|
||||||
$(obj)/x509.asn1.h \
|
$(obj)/x509.asn1.h \
|
||||||
|
224
crypto/asymmetric_keys/selftest.c
Normal file
224
crypto/asymmetric_keys/selftest.c
Normal file
@ -0,0 +1,224 @@
|
|||||||
|
/* Self-testing for signature checking.
|
||||||
|
*
|
||||||
|
* Copyright (C) 2022 Red Hat, Inc. All Rights Reserved.
|
||||||
|
* Written by David Howells (dhowells@redhat.com)
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include <linux/kernel.h>
|
||||||
|
#include <linux/cred.h>
|
||||||
|
#include <linux/key.h>
|
||||||
|
#include <crypto/pkcs7.h>
|
||||||
|
#include "x509_parser.h"
|
||||||
|
|
||||||
|
struct certs_test {
|
||||||
|
const u8 *data;
|
||||||
|
size_t data_len;
|
||||||
|
const u8 *pkcs7;
|
||||||
|
size_t pkcs7_len;
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Set of X.509 certificates to provide public keys for the tests. These will
|
||||||
|
* be loaded into a temporary keyring for the duration of the testing.
|
||||||
|
*/
|
||||||
|
static const __initconst u8 certs_selftest_keys[] = {
|
||||||
|
"\x30\x82\x05\x55\x30\x82\x03\x3d\xa0\x03\x02\x01\x02\x02\x14\x73"
|
||||||
|
"\x98\xea\x98\x2d\xd0\x2e\xa8\xb1\xcf\x57\xc7\xf2\x97\xb3\xe6\x1a"
|
||||||
|
"\xfc\x8c\x0a\x30\x0d\x06\x09\x2a\x86\x48\x86\xf7\x0d\x01\x01\x0b"
|
||||||
|
"\x05\x00\x30\x34\x31\x32\x30\x30\x06\x03\x55\x04\x03\x0c\x29\x43"
|
||||||
|
"\x65\x72\x74\x69\x66\x69\x63\x61\x74\x65\x20\x76\x65\x72\x69\x66"
|
||||||
|
"\x69\x63\x61\x74\x69\x6f\x6e\x20\x73\x65\x6c\x66\x2d\x74\x65\x73"
|
||||||
|
"\x74\x69\x6e\x67\x20\x6b\x65\x79\x30\x20\x17\x0d\x32\x32\x30\x35"
|
||||||
|
"\x31\x38\x32\x32\x33\x32\x34\x31\x5a\x18\x0f\x32\x31\x32\x32\x30"
|
||||||
|
"\x34\x32\x34\x32\x32\x33\x32\x34\x31\x5a\x30\x34\x31\x32\x30\x30"
|
||||||
|
"\x06\x03\x55\x04\x03\x0c\x29\x43\x65\x72\x74\x69\x66\x69\x63\x61"
|
||||||
|
"\x74\x65\x20\x76\x65\x72\x69\x66\x69\x63\x61\x74\x69\x6f\x6e\x20"
|
||||||
|
"\x73\x65\x6c\x66\x2d\x74\x65\x73\x74\x69\x6e\x67\x20\x6b\x65\x79"
|
||||||
|
"\x30\x82\x02\x22\x30\x0d\x06\x09\x2a\x86\x48\x86\xf7\x0d\x01\x01"
|
||||||
|
"\x01\x05\x00\x03\x82\x02\x0f\x00\x30\x82\x02\x0a\x02\x82\x02\x01"
|
||||||
|
"\x00\xcc\xac\x49\xdd\x3b\xca\xb0\x15\x7e\x84\x6a\xb2\x0a\x69\x5f"
|
||||||
|
"\x1c\x0a\x61\x82\x3b\x4f\x2c\xa3\x95\x2c\x08\x58\x4b\xb1\x5d\x99"
|
||||||
|
"\xe0\xc3\xc1\x79\xc2\xb3\xeb\xc0\x1e\x6d\x3e\x54\x1d\xbd\xb7\x92"
|
||||||
|
"\x7b\x4d\xb5\x95\x58\xb2\x52\x2e\xc6\x24\x4b\x71\x63\x80\x32\x77"
|
||||||
|
"\xa7\x38\x5e\xdb\x72\xae\x6e\x0d\xec\xfb\xb6\x6d\x01\x7f\xe9\x55"
|
||||||
|
"\x66\xdf\xbf\x1d\x76\x78\x02\x31\xe8\xe5\x07\xf8\xb7\x82\x5c\x0d"
|
||||||
|
"\xd4\xbb\xfb\xa2\x59\x0d\x2e\x3a\x78\x95\x3a\x8b\x46\x06\x47\x44"
|
||||||
|
"\x46\xd7\xcd\x06\x6a\x41\x13\xe3\x19\xf6\xbb\x6e\x38\xf4\x83\x01"
|
||||||
|
"\xa3\xbf\x4a\x39\x4f\xd7\x0a\xe9\x38\xb3\xf5\x94\x14\x4e\xdd\xf7"
|
||||||
|
"\x43\xfd\x24\xb2\x49\x3c\xa5\xf7\x7a\x7c\xd4\x45\x3d\x97\x75\x68"
|
||||||
|
"\xf1\xed\x4c\x42\x0b\x70\xca\x85\xf3\xde\xe5\x88\x2c\xc5\xbe\xb6"
|
||||||
|
"\x97\x34\xba\x24\x02\xcd\x8b\x86\x9f\xa9\x73\xca\x73\xcf\x92\x81"
|
||||||
|
"\xee\x75\x55\xbb\x18\x67\x5c\xff\x3f\xb5\xdd\x33\x1b\x0c\xe9\x78"
|
||||||
|
"\xdb\x5c\xcf\xaa\x5c\x43\x42\xdf\x5e\xa9\x6d\xec\xd7\xd7\xff\xe6"
|
||||||
|
"\xa1\x3a\x92\x1a\xda\xae\xf6\x8c\x6f\x7b\xd5\xb4\x6e\x06\xe9\x8f"
|
||||||
|
"\xe8\xde\x09\x31\x89\xed\x0e\x11\xa1\xfa\x8a\xe9\xe9\x64\x59\x62"
|
||||||
|
"\x53\xda\xd1\x70\xbe\x11\xd4\x99\x97\x11\xcf\x99\xde\x0b\x9d\x94"
|
||||||
|
"\x7e\xaa\xb8\x52\xea\x37\xdb\x90\x7e\x35\xbd\xd9\xfe\x6d\x0a\x48"
|
||||||
|
"\x70\x28\xdd\xd5\x0d\x7f\x03\x80\x93\x14\x23\x8f\xb9\x22\xcd\x7c"
|
||||||
|
"\x29\xfe\xf1\x72\xb5\x5c\x0b\x12\xcf\x9c\x15\xf6\x11\x4c\x7a\x45"
|
||||||
|
"\x25\x8c\x45\x0a\x34\xac\x2d\x9a\x81\xca\x0b\x13\x22\xcd\xeb\x1a"
|
||||||
|
"\x38\x88\x18\x97\x96\x08\x81\xaa\xcc\x8f\x0f\x8a\x32\x7b\x76\x68"
|
||||||
|
"\x03\x68\x43\xbf\x11\xba\x55\x60\xfd\x80\x1c\x0d\x9b\x69\xb6\x09"
|
||||||
|
"\x72\xbc\x0f\x41\x2f\x07\x82\xc6\xe3\xb2\x13\x91\xc4\x6d\x14\x95"
|
||||||
|
"\x31\xbe\x19\xbd\xbc\xed\xe1\x4c\x74\xa2\xe0\x78\x0b\xbb\x94\xec"
|
||||||
|
"\x4c\x53\x3a\xa2\xb5\x84\x1d\x4b\x65\x7e\xdc\xf7\xdb\x36\x7d\xbe"
|
||||||
|
"\x9e\x3b\x36\x66\x42\x66\x76\x35\xbf\xbe\xf0\xc1\x3c\x7c\xe9\x42"
|
||||||
|
"\x5c\x24\x53\x03\x05\xa8\x67\x24\x50\x02\x75\xff\x24\x46\x3b\x35"
|
||||||
|
"\x89\x76\xe6\x70\xda\xc5\x51\x8c\x9a\xe5\x05\xb0\x0b\xd0\x2d\xd4"
|
||||||
|
"\x7d\x57\x75\x94\x6b\xf9\x0a\xad\x0e\x41\x00\x15\xd0\x4f\xc0\x7f"
|
||||||
|
"\x90\x2d\x18\x48\x8f\x28\xfe\x5d\xa7\xcd\x99\x9e\xbd\x02\x6c\x8a"
|
||||||
|
"\x31\xf3\x1c\xc7\x4b\xe6\x93\xcd\x42\xa2\xe4\x68\x10\x47\x9d\xfc"
|
||||||
|
"\x21\x02\x03\x01\x00\x01\xa3\x5d\x30\x5b\x30\x0c\x06\x03\x55\x1d"
|
||||||
|
"\x13\x01\x01\xff\x04\x02\x30\x00\x30\x0b\x06\x03\x55\x1d\x0f\x04"
|
||||||
|
"\x04\x03\x02\x07\x80\x30\x1d\x06\x03\x55\x1d\x0e\x04\x16\x04\x14"
|
||||||
|
"\xf5\x87\x03\xbb\x33\xce\x1b\x73\xee\x02\xec\xcd\xee\x5b\x88\x17"
|
||||||
|
"\x51\x8f\xe3\xdb\x30\x1f\x06\x03\x55\x1d\x23\x04\x18\x30\x16\x80"
|
||||||
|
"\x14\xf5\x87\x03\xbb\x33\xce\x1b\x73\xee\x02\xec\xcd\xee\x5b\x88"
|
||||||
|
"\x17\x51\x8f\xe3\xdb\x30\x0d\x06\x09\x2a\x86\x48\x86\xf7\x0d\x01"
|
||||||
|
"\x01\x0b\x05\x00\x03\x82\x02\x01\x00\xc0\x2e\x12\x41\x7b\x73\x85"
|
||||||
|
"\x16\xc8\xdb\x86\x79\xe8\xf5\xcd\x44\xf4\xc6\xe2\x81\x23\x5e\x47"
|
||||||
|
"\xcb\xab\x25\xf1\x1e\x58\x3e\x31\x7f\x78\xad\x85\xeb\xfe\x14\x88"
|
||||||
|
"\x60\xf7\x7f\xd2\x26\xa2\xf4\x98\x2a\xfd\xba\x05\x0c\x20\x33\x12"
|
||||||
|
"\xcc\x4d\x14\x61\x64\x81\x93\xd3\x33\xed\xc8\xff\xf1\x78\xcc\x5f"
|
||||||
|
"\x51\x9f\x09\xd7\xbe\x0d\x5c\x74\xfd\x9b\xdf\x52\x4a\xc9\xa8\x71"
|
||||||
|
"\x25\x33\x04\x10\x67\x36\xd0\xb3\x0b\xc9\xa1\x40\x72\xae\x41\x7b"
|
||||||
|
"\x68\xe6\xe4\x7b\xd0\x28\xf7\x6d\xe7\x3f\x50\xfc\x91\x7c\x91\x56"
|
||||||
|
"\xd4\xdf\xa6\xbb\xe8\x4d\x1b\x58\xaa\x28\xfa\xc1\x19\xeb\x11\x2f"
|
||||||
|
"\x24\x8b\x7c\xc5\xa9\x86\x26\xaa\x6e\xb7\x9b\xd5\xf8\x06\xfb\x02"
|
||||||
|
"\x52\x7b\x9c\x9e\xa1\xe0\x07\x8b\x5e\xe4\xb8\x55\x29\xf6\x48\x52"
|
||||||
|
"\x1c\x1b\x54\x2d\x46\xd8\xe5\x71\xb9\x60\xd1\x45\xb5\x92\x89\x8a"
|
||||||
|
"\x63\x58\x2a\xb3\xc6\xb2\x76\xe2\x3c\x82\x59\x04\xae\x5a\xc4\x99"
|
||||||
|
"\x7b\x2e\x4b\x46\x57\xb8\x29\x24\xb2\xfd\xee\x2c\x0d\xa4\x83\xfa"
|
||||||
|
"\x65\x2a\x07\x35\x8b\x97\xcf\xbd\x96\x2e\xd1\x7e\x6c\xc2\x1e\x87"
|
||||||
|
"\xb6\x6c\x76\x65\xb5\xb2\x62\xda\x8b\xe9\x73\xe3\xdb\x33\xdd\x13"
|
||||||
|
"\x3a\x17\x63\x6a\x76\xde\x8d\x8f\xe0\x47\x61\x28\x3a\x83\xff\x8f"
|
||||||
|
"\xe7\xc7\xe0\x4a\xa3\xe5\x07\xcf\xe9\x8c\x35\x35\x2e\xe7\x80\x66"
|
||||||
|
"\x31\xbf\x91\x58\x0a\xe1\x25\x3d\x38\xd3\xa4\xf0\x59\x34\x47\x07"
|
||||||
|
"\x62\x0f\xbe\x30\xdd\x81\x88\x58\xf0\x28\xb0\x96\xe5\x82\xf8\x05"
|
||||||
|
"\xb7\x13\x01\xbc\xfa\xc6\x1f\x86\x72\xcc\xf9\xee\x8e\xd9\xd6\x04"
|
||||||
|
"\x8c\x24\x6c\xbf\x0f\x5d\x37\x39\xcf\x45\xc1\x93\x3a\xd2\xed\x5c"
|
||||||
|
"\x58\x79\x74\x86\x62\x30\x7e\x8e\xbb\xdd\x7a\xa9\xed\xca\x40\xcb"
|
||||||
|
"\x62\x47\xf4\xb4\x9f\x52\x7f\x72\x63\xa8\xf0\x2b\xaf\x45\x2a\x48"
|
||||||
|
"\x19\x6d\xe3\xfb\xf9\x19\x66\x69\xc8\xcc\x62\x87\x6c\x53\x2b\x2d"
|
||||||
|
"\x6e\x90\x6c\x54\x3a\x82\x25\x41\xcb\x18\x6a\xa4\x22\xa8\xa1\xc4"
|
||||||
|
"\x47\xd7\x81\x00\x1c\x15\x51\x0f\x1a\xaf\xef\x9f\xa6\x61\x8c\xbd"
|
||||||
|
"\x6b\x8b\xed\xe6\xac\x0e\xb6\x3a\x4c\x92\xe6\x0f\x91\x0a\x0f\x71"
|
||||||
|
"\xc7\xa0\xb9\x0d\x3a\x17\x5a\x6f\x35\xc8\xe7\x50\x4f\x46\xe8\x70"
|
||||||
|
"\x60\x48\x06\x82\x8b\x66\x58\xe6\x73\x91\x9c\x12\x3d\x35\x8e\x46"
|
||||||
|
"\xad\x5a\xf5\xb3\xdb\x69\x21\x04\xfd\xd3\x1c\xdf\x94\x9d\x56\xb0"
|
||||||
|
"\x0a\xd1\x95\x76\x8d\xec\x9e\xdd\x0b\x15\x97\x64\xad\xe5\xf2\x62"
|
||||||
|
"\x02\xfc\x9e\x5f\x56\x42\x39\x05\xb3"
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Signed data and detached signature blobs that form the verification tests.
|
||||||
|
*/
|
||||||
|
static const __initconst u8 certs_selftest_1_data[] = {
|
||||||
|
"\x54\x68\x69\x73\x20\x69\x73\x20\x73\x6f\x6d\x65\x20\x74\x65\x73"
|
||||||
|
"\x74\x20\x64\x61\x74\x61\x20\x75\x73\x65\x64\x20\x66\x6f\x72\x20"
|
||||||
|
"\x73\x65\x6c\x66\x2d\x74\x65\x73\x74\x69\x6e\x67\x20\x63\x65\x72"
|
||||||
|
"\x74\x69\x66\x69\x63\x61\x74\x65\x20\x76\x65\x72\x69\x66\x69\x63"
|
||||||
|
"\x61\x74\x69\x6f\x6e\x2e\x0a"
|
||||||
|
};
|
||||||
|
|
||||||
|
static const __initconst u8 certs_selftest_1_pkcs7[] = {
|
||||||
|
"\x30\x82\x02\xab\x06\x09\x2a\x86\x48\x86\xf7\x0d\x01\x07\x02\xa0"
|
||||||
|
"\x82\x02\x9c\x30\x82\x02\x98\x02\x01\x01\x31\x0d\x30\x0b\x06\x09"
|
||||||
|
"\x60\x86\x48\x01\x65\x03\x04\x02\x01\x30\x0b\x06\x09\x2a\x86\x48"
|
||||||
|
"\x86\xf7\x0d\x01\x07\x01\x31\x82\x02\x75\x30\x82\x02\x71\x02\x01"
|
||||||
|
"\x01\x30\x4c\x30\x34\x31\x32\x30\x30\x06\x03\x55\x04\x03\x0c\x29"
|
||||||
|
"\x43\x65\x72\x74\x69\x66\x69\x63\x61\x74\x65\x20\x76\x65\x72\x69"
|
||||||
|
"\x66\x69\x63\x61\x74\x69\x6f\x6e\x20\x73\x65\x6c\x66\x2d\x74\x65"
|
||||||
|
"\x73\x74\x69\x6e\x67\x20\x6b\x65\x79\x02\x14\x73\x98\xea\x98\x2d"
|
||||||
|
"\xd0\x2e\xa8\xb1\xcf\x57\xc7\xf2\x97\xb3\xe6\x1a\xfc\x8c\x0a\x30"
|
||||||
|
"\x0b\x06\x09\x60\x86\x48\x01\x65\x03\x04\x02\x01\x30\x0d\x06\x09"
|
||||||
|
"\x2a\x86\x48\x86\xf7\x0d\x01\x01\x01\x05\x00\x04\x82\x02\x00\xac"
|
||||||
|
"\xb0\xf2\x07\xd6\x99\x6d\xc0\xc0\xd9\x8d\x31\x0d\x7e\x04\xeb\xc3"
|
||||||
|
"\x88\x90\xc4\x58\x46\xd4\xe2\xa0\xa3\x25\xe3\x04\x50\x37\x85\x8c"
|
||||||
|
"\x91\xc6\xfc\xc5\xd4\x92\xfd\x05\xd8\xb8\xa3\xb8\xba\x89\x13\x00"
|
||||||
|
"\x88\x79\x99\x51\x6b\x5b\x28\x31\xc0\xb3\x1b\x7a\x68\x2c\x00\xdb"
|
||||||
|
"\x4b\x46\x11\xf3\xfa\x50\x8e\x19\x89\xa2\x4c\xda\x4c\x89\x01\x11"
|
||||||
|
"\x89\xee\xd3\xc8\xc1\xe7\xa7\xf6\xb2\xa2\xf8\x65\xb8\x35\x20\x33"
|
||||||
|
"\xba\x12\x62\xd5\xbd\xaa\x71\xe5\x5b\xc0\x6a\x32\xff\x6a\x2e\x23"
|
||||||
|
"\xef\x2b\xb6\x58\xb1\xfb\x5f\x82\x34\x40\x6d\x9f\xbc\x27\xac\x37"
|
||||||
|
"\x23\x99\xcf\x7d\x20\xb2\x39\x01\xc0\x12\xce\xd7\x5d\x2f\xb6\xab"
|
||||||
|
"\xb5\x56\x4f\xef\xf4\x72\x07\x58\x65\xa9\xeb\x1f\x75\x1c\x5f\x0c"
|
||||||
|
"\x88\xe0\xa4\xe2\xcd\x73\x2b\x9e\xb2\x05\x7e\x12\xf8\xd0\x66\x41"
|
||||||
|
"\xcc\x12\x63\xd4\xd6\xac\x9b\x1d\x14\x77\x8d\x1c\x57\xd5\x27\xc6"
|
||||||
|
"\x49\xa2\x41\x43\xf3\x59\x29\xe5\xcb\xd1\x75\xbc\x3a\x97\x2a\x72"
|
||||||
|
"\x22\x66\xc5\x3b\xc1\xba\xfc\x53\x18\x98\xe2\x21\x64\xc6\x52\x87"
|
||||||
|
"\x13\xd5\x7c\x42\xe8\xfb\x9c\x9a\x45\x32\xd5\xa5\x22\x62\x9d\xd4"
|
||||||
|
"\xcb\xa4\xfa\x77\xbb\x50\x24\x0b\x8b\x88\x99\x15\x56\xa9\x1e\x92"
|
||||||
|
"\xbf\x5d\x94\x77\xb6\xf1\x67\x01\x60\x06\x58\x5c\xdf\x18\x52\x79"
|
||||||
|
"\x37\x30\x93\x7d\x87\x04\xf1\xe0\x55\x59\x52\xf3\xc2\xb1\x1c\x5b"
|
||||||
|
"\x12\x7c\x49\x87\xfb\xf7\xed\xdd\x95\x71\xec\x4b\x1a\x85\x08\xb0"
|
||||||
|
"\xa0\x36\xc4\x7b\xab\x40\xe0\xf1\x98\xcc\xaf\x19\x40\x8f\x47\x6f"
|
||||||
|
"\xf0\x6c\x84\x29\x7f\x7f\x04\x46\xcb\x08\x0f\xe0\xc1\xc9\x70\x6e"
|
||||||
|
"\x95\x3b\xa4\xbc\x29\x2b\x53\x67\x45\x1b\x0d\xbc\x13\xa5\x76\x31"
|
||||||
|
"\xaf\xb9\xd0\xe0\x60\x12\xd2\xf4\xb7\x7c\x58\x7e\xf6\x2d\xbb\x24"
|
||||||
|
"\x14\x5a\x20\x24\xa8\x12\xdf\x25\xbd\x42\xce\x96\x7c\x2e\xba\x14"
|
||||||
|
"\x1b\x81\x9f\x18\x45\xa4\xc6\x70\x3e\x0e\xf0\xd3\x7b\x9c\x10\xbe"
|
||||||
|
"\xb8\x7a\x89\xc5\x9e\xd9\x97\xdf\xd7\xe7\xc6\x1d\xc0\x20\x6c\xb8"
|
||||||
|
"\x1e\x3a\x63\xb8\x39\x8e\x8e\x62\xd5\xd2\xb4\xcd\xff\x46\xfc\x8e"
|
||||||
|
"\xec\x07\x35\x0c\xff\xb0\x05\xe6\xf4\xe5\xfe\xa2\xe3\x0a\xe6\x36"
|
||||||
|
"\xa7\x4a\x7e\x62\x1d\xc4\x50\x39\x35\x4e\x28\xcb\x4a\xfb\x9d\xdb"
|
||||||
|
"\xdd\x23\xd6\x53\xb1\x74\x77\x12\xf7\x9c\xf0\x9a\x6b\xf7\xa9\x64"
|
||||||
|
"\x2d\x86\x21\x2a\xcf\xc6\x54\xf5\xc9\xad\xfa\xb5\x12\xb4\xf3\x51"
|
||||||
|
"\x77\x55\x3c\x6f\x0c\x32\xd3\x8c\x44\x39\x71\x25\xfe\x96\xd2"
|
||||||
|
};
|
||||||
|
|
||||||
|
/*
|
||||||
|
* List of tests to be run.
|
||||||
|
*/
|
||||||
|
#define TEST(data, pkcs7) { data, sizeof(data) - 1, pkcs7, sizeof(pkcs7) - 1 }
|
||||||
|
static const struct certs_test certs_tests[] __initconst = {
|
||||||
|
TEST(certs_selftest_1_data, certs_selftest_1_pkcs7),
|
||||||
|
};
|
||||||
|
|
||||||
|
int __init fips_signature_selftest(void)
|
||||||
|
{
|
||||||
|
struct key *keyring;
|
||||||
|
int ret, i;
|
||||||
|
|
||||||
|
pr_notice("Running certificate verification selftests\n");
|
||||||
|
|
||||||
|
keyring = keyring_alloc(".certs_selftest",
|
||||||
|
GLOBAL_ROOT_UID, GLOBAL_ROOT_GID, current_cred(),
|
||||||
|
(KEY_POS_ALL & ~KEY_POS_SETATTR) |
|
||||||
|
KEY_USR_VIEW | KEY_USR_READ |
|
||||||
|
KEY_USR_SEARCH,
|
||||||
|
KEY_ALLOC_NOT_IN_QUOTA,
|
||||||
|
NULL, NULL);
|
||||||
|
if (IS_ERR(keyring))
|
||||||
|
panic("Can't allocate certs selftest keyring: %ld\n",
|
||||||
|
PTR_ERR(keyring));
|
||||||
|
|
||||||
|
ret = x509_load_certificate_list(certs_selftest_keys,
|
||||||
|
sizeof(certs_selftest_keys) - 1, keyring);
|
||||||
|
if (ret < 0)
|
||||||
|
panic("Can't allocate certs selftest keyring: %d\n", ret);
|
||||||
|
|
||||||
|
for (i = 0; i < ARRAY_SIZE(certs_tests); i++) {
|
||||||
|
const struct certs_test *test = &certs_tests[i];
|
||||||
|
struct pkcs7_message *pkcs7;
|
||||||
|
|
||||||
|
pkcs7 = pkcs7_parse_message(test->pkcs7, test->pkcs7_len);
|
||||||
|
if (IS_ERR(pkcs7))
|
||||||
|
panic("Certs selftest %d: pkcs7_parse_message() = %d\n", i, ret);
|
||||||
|
|
||||||
|
pkcs7_supply_detached_data(pkcs7, test->data, test->data_len);
|
||||||
|
|
||||||
|
ret = pkcs7_verify(pkcs7, VERIFYING_MODULE_SIGNATURE);
|
||||||
|
if (ret < 0)
|
||||||
|
panic("Certs selftest %d: pkcs7_verify() = %d\n", i, ret);
|
||||||
|
|
||||||
|
ret = pkcs7_validate_trust(pkcs7, keyring);
|
||||||
|
if (ret < 0)
|
||||||
|
panic("Certs selftest %d: pkcs7_validate_trust() = %d\n", i, ret);
|
||||||
|
|
||||||
|
pkcs7_free_message(pkcs7);
|
||||||
|
}
|
||||||
|
|
||||||
|
key_put(keyring);
|
||||||
|
return 0;
|
||||||
|
}
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user