id
stringlengths
40
40
instruction
stringlengths
68
308
input
stringlengths
17
33.4k
output
stringlengths
100
30k
12d0a24afd9ea58e581ea64d64e066f2027b28d9
Analyze and fix the following issue in the Linux kernel code: erofs: Fix detection of atomic context
Problem Details: Current check for atomic context is not sufficient as z_erofs_decompressqueue_endio can be called under rcu lock from blk_mq_flush_plug_list(). See the stacktrace [1] In such case we should hand off the decompression work for async processing rather than trying to do sync decompression in current cont...
```diff diff --git a/fs/erofs/zdata.c b/fs/erofs/zdata.c index 264bf553c287..5f1890e309c6 100644 --- a/fs/erofs/zdata.c +++ b/fs/erofs/zdata.c @@ -1447,7 +1447,7 @@ static void z_erofs_decompress_kickoff(struct z_erofs_decompressqueue *io, if (atomic_add_return(bios, &io->pending_bios)) return; /* Use (kthread_)...
98703e4e061fb8715c7613cd227e32cdfd136b23
Analyze and fix the following issue in the Linux kernel code: drm: bridge: dw_hdmi: fix connector access for scdc
Problem Details: Commit 5d844091f237 ("drm/scdc-helper: Pimp SCDC debugs") changed the scdc interface to pick up an i2c adapter from a connector instead. However, in the case of dw-hdmi, the wrong connector was being used to pass i2c adapter information, since dw-hdmi's embedded connector structure is only populated wh...
```diff diff --git a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c index 603bb3c51027..3b40e0fdca5c 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-hdmi.c @@ -1426,9 +1426,9 @@ void dw_hdmi_set_high_tmds_clock_ratio(struct dw_hdmi *...
700c48b439921b67715e25380e0f67e6e490d7b8
Analyze and fix the following issue in the Linux kernel code: modpost: use null string instead of NULL pointer for default namespace
Problem Details: The default namespace is the null string, "". When set, the null string "" is converted to NULL: s->namespace = namespace[0] ? NOFAIL(strdup(namespace)) : NULL; When printed, the NULL pointer is get back to the null string: sym->namespace ?: "" This saves 1 byte memory allocated for "", but lo...
```diff diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c index bc9ef40ac620..a7c979b0ea21 100644 --- a/scripts/mod/modpost.c +++ b/scripts/mod/modpost.c @@ -300,6 +300,13 @@ static bool contains_namespace(struct list_head *head, const char *namespace) { struct namespace_list *list; + /* + * The default ...
05aa61334592adb230749ff465b103ee10e63936
Analyze and fix the following issue in the Linux kernel code: drm: bridge: dw-mipi-dsi: Fix enable/disable of DSI controller
Problem Details: Before this patch, booting to Linux VT and doing a simple: echo 2 > /sys/class/graphics/fb0/blank echo 0 > /sys/class/graphics/fb0/blank would result in failures to re-enable the panel. Mode set callback is called only once during boot in this scenario, while calls to enable/disable callbacks are...
```diff diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c index b2efecf7d160..4291798bd70f 100644 --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c @@ -265,6 +265,7 @@ struct dw_mipi_dsi { struct dw_mipi_dsi...
e30cb0599799aac099209e3b045379613c80730e
Analyze and fix the following issue in the Linux kernel code: drm/sched: Make sure we wait for all dependencies in kill_jobs_cb()
Problem Details: drm_sched_entity_kill_jobs_cb() logic is omitting the last fence popped from the dependency array that was waited upon before drm_sched_entity_kill() was called (drm_sched_entity::dependency field), so we're basically waiting for all dependencies except one. In theory, this wait shouldn't be needed be...
```diff diff --git a/drivers/gpu/drm/scheduler/sched_entity.c b/drivers/gpu/drm/scheduler/sched_entity.c index e0a8890a62e2..42021d1f7e01 100644 --- a/drivers/gpu/drm/scheduler/sched_entity.c +++ b/drivers/gpu/drm/scheduler/sched_entity.c @@ -155,16 +155,32 @@ static void drm_sched_entity_kill_jobs_cb(struct dma_fence ...
ee77f3d602b0116203151fee372817c194970213
Analyze and fix the following issue in the Linux kernel code: selftests/bpf: Fix compilation failure for prog vrf_socket_lookup
Problem Details: When building the latest kernel/selftest with clang17 compiler: make LLVM=1 -j <== for kernel make -C tools/testing/selftests/bpf LLVM=1 -j <== for selftest I hit the following compilation error: [...] In file included from progs/vrf_socket_lookup.c:3: ...
```diff diff --git a/tools/testing/selftests/bpf/progs/vrf_socket_lookup.c b/tools/testing/selftests/bpf/progs/vrf_socket_lookup.c index 26e07a252585..bcfb6feb38c0 100644 --- a/tools/testing/selftests/bpf/progs/vrf_socket_lookup.c +++ b/tools/testing/selftests/bpf/progs/vrf_socket_lookup.c @@ -1,11 +1,12 @@ // SPDX-Li...
a9628e88776eb7d045cf46467f1afdd0f7fe72ea
Analyze and fix the following issue in the Linux kernel code: revert "net: align SO_RCVMARK required privileges with SO_MARK"
Problem Details: This reverts commit 1f86123b9749 ("net: align SO_RCVMARK required privileges with SO_MARK") because the reasoning in the commit message is not really correct: SO_RCVMARK is used for 'reading' incoming skb mark (via cmsg), as such it is more equivalent to 'getsockopt(SO_MARK)' which has no priv chec...
```diff diff --git a/net/core/sock.c b/net/core/sock.c index 24f2761bdb1d..6e5662ca00fe 100644 --- a/net/core/sock.c +++ b/net/core/sock.c @@ -1362,12 +1362,6 @@ set_sndbuf: __sock_set_mark(sk, val); break; case SO_RCVMARK: - if (!sockopt_ns_capable(sock_net(sk)->user_ns, CAP_NET_RAW) && - !sockopt_ns_cap...
dec24b3b339487e58ce2da2875e9ee0316cc7e70
Analyze and fix the following issue in the Linux kernel code: net: wwan: iosm: Convert single instance struct member to flexible array
Problem Details: struct mux_adth actually ends with multiple struct mux_adth_dg members. This is seen both in the comments about the member: /** * struct mux_adth - Structure of the Aggregated Datagram Table Header. ... * @dg: datagramm table with variable length */ and in the preparation for populating it: ...
```diff diff --git a/drivers/net/wwan/iosm/iosm_ipc_mux_codec.c b/drivers/net/wwan/iosm/iosm_ipc_mux_codec.c index d6b166fc5c0e..bff46f7ca59f 100644 --- a/drivers/net/wwan/iosm/iosm_ipc_mux_codec.c +++ b/drivers/net/wwan/iosm/iosm_ipc_mux_codec.c @@ -626,14 +626,12 @@ static void mux_dl_adb_decode(struct iosm_mux *ipc_...
2174a08db80d1efeea382e25ac41c4e7511eb6d6
Analyze and fix the following issue in the Linux kernel code: sch_netem: acquire qdisc lock in netem_change()
Problem Details: syzbot managed to trigger a divide error [1] in netem. It could happen if q->rate changes while netem_enqueue() is running, since q->rate is read twice. It turns out netem_change() always lacked proper synchronization. [1] divide error: 0000 [#1] SMP KASAN CPU: 1 PID: 7867 Comm: syz-executor.1 Not t...
```diff diff --git a/net/sched/sch_netem.c b/net/sched/sch_netem.c index 6ef3021e1169..e79be1b3e74d 100644 --- a/net/sched/sch_netem.c +++ b/net/sched/sch_netem.c @@ -966,6 +966,7 @@ static int netem_change(struct Qdisc *sch, struct nlattr *opt, if (ret < 0) return ret; + sch_tree_lock(sch); /* backup q->clg a...
e38910c0072b541a91954682c8b074a93e57c09b
Analyze and fix the following issue in the Linux kernel code: can: isotp: isotp_sendmsg(): fix return error fix on TX path
Problem Details: With commit d674a8f123b4 ("can: isotp: isotp_sendmsg(): fix return error on FC timeout on TX path") the missing correct return value in the case of a protocol error was introduced. But the way the error value has been read and sent to the user space does not follow the common scheme to clear the error...
```diff diff --git a/net/can/isotp.c b/net/can/isotp.c index 84f9aba02901..ca9d728d6d72 100644 --- a/net/can/isotp.c +++ b/net/can/isotp.c @@ -1112,8 +1112,9 @@ wait_free_buffer: if (err) goto err_event_drop; - if (sk->sk_err) - return -sk->sk_err; + err = sock_error(sk); + if (err) + return err; } ...
46448b36ff8c807194d5884a6efce00891e4bd02
Analyze and fix the following issue in the Linux kernel code: ARM: mvebu: fix unit address on armada-390-db flash
Problem Details: The unit address needs to be changed to match the reg property: arch/arm/boot/dts/marvell/armada-390-db.dts:84.10-106.4: Warning (spi_bus_reg): /soc/spi@10680/flash@1: SPI bus unit address format error, expected "0" Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Reviewed-by: Krzysztof Kozlowski...
```diff diff --git a/arch/arm/boot/dts/marvell/armada-390-db.dts b/arch/arm/boot/dts/marvell/armada-390-db.dts index 792d0a0184e8..20f518dbac97 100644 --- a/arch/arm/boot/dts/marvell/armada-390-db.dts +++ b/arch/arm/boot/dts/marvell/armada-390-db.dts @@ -81,7 +81,7 @@ pinctrl-0 = <&spi1_pins>; pinctrl-names = "defa...
146b6f6855e7656e8329910606595220c761daac
Analyze and fix the following issue in the Linux kernel code: platform/x86/amd/pmf: Register notify handler only if SPS is enabled
Problem Details: Power source notify handler is getting registered even when none of the PMF feature in enabled leading to a crash. ... [ 22.592162] Call Trace: [ 22.592164] <TASK> [ 22.592164] ? rcu_note_context_switch+0x5e0/0x660 [ 22.592166] ? __warn+0x81/0x130 [ 22.592171] ? rcu_note_context_switch+0...
```diff diff --git a/drivers/platform/x86/amd/pmf/core.c b/drivers/platform/x86/amd/pmf/core.c index ee5f124f78b6..7780705917b7 100644 --- a/drivers/platform/x86/amd/pmf/core.c +++ b/drivers/platform/x86/amd/pmf/core.c @@ -297,6 +297,8 @@ static void amd_pmf_init_features(struct amd_pmf_dev *dev) /* Enable Static Sli...
c7c059fba6fb19c3bc924925c984772e733cb594
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: Fix race condition in mirror installation
Problem Details: When mirroring to a gretap in hardware the device expects to be programmed with the egress port and all the encapsulating headers. This requires the driver to resolve the path the packet will take in the software data path and program the device accordingly. If the path cannot be resolved (in this cas...
```diff diff --git a/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh b/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh index c5095da7f6bf..aec752a22e9e 100755 --- a/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh +++ b/tools/testing/selftests/net/forwarding/mirror_gre_bridge...
2c56a751845ddfd3078ebe79981aaaa182629163
Analyze and fix the following issue in the Linux kernel code: drm/panel: simple: Add connector_type for innolux_at043tn24
Problem Details: The innolux at043tn24 display is a parallel LCD. Pass the 'connector_type' information to avoid the following warning: panel-simple panel: Specify missing connector_type Signed-off-by: Fabio Estevam <festevam@denx.de> Fixes: 41bcceb4de9c ("drm/panel: simple: Add support for Innolux AT043TN24") Review...
```diff diff --git a/drivers/gpu/drm/panel/panel-simple.c b/drivers/gpu/drm/panel/panel-simple.c index 065f378bba9d..454a13cca43a 100644 --- a/drivers/gpu/drm/panel/panel-simple.c +++ b/drivers/gpu/drm/panel/panel-simple.c @@ -2117,6 +2117,7 @@ static const struct panel_desc innolux_at043tn24 = { .height = 54, }, ...
a454850a815e62fa5d7c1eded0e8d56742613b94
Analyze and fix the following issue in the Linux kernel code: dt-bindings: phy: brcm,brcmstb-usb-phy: Fix error in "compatible" conditional schema
Problem Details: The conditional if/then schema has an error as the "enum" values have "const" in them. Drop the "const". Signed-off-by: Rob Herring <robh@kernel.org> Fixes: 46b616c1574d ("dt-bindings: phy: brcm, brcmstb-usb-phy: add BCM4908 binding") Acked-by: Rafał Miłecki <rafal@milecki.pl> Message-ID: <20230621230...
```diff diff --git a/Documentation/devicetree/bindings/phy/brcm,brcmstb-usb-phy.yaml b/Documentation/devicetree/bindings/phy/brcm,brcmstb-usb-phy.yaml index 43a4b880534c..580fbe37b37f 100644 --- a/Documentation/devicetree/bindings/phy/brcm,brcmstb-usb-phy.yaml +++ b/Documentation/devicetree/bindings/phy/brcm,brcmstb-us...
03bd158e1535e68bcd2b1e095b0ebcad7c84bd20
Analyze and fix the following issue in the Linux kernel code: remoteproc: stm32: use correct format strings on 64-bit
Problem Details: With CONFIG_ARCH_STM32 making it into arch/arm64, a couple of format strings no longer work, since they rely on size_t being compatible with %x, or they print an 'int' using %z: drivers/remoteproc/stm32_rproc.c: In function 'stm32_rproc_mem_alloc': drivers/remoteproc/stm32_rproc.c:122:22: error: forma...
```diff diff --git a/drivers/remoteproc/Kconfig b/drivers/remoteproc/Kconfig index a850e9f486dd..48845dc8fa85 100644 --- a/drivers/remoteproc/Kconfig +++ b/drivers/remoteproc/Kconfig @@ -313,7 +313,7 @@ config ST_SLIM_REMOTEPROC config STM32_RPROC tristate "STM32 remoteproc support" - depends on ARCH_STM32 + depen...
2c470dbbd32ff7f864e77397269cbb7dc453cfa2
Analyze and fix the following issue in the Linux kernel code: can: kvaser_pciefd: Define unsigned constants with type suffix 'U'
Problem Details: Define unsigned constants with type suffix 'U' Signed-off-by: Jimmy Assarsson <extja@kvaser.com> Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr> Link: https://lore.kernel.org/all/20230529134248.752036-6-extja@kvaser.com Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
```diff diff --git a/drivers/net/can/kvaser_pciefd.c b/drivers/net/can/kvaser_pciefd.c index 88bad2c2b641..abb556fb5cb6 100644 --- a/drivers/net/can/kvaser_pciefd.c +++ b/drivers/net/can/kvaser_pciefd.c @@ -25,12 +25,12 @@ MODULE_DESCRIPTION("CAN driver for Kvaser CAN/PCIe devices"); #define KVASER_PCIEFD_WAIT_TIMEO...
ec681b91befa982477e24a150dd6452427fe6473
Analyze and fix the following issue in the Linux kernel code: can: kvaser_pciefd: Set hardware timestamp on transmitted packets
Problem Details: Set hardware timestamp on transmitted packets. Fixes: 26ad340e582d ("can: kvaser_pciefd: Add driver for Kvaser PCIEcan devices") Signed-off-by: Jimmy Assarsson <extja@kvaser.com> Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr> Link: https://lore.kernel.org/all/20230529134248.752036-5-extja@k...
```diff diff --git a/drivers/net/can/kvaser_pciefd.c b/drivers/net/can/kvaser_pciefd.c index 7646338d4d44..88bad2c2b641 100644 --- a/drivers/net/can/kvaser_pciefd.c +++ b/drivers/net/can/kvaser_pciefd.c @@ -1485,6 +1485,7 @@ static void kvaser_pciefd_handle_nack_packet(struct kvaser_pciefd_can *can, if (skb) { c...
76c66ddf7f899b6a9cbd9098990b90f77a8bea9c
Analyze and fix the following issue in the Linux kernel code: can: kvaser_pciefd: Remove handler for unused KVASER_PCIEFD_PACK_TYPE_EFRAME_ACK
Problem Details: The Kvaser KCAN controller got a feature to send error frames on request. The packet KVASER_PCIEFD_PACK_TYPE_EFRAME_ACK signals that the requested error frame was transmitted. Since this feature is not supported by the driver, drop the handler and add KVASER_PCIEFD_PACK_TYPE_EFRAME_ACK to the list of u...
```diff diff --git a/drivers/net/can/kvaser_pciefd.c b/drivers/net/can/kvaser_pciefd.c index d60d17199a1b..1821ffa4ca79 100644 --- a/drivers/net/can/kvaser_pciefd.c +++ b/drivers/net/can/kvaser_pciefd.c @@ -1472,40 +1472,6 @@ static int kvaser_pciefd_handle_status_packet(struct kvaser_pciefd *pcie, return 0; } -st...
7c921556c04f1907e68e57610f315d8873320ad7
Analyze and fix the following issue in the Linux kernel code: can: kvaser_pciefd: Remove useless write to interrupt register
Problem Details: The PCI interrupt register, KVASER_PCIEFD_IRQ_REG, is level triggered. Writing to the register doesn't affect it. Fixes: 26ad340e582d ("can: kvaser_pciefd: Add driver for Kvaser PCIEcan devices") Signed-off-by: Jimmy Assarsson <extja@kvaser.com> Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr...
```diff diff --git a/drivers/net/can/kvaser_pciefd.c b/drivers/net/can/kvaser_pciefd.c index be189edb256c..d60d17199a1b 100644 --- a/drivers/net/can/kvaser_pciefd.c +++ b/drivers/net/can/kvaser_pciefd.c @@ -1768,7 +1768,6 @@ static irqreturn_t kvaser_pciefd_irq_handler(int irq, void *dev) kvaser_pciefd_transmit_irq...
9fde4c557f78ee2f3626e92b4089ce9d54a2573a
Analyze and fix the following issue in the Linux kernel code: can: length: fix bitstuffing count
Problem Details: The Stuff Bit Count is always coded on 4 bits [1]. Update the Stuff Bit Count size accordingly. In addition, the CRC fields of CAN FD Frames contain stuff bits at fixed positions called fixed stuff bits [2]. The CRC field starts with a fixed stuff bit and then has another fixed stuff bit after each fo...
```diff diff --git a/include/linux/can/length.h b/include/linux/can/length.h index 69336549d24f..b8c12c83bc51 100644 --- a/include/linux/can/length.h +++ b/include/linux/can/length.h @@ -72,17 +72,18 @@ * Error Status Indicator (ESI) 1 * Data length code (DLC) 4 * Data field 0...512 - * Stuff Bit Count (SBC)...
10711b11102bfc351240982d46a51d4eecc28c10
Analyze and fix the following issue in the Linux kernel code: can: length: fix description of the RRS field
Problem Details: The CAN-FD frames only have one reserved bit. The bit corresponding to Classical CAN frame's RTR bit is called the "Remote Request Substitution (RRS)" [1]. N.B. The RRS is not to be confused with the Substitute Remote Request (SRR). Fix the description in the CANFD_FRAME_OVERHEAD_SFF/EFF macros. The...
```diff diff --git a/include/linux/can/length.h b/include/linux/can/length.h index b8c12c83bc51..521fdbce2d69 100644 --- a/include/linux/can/length.h +++ b/include/linux/can/length.h @@ -1,6 +1,7 @@ /* SPDX-License-Identifier: GPL-2.0 */ /* Copyright (C) 2020 Oliver Hartkopp <socketcan@hartkopp.net> * Copyright (C)...
3d68f116ccdfe8cd3a4923b47ae55401fd85d74b
Analyze and fix the following issue in the Linux kernel code: can: m_can: fix coding style
Problem Details: This patch aligns code to match open parenthesis and removes a trailing whitespace. Fixes: eb38c2053b67 ("can: rx-offload: rename can_rx_offload_queue_sorted() -> can_rx_offload_queue_timestamp()") Fixes: f5071d9e729d ("can: m_can: m_can_handle_bus_errors(): add support for handling DLEC error on CAN-...
```diff diff --git a/drivers/net/can/m_can/m_can.c b/drivers/net/can/m_can/m_can.c index a5003435802b..c5af92bcc9c9 100644 --- a/drivers/net/can/m_can/m_can.c +++ b/drivers/net/can/m_can/m_can.c @@ -469,7 +469,7 @@ static void m_can_receive_skb(struct m_can_classdev *cdev, int err; err = can_rx_offload_queue_ti...
8a9d8a3c8a05fdb9d076905855bc0d5b5ee8c881
Analyze and fix the following issue in the Linux kernel code: can: ti_hecc: fix coding style
Problem Details: This patch aligns code to match open parenthesis. Link: https://lore.kernel.org/all/20230620131130.240180-3-mkl@pengutronix.de Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
```diff diff --git a/drivers/net/can/ti_hecc.c b/drivers/net/can/ti_hecc.c index 9bab0b4cc449..54284661992e 100644 --- a/drivers/net/can/ti_hecc.c +++ b/drivers/net/can/ti_hecc.c @@ -625,7 +625,7 @@ static int ti_hecc_error(struct net_device *ndev, int int_status, timestamp = hecc_read(priv, HECC_CANLNT); err =...
fe6027fe097a173d12067e781143bc1cd2fb1a57
Analyze and fix the following issue in the Linux kernel code: can: rx-offload: fix coding style
Problem Details: This patch aligns code to match open parenthesis. Link: https://lore.kernel.org/all/20230620131130.240180-2-mkl@pengutronix.de Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
```diff diff --git a/drivers/net/can/dev/rx-offload.c b/drivers/net/can/dev/rx-offload.c index 81ebf0562c89..161e45a7e8c1 100644 --- a/drivers/net/can/dev/rx-offload.c +++ b/drivers/net/can/dev/rx-offload.c @@ -220,7 +220,7 @@ int can_rx_offload_irq_offload_fifo(struct can_rx_offload *offload) EXPORT_SYMBOL_GPL(can_rx...
8a99f2ada0b808aaaa3e2f13c15e623c7fe329bd
Analyze and fix the following issue in the Linux kernel code: can: esd_usb: Use consistent prefix ESD_USB_ for macros
Problem Details: Rename the following macros: - ESD_RTR to ESD_USB_RTR - ESD_EV_CAN_ERROR_EXT to ESD_USB_EV_CAN_ERROR_EXT Additionally remove the double newline trailing to definition of ESD_USB_RTR. Signed-off-by: Frank Jungclaus <frank.jungclaus@esd.eu> Link: https://lore.kernel.org/r/20230523173105.3175086-3-frank...
```diff diff --git a/drivers/net/can/usb/esd_usb.c b/drivers/net/can/usb/esd_usb.c index d40a04db7458..6201637ac0ff 100644 --- a/drivers/net/can/usb/esd_usb.c +++ b/drivers/net/can/usb/esd_usb.c @@ -43,8 +43,7 @@ MODULE_LICENSE("GPL v2"); #define ESD_USB_CMD_IDADD 6 /* also used for IDADD_REPLY */ /* esd CAN messa...
1336ca2d46017d4249a9bd6a9a403d1e86109751
Analyze and fix the following issue in the Linux kernel code: can: esd_usb: Don't bother the user with nonessential log message
Problem Details: Replace a netdev_info(), emitting an informational message about the BTR value to be send to the controller, with a debug message by means of netdev_dbg(). Link: https://lore.kernel.org/all/20230509-superglue-hazy-38108aa66bfa-mkl@pengutronix.de/ Suggested-by: Marc Kleine-Budde <mkl@pengutronix.de> Su...
```diff diff --git a/drivers/net/can/usb/esd_usb.c b/drivers/net/can/usb/esd_usb.c index c10fa578a5b0..1399b832ea3f 100644 --- a/drivers/net/can/usb/esd_usb.c +++ b/drivers/net/can/usb/esd_usb.c @@ -955,7 +955,7 @@ static int esd_usb_2_set_bittiming(struct net_device *netdev) msg->setbaud.rsvd = 0; msg->setbaud.bau...
8ef426e1f605cea86f9375ca75b59b3e7afab5f7
Analyze and fix the following issue in the Linux kernel code: can: esd_usb: Prefix all structures with the device name
Problem Details: Prefix all the structures with the device name. For commonly used structures make use of (the module name) esd_usb_. For esd CAN-USB/2 and CAN-USB/Micro specific structures use esd_usb_2_ and esd_usb_m. Link: https://lore.kernel.org/all/CAMZ6RqLaDNy-fZ2G0+QMhUEckkXLL+ZyELVSDFmqpd++aBzZQg@mail.gmail.co...
```diff diff --git a/drivers/net/can/usb/esd_usb.c b/drivers/net/can/usb/esd_usb.c index b7d5a82d602b..842e4dd187d4 100644 --- a/drivers/net/can/usb/esd_usb.c +++ b/drivers/net/can/usb/esd_usb.c @@ -89,13 +89,13 @@ MODULE_LICENSE("GPL v2"); #define ESD_USB_MAX_RX_URBS 4 #define ESD_USB_MAX_TX_URBS 16 /* must be pow...
7e6689b34a815bd379dfdbe9855d36f395ef056c
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Set address alignment for endpoint mode
Problem Details: The address translation unit of the rockchip EP controller does not use the lower 8 bits of a PCIe-space address to map local memory. Thus we must set the align feature field to 256 to let the user know about this constraint. Link: https://lore.kernel.org/r/20230418074700.1083505-12-rick.wertenbroek@g...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index edfced311a9f..0af0e965fb57 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -442,6 +442,7 @@ static const struct pci_epc_features rockchip_pcie_epc_fe...
a52587e0bee14cbeeadf48a24013828cb04b8df8
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Don't advertise MSI-X in PCIe capabilities
Problem Details: The RK3399 PCIe endpoint controller cannot generate MSI-X IRQs. This is documented in the RK3399 technical reference manual (TRM) section 17.5.9 "Interrupt Support". MSI-X capability should therefore not be advertised. Remove the MSI-X capability by editing the capability linked-list. The previous ent...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index 63fbb379638b..edfced311a9f 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -507,6 +507,7 @@ static int rockchip_pcie_ep_probe(struct platform_device ...
8962b2cb39119cbda4fc69a1f83957824f102f81
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Use u32 variable to access 32-bit registers
Problem Details: Previously u16 variables were used to access 32-bit registers, this resulted in not all of the data being read from the registers. Also the left shift of more than 16-bits would result in moving data out of the variable. Use u32 variables to access 32-bit registers Link: https://lore.kernel.org/r/2023...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index 771f1bb93251..63fbb379638b 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -271,15 +271,15 @@ static int rockchip_pcie_ep_set_msi(struct pci_epc *epc...
dc73ed0f1b8bddd7f2bf70d123e68ffc99ad71ce
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Fix window mapping and address translation for endpoint
Problem Details: The RK3399 PCI endpoint core has 33 windows for PCIe space, now in the driver up to 32 fixed size (1M) windows are used and pages are allocated and mapped accordingly. The driver first used a single window and allocated space inside which caused translation issues (between CPU space and PCI space) beca...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index d6d4b0f2e733..771f1bb93251 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -64,52 +64,29 @@ static void rockchip_pcie_clear_ep_ob_atu(struct rockchip...
166e89d99dd85a856343cca51eee781b793801f2
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Fix legacy IRQ generation for RK3399 PCIe endpoint core
Problem Details: Fix legacy IRQ generation for RK3399 PCIe endpoint core according to the technical reference manual (TRM). Assert and deassert legacy interrupt (INTx) through the legacy interrupt control register ("PCIE_CLIENT_LEGACY_INT_CTRL") instead of manually generating a PCIe message. The generation of the legac...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index d00baed65eba..d6d4b0f2e733 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -337,48 +337,25 @@ static int rockchip_pcie_ep_get_msi(struct pci_epc *epc...
9dd3c7c4c8c3f7f010d9cdb7c3f42506d93c9527
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Add poll and timeout to wait for PHY PLLs to be locked
Problem Details: The RK3399 PCIe controller should wait until the PHY PLLs are locked. Add poll and timeout to wait for PHY PLLs to be locked. If they cannot be locked generate error message and jump to error handler. Accessing registers in the PHY clock domain when PLLs are not locked causes hang The PHY PLLs status i...
```diff diff --git a/drivers/pci/controller/pcie-rockchip.c b/drivers/pci/controller/pcie-rockchip.c index 990a00e08bc5..1aa84035a8bc 100644 --- a/drivers/pci/controller/pcie-rockchip.c +++ b/drivers/pci/controller/pcie-rockchip.c @@ -14,6 +14,7 @@ #include <linux/clk.h> #include <linux/delay.h> #include <linux/gpio...
f397fd4ac1fa3afcabd8cee030f953ccaed2a364
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Assert PCI Configuration Enable bit after probe
Problem Details: Assert PCI Configuration Enable bit after probe. When this bit is left to 0 in the endpoint mode, the RK3399 PCIe endpoint core will generate configuration request retry status (CRS) messages back to the root complex. Assert this bit after probe to allow the RK3399 PCIe endpoint core to reply to config...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index 9b835377bd9e..d00baed65eba 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -623,6 +623,9 @@ static int rockchip_pcie_ep_probe(struct platform_device ...
1f1c42ece18de365c976a060f3c8eb481b038e3a
Analyze and fix the following issue in the Linux kernel code: PCI: rockchip: Write PCI Device ID to correct register
Problem Details: Write PCI Device ID (DID) to the correct register. The Device ID was not updated through the correct register. Device ID was written to a read-only register and therefore did not work. The Device ID is now set through the correct register. This is documented in the RK3399 TRM section 17.6.6.1.1 Link: ...
```diff diff --git a/drivers/pci/controller/pcie-rockchip-ep.c b/drivers/pci/controller/pcie-rockchip-ep.c index d5c477020417..9b835377bd9e 100644 --- a/drivers/pci/controller/pcie-rockchip-ep.c +++ b/drivers/pci/controller/pcie-rockchip-ep.c @@ -115,6 +115,7 @@ static void rockchip_pcie_prog_ep_ob_atu(struct rockchip_...
9dc3a695da58f69ce580797a2fccea8262faa9cd
Analyze and fix the following issue in the Linux kernel code: can: esd_usb: Use consistent prefixes for macros
Problem Details: Add the consistent prefix ESD_USB_ to all macros defined within esd_usb.c. For macros specific to esd CAN-USB/2 use ESD_USB_2_ as prefix. For macros specific to esd CAN-USB/Micro use ESD_USB_M_ as prefix. Change the macro ESD_USB_3_SAMPLES to ESD_USB_TRIPLE_SAMPLES to not mix up with the prefix ESD_USB...
```diff diff --git a/drivers/net/can/usb/esd_usb.c b/drivers/net/can/usb/esd_usb.c index 310cae5c4648..b7d5a82d602b 100644 --- a/drivers/net/can/usb/esd_usb.c +++ b/drivers/net/can/usb/esd_usb.c @@ -23,33 +23,33 @@ MODULE_DESCRIPTION("CAN driver for esd electronics gmbh CAN-USB/2 and CAN-USB/Mi MODULE_LICENSE("GPL v2"...
7f4e09700bdc13ce9aafa279bc999051e9bcda35
Analyze and fix the following issue in the Linux kernel code: wifi: mac80211: report all unusable beacon frames
Problem Details: Properly check for RX_DROP_UNUSABLE now that the new drop reason infrastructure is used. Without this change, the comparison will always be false as a more specific reason is given in the lower bits of result. Fixes: baa951a1c177 ("mac80211: use the new drop reasons infrastructure") Signed-off-by: Ben...
```diff diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c index d996aa2579df..fc6e130364da 100644 --- a/net/mac80211/rx.c +++ b/net/mac80211/rx.c @@ -2110,7 +2110,7 @@ ieee80211_rx_h_decrypt(struct ieee80211_rx_data *rx) /* either the frame has been decrypted or will be dropped */ status->flag |= RX_FLAG_DECRYPTED...
00079f18c24f373797cc38273c1bc0b475469d2b
Analyze and fix the following issue in the Linux kernel code: selftests: mptcp: join: skip check if MIB counter not supported (part 2)
Problem Details: Selftests are supposed to run on any kernels, including the old ones not supporting all MPTCP features. One of them is the MPTCP MIB counters introduced in commit fc518953bc9c ("mptcp: add and use MIB counter infrastructure") and more later. The MPTCP Join selftest heavily relies on these counters. I...
```diff diff --git a/tools/testing/selftests/net/mptcp/mptcp_join.sh b/tools/testing/selftests/net/mptcp/mptcp_join.sh index 1b68fe1c0885..a7973d6a40a0 100755 --- a/tools/testing/selftests/net/mptcp/mptcp_join.sh +++ b/tools/testing/selftests/net/mptcp/mptcp_join.sh @@ -1683,12 +1683,12 @@ chk_add_tx_nr() timeout=$(i...
57fc0f1ceaa4016354cf6f88533e20b56190e41a
Analyze and fix the following issue in the Linux kernel code: mptcp: ensure listener is unhashed before updating the sk status
Problem Details: The MPTCP protocol access the listener subflow in a lockless manner in a couple of places (poll, diag). That works only if the msk itself leaves the listener status only after that the subflow itself has been closed/disconnected. Otherwise we risk deadlock in diag, as reported by Christoph. Address th...
```diff diff --git a/net/mptcp/pm_netlink.c b/net/mptcp/pm_netlink.c index 59f8f3124855..1224dfca5bf3 100644 --- a/net/mptcp/pm_netlink.c +++ b/net/mptcp/pm_netlink.c @@ -1047,6 +1047,7 @@ static int mptcp_pm_nl_create_listen_socket(struct sock *sk, if (err) return err; + inet_sk_state_store(newsk, TCP_LISTEN); ...
81c1d029016001f994ce1c46849c5e9900d8eab8
Analyze and fix the following issue in the Linux kernel code: mptcp: consolidate fallback and non fallback state machine
Problem Details: An orphaned msk releases the used resources via the worker, when the latter first see the msk in CLOSED status. If the msk status transitions to TCP_CLOSE in the release callback invoked by the worker's final release_sock(), such instance of the workqueue will not take any action. Additionally the MP...
```diff diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index 9a40dae31cec..27d206f7af62 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -44,7 +44,7 @@ enum { static struct percpu_counter mptcp_sockets_allocated ____cacheline_aligned_in_smp; static void __mptcp_destroy_sock(struct sock *sk)...
56a666c48b038e91b76471289e2cf60c79d326b9
Analyze and fix the following issue in the Linux kernel code: mptcp: fix possible list corruption on passive MPJ
Problem Details: At passive MPJ time, if the msk socket lock is held by the user, the new subflow is appended to the msk->join_list under the msk data lock. In mptcp_release_cb()/__mptcp_flush_join_list(), the subflows in that list are moved from the join_list into the conn_list under the msk socket lock. Append and ...
```diff diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index ee357700b27b..9a40dae31cec 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -850,12 +850,12 @@ static bool __mptcp_finish_join(struct mptcp_sock *msk, struct sock *ssk) return true; } -static void __mptcp_flush_join_list(struct s...
0ad529d9fd2bfa3fc619552a8d2fb2f2ef0bce2e
Analyze and fix the following issue in the Linux kernel code: mptcp: fix possible divide by zero in recvmsg()
Problem Details: Christoph reported a divide by zero bug in mptcp_recvmsg(): divide error: 0000 [#1] PREEMPT SMP CPU: 1 PID: 19978 Comm: syz-executor.6 Not tainted 6.4.0-rc2-gffcc7899081b #20 Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.11.0-2.el7 04/01/2014 RIP: 0010:__tcp_select_window+0x30e/0x420 n...
```diff diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index 86f8a7621aff..ee357700b27b 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -3082,6 +3082,12 @@ static int mptcp_disconnect(struct sock *sk, int flags) { struct mptcp_sock *msk = mptcp_sk(sk); + /* Deny disconnect if other thread...
c2b2ae3925b65070adb27d5a31a31c376f26dec7
Analyze and fix the following issue in the Linux kernel code: mptcp: handle correctly disconnect() failures
Problem Details: Currently the mptcp code has assumes that disconnect() can fail only at mptcp_sendmsg_fastopen() time - to avoid a deadlock scenario - and don't even bother returning an error code. Soon mptcp_disconnect() will handle more error conditions: let's track them explicitly. As a bonus, explicitly annotate...
```diff diff --git a/net/mptcp/protocol.c b/net/mptcp/protocol.c index 67311e7d5b21..86f8a7621aff 100644 --- a/net/mptcp/protocol.c +++ b/net/mptcp/protocol.c @@ -1727,7 +1727,13 @@ static int mptcp_sendmsg_fastopen(struct sock *sk, struct msghdr *msg, if (ret && ret != -EINPROGRESS && ret != -ERESTARTSYS && ret != ...
5dfbbaa208f5429a02ccb410ae3515222bbe64ef
Analyze and fix the following issue in the Linux kernel code: net: ena: Fix rst format issues in readme
Problem Details: This patch fixes a warning in the ena documentation file identified by the kernel automatic tools. The patch also adds a missing newline between sections. Signed-off-by: David Arinzon <darinzon@amazon.com> Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202...
```diff diff --git a/Documentation/networking/device_drivers/ethernet/amazon/ena.rst b/Documentation/networking/device_drivers/ethernet/amazon/ena.rst index 491492677632..5eaa3ab6c73e 100644 --- a/Documentation/networking/device_drivers/ethernet/amazon/ena.rst +++ b/Documentation/networking/device_drivers/ethernet/amaz...
4b2e28758dafeeaa34819296821686addfddaa6a
Analyze and fix the following issue in the Linux kernel code: scsi: target: tcmu: Replace strlcpy() with strscpy()
Problem Details: strlcpy() reads the entire source buffer first. This read may exceed the destination size limit. This is both inefficient and can lead to linear read overflows if a source string is not NUL-terminated [1]. In an effort to remove strlcpy() completely [2], replace strlcpy() here with strscpy(). No re...
```diff diff --git a/drivers/target/target_core_user.c b/drivers/target/target_core_user.c index 15ffc8d2ac7b..22cc6cac0ba2 100644 --- a/drivers/target/target_core_user.c +++ b/drivers/target/target_core_user.c @@ -2820,14 +2820,14 @@ static ssize_t tcmu_dev_config_store(struct config_item *item, const char *page, ...
d1e8a9fbb39292e6666192565b51bbda781f9f04
Analyze and fix the following issue in the Linux kernel code: scsi: ncr53c8xx: Replace strlcpy() with strscpy()
Problem Details: strlcpy() reads the entire source buffer first. This read may exceed the destination size limit. This is both inefficient and can lead to linear read overflows if a source string is not NUL-terminated [1]. In an effort to remove strlcpy() completely [2], replace strlcpy() here with strscpy(). No re...
```diff diff --git a/drivers/scsi/ncr53c8xx.c b/drivers/scsi/ncr53c8xx.c index 4458449c960b..35869b4f9329 100644 --- a/drivers/scsi/ncr53c8xx.c +++ b/drivers/scsi/ncr53c8xx.c @@ -4555,7 +4555,7 @@ static void ncr_detach(struct ncb *np) char inst_name[16]; /* Local copy so we don't access np after freeing it! */ -...
00c2cae6b66a913e8d9a39073988e4aa5baff0d8
Analyze and fix the following issue in the Linux kernel code: scsi: lpfc: Fix lpfc_name struct packing
Problem Details: clang points out that the lpfc_name structure has an 8-byte alignment requirement on most architectures, but is embedded in a number of other structures that are forced to be only 1-byte aligned: drivers/scsi/lpfc/lpfc_hw.h:1516:30: error: field pe within 'struct lpfc_fdmi_reg_port_list' is less align...
```diff diff --git a/drivers/scsi/lpfc/lpfc_hw.h b/drivers/scsi/lpfc/lpfc_hw.h index 663755842e4a..aaea3e31944d 100644 --- a/drivers/scsi/lpfc/lpfc_hw.h +++ b/drivers/scsi/lpfc/lpfc_hw.h @@ -365,7 +365,7 @@ struct lpfc_name { uint8_t IEEE[6]; /* FC IEEE address */ } s; uint8_t wwn[8]; - uint64_t name; + uin...
ca4fa87435370747cac535cecfd08672bb679487
Analyze and fix the following issue in the Linux kernel code: selftests: tc-testing: add one test for flushing explicitly created chain
Problem Details: Add the test for additional reference to chains that are explicitly created by RTM_NEWCHAIN message. The test result: 1..1 ok 1 c2b4 - soft lockup alarm will be not generated after delete the prio 0 filter of the chain This is a follow up to commit c9a82bec02c3 ("net/sched: cls_api: Fix lockup o...
```diff diff --git a/tools/testing/selftests/tc-testing/tc-tests/infra/filter.json b/tools/testing/selftests/tc-testing/tc-tests/infra/filter.json new file mode 100644 index 000000000000..c4c778e83da2 --- /dev/null +++ b/tools/testing/selftests/tc-testing/tc-tests/infra/filter.json @@ -0,0 +1,25 @@ +[ + { + "...
1ca09f5746edd5e483d144118497f622af9dbe60
Analyze and fix the following issue in the Linux kernel code: dt-bindings: net: micrel,ks8851: allow SPI device properties
Problem Details: The Micrel KS8851 can be attached to SPI or parallel bus and the difference is expressed in compatibles. Allow common SPI properties when this is a SPI variant and narrow the parallel memory bus properties to the second case. This fixes dtbs_check warning: qcom-msm8960-cdp.dtb: ethernet@0: Unevalu...
```diff diff --git a/Documentation/devicetree/bindings/net/micrel,ks8851.yaml b/Documentation/devicetree/bindings/net/micrel,ks8851.yaml index b44d83554ef5..b726c6e14633 100644 --- a/Documentation/devicetree/bindings/net/micrel,ks8851.yaml +++ b/Documentation/devicetree/bindings/net/micrel,ks8851.yaml @@ -44,13 +44,13 ...
6a0a6dd8df9b6e9c0ed8d99bbfb4e5e2f8c9834f
Analyze and fix the following issue in the Linux kernel code: dt-bindings: net: bluetooth: qualcomm: document VDD_CH1
Problem Details: WCN3990 comes with two chains - CH0 and CH1 - where each takes VDD regulator. It seems VDD_CH1 is optional (Linux driver does not care about it), so document it to fix dtbs_check warnings like: sdm850-lenovo-yoga-c630.dtb: bluetooth: 'vddch1-supply' does not match any of the regexes: 'pinctrl-[0-9]...
```diff diff --git a/Documentation/devicetree/bindings/net/bluetooth/qualcomm-bluetooth.yaml b/Documentation/devicetree/bindings/net/bluetooth/qualcomm-bluetooth.yaml index 68f78b90d23a..604985c8068e 100644 --- a/Documentation/devicetree/bindings/net/bluetooth/qualcomm-bluetooth.yaml +++ b/Documentation/devicetree/bind...
9a5cb79762e0eda17ca15c2a6eaca4622383c21c
Analyze and fix the following issue in the Linux kernel code: bpf: Fix bpf socket lookup from tc/xdp to respect socket VRF bindings
Problem Details: When calling bpf_sk_lookup_tcp(), bpf_sk_lookup_udp() or bpf_skc_lookup_tcp() from tc/xdp ingress, VRF socket bindings aren't respoected, i.e. unbound sockets are returned, and bound sockets aren't found. VRF binding is determined by the sdif argument to sk_lookup(), however when called from tc the IP...
```diff diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 08fbd4622ccf..8c95ebbcf203 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h @@ -5090,6 +5090,15 @@ static inline bool netif_is_l3_slave(const struct net_device *dev) return dev->priv_flags & IFF_L3MDEV_SLAVE; } +...
664bc72dd20073be227f9e68b3db75313c6926f8
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: one_armed_router: Use port MAC for bridge address
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/one_armed_router.sh b/tools/testing/selftests/drivers/net/mlxsw/one_armed_router.sh index f02d83e94576..fca0e1e642c6 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/one_armed_router.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/one_armed_router....
5541577521cc2e22bc84ba92be24959671006283
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: vxlan: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge (this holds for all bridges used here), the bridge MAC address does not have the same prefix as other interfaces in the ...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/vxlan.sh b/tools/testing/selftests/drivers/net/mlxsw/vxlan.sh index 99a332b712f0..4687b0a7dffb 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/vxlan.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/vxlan.sh @@ -444,8 +444,12 @@ offload_indication_s...
08035d8e354d9fc652c9d12668e89d83edc8f974
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: spectrum: q_in_vni_veto: Disable IPv6 autogen on a bridge
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/spectrum/q_in_vni_veto.sh b/tools/testing/selftests/drivers/net/mlxsw/spectrum/q_in_vni_veto.sh index f0443b1b05b9..60753d46a2d4 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/spectrum/q_in_vni_veto.sh +++ b/tools/testing/selftests/drivers/net/mlxsw...
ea2d5f757e914fa0f82949e130ee9da0ee931e59
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: qos_mc_aware: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge (this holds for both bridges used here), the bridge MAC address does not have the same prefix as other interfaces in the...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/qos_mc_aware.sh b/tools/testing/selftests/drivers/net/mlxsw/qos_mc_aware.sh index c8e55fa91660..6d892de43fa8 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/qos_mc_aware.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/qos_mc_aware.sh @@ -135,11 +1...
ec7023e6745e6fb34cd855522cb8f995194bdbf1
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: qos_ets_strict: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge (this holds for both bridges used here), the bridge MAC address does not have the same prefix as other interfaces in the...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/qos_ets_strict.sh b/tools/testing/selftests/drivers/net/mlxsw/qos_ets_strict.sh index 690d8daa71b4..fee74f215cec 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/qos_ets_strict.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/qos_ets_strict.sh @@ -1...
6349f9bbbfb2bda12c0a633965d03435d18d930f
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: qos_dscp_bridge: Disable IPv6 autogen on a bridge
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/qos_dscp_bridge.sh b/tools/testing/selftests/drivers/net/mlxsw/qos_dscp_bridge.sh index 87c41f5727c9..914c63d6318a 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/qos_dscp_bridge.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/qos_dscp_bridge.sh @...
32b3a7bf8570d24b30d1961fb3eaddb9f1c3250a
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: mirror_gre_scale: Disable IPv6 autogen on a bridge
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/mirror_gre_scale.sh b/tools/testing/selftests/drivers/net/mlxsw/mirror_gre_scale.sh index e00435753008..e5589e2fca85 100644 --- a/tools/testing/selftests/drivers/net/mlxsw/mirror_gre_scale.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/mirror_gre_scale....
a758dc469a9caf958c0f02426aa76162c89faa97
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: extack: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge (this holds for all bridges used here), the bridge MAC address does not have the same prefix as other interfaces in the ...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/extack.sh b/tools/testing/selftests/drivers/net/mlxsw/extack.sh index 7a0a99c1d22f..6fd422d38fe8 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/extack.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/extack.sh @@ -35,7 +35,9 @@ netdev_pre_up_test(...
8cfdd300a5e95fea14050cd86259bafb35244a2f
Analyze and fix the following issue in the Linux kernel code: selftests: mlxsw: q_in_q_veto: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. The swp enslavement to the 802.1ad bridge is not allowed, because RIFs are not allowed to be created for 802.1ad bridges, but the address indicates one needs to be created. Thus the ve...
```diff diff --git a/tools/testing/selftests/drivers/net/mlxsw/q_in_q_veto.sh b/tools/testing/selftests/drivers/net/mlxsw/q_in_q_veto.sh index 7edaed8eb86a..00d55b0e98c1 100755 --- a/tools/testing/selftests/drivers/net/mlxsw/q_in_q_veto.sh +++ b/tools/testing/selftests/drivers/net/mlxsw/q_in_q_veto.sh @@ -48,6 +48,7 @@...
5e71bf50c2e284e4b287d55336a1b2f47027624c
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: router_bridge: Use port MAC for bridge address
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/net/forwarding/router_bridge.sh b/tools/testing/selftests/net/forwarding/router_bridge.sh index ebc596a272f7..8ce0aed54ece 100755 --- a/tools/testing/selftests/net/forwarding/router_bridge.sh +++ b/tools/testing/selftests/net/forwarding/router_bridge.sh @@ -38,7 +38,8 @@ h2_...
8fd32576e650efe88e396febd494f12adf18262a
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: mirror_gre_*: Use port MAC for bridge address
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh b/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh index c5095da7f6bf..8ce3d95f1add 100755 --- a/tools/testing/selftests/net/forwarding/mirror_gre_bridge_1d.sh +++ b/tools/testing/selftests/net/forwarding/mirror_gre_bridge...
92c3bb5393db2f36e6a23ba7bb50b34c18c523f5
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: mirror_gre_*: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/net/forwarding/mirror_gre_bound.sh b/tools/testing/selftests/net/forwarding/mirror_gre_bound.sh index 360ca133bead..6c257ec03756 100755 --- a/tools/testing/selftests/net/forwarding/mirror_gre_bound.sh +++ b/tools/testing/selftests/net/forwarding/mirror_gre_bound.sh @@ -98,6 ...
f61018dc3e21ba0bee9caadf3015a65a7b4ce09f
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: pedit_dsfield: Disable IPv6 autogen on a bridge
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/net/forwarding/skbedit_priority.sh b/tools/testing/selftests/net/forwarding/skbedit_priority.sh index bde11dc27873..3dd5fcbd3eaa 100755 --- a/tools/testing/selftests/net/forwarding/skbedit_priority.sh +++ b/tools/testing/selftests/net/forwarding/skbedit_priority.sh @@ -54,7 ...
d7442b7d288e8a00290808623f77bc5ed87ba8e6
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: skbedit_priority: Disable IPv6 autogen on a bridge
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. At the time that the front panel port is enslaved to the bridge, the bridge MAC address does not have the same prefix as other interfaces in the system. On Nvidia Spectrum-1 machines a...
```diff diff --git a/tools/testing/selftests/net/forwarding/pedit_dsfield.sh b/tools/testing/selftests/net/forwarding/pedit_dsfield.sh index 64fbd211d907..af008fbf2725 100755 --- a/tools/testing/selftests/net/forwarding/pedit_dsfield.sh +++ b/tools/testing/selftests/net/forwarding/pedit_dsfield.sh @@ -60,7 +60,9 @@ h2_...
c801533304ca87e314ecc6fc43b9a7822f159f18
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: dual_vxlan_bridge: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. This will cause this selftest to fail spuriously. The swp enslavement to the 802.1ad bridge is not allowed, because RIFs are not allowed to be created for 802.1ad bridges, but the addr...
```diff diff --git a/tools/testing/selftests/net/forwarding/dual_vxlan_bridge.sh b/tools/testing/selftests/net/forwarding/dual_vxlan_bridge.sh index 5148d97a5df8..68ee92df3e07 100755 --- a/tools/testing/selftests/net/forwarding/dual_vxlan_bridge.sh +++ b/tools/testing/selftests/net/forwarding/dual_vxlan_bridge.sh @@ -1...
8c3736ce595bccb6322c44a1f853216e278aa635
Analyze and fix the following issue in the Linux kernel code: selftests: forwarding: q_in_vni: Disable IPv6 autogen on bridges
Problem Details: In a future patch, mlxsw will start adding RIFs to uppers of front panel port netdevices, if they have an IP address. This will cause this selftest to fail spuriously. The swp enslavement to the 802.1ad bridge is not allowed, because RIFs are not allowed to be created for 802.1ad bridges, but the addr...
```diff diff --git a/tools/testing/selftests/net/forwarding/q_in_vni.sh b/tools/testing/selftests/net/forwarding/q_in_vni.sh index 4c50c0234bce..798b13525c02 100755 --- a/tools/testing/selftests/net/forwarding/q_in_vni.sh +++ b/tools/testing/selftests/net/forwarding/q_in_vni.sh @@ -137,6 +137,7 @@ switch_create() { ...
36de5f303ca1bd6fce74815ef17ef3d8ff8737b5
Analyze and fix the following issue in the Linux kernel code: cgroup: Avoid -Wstringop-overflow warnings
Problem Details: Address the following -Wstringop-overflow warnings seen when built with ARM architecture and aspeed_g4_defconfig configuration (notice that under this configuration CGROUP_SUBSYS_COUNT == 0): kernel/cgroup/cgroup.c:1208:16: warning: 'find_existing_css_set' accessing 4 bytes in a region of size 0 [-Wstr...
```diff diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c index 065bebb4af9b..1404e8e8abf7 100644 --- a/kernel/cgroup/cgroup.c +++ b/kernel/cgroup/cgroup.c @@ -1198,6 +1198,9 @@ static struct css_set *find_css_set(struct css_set *old_cset, unsigned long key; int ssid; + if (!CGROUP_HAS_SUBSYS_CONFIG) +...
e8b4858b158eb31c0c3699280af78f34cdc9d993
Analyze and fix the following issue in the Linux kernel code: dt-bindings: bus: ti-sysc: fix typo
Problem Details: Fix typo (period vs comma) in list of valid clock names. Signed-off-by: Mans Rullgard <mans@mansr.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Link: https://lore.kernel.org/r/20230620200917.24958-1-mans@mansr.com Signed-off-by: Rob Herring <robh@kernel.org>
```diff diff --git a/Documentation/devicetree/bindings/bus/ti-sysc.yaml b/Documentation/devicetree/bindings/bus/ti-sysc.yaml index f089634f9466..6d7bca6c138e 100644 --- a/Documentation/devicetree/bindings/bus/ti-sysc.yaml +++ b/Documentation/devicetree/bindings/bus/ti-sysc.yaml @@ -97,7 +97,7 @@ properties: - en...
017fb83ee0612595ec70c65ddd83472706b02a50
Analyze and fix the following issue in the Linux kernel code: block: Improve kernel-doc headers
Problem Details: Fix the documentation of the devt_from_partuuid() return value. Fix the following two recently introduced kernel-doc warnings: block/bdev.c:570: warning: Function parameter or member 'hops' not described in 'bd_finish_claiming' block/early-lookup.c:46: warning: Function parameter or member 'devt' not...
```diff diff --git a/block/bdev.c b/block/bdev.c index 9bb54d9d02a6..979e28a46b98 100644 --- a/block/bdev.c +++ b/block/bdev.c @@ -561,6 +561,7 @@ static void bd_clear_claiming(struct block_device *whole, void *holder) * bd_finish_claiming - finish claiming of a block device * @bdev: block device of interest * @h...
a04de42460e271e532b43ad40e9fb07a9a09fe5c
Analyze and fix the following issue in the Linux kernel code: cgroup: remove obsolete comment on cgroup_on_dfl()
Problem Details: The debug feature is supported since commit 8cc38fa7fa31 ("cgroup: make debug an implicit controller on cgroup2"), update corresponding comment. Signed-off-by: Miaohe Lin <linmiaohe@huawei.com> Signed-off-by: Tejun Heo <tj@kernel.org>
```diff diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c index 04d1c0cde882..065bebb4af9b 100644 --- a/kernel/cgroup/cgroup.c +++ b/kernel/cgroup/cgroup.c @@ -313,8 +313,6 @@ bool cgroup_ssid_enabled(int ssid) * masks of ancestors. * * - blkcg: blk-throttle becomes properly hierarchical. - * - * - d...
9b53a13422162feac7c7ee58e5bc0e0a80a41963
Analyze and fix the following issue in the Linux kernel code: counter: Fix menuconfig "Counter support" submenu entries disappearance
Problem Details: The current placement of the I8254 Kconfig entry results in the disappearance of the "Counter support" submenu items in menuconfig. Move the I8254 above the menuconfig COUNTER entry to restore the intended submenu behavior. Fixes: d428487471ba ("counter: i8254: Introduce the Intel 8254 interface libra...
```diff diff --git a/drivers/counter/Kconfig b/drivers/counter/Kconfig index a61a4b9b8ec6..86536c2cc531 100644 --- a/drivers/counter/Kconfig +++ b/drivers/counter/Kconfig @@ -3,13 +3,6 @@ # Counter devices # -menuconfig COUNTER - tristate "Counter support" - help - This enables counter device support through the ...
12ec37be3faf9df7831ce210947f111b3417baf3
Analyze and fix the following issue in the Linux kernel code: wifi: ath10k: improve structure padding
Problem Details: Including an aligned structure inside of a packed one is ambiguous and can lead to misaligned data, as pointed out by this clang warning: drivers/net/wireless/ath/ath10k/htt.h:715:34: error: field prefix within 'struct htt_rx_indication' is less aligned than 'struct htt_rx_indication_prefix' and is us...
```diff diff --git a/drivers/net/wireless/ath/ath10k/htt.h b/drivers/net/wireless/ath/ath10k/htt.h index c051a22fce14..e0c9f45e7476 100644 --- a/drivers/net/wireless/ath/ath10k/htt.h +++ b/drivers/net/wireless/ath/ath10k/htt.h @@ -707,7 +707,7 @@ struct htt_rx_indication_prefix { __le16 fw_rx_desc_bytes; u8 pad0; ...
2aa083acea9f61be3280184384551178f510ff51
Analyze and fix the following issue in the Linux kernel code: wifi: ath9k: convert msecs to jiffies where needed
Problem Details: Since 'ieee80211_queue_delayed_work()' expects timeout in jiffies and not milliseconds, 'msecs_to_jiffies()' should be used in 'ath_restart_work()' and '__ath9k_flush()'. Fixes: d63ffc45c5d3 ("ath9k: rename tx_complete_work to hw_check_work") Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru> Acked-b...
```diff diff --git a/drivers/net/wireless/ath/ath9k/main.c b/drivers/net/wireless/ath/ath9k/main.c index 7f9f06ea8a05..6360d3356e25 100644 --- a/drivers/net/wireless/ath/ath9k/main.c +++ b/drivers/net/wireless/ath/ath9k/main.c @@ -203,7 +203,7 @@ void ath_cancel_work(struct ath_softc *sc) void ath_restart_work(struct ...
cb60fdf6e23068e0954b2a66855b7dc5d6019a87
Analyze and fix the following issue in the Linux kernel code: dt-bindings: phy: mixel,mipi-dsi-phy: Remove assigned-clock* properties
Problem Details: With dt-schema v2021.02 these properties are added by default. Some SoC (e.g. imx8mq) configure more than just one clock using these properties. Fixes: f9b0593dd4fc6 ("dt-bindings: phy: Convert mixel,mipi-dsi-phy to json-schema") Signed-off-by: Alexander Stein <alexander.stein@ew.tq-group.com> Reviewe...
```diff diff --git a/Documentation/devicetree/bindings/phy/mixel,mipi-dsi-phy.yaml b/Documentation/devicetree/bindings/phy/mixel,mipi-dsi-phy.yaml index 786cfd71cb7e..3c28ec50f097 100644 --- a/Documentation/devicetree/bindings/phy/mixel,mipi-dsi-phy.yaml +++ b/Documentation/devicetree/bindings/phy/mixel,mipi-dsi-phy.ya...
0eac9e977283d1573aa8c1f614afbe807aae62d1
Analyze and fix the following issue in the Linux kernel code: dt-bindings: phy: intel,combo-phy: restrict node name suffixes
Problem Details: Make the pattern matching node names a bit stricter to improve DTS consistency. The pattern is restricted to: 1. Only one unit address or one -N suffix, 2. -N suffixes to decimal numbers. Suggested-by: Rob Herring <robh@kernel.org> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> A...
```diff diff --git a/Documentation/devicetree/bindings/phy/intel,combo-phy.yaml b/Documentation/devicetree/bindings/phy/intel,combo-phy.yaml index 5d54b0a0e873..7dd6a4d94b48 100644 --- a/Documentation/devicetree/bindings/phy/intel,combo-phy.yaml +++ b/Documentation/devicetree/bindings/phy/intel,combo-phy.yaml @@ -15,7 ...
44faada0f38fc333d392af04c343b0e23f8f5d81
Analyze and fix the following issue in the Linux kernel code: phy: tegra: xusb: check return value of devm_kzalloc()
Problem Details: devm_kzalloc() returns a pointer to dynamically allocated memory. Pointer could be NULL in case allocation fails. Check pointer validity. Identified with coccinelle (kmerr.cocci script). Fixes: f67213cee2b3 ("phy: tegra: xusb: Add usb-role-switch support") Signed-off-by: Claudiu Beznea <claudiu.beznea...
```diff diff --git a/drivers/phy/tegra/xusb.c b/drivers/phy/tegra/xusb.c index b5bad46a04a3..a296b87dced1 100644 --- a/drivers/phy/tegra/xusb.c +++ b/drivers/phy/tegra/xusb.c @@ -676,6 +676,9 @@ static int tegra_xusb_setup_usb_role_switch(struct tegra_xusb_port *port) port->dev.driver = devm_kzalloc(&port->dev, ...
69cbeb61ff9093a9155cb19a36d633033f71093a
Analyze and fix the following issue in the Linux kernel code: Revert "efi: random: refresh non-volatile random seed when RNG is initialized"
Problem Details: This reverts commit e7b813b32a42a3a6281a4fd9ae7700a0257c1d50 (and the subsequent fix for it: 41a15855c1ee "efi: random: fix NULL-deref when refreshing seed"). It turns otu to cause non-deterministic boot stalls on at least a HP 6730b laptop. Reported-and-bisected-by: Sami Korkalainen <sami.korkalaine...
```diff diff --git a/drivers/firmware/efi/efi.c b/drivers/firmware/efi/efi.c index abeff7dc0b58..34b9e7876538 100644 --- a/drivers/firmware/efi/efi.c +++ b/drivers/firmware/efi/efi.c @@ -361,24 +361,6 @@ static void __init efi_debugfs_init(void) static inline void efi_debugfs_init(void) {} #endif -static void refre...
104d32bd81f620bb9f67fbf7d1159c414e89f05f
Analyze and fix the following issue in the Linux kernel code: mfd: stmpe: Only disable the regulators if they are enabled
Problem Details: In stmpe_probe(), if some regulator_enable() calls fail, probing continues and there is only a dev_warn(). So, if stmpe_probe() is called the regulator may not be enabled. It is cleaner to test it before calling regulator_disable() in the remove function. Fixes: 9c9e321455fb ("mfd: stmpe: add optiona...
```diff diff --git a/drivers/mfd/stmpe.c b/drivers/mfd/stmpe.c index a92301dfc712..9c3cf58457a7 100644 --- a/drivers/mfd/stmpe.c +++ b/drivers/mfd/stmpe.c @@ -1485,9 +1485,9 @@ int stmpe_probe(struct stmpe_client_info *ci, enum stmpe_partnum partnum) void stmpe_remove(struct stmpe *stmpe) { - if (!IS_ERR(stmpe->vio...
03f44ffb3d5be2fceda375d92c70ab6de4df7081
Analyze and fix the following issue in the Linux kernel code: cpufreq: intel_pstate: Fix energy_performance_preference for passive
Problem Details: If the intel_pstate driver is set to passive mode, then writing the same value to the energy_performance_preference sysfs twice will fail. This is caused by the wrong return value used (index of the matched energy_perf_string), instead of the length of the passed in parameter. Fix by forcing the intern...
```diff diff --git a/drivers/cpufreq/intel_pstate.c b/drivers/cpufreq/intel_pstate.c index 2548ec92faa2..f29182512b98 100644 --- a/drivers/cpufreq/intel_pstate.c +++ b/drivers/cpufreq/intel_pstate.c @@ -824,6 +824,8 @@ static ssize_t store_energy_performance_preference( err = cpufreq_start_governor(policy); if ...
21aa27ddc58269349597c6d243212bcc4065d277
Analyze and fix the following issue in the Linux kernel code: drm/shmem-helper: Switch to reservation lock
Problem Details: Replace all drm-shmem locks with a GEM reservation lock. This makes locks consistent with dma-buf locking convention where importers are responsible for holding reservation lock for all operations performed over dma-bufs, preventing deadlock between dma-buf importers and exporters. Suggested-by: Danie...
```diff diff --git a/drivers/gpu/drm/drm_gem_shmem_helper.c b/drivers/gpu/drm/drm_gem_shmem_helper.c index 4ea6507a77e5..a783d2245599 100644 --- a/drivers/gpu/drm/drm_gem_shmem_helper.c +++ b/drivers/gpu/drm/drm_gem_shmem_helper.c @@ -88,8 +88,6 @@ __drm_gem_shmem_create(struct drm_device *dev, size_t size, bool privat...
8021fa16b7ec0a3b0457dc15484a7691f99265bc
Analyze and fix the following issue in the Linux kernel code: dma-buf: Change locking policy for mmap()
Problem Details: Change locking policy of mmap() callback, making exporters responsible for handling dma-buf reservation locking. Previous locking policy stated that dma-buf is locked for both importers and exporters by the dma-buf core, which caused a deadlock problem for DRM drivers in a case of self-imported dma-buf...
```diff diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c index aa4ea8530cb3..21916bba77d5 100644 --- a/drivers/dma-buf/dma-buf.c +++ b/drivers/dma-buf/dma-buf.c @@ -131,7 +131,6 @@ static struct file_system_type dma_buf_fs_type = { static int dma_buf_mmap_internal(struct file *file, struct vm_area_st...
11f38236f7bb51c04164e0f5a9630cc6b2f9e099
Analyze and fix the following issue in the Linux kernel code: drm: Don't assert held reservation lock for dma-buf mmapping
Problem Details: Don't assert held dma-buf reservation lock on memory mapping of exported buffer. We're going to change dma-buf mmap() locking policy such that exporters will have to handle the lock. The previous locking policy caused deadlock problem for DRM drivers in a case of self-imported dma-bufs once these driv...
```diff diff --git a/drivers/gpu/drm/drm_prime.c b/drivers/gpu/drm/drm_prime.c index 6bcf324ef81c..f9d4e228b09e 100644 --- a/drivers/gpu/drm/drm_prime.c +++ b/drivers/gpu/drm/drm_prime.c @@ -778,8 +778,6 @@ int drm_gem_dmabuf_mmap(struct dma_buf *dma_buf, struct vm_area_struct *vma) { struct drm_gem_object *obj = dm...
42850c9aadfe56fa640b4b77bee4b3c3dab0d583
Analyze and fix the following issue in the Linux kernel code: udmabuf: Don't assert held reservation lock for dma-buf mmapping
Problem Details: Don't assert held dma-buf reservation lock on memory mapping of exported buffer. We're going to change dma-buf mmap() locking policy such that exporters will have to handle the lock. The previous locking policy caused deadlock problem for DRM drivers in a case of self-imported dma-bufs once these driv...
```diff diff --git a/drivers/dma-buf/udmabuf.c b/drivers/dma-buf/udmabuf.c index 01f2e86f3f7c..06729cd60136 100644 --- a/drivers/dma-buf/udmabuf.c +++ b/drivers/dma-buf/udmabuf.c @@ -52,8 +52,6 @@ static int mmap_udmabuf(struct dma_buf *buf, struct vm_area_struct *vma) { struct udmabuf *ubuf = buf->priv; - dma_res...
30b5144ca41266ffc6071c33eea4076b66ac5eb9
Analyze and fix the following issue in the Linux kernel code: dma-buf/heaps: Don't assert held reservation lock for dma-buf mmapping
Problem Details: Don't assert held dma-buf reservation lock on memory mapping of exported buffer. We're going to change dma-buf mmap() locking policy such that exporters will have to handle the lock. The previous locking policy caused deadlock problem for DRM drivers in a case of self-imported dma-bufs once these driv...
```diff diff --git a/drivers/dma-buf/heaps/cma_heap.c b/drivers/dma-buf/heaps/cma_heap.c index a7f048048864..ee899f8e6721 100644 --- a/drivers/dma-buf/heaps/cma_heap.c +++ b/drivers/dma-buf/heaps/cma_heap.c @@ -13,7 +13,6 @@ #include <linux/dma-buf.h> #include <linux/dma-heap.h> #include <linux/dma-map-ops.h> -#incl...
6f508c8875702ff865440cfff3929dd36083e8b2
Analyze and fix the following issue in the Linux kernel code: media: videobuf2: Don't assert held reservation lock for dma-buf mmapping
Problem Details: Don't assert held dma-buf reservation lock on memory mapping of exported buffer. We're going to change dma-buf mmap() locking policy such that exporters will have to handle the lock. The previous locking policy caused deadlock problem for DRM drivers in a case of self-imported dma-bufs once these driv...
```diff diff --git a/drivers/media/common/videobuf2/videobuf2-dma-contig.c b/drivers/media/common/videobuf2/videobuf2-dma-contig.c index 205d3cac425c..2fa455d4a048 100644 --- a/drivers/media/common/videobuf2/videobuf2-dma-contig.c +++ b/drivers/media/common/videobuf2/videobuf2-dma-contig.c @@ -11,7 +11,6 @@ */ #in...
147394dbe1237ef1f2da528c238633215f7193e1
Analyze and fix the following issue in the Linux kernel code: RDMA/bnxt_re: Initialize opcode while sending message
Problem Details: Fix compilation warning: drivers/infiniband/hw/bnxt_re/qplib_rcfw.c:325:18: error: variable 'opcode' is uninitialized when used here [-Werror,-Wuninitialized] crsqe->opcode = opcode; ^~~~~~ drivers/infiniband/hw/bnxt_re/qplib_rcfw.c:291:11: note: initialize the vari...
```diff diff --git a/drivers/infiniband/hw/bnxt_re/qplib_rcfw.c b/drivers/infiniband/hw/bnxt_re/qplib_rcfw.c index bb5aebafe162..92b3a4fbd0b2 100644 --- a/drivers/infiniband/hw/bnxt_re/qplib_rcfw.c +++ b/drivers/infiniband/hw/bnxt_re/qplib_rcfw.c @@ -274,7 +274,7 @@ static void __send_message_no_waiter(struct bnxt_qpli...
a9e7c964cea4fb1541cc81a11d1b2fd135f4cf38
Analyze and fix the following issue in the Linux kernel code: ASoC: cs43130: Fix numerator/denominator mixup
Problem Details: In converting to using the standard u16_fract type, commit [1] made the obvious mistake and failed to take account of the difference in numerator and denominator ordering, breaking all uses of the cs43130 codec. Fix it. [1] commit e14bd35ef446 ("ASoC: cs43130: Re-use generic struct u16_fract") Fixes...
```diff diff --git a/sound/soc/codecs/cs43130.h b/sound/soc/codecs/cs43130.h index 1dd893674313..90e8895275e7 100644 --- a/sound/soc/codecs/cs43130.h +++ b/sound/soc/codecs/cs43130.h @@ -381,88 +381,88 @@ struct cs43130_clk_gen { /* frm_size = 16 */ static const struct cs43130_clk_gen cs43130_16_clk_gen[] = { - { 2...
da86b2b13f1d1ca26745b951ac94421f3137539a
Analyze and fix the following issue in the Linux kernel code: drm/i915/guc/slpc: Apply min softlimit correctly
Problem Details: The scenario being fixed here is depicted in the following sequence- modprobe i915 echo 1 > /sys/class/drm/card0/gt/gt0/slpc_ignore_eff_freq echo 300 > /sys/class/drm/card0/gt_min_freq_mhz (RPn) cat /sys/class/drm/card0/gt_cur_freq_mhz --> cur == RPn as expected echo 1 > /sys/kernel/debug/dri/0/gt0/re...
```diff diff --git a/drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c b/drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c index 01b75529311c..ee9f83af7cf6 100644 --- a/drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c +++ b/drivers/gpu/drm/i915/gt/uc/intel_guc_slpc.c @@ -606,7 +606,7 @@ static int slpc_set_softlimits(struct intel_guc_s...
724418b84e6248cd27599607b7e5fac365b8e3f5
Analyze and fix the following issue in the Linux kernel code: ALSA: hda/realtek: Add quirks for ROG ALLY CS35l41 audio
Problem Details: This requires a patched ACPI table or a firmware from ASUS to work because the system does not come with the _DSD field for the CSC3551. Link: https://bugzilla.kernel.org/show_bug.cgi?id=217550 Signed-off-by: Matthew Anderson <ruinairas1992@gmail.com> Tested-by: Philip Mueller <philm@manjaro.org> Link...
```diff diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index ce9a9cb41e4b..2ab1065d5a1c 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c @@ -7121,6 +7121,10 @@ enum { ALC294_FIXUP_ASUS_DUAL_SPK, ALC285_FIXUP_THINKPAD_X1_GEN7, ALC285_FIXUP_THINKPAD_HEADSET_...
ff399bab86382c896c3922a570884bba287eb465
Analyze and fix the following issue in the Linux kernel code: usb: gadget: legacy: fix error return code in gfs_bind
Problem Details: We must return negative error code -ENOMEM if function 'usb_otg_descriptor_alloc()' fails. Signed-off-by: Wei Chen <harperchen1110@gmail.com> Link: https://lore.kernel.org/r/20230621124323.47183-1-harperchen1110@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
```diff diff --git a/drivers/usb/gadget/legacy/g_ffs.c b/drivers/usb/gadget/legacy/g_ffs.c index 097854683e5b..a9544fea8723 100644 --- a/drivers/usb/gadget/legacy/g_ffs.c +++ b/drivers/usb/gadget/legacy/g_ffs.c @@ -389,8 +389,10 @@ static int gfs_bind(struct usb_composite_dev *cdev) struct usb_descriptor_header *usb...
25a2bc21c86392223142dcbd5bc92e598a950678
Analyze and fix the following issue in the Linux kernel code: usb: typec: ucsi: call typec_set_mode on non-altmode partner change
Problem Details: Add support for calling typec_set_mode() for the DEBUG, AUDIO accessory modes. Let's also call typec_set_mode() for USB as default and SAFE when partner is disconnected. The USB state is only called when ALT mode is specifically not specified by the partner status flags in order to leave the altmode ...
```diff diff --git a/drivers/usb/typec/ucsi/ucsi.c b/drivers/usb/typec/ucsi/ucsi.c index 2b472ec01dc4..44f43cdea5c1 100644 --- a/drivers/usb/typec/ucsi/ucsi.c +++ b/drivers/usb/typec/ucsi/ucsi.c @@ -809,6 +809,23 @@ static void ucsi_partner_change(struct ucsi_connector *con) break; } + if (con->status.flags & UC...
a82d62f708545d22859584e0e0620da8e3759bbc
Analyze and fix the following issue in the Linux kernel code: Revert "8250: add support for ASIX devices with a FIFO bug"
Problem Details: This reverts commit eb26dfe8aa7eeb5a5aa0b7574550125f8aa4c3b3. Commit eb26dfe8aa7e ("8250: add support for ASIX devices with a FIFO bug") merged on Jul 13, 2012 adds a quirk for PCI_VENDOR_ID_ASIX (0x9710). But that ID is the same as PCI_VENDOR_ID_NETMOS defined in 1f8b061050c7 ("[PATCH] Netmos paralle...
```diff diff --git a/drivers/tty/serial/8250/8250.h b/drivers/tty/serial/8250/8250.h index 471c6bc5f78f..1aa3e55c8b47 100644 --- a/drivers/tty/serial/8250/8250.h +++ b/drivers/tty/serial/8250/8250.h @@ -91,7 +91,6 @@ struct serial8250_config { #define UART_BUG_TXEN BIT(1) /* UART has buggy TX IIR status */ #define UA...
27a826837ec9a3e94cc44bd9328b8289b0fcecd7
Analyze and fix the following issue in the Linux kernel code: serial: atmel: don't enable IRQs prematurely
Problem Details: The atmel_complete_tx_dma() function disables IRQs at the start of the function by calling spin_lock_irqsave(&port->lock, flags); There is no need to disable them a second time using the spin_lock_irq() function and, in fact, doing so is a bug because it will enable IRQs prematurely when we call spin_u...
```diff diff --git a/drivers/tty/serial/atmel_serial.c b/drivers/tty/serial/atmel_serial.c index 6e9192f122aa..3467a875641a 100644 --- a/drivers/tty/serial/atmel_serial.c +++ b/drivers/tty/serial/atmel_serial.c @@ -868,11 +868,11 @@ static void atmel_complete_tx_dma(void *arg) dmaengine_terminate_all(chan); uart_x...
944ee77dc6ec7b0afd8ec70ffc418b238c92f12b
Analyze and fix the following issue in the Linux kernel code: HID: hidraw: fix data race on device refcount
Problem Details: The hidraw_open() function increments the hidraw device reference counter. The counter has no dedicated synchronization mechanism, resulting in a potential data race when concurrently opening a device. The race is a regression introduced by commit 8590222e4b02 ("HID: hidraw: Replace hidraw device tabl...
```diff diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c index 197b1e7bf029..b617aada50b0 100644 --- a/drivers/hid/hidraw.c +++ b/drivers/hid/hidraw.c @@ -272,7 +272,12 @@ static int hidraw_open(struct inode *inode, struct file *file) goto out; } - down_read(&minors_rwsem); + /* + * Technically not writ...
f40f97aaf7fa6222f4ec073c24fb14f04ffb6f80
Analyze and fix the following issue in the Linux kernel code: perf arm-spe: Fix a dangling Documentation/arm64 reference
Problem Details: The arm64 documentation has moved under Documentation/arch/. Fix up a dangling reference to match. Cc: Peter Zijlstra <peterz@infradead.org> Cc: Ingo Molnar <mingo@redhat.com> Cc: Mark Rutland <mark.rutland@arm.com> Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com> Cc: Jiri Olsa <jolsa@kern...
```diff diff --git a/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c b/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c index f3918f290df5..ba807071d3c1 100644 --- a/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c +++ b/tools/perf/util/arm-spe-decoder/arm-spe-decoder.c @@ -51,7 +51,7 @@ static u64 arm_spe_calc_ip(...
c30034054a1ad394273f3fffe14752f83251600a
Analyze and fix the following issue in the Linux kernel code: mm: Fix a dangling Documentation/arm64 reference
Problem Details: The arm64 documentation has moved under Documentation/arch/. Fix up a reference in mm/mremap.c to match. Cc: Andrew Morton <akpm@linux-foundation.org> Cc: linux-mm@kvack.org Acked-by: Mike Rapoport (IBM) <rppt@kernel.org> Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Jonathan Cor...
```diff diff --git a/mm/mremap.c b/mm/mremap.c index b11ce6c92099..3185724d8b13 100644 --- a/mm/mremap.c +++ b/mm/mremap.c @@ -914,7 +914,8 @@ SYSCALL_DEFINE5(mremap, unsigned long, addr, unsigned long, old_len, * mapping address intact. A non-zero tag will cause the subsequent * range checks to reject the addres...
6e4596c4038adfcf52d0dc37ba9cb505c4afaa65
Analyze and fix the following issue in the Linux kernel code: arm64: Fix dangling references to Documentation/arm64
Problem Details: The arm64 documentation has moved under Documentation/arch/; fix up references in the arm64 subtree to match. Cc: Will Deacon <will@kernel.org> Cc: Ard Biesheuvel <ardb@kernel.org> Cc: linux-efi@vger.kernel.org Acked-by: Catalin Marinas <catalin.marinas@arm.com> Signed-off-by: Jonathan Corbet <corbet@...
```diff diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig index 377f50dda2de..c9f135bf8e6c 100644 --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig @@ -1585,7 +1585,7 @@ config ARM64_TAGGED_ADDR_ABI When this option is enabled, user applications can opt in to a relaxed ABI via prctl() allowing tagged address...
a0468d4efc0e9f268e362d6840c84107703bd24e
Analyze and fix the following issue in the Linux kernel code: dt-bindings: fix dangling Documentation/arm64 reference
Problem Details: The arm64 documentation has move under Documentation/arch/ fix a reference to match. Cc: Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org> Cc: Conor Dooley <conor+dt@kernel.org> Cc: devicetree@vger.kernel.org Acked-by: Catalin Marinas <catalin.marinas@arm.com> Acked-by: Rob Herring <robh@kernel....
```diff diff --git a/Documentation/devicetree/bindings/cpu/idle-states.yaml b/Documentation/devicetree/bindings/cpu/idle-states.yaml index b8cc826c9501..b3a5356f9916 100644 --- a/Documentation/devicetree/bindings/cpu/idle-states.yaml +++ b/Documentation/devicetree/bindings/cpu/idle-states.yaml @@ -259,7 +259,7 @@ descr...