platform/kernel/linux-starfive.git
23 months agoof: overlay: Simplify of_overlay_fdt_apply() tail
Geert Uytterhoeven [Fri, 15 Jul 2022 14:03:15 +0000 (16:03 +0200)]
of: overlay: Simplify of_overlay_fdt_apply() tail

It does not hurt to fill in the changeset id while the mutex is still
held.  After doing so, the function tails for the success and failure
cases become identical, so they can be unified.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Frank Rowand <frank.rowand@sony.com>
Tested-by: Frank Rowand <frank.rowand@sony.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/6a3357a8f7f29704350e3ffae768ee8a462b54d3.1657893306.git.geert+renesas@glider.be
23 months agoof: overlay: Move devicetree_corrupt() check up
Geert Uytterhoeven [Fri, 15 Jul 2022 14:03:14 +0000 (16:03 +0200)]
of: overlay: Move devicetree_corrupt() check up

There is no point in doing several preparatory steps in
of_overlay_fdt_apply(), only to see of_overlay_apply() return early
because of a corrupt device tree.

Move the check for a corrupt device tree from of_overlay_apply() to
of_overlay_fdt_apply(), to check for this as early as possible.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Frank Rowand <frank.rowand@sony.com>
Tested-by: Frank Rowand <frank.rowand@sony.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/c91ce7112eb5167ea46a43d8a980e76b920010ba.1657893306.git.geert+renesas@glider.be
23 months agodt-bindings: bus: qcom,ssc-block-bus: rework arrays and drop redundant minItems
Krzysztof Kozlowski [Tue, 12 Jul 2022 15:46:02 +0000 (17:46 +0200)]
dt-bindings: bus: qcom,ssc-block-bus: rework arrays and drop redundant minItems

There is no need to specify "minItems" if it equals to "maxItems".  On the
other hand number of items in an array can be specified via describing
items, which might bring some additional information.  This simplifies a
bit the binding.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220712154602.26994-1-krzysztof.kozlowski@linaro.org
23 months agoof: device: Fix missing of_node_put() in of_dma_set_restricted_buffer
Liang He [Sat, 2 Jul 2022 01:44:49 +0000 (09:44 +0800)]
of: device: Fix missing of_node_put() in of_dma_set_restricted_buffer

We should use of_node_put() for the reference 'node' returned by
of_parse_phandle() which will increase the refcount.

Fixes: fec9b625095f ("of: Add plumbing for restricted DMA pool")
Co-authored-by: Miaoqian Lin <linmq006@gmail.com>
Signed-off-by: Liang He <windhl@126.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220702014449.263772-1-windhl@126.com
23 months agoof: unittest: make unittest_gpio_remove() consistent with unittest_gpio_probe()
Andy Shevchenko [Fri, 8 Jul 2022 21:45:39 +0000 (00:45 +0300)]
of: unittest: make unittest_gpio_remove() consistent with unittest_gpio_probe()

On the ->remove() stage the callback uses physical device node instead of one
from GPIO chip and the variable name which is different to one used in
unittest_gpio_probe(). Make these consistent with unittest_gpio_probe().

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220708214539.7254-2-andriy.shevchenko@linux.intel.com
23 months agoof: unittest: Switch to use fwnode instead of of_node
Andy Shevchenko [Fri, 8 Jul 2022 21:45:38 +0000 (00:45 +0300)]
of: unittest: Switch to use fwnode instead of of_node

The OF node in the GPIO library is deprecated and soon will be removed.
GPIO library now accepts fwnode as a firmware node, so switch the module
to use it instead.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Bartosz Golaszewski <brgl@bgdev.pl>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220708214539.7254-1-andriy.shevchenko@linux.intel.com
23 months agodt-bindings: mtd/partitions: Convert arm-firmware-suite to DT schema
Rob Herring [Wed, 29 Jun 2022 18:50:30 +0000 (12:50 -0600)]
dt-bindings: mtd/partitions: Convert arm-firmware-suite to DT schema

Convert the arm,arm-firmware-suite partition binding to DT schema
format. Simple conversion as there's only a compatible property.

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20220629185031.23826-1-robh@kernel.org
23 months agodt-bindings: arm: cpus: add cortex-a78ae compatible
Chanho Park [Thu, 7 Jul 2022 08:27:53 +0000 (17:27 +0900)]
dt-bindings: arm: cpus: add cortex-a78ae compatible

Cortex A78AE's MPIDR has been added since
commit 83bea32ac7ed ("arm64: Add part number for Arm Cortex-A78AE")
We also need to add the compatible.

Signed-off-by: Chanho Park <chanho61.park@samsung.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220707082753.28862-1-chanho61.park@samsung.com
23 months agodt-bindings: arm: nvidia,tegra20-pmc: Move fixed string property names under 'properties'
Rob Herring [Wed, 6 Jul 2022 21:20:34 +0000 (15:20 -0600)]
dt-bindings: arm: nvidia,tegra20-pmc: Move fixed string property names under 'properties'

Fixed string property names should be under 'properties' rather than
'patternProperties'. Additionally, without beginning and end of line
anchors, any prefix or suffix is allowed on the specified property names.

As all the nvidia,tegra20-pmc powergates child node properties are fixed
strings, change 'patternProperties' to 'properties'.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Thierry Reding <treding@nvidia.com>
Link: https://lore.kernel.org/r/20220706212034.568861-1-robh@kernel.org
23 months agodt-bindings: hwinfo: samsung,s5pv210-chipid: add S5PV210 ChipID
Krzysztof Kozlowski [Tue, 5 Jul 2022 15:46:13 +0000 (17:46 +0200)]
dt-bindings: hwinfo: samsung,s5pv210-chipid: add S5PV210 ChipID

Document already used S5PV210 ChipID block.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220705154613.453096-2-krzysztof.kozlowski@linaro.org
23 months agodt-bindings: hwinfo: group Chip ID-like devices
Krzysztof Kozlowski [Tue, 5 Jul 2022 15:46:12 +0000 (17:46 +0200)]
dt-bindings: hwinfo: group Chip ID-like devices

Group devices like Chip ID or SoC information under "hwinfo" directory.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220705154613.453096-1-krzysztof.kozlowski@linaro.org
23 months agodt-bindings: watchdog: faraday: Fix typo in example 'timeout-sec' property
Rob Herring [Thu, 26 May 2022 01:41:27 +0000 (20:41 -0500)]
dt-bindings: watchdog: faraday: Fix typo in example 'timeout-sec' property

The 'unevaluatedProperties' schema checks is not fully working and doesn't
catch some cases where there's a $ref to another schema. A fix is pending,
but results in new warnings in examples.

The correct common watchdog property is 'timeout-sec', not 'timeout-secs'.

Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20220526014127.2872254-1-robh@kernel.org
23 months agodt-bindings: chosen: remove old .txt binding
Jason A. Donenfeld [Tue, 28 Jun 2022 15:33:54 +0000 (17:33 +0200)]
dt-bindings: chosen: remove old .txt binding

chosen.txt has been replaced by a schema in dtschema[1] and is now out
of date as well. Remove it to avoid confusion.

[1] https://github.com/devicetree-org/dt-schema/blob/main/dtschema/schemas/chosen.yaml

Link: https://lore.kernel.org/lkml/c8dddfe6-6385-ed34-e789-9f845c8a32bd@linaro.org/
Link: https://lore.kernel.org/lkml/CAL_Jsq+uSdk9YNbUW35yjN3q8-3FDobrxHmBpy=4RKmCfnB0KQ@mail.gmail.com/
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
[robh: Improve commmit msg]
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220628153354.870543-1-Jason@zx2c4.com
23 months agodt-bindings: connector: usb: align example indentation to four-space
Krzysztof Kozlowski [Fri, 24 Jun 2022 16:21:41 +0000 (18:21 +0200)]
dt-bindings: connector: usb: align example indentation to four-space

One DTS example was using 8-space indentation, while others 2-space.
For complex DTS with multiple levels, 2-space is not that readable and
in DTS examples 4-space is preferred.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220624162141.25890-1-krzysztof.kozlowski@linaro.org
23 months agodocs: dt: writing-bindings: Update URL to DT schemas
Paul Cercueil [Mon, 27 Jun 2022 22:39:50 +0000 (23:39 +0100)]
docs: dt: writing-bindings: Update URL to DT schemas

The previous URL was giving a 404 error.

Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220627223950.35748-1-paul@crapouillou.net
23 months agoMerge branch 'dt/linus' into dt/next
Rob Herring [Wed, 29 Jun 2022 21:11:43 +0000 (15:11 -0600)]
Merge branch 'dt/linus' into dt/next

Pull in the binding fixes so we don't have all the warnings.

23 months agomedia: dt-bindings: Convert gpio-ir-receiver to DT schema
Rob Herring [Mon, 6 Jun 2022 18:49:44 +0000 (13:49 -0500)]
media: dt-bindings: Convert gpio-ir-receiver to DT schema

Convert the gpio-ir-receiver binding to DT schema format.

Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220606184944.1067068-2-robh@kernel.org
23 months agomedia: dt-bindings: rc: Allow 'ir-receiver' node names
Rob Herring [Mon, 6 Jun 2022 18:49:43 +0000 (13:49 -0500)]
media: dt-bindings: rc: Allow 'ir-receiver' node names

Most existing 'gpio-ir-receiver' nodes use 'ir-receiver' for their node
name, so add it as an allowed node name.

Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220606184944.1067068-1-robh@kernel.org
23 months agodt-bindings: nfc: nxp,nci: drop Charles Gorand's mail
Michael Walle [Tue, 28 Jun 2022 07:09:59 +0000 (09:09 +0200)]
dt-bindings: nfc: nxp,nci: drop Charles Gorand's mail

Mails to Charles get an auto reply, that he is no longer working at
Eff'Innov technologies. Remove the entry.

Signed-off-by: Michael Walle <michael@walle.cc>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220628070959.187734-1-michael@walle.cc
23 months agodt-bindings: ata: ahci-ceva: convert to yaml
Piyush Mehta [Mon, 20 Jun 2022 07:37:17 +0000 (13:07 +0530)]
dt-bindings: ata: ahci-ceva: convert to yaml

Convert the ahci-ceva doc to yaml.

Signed-off-by: Piyush Mehta <piyush.mehta@xilinx.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220620073717.3079-1-piyush.mehta@xilinx.com
23 months agoof: reserved-memory: Print allocation/reservation failures as error
Vincent Whitchurch [Tue, 28 Jun 2022 11:35:40 +0000 (13:35 +0200)]
of: reserved-memory: Print allocation/reservation failures as error

If the allocation/reservation of reserved-memory fails, it is normally
an error, so print it as an error so that it doesn't get hidden from the
console due to the loglevel.  Also make the allocation failure include
the size just like the reservation failure.

Signed-off-by: Vincent Whitchurch <vincent.whitchurch@axis.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220628113540.2790835-1-vincent.whitchurch@axis.com
23 months agoof: Drop duplicate 'the' in of_find_last_cache_level kerneldoc
Deming Wang [Fri, 24 Jun 2022 01:12:47 +0000 (21:12 -0400)]
of: Drop duplicate 'the' in of_find_last_cache_level kerneldoc

Delete duplicate words of "the".

Signed-off-by: Deming Wang <wangdeming@inspur.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220624011247.1735-1-wangdeming@inspur.com
2 years agodt-bindings: vexpress-sysreg: Allow for no child nodes
Rob Herring [Mon, 13 Jun 2022 17:18:08 +0000 (11:18 -0600)]
dt-bindings: vexpress-sysreg: Allow for no child nodes

It is valid for arm,vexpress-sysreg to have no child nodes when either
the deprecated binding without child nodes is used or a platform
has no GPIOs. If there are no child nodes, then "#address-cells" and
"#size-cells" should not be required. However, "reg" should be present
in all cases, so let's add it now.

Cc: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220613171809.3928949-2-robh@kernel.org
2 years agodt-bindings: vexpress-sysreg: Add deprecated GPIO provider properties
Rob Herring [Mon, 13 Jun 2022 17:18:07 +0000 (11:18 -0600)]
dt-bindings: vexpress-sysreg: Add deprecated GPIO provider properties

While the current binding expects a child GPIO node, the old style binding
with GPIO provider properties in the parent vexpress-sysreg node is
still in use. Add the GPIO provider properties as deprecated.

Cc: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220613171809.3928949-1-robh@kernel.org
2 years agodt-bindings: perf: Convert Arm CCN to DT schema
Rob Herring [Mon, 13 Jun 2022 14:55:54 +0000 (08:55 -0600)]
dt-bindings: perf: Convert Arm CCN to DT schema

Convert the Arm CCN performance monitors binding to DT schema format.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Robin Murphy <robin.murphy@arm.com>
Link: https://lore.kernel.org/r/20220613145554.3727354-1-robh@kernel.org
2 years agodt-bindings: display: Add Arm virtual platforms display
Rob Herring [Mon, 13 Jun 2022 14:57:09 +0000 (08:57 -0600)]
dt-bindings: display: Add Arm virtual platforms display

'arm,rtsm-display' is a panel for Arm, Ltd. virtual platforms (e.g. FVP).
The binding has been in use for a long time, but was never documented.

Some users and an example have a 'panel-dpi' compatible, but that's not
needed without a 'panel-timing' node which none of the users have since
commit 928faf5e3e8d ("arm64: dts: fvp: Remove panel timings"). The
example does have a 'panel-timing' node, but it should not for the
same reasons the node was removed in the dts files. So update the
example in arm,pl11x.yaml to match the schema.

Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Robin Murphy <robin.murphy@arm.com>
Cc: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Link: https://lore.kernel.org/r/20220613145709.3729053-1-robh@kernel.org
2 years agodt-bindings: efm32: remove bindings for deleted platform
Wolfram Sang [Wed, 15 Jun 2022 21:07:19 +0000 (23:07 +0200)]
dt-bindings: efm32: remove bindings for deleted platform

Commit cc6111375cec ("ARM: drop efm32 platform") removed the platform,
so no need to still carry the bindings.

Signed-off-by: Wolfram Sang <wsa@kernel.org>
Acked-by: Mark Brown <broonie@kernel.org>
Acked-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220615210720.6363-1-wsa@kernel.org
2 years agodt-bindings: hwmon: move ibm,p8-occ bindings to proper folder
Wolfram Sang [Wed, 15 Jun 2022 21:16:19 +0000 (23:16 +0200)]
dt-bindings: hwmon: move ibm,p8-occ bindings to proper folder

It accidently ended up in i2c, but it should be in the hwmon folder.

Signed-off-by: Wolfram Sang <wsa@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220615211619.6742-1-wsa@kernel.org
2 years agodt-bindings: interrupt-controller: Convert rda,8810pl-intc to YAML
Stanislav Jakubek [Sat, 11 Jun 2022 18:07:03 +0000 (20:07 +0200)]
dt-bindings: interrupt-controller: Convert rda,8810pl-intc to YAML

Convert RDA Micro interrupt controller bindings to DT schema format.

Signed-off-by: Stanislav Jakubek <stano.jakubek@gmail.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220611180703.GA24988@standask-GA-A55M-S2HP
2 years agodt-bindings: display: arm,malidp: remove bogus RQOS property
Andre Przywara [Thu, 9 Jun 2022 16:27:29 +0000 (17:27 +0100)]
dt-bindings: display: arm,malidp: remove bogus RQOS property

As Liviu pointed out, the arm,malidp-arqos-high-level property
mentioned in the original .txt binding was a mistake, and
arm,malidp-arqos-value needs to take its place.

The binding commit ce6eb0253cba ("dt/bindings: display: Add optional
property node define for Mali DP500") mentions the right name in the
commit message, but has the wrong name in the diff.
Commit d298e6a27a81 ("drm/arm/mali-dp: Add display QoS interface
configuration for Mali DP500") uses the property in the driver, but uses
the shorter name.

Remove the wrong property from the binding, and use the proper name in
the example. The actual property was already documented properly.

Fixes: 2c8b082a3ab1 ("dt-bindings: display: convert Arm Mali-DP to DT schema")
Link: https://lore.kernel.org/linux-arm-kernel/YnumGEilUblhBx8E@e110455-lin.cambridge.arm.com/
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reported-by: Liviu Dudau <liviu.dudau@arm.com>
Reviewed-by: Liviu Dudau <liviu.dudau@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220609162729.1441760-1-andre.przywara@arm.com
2 years agodt-bindings: pinctrl: ralink: Fix 'enum' lists with duplicate entries
Rob Herring [Mon, 6 Jun 2022 21:22:39 +0000 (16:22 -0500)]
dt-bindings: pinctrl: ralink: Fix 'enum' lists with duplicate entries

There's no reason to list the same value twice in an 'enum'. This was fixed
treewide in commit c3b006819426 ("dt-bindings: Fix 'enum' lists with
duplicate entries"), but this one got added in the merge window.

A meta-schema change will catch future cases.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Sergio Paracuellos <sergio.paracuellos@gmail.com>
Link: https://lore.kernel.org/r/20220606212239.1360877-1-robh@kernel.org
2 years agodt-bindings: sram: qcom,imem: add IMEM memory region
Krzysztof Kozlowski [Tue, 7 Jun 2022 17:18:36 +0000 (19:18 +0200)]
dt-bindings: sram: qcom,imem: add IMEM memory region

Add bindings for IMEM memory region (like SRAM) used on several
Qualcomm SoCs.  In the downstream (vendor) tree, it comes with several
children used for debugging purposes.  The upstreamed parts are much
smaller - just image loader and syscon reboot.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220607171848.535128-2-krzysztof.kozlowski@linaro.org
2 years agodt-bindings: sram: qcom,ocmem: cleanup example coding style
Krzysztof Kozlowski [Tue, 7 Jun 2022 17:18:35 +0000 (19:18 +0200)]
dt-bindings: sram: qcom,ocmem: cleanup example coding style

Fix the indentation in the OCMEM example and use generic node name -
sram - to reflect the type of the device.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220607171848.535128-1-krzysztof.kozlowski@linaro.org
2 years agodt-bindings: vendor-prefixes: document several vendors for Aspeed BMC boards
Krzysztof Kozlowski [Sun, 29 May 2022 10:49:22 +0000 (12:49 +0200)]
dt-bindings: vendor-prefixes: document several vendors for Aspeed BMC boards

Add vendor prefixes for manufacturers of Aspeed SoC based BMC boards:
ASrock, ByteDance, Ingrasys, Inventec and Quanta.  Move also bticino to
proper alphabetical place.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220529104928.79636-1-krzysztof.kozlowski@linaro.org
2 years agoof: check previous kernel's ima-kexec-buffer against memory bounds
Vaibhav Jain [Tue, 31 May 2022 04:14:46 +0000 (09:44 +0530)]
of: check previous kernel's ima-kexec-buffer against memory bounds

Presently ima_get_kexec_buffer() doesn't check if the previous kernel's
ima-kexec-buffer lies outside the addressable memory range. This can result
in a kernel panic if the new kernel is booted with 'mem=X' arg and the
ima-kexec-buffer was allocated beyond that range by the previous kernel.
The panic is usually of the form below:

$ sudo kexec --initrd initrd vmlinux --append='mem=16G'

<snip>
 BUG: Unable to handle kernel data access on read at 0xc000c01fff7f0000
 Faulting instruction address: 0xc000000000837974
 Oops: Kernel access of bad area, sig: 11 [#1]
<snip>
 NIP [c000000000837974] ima_restore_measurement_list+0x94/0x6c0
 LR [c00000000083b55c] ima_load_kexec_buffer+0xac/0x160
 Call Trace:
 [c00000000371fa80] [c00000000083b55c] ima_load_kexec_buffer+0xac/0x160
 [c00000000371fb00] [c0000000020512c4] ima_init+0x80/0x108
 [c00000000371fb70] [c0000000020514dc] init_ima+0x4c/0x120
 [c00000000371fbf0] [c000000000012240] do_one_initcall+0x60/0x2c0
 [c00000000371fcc0] [c000000002004ad0] kernel_init_freeable+0x344/0x3ec
 [c00000000371fda0] [c0000000000128a4] kernel_init+0x34/0x1b0
 [c00000000371fe10] [c00000000000ce64] ret_from_kernel_thread+0x5c/0x64
 Instruction dump:
 f92100b8 f92100c0 90e10090 910100a0 4182050c 282a0017 3bc00000 40810330
 7c0802a6 fb610198 7c9b2378 f80101d0 <a12400002c090001 40820614 e9240010
 ---[ end trace 0000000000000000 ]---

Fix this issue by checking returned PFN range of previous kernel's
ima-kexec-buffer with page_is_ram() to ensure correct memory bounds.

Fixes: 467d27824920 ("powerpc: ima: get the kexec buffer passed by the previous kernel")
Cc: Frank Rowand <frowand.list@gmail.com>
Cc: Prakhar Srivastava <prsriva@linux.microsoft.com>
Cc: Lakshmi Ramasubramanian <nramas@linux.microsoft.com>
Cc: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Cc: Rob Herring <robh@kernel.org>
Cc: Ritesh Harjani <ritesh.list@gmail.com>
Cc: Robin Murphy <robin.murphy@arm.com>
Signed-off-by: Vaibhav Jain <vaibhav@linux.ibm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220531041446.3334259-1-vaibhav@linux.ibm.com
2 years agodt-bindings: Drop more redundant 'maxItems/minItems' in if/then schemas
Rob Herring [Mon, 6 Jun 2022 22:51:36 +0000 (17:51 -0500)]
dt-bindings: Drop more redundant 'maxItems/minItems' in if/then schemas

Another round from new cases in 5.19-rc of removing redundant
minItems/maxItems when 'items' list is specified. This time it is in
if/then schemas as the meta-schema was failing to check this case.

If a property has an 'items' list, then a 'minItems' or 'maxItems' with the
same size as the list is redundant and can be dropped. Note that is DT
schema specific behavior and not standard json-schema behavior. The tooling
will fixup the final schema adding any unspecified minItems/maxItems.

Signed-off-by: Rob Herring <robh@kernel.org>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Acked-by: Ulf Hansson <ulf.hansson@linaro.org>
Link: https://lore.kernel.org/r/20220606225137.1536010-1-robh@kernel.org
2 years agodt-bindings: nvme: apple,nvme-ans: Drop 'maxItems' from 'apple,sart'
Rob Herring [Mon, 6 Jun 2022 21:22:30 +0000 (16:22 -0500)]
dt-bindings: nvme: apple,nvme-ans: Drop 'maxItems' from 'apple,sart'

A 'phandle' type is always a single cell, so 'maxItems: 1' is redundant.

Fixes: 82b96552f15a ("dt-bindings: nvme: Add Apple ANS NVMe")
Signed-off-by: Rob Herring <robh@kernel.org>
Reviewed-by: Sven Peter <sven@svenpeter.dev>
Link: https://lore.kernel.org/r/20220606212230.1360617-1-robh@kernel.org
2 years agodt-bindings: display: bridge: sil,sii9022: Convert to json-schema
Geert Uytterhoeven [Thu, 19 May 2022 13:41:06 +0000 (15:41 +0200)]
dt-bindings: display: bridge: sil,sii9022: Convert to json-schema

Convert the Silicon Image sii902x HDMI bridge Device Tree binding
documentation to json-schema.

Add missing sil,sii9022-cpi and sil,sii9022-tpi compatible values.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Rob Herring <robh@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/2f8e12b4980a82788c1dd413ceedf8d144fdca91.1652967387.git.geert+renesas@glider.be
2 years agodt-bindings: ps2-gpio: document bus signals open drain
Danilo Krummrich [Sun, 29 May 2022 13:26:38 +0000 (15:26 +0200)]
dt-bindings: ps2-gpio: document bus signals open drain

The PS/2 bus defines data and clock line to be open drain, this should
be reflected in the gpio flags set in the binding.

Especially, this is important since the clock line sometimes is driven
by the host while being used as interrupt source.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Signed-off-by: Danilo Krummrich <danilokrummrich@dk-develop.de>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220529132638.13420-2-danilokrummrich@dk-develop.de
2 years agodt-bindings: ps2-gpio: convert binding to json-schema
Danilo Krummrich [Sun, 29 May 2022 13:26:37 +0000 (15:26 +0200)]
dt-bindings: ps2-gpio: convert binding to json-schema

Convert the ps2-gpio dt-binding documentation to DT schema format using
the json-schema.

Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com>
Signed-off-by: Danilo Krummrich <danilokrummrich@dk-develop.de>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220529132638.13420-1-danilokrummrich@dk-develop.de
2 years agoof: constify of_property_check_flags() prop argument
Clément Léger [Wed, 1 Jun 2022 08:17:58 +0000 (10:17 +0200)]
of: constify of_property_check_flags() prop argument

This argument is not modified and thus can be set as const.

Signed-off-by: Clément Léger <clement.leger@bootlin.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220601081801.348571-2-clement.leger@bootlin.com
2 years agoMAINTAINERS: rectify entries for ARM DRM DRIVERS after dt conversion
Lukas Bulwahn [Wed, 1 Jun 2022 04:17:46 +0000 (06:17 +0200)]
MAINTAINERS: rectify entries for ARM DRM DRIVERS after dt conversion

The three commits:

  36fd2a65bcaf ("dt-bindings: display: convert Arm HDLCD to DT schema")
  0f6983509ea1 ("dt-bindings: display: convert Arm Komeda to DT schema")
  2c8b082a3ab1 ("dt-bindings: display: convert Arm Mali-DP to DT schema")

convert the arm display dt-bindings, arm,*.txt to arm,*.yaml, but miss to
adjust its reference in MAINTAINERS.

Hence, ./scripts/get_maintainer.pl --self-test=patterns complains about
broken references.

Repair these file references in ARM HDLCD DRM DRIVER, ARM KOMEDA DRM-KMS
DRIVER and ARM MALI-DP DRM DRIVER.

Signed-off-by: Lukas Bulwahn <lukas.bulwahn@gmail.com>
Acked-by: Andre Przywara <andre.przywara@arm.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220601041746.22986-1-lukas.bulwahn@gmail.com
2 years agoMAINTAINERS: update snps,axs10x-reset.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:42 +0000 (16:25 +0100)]
MAINTAINERS: update snps,axs10x-reset.yaml reference

Changeset 820f722c05dd ("dt-bindings: reset: snps,axs10x-reset: Convert to yaml")
renamed: Documentation/devicetree/bindings/reset/snps,axs10x-reset.txt
to: Documentation/devicetree/bindings/reset/snps,axs10x-reset.yaml.

Update its cross-reference accordingly.

Fixes: 820f722c05dd ("dt-bindings: reset: snps,axs10x-reset: Convert to yaml")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/56560a2bcc06af94d36a28ed2cfdb25de481eee5.1654529011.git.mchehab@kernel.org
2 years agoMAINTAINERS: update dongwoon,dw9807-vcm.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:40 +0000 (16:25 +0100)]
MAINTAINERS: update dongwoon,dw9807-vcm.yaml reference

Changeset a1f4626b282d ("media: dt-bindings: Convert Dongwoon dw9807-vcm bindings to json-schema")
renamed: Documentation/devicetree/bindings/media/i2c/dongwoon,dw9807-vcm.txt
to: Documentation/devicetree/bindings/media/i2c/dongwoon,dw9807-vcm.yaml.

Update its cross-reference accordingly.

Fixes: a1f4626b282d ("media: dt-bindings: Convert Dongwoon dw9807-vcm bindings to json-schema")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/89f11772dd4afe9700d6cbbb3da8749eb98b396a.1654529011.git.mchehab@kernel.org
2 years agoMAINTAINERS: update cortina,gemini-ethernet.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:39 +0000 (16:25 +0100)]
MAINTAINERS: update cortina,gemini-ethernet.yaml reference

Changeset 208b65f7b5cc ("dt-bindings: net: convert net/cortina,gemini-ethernet to yaml")
renamed: Documentation/devicetree/bindings/net/cortina,gemini-ethernet.txt
to: Documentation/devicetree/bindings/net/cortina,gemini-ethernet.yaml.

Update its cross-reference accordingly.

Fixes: 208b65f7b5cc ("dt-bindings: net: convert net/cortina,gemini-ethernet to yaml")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/d27b5d508fb757147b720bf573ce5a2e3fc5920e.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: mfd: rk808: update rockchip,rk808.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:27 +0000 (16:25 +0100)]
dt-bindings: mfd: rk808: update rockchip,rk808.yaml reference

Changeset 6c38ca03406e ("dt-bindings: mfd: rk808: Convert bindings to yaml")
renamed: Documentation/devicetree/bindings/mfd/rk808.txt
to: Documentation/devicetree/bindings/mfd/rockchip,rk808.yaml.

Update its cross-reference accordingly.

Fixes: 6c38ca03406e ("dt-bindings: mfd: rk808: Convert bindings to yaml")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/417281c270e098eefed763859480014bec75c883.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: reset: update st,stih407-powerdown.yaml references
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:26 +0000 (16:25 +0100)]
dt-bindings: reset: update st,stih407-powerdown.yaml references

Changeset 2ca065dc9468 ("dt-bindings: reset: st,sti-powerdown: Convert to yaml")
renamed: Documentation/devicetree/bindings/reset/st,sti-powerdown.txt
to: Documentation/devicetree/bindings/reset/st,stih407-powerdown.yaml.

Update the cross-references accordingly.

Fixes: 2ca065dc9468 ("dt-bindings: reset: st,sti-powerdown: Convert to yaml")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/debdd5a9a1bfa0cf1c7e9c45da32edbc2ac2d10a.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: arm: update vexpress-config.yaml references
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:25 +0000 (16:25 +0100)]
dt-bindings: arm: update vexpress-config.yaml references

Changeset 7e8339b5162f ("dt-bindings: arm: convert vexpress-config to DT schema")
renamed: Documentation/devicetree/bindings/arm/vexpress-sysreg.txt
to: Documentation/devicetree/bindings/arm/vexpress-config.yaml.

Update the cross-references accordingly.

Fixes: 7e8339b5162f ("dt-bindings: arm: convert vexpress-config to DT schema")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Acked-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/7020edd9e183652249fc95bf61a1055cc342a4dc.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: interrupt-controller: update brcm,l2-intc.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:24 +0000 (16:25 +0100)]
dt-bindings: interrupt-controller: update brcm,l2-intc.yaml reference

Changeset 539d25b21fe8 ("dt-bindings: interrupt-controller: Convert Broadcom STB L2 to YAML")
renamed: Documentation/devicetree/bindings/interrupt-controller/brcm,l2-intc.txt
to: Documentation/devicetree/bindings/interrupt-controller/brcm,l2-intc.yaml.

Update its cross-reference accordingly.

Fixes: 539d25b21fe8 ("dt-bindings: interrupt-controller: Convert Broadcom STB L2 to YAML")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/a40c02a7aaea91ea7b6ce24b6bc574ae5bcf4cf6.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: mfd: bd9571mwv: update rohm,bd9571mwv.yaml reference
Mauro Carvalho Chehab [Mon, 6 Jun 2022 15:25:23 +0000 (16:25 +0100)]
dt-bindings: mfd: bd9571mwv: update rohm,bd9571mwv.yaml reference

Changeset 983b62975e90 ("dt-bindings: mfd: bd9571mwv: Convert to json-schema")
renamed: Documentation/devicetree/bindings/mfd/bd9571mwv.txt
to: Documentation/devicetree/bindings/mfd/rohm,bd9571mwv.yaml.

Update its cross-reference accordingly.

Fixes: 983b62975e90 ("dt-bindings: mfd: bd9571mwv: Convert to json-schema")
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/1906a4d935eab57c10ce09358eae02175ce4abb7.1654529011.git.mchehab@kernel.org
2 years agodt-bindings: update Luca Ceresoli's e-mail address
Luca Ceresoli [Fri, 3 Jun 2022 15:57:23 +0000 (17:57 +0200)]
dt-bindings: update Luca Ceresoli's e-mail address

My Bootlin address is preferred from now on.

Signed-off-by: Luca Ceresoli <luca@lucaceresoli.net>
Signed-off-by: Luca Ceresoli <luca.ceresoli@bootlin.com>
Acked-by: Rob Herring <robh@kernel.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220603155727.1232061-2-luca@lucaceresoli.net
2 years agodt-bindings: msm: update maintainers list with proper id
Krishna Manikandan [Thu, 2 Jun 2022 10:49:58 +0000 (16:19 +0530)]
dt-bindings: msm: update maintainers list with proper id

Use quic id instead of codeaurora id in maintainers list
for display devicetree bindings.

Signed-off-by: Krishna Manikandan <quic_mkrishn@quicinc.com>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/1654166998-14907-1-git-send-email-quic_mkrishn@quicinc.com
2 years agodt-bindings: vendor-prefixes: document deprecated Atheros
Krzysztof Kozlowski [Wed, 1 Jun 2022 13:52:22 +0000 (15:52 +0200)]
dt-bindings: vendor-prefixes: document deprecated Atheros

Two old boards use "atheros" prefix instead of already documented "qca".
Document it as deprecated to fix warnings like:

  at91-gatwick.dtb: atheros@0: 'atheros,board-id' does not match any of the regexes

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220601135222.205035-1-krzysztof.kozlowski@linaro.org
2 years agodt-bindings: Update QCOM USB subsystem maintainer information
Wesley Cheng [Fri, 3 Jun 2022 02:14:32 +0000 (19:14 -0700)]
dt-bindings: Update QCOM USB subsystem maintainer information

Update devicetree binding files with the proper maintainer, and updated
contact email.

Signed-off-by: Wesley Cheng <quic_wcheng@quicinc.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Rob Herring <robh@kernel.org>
Link: https://lore.kernel.org/r/20220603021432.13365-1-quic_wcheng@quicinc.com
2 years agoLinux 5.19-rc1
Linus Torvalds [Mon, 6 Jun 2022 00:18:54 +0000 (17:18 -0700)]
Linux 5.19-rc1

2 years agoMerge tag 'pull-work.fd-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs
Linus Torvalds [Mon, 6 Jun 2022 00:14:03 +0000 (17:14 -0700)]
Merge tag 'pull-work.fd-fixes' of git://git./linux/kernel/git/viro/vfs

Pull file descriptor fix from Al Viro:
 "Fix for breakage in #work.fd this window"

* tag 'pull-work.fd-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  fix the breakage in close_fd_get_file() calling conventions change

2 years agoMerge tag 'mm-hotfixes-stable-2022-06-05' of git://git.kernel.org/pub/scm/linux/kerne...
Linus Torvalds [Mon, 6 Jun 2022 00:05:38 +0000 (17:05 -0700)]
Merge tag 'mm-hotfixes-stable-2022-06-05' of git://git./linux/kernel/git/akpm/mm

Pull mm hotfixes from Andrew Morton:
 "Fixups for various recently-added and longer-term issues and a few
  minor tweaks:

   - fixes for material merged during this merge window

   - cc:stable fixes for more longstanding issues

   - minor mailmap and MAINTAINERS updates"

* tag 'mm-hotfixes-stable-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm:
  mm/oom_kill.c: fix vm_oom_kill_table[] ifdeffery
  x86/kexec: fix memory leak of elf header buffer
  mm/memremap: fix missing call to untrack_pfn() in pagemap_range()
  mm: page_isolation: use compound_nr() correctly in isolate_single_pageblock()
  mm: hugetlb_vmemmap: fix CONFIG_HUGETLB_PAGE_FREE_VMEMMAP_DEFAULT_ON
  MAINTAINERS: add maintainer information for z3fold
  mailmap: update Josh Poimboeuf's email

2 years agoMerge tag 'mm-nonmm-stable-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 5 Jun 2022 23:58:27 +0000 (16:58 -0700)]
Merge tag 'mm-nonmm-stable-2022-06-05' of git://git./linux/kernel/git/akpm/mm

Pull delay-accounting update from Andrew Morton:
 "A single featurette for delay accounting.

  Delayed a bit because, unusually, it had dependencies on both the
  mm-stable and mm-nonmm-stable queues"

* tag 'mm-nonmm-stable-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm:
  delayacct: track delays from write-protect copy

2 years agobluetooth: don't use bitmaps for random flag accesses
Linus Torvalds [Sun, 5 Jun 2022 18:51:48 +0000 (11:51 -0700)]
bluetooth: don't use bitmaps for random flag accesses

The bluetooth code uses our bitmap infrastructure for the two bits (!)
of connection setup flags, and in the process causes odd problems when
it converts between a bitmap and just the regular values of said bits.

It's completely pointless to do things like bitmap_to_arr32() to convert
a bitmap into a u32.  It shoudln't have been a bitmap in the first
place.  The reason to use bitmaps is if you have arbitrary number of
bits you want to manage (not two!), or if you rely on the atomicity
guarantees of the bitmap setting and clearing.

The code could use an "atomic_t" and use "atomic_or/andnot()" to set and
clear the bit values, but considering that it then copies the bitmaps
around with "bitmap_to_arr32()" and friends, there clearly cannot be a
lot of atomicity requirements.

So just use a regular integer.

In the process, this avoids the warnings about erroneous use of
bitmap_from_u64() which were triggered on 32-bit architectures when
conversion from a u64 would access two words (and, surprise, surprise,
only one word is needed - and indeed overkill - for a 2-bit bitmap).

That was always problematic, but the compiler seems to notice it and
warn about the invalid pattern only after commit 0a97953fd221 ("lib: add
bitmap_{from,to}_arr64") changed the exact implementation details of
'bitmap_from_u64()', as reported by Sudip Mukherjee and Stephen Rothwell.

Fixes: fe92ee6425a2 ("Bluetooth: hci_core: Rework hci_conn_params flags")
Link: https://lore.kernel.org/all/YpyJ9qTNHJzz0FHY@debian/
Link: https://lore.kernel.org/all/20220606080631.0c3014f2@canb.auug.org.au/
Link: https://lore.kernel.org/all/20220605162537.1604762-1-yury.norov@gmail.com/
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Reported-by: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
Reviewed-by: Yury Norov <yury.norov@gmail.com>
Cc: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Cc: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2 years agofix the breakage in close_fd_get_file() calling conventions change
Al Viro [Sun, 5 Jun 2022 18:01:42 +0000 (14:01 -0400)]
fix the breakage in close_fd_get_file() calling conventions change

It used to grab an extra reference to struct file rather than
just transferring to caller the one it had removed from descriptor
table.  New variant doesn't, and callers need to be adjusted.

Reported-and-tested-by: syzbot+47dd250f527cb7bebf24@syzkaller.appspotmail.com
Fixes: 6319194ec57b ("Unify the primitives for file descriptor closing")
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2 years agoMerge tag 'x86-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 18:00:43 +0000 (11:00 -0700)]
Merge tag 'x86-urgent-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull x86 SGX fix from Thomas Gleixner:
 "A single fix for x86/SGX to prevent that memory which is allocated for
  an SGX enclave is accounted to the wrong memory control group"

* tag 'x86-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/sgx: Set active memcg prior to shmem allocation

2 years agoMerge tag 'x86-mm-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip
Linus Torvalds [Sun, 5 Jun 2022 17:57:35 +0000 (10:57 -0700)]
Merge tag 'x86-mm-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull x86 mm cleanup from Thomas Gleixner:
 "Use PAGE_ALIGNED() instead of open coding it in the x86/mm code"

* tag 'x86-mm-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/mm: Use PAGE_ALIGNED(x) instead of IS_ALIGNED(x, PAGE_SIZE)

2 years agoMerge tag 'x86-microcode-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 5 Jun 2022 17:55:23 +0000 (10:55 -0700)]
Merge tag 'x86-microcode-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull x86 microcode updates from Thomas Gleixner:

 - Disable late microcode loading by default. Unless the HW people get
   their act together and provide a required minimum version in the
   microcode header for making a halfways informed decision its just
   lottery and broken.

 - Warn and taint the kernel when microcode is loaded late

 - Remove the old unused microcode loader interface

 - Remove a redundant perf callback from the microcode loader

* tag 'x86-microcode-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/microcode: Remove unnecessary perf callback
  x86/microcode: Taint and warn on late loading
  x86/microcode: Default-disable late loading
  x86/microcode: Rip out the OLD_INTERFACE

2 years agoMerge tag 'x86-cleanups-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 5 Jun 2022 17:53:41 +0000 (10:53 -0700)]
Merge tag 'x86-cleanups-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull x86 cleanups from Thomas Gleixner:
 "A set of small x86 cleanups:

   - Remove unused headers in the IDT code

   - Kconfig indendation and comment fixes

   - Fix all 'the the' typos in one go instead of waiting for bots to
     fix one at a time"

* tag 'x86-cleanups-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86: Fix all occurences of the "the the" typo
  x86/idt: Remove unused headers
  x86/Kconfig: Fix indentation of arch/x86/Kconfig.debug
  x86/Kconfig: Fix indentation and add endif comments to arch/x86/Kconfig

2 years agoMerge tag 'x86-boot-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 17:49:42 +0000 (10:49 -0700)]
Merge tag 'x86-boot-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull x86 boot update from Thomas Gleixner:
 "Use strlcpy() instead of strscpy() in arch_setup()"

* tag 'x86-boot-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/setup: Use strscpy() to replace deprecated strlcpy()

2 years agoMerge tag 'timers-core-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 17:47:06 +0000 (10:47 -0700)]
Merge tag 'timers-core-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull clockevent/clocksource updates from Thomas Gleixner:

 - Device tree bindings for MT8186

 - Tell the kernel that the RISC-V SBI timer stops in deeper power
   states

 - Make device tree parsing in sp804 more robust

 - Dead code removal and tiny fixes here and there

 - Add the missing SPDX identifiers

* tag 'timers-core-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  clocksource/drivers/oxnas-rps: Fix irq_of_parse_and_map() return value
  clocksource/drivers/timer-ti-dm: Remove unnecessary NULL check
  clocksource/drivers/timer-sun5i: Convert to SPDX identifier
  clocksource/drivers/timer-sun4i: Convert to SPDX identifier
  clocksource/drivers/pistachio: Convert to SPDX identifier
  clocksource/drivers/orion: Convert to SPDX identifier
  clocksource/drivers/lpc32xx: Convert to SPDX identifier
  clocksource/drivers/digicolor: Convert to SPDX identifier
  clocksource/drivers/armada-370-xp: Convert to SPDX identifier
  clocksource/drivers/mips-gic-timer: Convert to SPDX identifier
  clocksource/drivers/jcore: Convert to SPDX identifier
  clocksource/drivers/bcm_kona: Convert to SPDX identifier
  clocksource/drivers/sp804: Avoid error on multiple instances
  clocksource/drivers/riscv: Events are stopped during CPU suspend
  clocksource/drivers/ixp4xx: Drop boardfile probe path
  dt-bindings: timer: Add compatible for Mediatek MT8186

2 years agoMerge tag 'sched-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 5 Jun 2022 17:42:40 +0000 (10:42 -0700)]
Merge tag 'sched-urgent-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull scheduler fix from Thomas Gleixner:
 "Fix the fallout of sysctl code move which placed the init function
  wrong"

* tag 'sched-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  sched/autogroup: Fix sysctl move

2 years agoMerge tag 'perf-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 17:40:31 +0000 (10:40 -0700)]
Merge tag 'perf-urgent-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull perf fixes from Thomas Gleixner:

  - Make the ICL event constraints match reality

  - Remove a unused local variable

* tag 'perf-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  perf/core: Remove unused local variable
  perf/x86/intel: Fix event constraints for ICL

2 years agoMerge tag 'perf-core-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 17:39:20 +0000 (10:39 -0700)]
Merge tag 'perf-core-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull perf fixlet from Thomas Gleixner:
 "Trivial indentation fix in Kconfig"

* tag 'perf-core-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  perf/x86/Kconfig: Fix indentation in the Kconfig file

2 years agoMerge tag 'objtool-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sun, 5 Jun 2022 16:45:27 +0000 (09:45 -0700)]
Merge tag 'objtool-urgent-2022-06-05' of git://git./linux/kernel/git/tip/tip

Pull objtool fixes from Thomas Gleixner:

 - Handle __ubsan_handle_builtin_unreachable() correctly and treat it as
   noreturn

 - Allow architectures to select uaccess validation

 - Use the non-instrumented bit test for test_cpu_has() to prevent
   escape from non-instrumentable regions

 - Use arch_ prefixed atomics for JUMP_LABEL=n builds to prevent escape
   from non-instrumentable regions

 - Mark a few tiny inline as __always_inline to prevent GCC from
   bringing them out of line and instrumenting them

 - Mark the empty stub context_tracking_enabled() as always inline as
   GCC brings them out of line and instruments the empty shell

 - Annotate ex_handler_msr_mce() as dead end

* tag 'objtool-urgent-2022-06-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/extable: Annotate ex_handler_msr_mce() as a dead end
  context_tracking: Always inline empty stubs
  x86: Always inline on_thread_stack() and current_top_of_stack()
  jump_label,noinstr: Avoid instrumentation for JUMP_LABEL=n builds
  x86/cpu: Elide KCSAN for cpu_has() and friends
  objtool: Mark __ubsan_handle_builtin_unreachable() as noreturn
  objtool: Add CONFIG_HAVE_UACCESS_VALIDATION

2 years agoMerge tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi
Linus Torvalds [Sun, 5 Jun 2022 16:25:12 +0000 (09:25 -0700)]
Merge tag 'scsi-misc' of git://git./linux/kernel/git/jejb/scsi

Pull more SCSI updates from James Bottomley:
 "Mostly small bug fixes plus other trivial updates.

  The major change of note is moving ufs out of scsi and a minor update
  to lpfc vmid handling"

* tag 'scsi-misc' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi: (24 commits)
  scsi: qla2xxx: Remove unused 'ql_dm_tgt_ex_pct' parameter
  scsi: qla2xxx: Remove setting of 'req' and 'rsp' parameters
  scsi: mpi3mr: Fix kernel-doc
  scsi: lpfc: Add support for ATTO Fibre Channel devices
  scsi: core: Return BLK_STS_TRANSPORT for ALUA transitioning
  scsi: sd_zbc: Prevent zone information memory leak
  scsi: sd: Fix potential NULL pointer dereference
  scsi: mpi3mr: Rework mrioc->bsg_device model to fix warnings
  scsi: myrb: Fix up null pointer access on myrb_cleanup()
  scsi: core: Unexport scsi_bus_type
  scsi: sd: Don't call blk_cleanup_disk() in sd_probe()
  scsi: ufs: ufshcd: Delete unnecessary NULL check
  scsi: isci: Fix typo in comment
  scsi: pmcraid: Fix typo in comment
  scsi: smartpqi: Fix typo in comment
  scsi: qedf: Fix typo in comment
  scsi: esas2r: Fix typo in comment
  scsi: storvsc: Fix typo in comment
  scsi: ufs: Split the drivers/scsi/ufs directory
  scsi: qla1280: Remove redundant variable
  ...

2 years agoMerge tag 'hte/for-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra...
Linus Torvalds [Sun, 5 Jun 2022 16:12:28 +0000 (09:12 -0700)]
Merge tag 'hte/for-5.19-rc1' of git://git./linux/kernel/git/tegra/linux

Pull hardware timestamping subsystem from Thierry Reding:
 "This contains the new HTE (hardware timestamping engine) subsystem
  that has been in the works for a couple of months now.

  The infrastructure provided allows for drivers to register as hardware
  timestamp providers, while consumers will be able to request events
  that they are interested in (such as GPIOs and IRQs) to be timestamped
  by the hardware providers.

  Note that this currently supports only one provider, but there seems
  to be enough interest in this functionality and we expect to see more
  drivers added once this is merged"

[ Linus Walleij mentions the Intel PMC in the Elkhart and Tiger Lake
  platforms as another future timestamp provider ]

* tag 'hte/for-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux:
  dt-bindings: timestamp: Correct id path
  dt-bindings: Renamed hte directory to timestamp
  hte: Uninitialized variable in hte_ts_get()
  hte: Fix off by one in hte_push_ts_ns()
  hte: Fix possible use-after-free in tegra_hte_test_remove()
  hte: Remove unused including <linux/version.h>
  MAINTAINERS: Add HTE Subsystem
  hte: Add Tegra HTE test driver
  tools: gpio: Add new hardware clock type
  gpiolib: cdev: Add hardware timestamp clock type
  gpio: tegra186: Add HTE support
  gpiolib: Add HTE support
  dt-bindings: Add HTE bindings
  hte: Add Tegra194 HTE kernel provider
  drivers: Add hardware timestamp engine (HTE) subsystem
  Documentation: Add HTE subsystem guide

2 years agoMerge tag 'kbuild-v5.19-3' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy...
Linus Torvalds [Sun, 5 Jun 2022 16:06:03 +0000 (09:06 -0700)]
Merge tag 'kbuild-v5.19-3' of git://git./linux/kernel/git/masahiroy/linux-kbuild

Pull more Kbuild updates from Masahiro Yamada:

 - Fix build regressions for parisc, csky, nios2, openrisc

 - Simplify module builds for CONFIG_LTO_CLANG and CONFIG_X86_KERNEL_IBT

 - Remove arch/parisc/nm, which was presumably a workaround for old
   tools

 - Check the odd combination of EXPORT_SYMBOL and 'static' precisely

 - Make external module builds robust against "too long argument error"

 - Support j, k keys for moving the cursor in nconfig

* tag 'kbuild-v5.19-3' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild: (25 commits)
  kbuild: Allow to select bash in a modified environment
  scripts: kconfig: nconf: make nconfig accept jk keybindings
  modpost: use fnmatch() to simplify match()
  modpost: simplify mod->name allocation
  kbuild: factor out the common objtool arguments
  kbuild: move vmlinux.o link to scripts/Makefile.vmlinux_o
  kbuild: clean .tmp_* pattern by make clean
  kbuild: remove redundant cleanups in scripts/link-vmlinux.sh
  kbuild: rebuild multi-object modules when objtool is updated
  kbuild: add cmd_and_savecmd macro
  kbuild: make *.mod rule robust against too long argument error
  kbuild: make built-in.a rule robust against too long argument error
  kbuild: check static EXPORT_SYMBOL* by script instead of modpost
  parisc: remove arch/parisc/nm
  kbuild: do not create *.prelink.o for Clang LTO or IBT
  kbuild: replace $(linked-object) with CONFIG options
  kbuild: do not try to parse *.cmd files for objects provided by compiler
  kbuild: replace $(if A,A,B) with $(or A,B) in scripts/Makefile.modpost
  modpost: squash if...else-if in find_elf_symbol2()
  modpost: reuse ARRAY_SIZE() macro for section_mismatch()
  ...

2 years agoMerge tag 'pull-18-rc1-work.namei' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 02:07:15 +0000 (19:07 -0700)]
Merge tag 'pull-18-rc1-work.namei' of git://git./linux/kernel/git/viro/vfs

Pull vfs pathname updates from Al Viro:
 "Several cleanups in fs/namei.c"

* tag 'pull-18-rc1-work.namei' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  namei: cleanup double word in comment
  get rid of dead code in legitimize_root()
  fs/namei.c:reserve_stack(): tidy up the call of try_to_unlazy()

2 years agoMerge tag 'pull-18-rc1-work.mount' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 02:00:05 +0000 (19:00 -0700)]
Merge tag 'pull-18-rc1-work.mount' of git://git./linux/kernel/git/viro/vfs

Pull mount handling updates from Al Viro:
 "Cleanups (and one fix) around struct mount handling.

  The fix is usermode_driver.c one - once you've done kern_mount(), you
  must kern_unmount(); simple mntput() will end up with a leak. Several
  failure exits in there messed up that way... In practice you won't hit
  those particular failure exits without fault injection, though"

* tag 'pull-18-rc1-work.mount' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  move mount-related externs from fs.h to mount.h
  blob_to_mnt(): kern_unmount() is needed to undo kern_mount()
  m->mnt_root->d_inode->i_sb is a weird way to spell m->mnt_sb...
  linux/mount.h: trim includes
  uninline may_mount() and don't opencode it in fspick(2)/fsopen(2)

2 years agoMerge tag 'pull-18-rc1-work.fd' of git://git.kernel.org/pub/scm/linux/kernel/git...
Linus Torvalds [Sun, 5 Jun 2022 01:52:00 +0000 (18:52 -0700)]
Merge tag 'pull-18-rc1-work.fd' of git://git./linux/kernel/git/viro/vfs

Pull file descriptor updates from Al Viro.

 - Descriptor handling cleanups

* tag 'pull-18-rc1-work.fd' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  Unify the primitives for file descriptor closing
  fs: remove fget_many and fput_many interface
  io_uring_enter(): don't leave f.flags uninitialized

2 years agoMerge tag '5.19-rc-smb3-client-fixes-part2' of git://git.samba.org/sfrench/cifs-2.6
Linus Torvalds [Sun, 5 Jun 2022 00:42:33 +0000 (17:42 -0700)]
Merge tag '5.19-rc-smb3-client-fixes-part2' of git://git.samba.org/sfrench/cifs-2.6

Pull cifs client fixes from Steve French:
 "Nine cifs/smb3 client fixes.

  Includes DFS fixes, some cleanup of leagcy SMB1 code, duplicated
  message cleanup and a double free and deadlock fix"

* tag '5.19-rc-smb3-client-fixes-part2' of git://git.samba.org/sfrench/cifs-2.6:
  cifs: fix uninitialized pointer in error case in dfs_cache_get_tgt_share
  cifs: skip trailing separators of prefix paths
  cifs: update internal module number
  cifs: version operations for smb20 unneeded when legacy support disabled
  cifs: do not build smb1ops if legacy support is disabled
  cifs: fix potential deadlock in direct reclaim
  cifs: when extending a file with falloc we should make files not-sparse
  cifs: remove repeated debug message on cifs_put_smb_ses()
  cifs: fix potential double free during failed mount

2 years agokbuild: Allow to select bash in a modified environment
Schspa Shi [Fri, 3 Jun 2022 09:38:52 +0000 (17:38 +0800)]
kbuild: Allow to select bash in a modified environment

This fixes the build error when the system has a default bash version
which is too old to support associative array variables.

The build error log as fellowing:
linux/scripts/check-local-export: line 11: declare: -A: invalid option
declare: usage: declare [-afFirtx] [-p] [name[=value] ...]

Signed-off-by: Schspa Shi <schspa@gmail.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2 years agoscripts: kconfig: nconf: make nconfig accept jk keybindings
Isak Ellmer [Wed, 1 Jun 2022 13:08:19 +0000 (15:08 +0200)]
scripts: kconfig: nconf: make nconfig accept jk keybindings

Make nconfig accept jk keybindings for movement in addition to arrow
keys.

Signed-off-by: Isak Ellmer <isak01@gmail.com>
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2 years agomodpost: use fnmatch() to simplify match()
Masahiro Yamada [Mon, 30 May 2022 09:01:39 +0000 (18:01 +0900)]
modpost: use fnmatch() to simplify match()

Replace the own implementation for wildcard (glob) matching with
a function call to fnmatch().

Also, change the return type to 'bool'.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
2 years agomodpost: simplify mod->name allocation
Masahiro Yamada [Mon, 30 May 2022 09:01:38 +0000 (18:01 +0900)]
modpost: simplify mod->name allocation

mod->name is set to the ELF filename with the suffix ".o" stripped.

The current code calls strdup() and free() to manipulate the string,
but a simpler approach is to pass new_module() with the name length
subtracted by 2.

Also, check if the passed filename ends with ".o" before stripping it.

The current code blindly chops the suffix:

    tmp[strlen(tmp) - 2] = '\0'

It will cause buffer under-run if strlen(tmp) < 2;

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
2 years agokbuild: factor out the common objtool arguments
Masahiro Yamada [Sat, 28 May 2022 15:47:04 +0000 (00:47 +0900)]
kbuild: factor out the common objtool arguments

scripts/Makefile.build and scripts/link-vmlinux.sh have similar setups
for the objtool arguments.

It was difficult to factor out them because all the vmlinux build rules
were written in a shell script. It is somewhat tedious to touch the two
files every time a new objtool option is supported.

To reduce the code duplication, move the objtool for vmlinux.o into
scripts/Makefile.vmlinux_o. Then, move the common macros to Makefile.lib
so they are shared between Makefile.build and Makefile.vmlinux_o.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Sedat Dilek <sedat.dilek@gmail.com> # LLVM-14 (x86-64)
2 years agokbuild: move vmlinux.o link to scripts/Makefile.vmlinux_o
Masahiro Yamada [Sat, 28 May 2022 15:47:03 +0000 (00:47 +0900)]
kbuild: move vmlinux.o link to scripts/Makefile.vmlinux_o

This is a preparation for moving the objtool rule in the next commit.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Sedat Dilek <sedat.dilek@gmail.com> # LLVM-14 (x86-64)
2 years agokbuild: clean .tmp_* pattern by make clean
Masahiro Yamada [Sat, 28 May 2022 15:47:02 +0000 (00:47 +0900)]
kbuild: clean .tmp_* pattern by make clean

Change the "make clean" rule to remove all the .tmp_* files.

.tmp_objdiff is the only exception, which should be removed by
"make mrproper".

Rename the record directory of objdiff, .tmp_objdiff to .objdiff to
avoid the removal by "make clean".

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Tested-by: Sedat Dilek <sedat.dilek@gmail.com> # LLVM-14 (x86-64)
2 years agoMerge tag 'bitmap-for-5.19-rc1' of https://github.com/norov/linux
Linus Torvalds [Sat, 4 Jun 2022 21:04:27 +0000 (14:04 -0700)]
Merge tag 'bitmap-for-5.19-rc1' of https://github.com/norov/linux

Pull bitmap updates from Yury Norov:

 - bitmap: optimize bitmap_weight() usage, from me

 - lib/bitmap.c make bitmap_print_bitmask_to_buf parseable, from Mauro
   Carvalho Chehab

 - include/linux/find: Fix documentation, from Anna-Maria Behnsen

 - bitmap: fix conversion from/to fix-sized arrays, from me

 - bitmap: Fix return values to be unsigned, from Kees Cook

It has been in linux-next for at least a week with no problems.

* tag 'bitmap-for-5.19-rc1' of https://github.com/norov/linux: (31 commits)
  nodemask: Fix return values to be unsigned
  bitmap: Fix return values to be unsigned
  KVM: x86: hyper-v: replace bitmap_weight() with hweight64()
  KVM: x86: hyper-v: fix type of valid_bank_mask
  ia64: cleanup remove_siblinginfo()
  drm/amd/pm: use bitmap_{from,to}_arr32 where appropriate
  KVM: s390: replace bitmap_copy with bitmap_{from,to}_arr64 where appropriate
  lib/bitmap: add test for bitmap_{from,to}_arr64
  lib: add bitmap_{from,to}_arr64
  lib/bitmap: extend comment for bitmap_(from,to)_arr32()
  include/linux/find: Fix documentation
  lib/bitmap.c make bitmap_print_bitmask_to_buf parseable
  MAINTAINERS: add cpumask and nodemask files to BITMAP_API
  arch/x86: replace nodes_weight with nodes_empty where appropriate
  mm/vmstat: replace cpumask_weight with cpumask_empty where appropriate
  clocksource: replace cpumask_weight with cpumask_empty in clocksource.c
  genirq/affinity: replace cpumask_weight with cpumask_empty where appropriate
  irq: mips: replace cpumask_weight with cpumask_empty where appropriate
  drm/i915/pmu: replace cpumask_weight with cpumask_empty where appropriate
  arch/x86: replace cpumask_weight with cpumask_empty where appropriate
  ...

2 years agoMerge tag 'for-5.19/parisc-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller...
Linus Torvalds [Sat, 4 Jun 2022 20:50:23 +0000 (13:50 -0700)]
Merge tag 'for-5.19/parisc-2' of git://git./linux/kernel/git/deller/parisc-linux

Pull more parisc architecture updates from Helge Deller:
 "A fix to prevent crash at bootup if CONFIG_SCHED_MC is enabled, and
  add auto-detection of primary graphics card for framebuffer driver"

* tag 'for-5.19/parisc-2' of git://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux:
  parisc/stifb: Keep track of hardware path of graphics card
  parisc/stifb: Implement fb_is_primary_device()
  parisc: fix a crash with multicore scheduler

2 years agoMerge tag 'for-linus-5.19-rc1b-tag' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 4 Jun 2022 20:42:53 +0000 (13:42 -0700)]
Merge tag 'for-linus-5.19-rc1b-tag' of git://git./linux/kernel/git/xen/tip

Pull more xen updates from Juergen Gross:
 "Two cleanup patches for Xen related code and (more important) an
  update of MAINTAINERS for Xen, as Boris Ostrovsky decided to step
  down"

* tag 'for-linus-5.19-rc1b-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
  xen: replace xen_remap() with memremap()
  MAINTAINERS: Update Xen maintainership
  xen: switch gnttab_end_foreign_access() to take a struct page pointer

2 years agoMerge tag 'perf-tools-for-v5.19-2022-06-04' of git://git.kernel.org/pub/scm/linux...
Linus Torvalds [Sat, 4 Jun 2022 20:33:12 +0000 (13:33 -0700)]
Merge tag 'perf-tools-for-v5.19-2022-06-04' of git://git./linux/kernel/git/acme/linux

Pull more perf tools updates from Arnaldo Carvalho de Melo:

 - Synthesize task events for pre-existing threads when using 'perf lock
   --threads', as we need to show task names.

 - Fix unwinding with ld.lld (>= version 10.0) linked objects, where
  .eh_frame_hdr and .text are in different PT_LOAD program headers,
   which makes perf record --call-graph dwarf fail with such obkects.

 - Check if 'perf record' hangs in the ARM SPE (Statistical Profiling
   Extensions) 'perf test' entry when recording a workload with forks.

 - Trace physical address for Arm SPE events, needed for 'perf c2c' to
   locate the memory node for samples.

 - Fix sorting in percent_rmt_hitm_cmp() in 'perf c2c'.

 - Further support for Intel hybrid systems in the evlist and 'perf
   record' code.

 - Update IBM s/390 vendor event JSON tables.

 - Add metrics (JSON) for Intel Sapphirerapids.

 - Update metrics for Intel Alderlake.

 - Correct typo of sysf 'event_source' directory in the documentation.

* tag 'perf-tools-for-v5.19-2022-06-04' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux:
  perf vendor events intel: Update metrics for Alderlake
  perf vendor events intel: Add metrics for Sapphirerapids
  perf c2c: Fix sorting in percent_rmt_hitm_cmp()
  perf mem: Trace physical address for Arm SPE events
  perf list: Update event description for IBM zEC12/zBC12 to latest level
  perf list: Update event description for IBM z196/z114 to latest level
  perf list: Update event description for IBM z15 to latest level
  perf list: Update event description for IBM z14 to latest level
  perf list: Update event description for IBM z13 to latest level
  perf list: Update event description for IBM z10 to latest level
  perf list: Add IBM z16 event description for s390
  perf record: Support sample-read topdown metric group for hybrid platforms
  perf lock: Change to synthesize task events
  perf unwind: Fix segbase for ld.lld linked objects
  perf test arm-spe: Check if perf-record hangs when recording workload with forks
  perf docs: Correct typo of event_sources
  perf evlist: Extend arch_evsel__must_be_in_group to support hybrid systems

2 years agocifs: fix uninitialized pointer in error case in dfs_cache_get_tgt_share
Steve French [Sat, 4 Jun 2022 06:18:37 +0000 (01:18 -0500)]
cifs: fix uninitialized pointer in error case in dfs_cache_get_tgt_share

Set default value of ppath to null.

Reported-by: kernel test robot <lkp@intel.com>
Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Steve French <stfrench@microsoft.com>
2 years agoparisc/stifb: Keep track of hardware path of graphics card
Helge Deller [Thu, 2 Jun 2022 11:55:26 +0000 (13:55 +0200)]
parisc/stifb: Keep track of hardware path of graphics card

Keep the pa_path (hardware path) of the graphics card in sti_struct and use
this info to give more useful info which card is currently being used.

Signed-off-by: Helge Deller <deller@gmx.de>
Cc: stable@vger.kernel.org # v5.10+
2 years agoparisc/stifb: Implement fb_is_primary_device()
Helge Deller [Thu, 2 Jun 2022 11:50:44 +0000 (13:50 +0200)]
parisc/stifb: Implement fb_is_primary_device()

Implement fb_is_primary_device() function, so that fbcon detects if this
framebuffer belongs to the default graphics card which was used to start
the system.

Signed-off-by: Helge Deller <deller@gmx.de>
Cc: stable@vger.kernel.org # v5.10+
2 years agoMerge tag 'gpio-fixes-for-v5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 4 Jun 2022 03:01:25 +0000 (20:01 -0700)]
Merge tag 'gpio-fixes-for-v5.19-rc1' of git://git./linux/kernel/git/brgl/linux

Pull gpio fixes from Bartosz Golaszewski:

 - use the correct register for regcache sync in gpio-pca953x

 - remove unused and potentially harmful code from gpio-adp5588

 - MAINTAINERS update

* tag 'gpio-fixes-for-v5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/brgl/linux:
  gpio: adp5588: Remove support for platform setup and teardown callbacks
  gpio: pca953x: use the correct register address to do regcache sync
  MAINTAINERS: Update Intel GPIO (PMIC and PCH) to Supported
  MAINTAINERS: Update GPIO ACPI library to Supported

2 years agoMerge tag 'regulator-fix-v5.19-rc0' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Sat, 4 Jun 2022 02:57:25 +0000 (19:57 -0700)]
Merge tag 'regulator-fix-v5.19-rc0' of git://git./linux/kernel/git/broonie/regulator

Pull regulator fix from Mark Brown:
 "One fix that came in during the merge window, fixing an error in the
  examples in the DT binding documentation for mt6315"

* tag 'regulator-fix-v5.19-rc0' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
  regulator: mt6315-regulator: fix invalid allowed mode

2 years agoMerge tag 'ntfs3_for_5.19' of https://github.com/Paragon-Software-Group/linux-ntfs3
Linus Torvalds [Fri, 3 Jun 2022 23:57:16 +0000 (16:57 -0700)]
Merge tag 'ntfs3_for_5.19' of https://github.com/Paragon-Software-Group/linux-ntfs3

Pull ntfs3 updates from Konstantin Komarov:

 - fix some memory leaks and panic

 - fixed xfstests (tested on x86_64): generic/092 generic/099
   generic/228 generic/240 generic/307 generic/444

 - fix some typos, dead code, etc

* tag 'ntfs3_for_5.19' of https://github.com/Paragon-Software-Group/linux-ntfs3:
  fs/ntfs3: provide block_invalidate_folio to fix memory leak
  fs/ntfs3: Fix invalid free in log_replay
  fs/ntfs3: Update valid size if -EIOCBQUEUED
  fs/ntfs3: Check new size for limits
  fs/ntfs3: Fix fiemap + fix shrink file size (to remove preallocated space)
  fs/ntfs3: In function ntfs_set_acl_ex do not change inode->i_mode if called from function ntfs_init_acl
  fs/ntfs3: Optimize locking in ntfs_save_wsl_perm
  fs/ntfs3: Update i_ctime when xattr is added
  fs/ntfs3: Restore ntfs_xattr_get_acl and ntfs_xattr_set_acl functions
  fs/ntfs3: Keep preallocated only if option prealloc enabled
  fs/ntfs3: Fix some memory leaks in an error handling path of 'log_replay()'

2 years agoMerge tag 'ptrace_stop-cleanup-for-v5.19' of git://git.kernel.org/pub/scm/linux/kerne...
Linus Torvalds [Fri, 3 Jun 2022 23:13:25 +0000 (16:13 -0700)]
Merge tag 'ptrace_stop-cleanup-for-v5.19' of git://git./linux/kernel/git/ebiederm/user-namespace

Pull ptrace_stop cleanups from Eric Biederman:
 "While looking at the ptrace problems with PREEMPT_RT and the problems
  Peter Zijlstra was encountering with ptrace in his freezer rewrite I
  identified some cleanups to ptrace_stop that make sense on their own
  and move make resolving the other problems much simpler.

  The biggest issue is the habit of the ptrace code to change
  task->__state from the tracer to suppress TASK_WAKEKILL from waking up
  the tracee. No other code in the kernel does that and it is straight
  forward to update signal_wake_up and friends to make that unnecessary.

  Peter's task freezer sets frozen tasks to a new state TASK_FROZEN and
  then it stores them by calling "wake_up_state(t, TASK_FROZEN)" relying
  on the fact that all stopped states except the special stop states can
  tolerate spurious wake up and recover their state.

  The state of stopped and traced tasked is changed to be stored in
  task->jobctl as well as in task->__state. This makes it possible for
  the freezer to recover tasks in these special states, as well as
  serving as a general cleanup. With a little more work in that
  direction I believe TASK_STOPPED can learn to tolerate spurious wake
  ups and become an ordinary stop state.

  The TASK_TRACED state has to remain a special state as the registers
  for a process are only reliably available when the process is stopped
  in the scheduler. Fundamentally ptrace needs acess to the saved
  register values of a task.

  There are bunch of semi-random ptrace related cleanups that were found
  while looking at these issues.

  One cleanup that deserves to be called out is from commit 57b6de08b5f6
  ("ptrace: Admit ptrace_stop can generate spuriuos SIGTRAPs"). This
  makes a change that is technically user space visible, in the handling
  of what happens to a tracee when a tracer dies unexpectedly. According
  to our testing and our understanding of userspace nothing cares that
  spurious SIGTRAPs can be generated in that case"

* tag 'ptrace_stop-cleanup-for-v5.19' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
  sched,signal,ptrace: Rework TASK_TRACED, TASK_STOPPED state
  ptrace: Always take siglock in ptrace_resume
  ptrace: Don't change __state
  ptrace: Admit ptrace_stop can generate spuriuos SIGTRAPs
  ptrace: Document that wait_task_inactive can't fail
  ptrace: Reimplement PTRACE_KILL by always sending SIGKILL
  signal: Use lockdep_assert_held instead of assert_spin_locked
  ptrace: Remove arch_ptrace_attach
  ptrace/xtensa: Replace PT_SINGLESTEP with TIF_SINGLESTEP
  ptrace/um: Replace PT_DTRACE with TIF_SINGLESTEP
  signal: Replace __group_send_sig_info with send_signal_locked
  signal: Rename send_signal send_signal_locked

2 years agoMerge tag 'kthread-cleanups-for-v5.19' of git://git.kernel.org/pub/scm/linux/kernel...
Linus Torvalds [Fri, 3 Jun 2022 23:03:05 +0000 (16:03 -0700)]
Merge tag 'kthread-cleanups-for-v5.19' of git://git./linux/kernel/git/ebiederm/user-namespace

Pull kthread updates from Eric Biederman:
 "This updates init and user mode helper tasks to be ordinary user mode
  tasks.

  Commit 40966e316f86 ("kthread: Ensure struct kthread is present for
  all kthreads") caused init and the user mode helper threads that call
  kernel_execve to have struct kthread allocated for them. This struct
  kthread going away during execve in turned made a use after free of
  struct kthread possible.

  Here, commit 343f4c49f243 ("kthread: Don't allocate kthread_struct for
  init and umh") is enough to fix the use after free and is simple
  enough to be backportable.

  The rest of the changes pass struct kernel_clone_args to clean things
  up and cause the code to make sense.

  In making init and the user mode helpers tasks purely user mode tasks
  I ran into two complications. The function task_tick_numa was
  detecting tasks without an mm by testing for the presence of
  PF_KTHREAD. The initramfs code in populate_initrd_image was using
  flush_delayed_fput to ensuere the closing of all it's file descriptors
  was complete, and flush_delayed_fput does not work in a userspace
  thread.

  I have looked and looked and more complications and in my code review
  I have not found any, and neither has anyone else with the code
  sitting in linux-next"

* tag 'kthread-cleanups-for-v5.19' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
  sched: Update task_tick_numa to ignore tasks without an mm
  fork: Stop allowing kthreads to call execve
  fork: Explicitly set PF_KTHREAD
  init: Deal with the init process being a user mode process
  fork: Generalize PF_IO_WORKER handling
  fork: Explicity test for idle tasks in copy_thread
  fork: Pass struct kernel_clone_args into copy_thread
  kthread: Don't allocate kthread_struct for init and umh

2 years agoMerge tag 'per-namespace-ipc-sysctls-for-v5.19' of git://git.kernel.org/pub/scm/linux...
Linus Torvalds [Fri, 3 Jun 2022 22:54:57 +0000 (15:54 -0700)]
Merge tag 'per-namespace-ipc-sysctls-for-v5.19' of git://git./linux/kernel/git/ebiederm/user-namespace

Pull ipc sysctl namespace updates from Eric Biederman:
 "This updates the ipc sysctls so that they are fundamentally per ipc
  namespace. Previously these sysctls depended upon a hack to simulate
  being per ipc namespace by looking up the ipc namespace in read or
  write. With this set of changes the ipc sysctls are registered per ipc
  namespace and open looks up the ipc namespace.

  Not only does this series of changes ensure the traditional binding at
  open time happens, but it sets a foundation for being able to relax
  the permission checks to allow a user namspace root to change the ipc
  sysctls for an ipc namespace that the user namespace root requires. To
  do this requires the ipc namespace to be known at open time"

* tag 'per-namespace-ipc-sysctls-for-v5.19' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace:
  ipc: Remove extra braces
  ipc: Check permissions for checkpoint_restart sysctls at open time
  ipc: Remove extra1 field abuse to pass ipc namespace
  ipc: Use the same namespace to modify and validate
  ipc: Store ipc sysctls in the ipc namespace
  ipc: Store mqueue sysctls in the ipc namespace

2 years agofirmware_loader: enable XZ by default if compressed support is enabled
Linus Torvalds [Fri, 3 Jun 2022 22:46:03 +0000 (15:46 -0700)]
firmware_loader: enable XZ by default if compressed support is enabled

Commit 23cfbc6ec44e ("firmware: Add the support for ZSTD-compressed
firmware files") added support for ZSTD compression, but in the process
also made the previously default XZ compression a config option.

That means that anybody who upgrades their kernel and does a

    make oldconfig

to update their configuration, will end up without the XZ compression
that the configuration used to have.

Add the 'default y' to make sure this doesn't happen.

The whole compression question should probably be improved upon, since
it is now possible to "enable" compression in the kernel config but not
enable any actual compression algorithm, which makes it all very
useless.  It makes no sense to ask Kconfig questions that enable
situations that are nonsensical like that.

This at least fixes the immediate problem of a kernel update resulting
in a nonbootable machine because of a missed option.

Fixes: 23cfbc6ec44e ("firmware: Add the support for ZSTD-compressed  firmware files")
Cc: Takashi Iwai <tiwai@suse.de>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2 years agoMerge tag 'for-linus-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw...
Linus Torvalds [Fri, 3 Jun 2022 21:42:24 +0000 (14:42 -0700)]
Merge tag 'for-linus-5.19-rc1' of git://git./linux/kernel/git/rw/ubifs

Pull JFFS2, UBI and UBIFS updates from Richard Weinberger:
 "JFFS2:
   - Fixes for a memory leak

  UBI:
   - Fixes for fastmap (UAF, high CPU usage)

  UBIFS:
   - Minor cleanups"

* tag 'for-linus-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/ubifs:
  ubi: ubi_create_volume: Fix use-after-free when volume creation failed
  ubi: fastmap: Check wl_pool for free peb before wear leveling
  ubi: fastmap: Fix high cpu usage of ubi_bgt by making sure wl_pool not empty
  ubifs: Use NULL instead of using plain integer as pointer
  ubifs: Simplify the return expression of run_gc()
  jffs2: fix memory leak in jffs2_do_fill_super
  jffs2: Use kzalloc instead of kmalloc/memset

2 years agoMerge tag 'for-linus-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml
Linus Torvalds [Fri, 3 Jun 2022 21:35:14 +0000 (14:35 -0700)]
Merge tag 'for-linus-5.19-rc1' of git://git./linux/kernel/git/rw/uml

Pull UML updates from Richard Weinberger:

 - Various cleanups and fixes: xterm, serial line, time travel

 - Set ARCH_HAS_GCOV_PROFILE_ALL

* tag 'for-linus-5.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rw/uml:
  um: Fix out-of-bounds read in LDT setup
  um: chan_user: Fix winch_tramp() return value
  um: virtio_uml: Fix broken device handling in time-travel
  um: line: Use separate IRQs per line
  um: Enable ARCH_HAS_GCOV_PROFILE_ALL
  um: Use asm-generic/dma-mapping.h
  um: daemon: Make default socket configurable
  um: xterm: Make default terminal emulator configurable