In the Linux kernel, the following vulnerability has been resolved:
bridge: Fix sleep in atomic context in sysfs path
Since the start of the git history, brport_store() always acquired the bridge lock. Back then this decision made sense: The bridge lock protects the STP state of the bridge and its ports and at that time the function was only used by two STP related attributes (cost and priority).
Nowadays, brport_store() processes a lot more attributes and most of them do not need the bridge lock:
* Bridge flags: Only require RTNL. Read locklessly by the data path. Annotations can be added in net-next.
* FDB port flushing: Only requires the FDB lock.
* Multicast attributes: Only require the multicast lock.
* Group forward mask: Only requires RTNL. Read locklessly by the data path. Annotations can be added in net-next.
* Backup port: Only requires RTNL. Read locklessly by the data path.
This is a problem as the bridge calls dev_set_promiscuity() when certain bridge port flags change and this function can sleep since the commit cited below, resulting in a splat such as [1].
Fix this by reducing the scope of the bridge lock and only take it when processing the two STP related attributes that require it. Remove the now stale comment from br_switchdev_set_port_flag(). The SWITCHDEV_F_DEFER flag can be removed in net-next.
[1] BUG: sleeping function called from invalid context at net/core/dev_addr_lists.c:1262 in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 372, name: bash preempt_count: 201, expected: 0 RCU nest depth: 0, expected: 0 5 locks held by bash/372: #0: ffff88810c51c3f0 (sb_writers#7){.+.+}-{0:0}, at: ksys_write (fs/read_write.c:740) #1: ffff888115ce9480 (&of->mutex){+.+.}-{4:4}, at: kernfs_fop_write_iter (fs/kernfs/file.c:343) #2: ffff88810b9fd330 (kn->active#37){.+.+}-{0:0}, at: kernfs_fop_write_iter (fs/kernfs/file.c:80 fs/kernfs/file.c:344) #3: ffffffffa59473a0 (rtnl_mutex){+.+.}-{4:4}, at: brport_store (net/bridge/br_sysfs_if.c:326) #4: ffff8881099d2d58 (&br->lock){+...}-{3:3}, at: brport_store (./include/linux/spinlock.h:348 net/bridge/br_sysfs_if.c:345) Preemption disabled at: 0x0 Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011 Call Trace: <TASK> dump_stack_lvl (lib/dump_stack.c:94 lib/dump_stack.c:120) __might_resched.cold (kernel/sched/core.c:9163) netif_rx_mode_run (net/core/dev_addr_lists.c:1262) netif_rx_mode_sync (net/core/dev_addr_lists.c:1428) dev_set_promiscuity (net/core/dev_api.c:289) br_manage_promisc (net/bridge/br_if.c:135 net/bridge/br_if.c:172) br_port_flags_change (net/bridge/br_if.c:242 net/bridge/br_if.c:747) store_learning (net/bridge/br_sysfs_if.c:79 net/bridge/br_sysfs_if.c:235) brport_store (net/bridge/br_sysfs_if.c:346) kernfs_fop_write_iter (fs/kernfs/file.c:352) new_sync_write (fs/read_write.c:595) vfs_write (fs/read_write.c:688) ksys_write (fs/read_write.c:740) do_syscall_64 (arch/x86/entry/syscall_64.c:63 arch/x86/entry/syscall_64.c:94) entry_SYSCALL_64_after_hwframe (arch/x86/entry/entry_64.S:121)
Covered by Rapid7
| Product | Vendor Advisory | Solution File | Added | Published |
|---|---|---|---|---|
| Amazon_linux_2023 | — | Upgrade kernel6.18-debuginfo-common-aarch64Upgrade kernel6.18Upgrade kernel6.18-debuginfo-common-x86_64Upgrade kernel6.18-develUpgrade kernel6.18-modules-extra-commonUpgrade kernel-livepatch-6.18.35-68.127Upgrade bpftool6.18Upgrade kernel6.18-tools-develUpgrade kernel6.18-toolsUpgrade python3-perf6.18Upgrade perf6.18-debuginfoUpgrade bpftool6.18-debuginfoUpgrade kernel6.18-tools-debuginfoUpgrade kernel6.18-debuginfoUpgrade kernel6.18-modules-extraUpgrade kernel6.18-headersUpgrade python3-perf6.18-debuginfoUpgrade perf6.18Upgrade microvm-kernel6.18 | Aug 10, 2026 | Jul 19, 2026 |
| Redhat_linux | — | No solution exists | Jul 23, 2026 | Jul 19, 2026 |
| Ubuntu | — | Upgrade linux-image-7.0.0-1015-raspiUpgrade linux-image-7.0.0-1011-oracleUpgrade linux-image-raspi-7.0Upgrade linux-image-gcp-7.0Upgrade linux-image-raspiUpgrade linux-image-7.0.0-1009-awsUpgrade linux-image-azure-fdeUpgrade linux-image-7.0.0-2016-nvidia-bosUpgrade linux-image-7.0.0-1011-gcp-64kUpgrade linux-image-7.0.0-1016-nvidiaUpgrade linux-image-7.0.0-1011-gcpUpgrade linux-image-ibmUpgrade linux-image-nvidia-7.0Upgrade linux-image-7.0.0-1008-oracleUpgrade linux-image-oracle-7.0Upgrade linux-image-nvidia-bosUpgrade linux-image-gcp-64kUpgrade linux-image-azureUpgrade linux-image-7.0.0-1015-raspi-realtimeUpgrade linux-image-oracleUpgrade linux-image-7.0.0-1008-oracle-64kUpgrade linux-image-nvidia-bos-64k-7.0Upgrade linux-image-awsUpgrade linux-image-azure-7.0Upgrade linux-image-nvidia-64k-7.0Upgrade linux-image-raspi-realtimeUpgrade linux-image-7.0.0-1011-oracle-64kUpgrade linux-image-nvidia-64kUpgrade linux-image-7.0.0-1014-azureUpgrade linux-image-oracle-64k-7.0Upgrade linux-image-nvidia-bos-7.0Upgrade linux-image-7.0.0-1009-aws-64kUpgrade linux-image-aws-64kUpgrade linux-image-7.0.0-1009-azure-fdeUpgrade linux-image-gcp-64k-7.0Upgrade linux-image-7.0.0-1010-ibmUpgrade linux-image-ibm-7.0Upgrade linux-image-nvidia-bos-64kUpgrade linux-image-nvidia-hwe-26.04Upgrade linux-image-azure-fde-7.0Upgrade linux-image-aws-64k-7.0Upgrade linux-image-raspi-realtime-7.0Upgrade linux-image-oracle-64kUpgrade linux-image-7.0.0-2016-nvidia-bos-64kUpgrade linux-image-7.0.0-1016-nvidia-64kUpgrade linux-image-7.0.0-1010-azureUpgrade linux-image-gcpUpgrade linux-image-nvidia-64k-hwe-26.04Upgrade linux-image-nvidiaUpgrade linux-image-aws-7.0 | Jul 21, 2026 | Jul 20, 2026 |
Prioritise with Active Threat Intelligence
With curated Threat Intelligence, you can see which vulnerabilities truly put you at risk, prioritize what matters most, and act before attackers do.
Explore Intelligence Hub