BUG: sleeping function called from invalid context in mmc_free_host

Status: upstream: reported C repro on 2026/08/05 22:45
Subsystems: mmc mm
Labels: prio:high
[Documentation on labels]
Reported-by: syzbot+0e06aa1bdc6495bac24b@syzkaller.appspotmail.com
First crash: 3d02h, last: 8h46m
Cause bisection: failed (error log, bisect log)
  
✨ AI Patch Versions (1)
Version Stage Reported Report Link Job
1 moderation 2026/08/07 03:36 Discussion dcef6af0-9740-47ea-949c-72048301deb8
✨ AI Jobs (3)
ID Workflow Result Correct Bug Created Started Finished Revision
fc199f99 assessment-security DenialOfService: ✅ Exploitable: ❌ FilesystemTrigger: ❌ NetworkTrigger: ❌ PeripheralTrigger: ✅ RemoteTrigger: ❌ Unprivileged: ❌ UserNamespace: ❌ VMGuestTrigger: ❌ VMHostTrigger: ❌ BUG: sleeping function called from invalid context in mmc_free_host 2026/08/06 06:47 2026/08/07 02:29 2026/08/07 02:33 c38879ea
dcef6af0 patching BUG: sleeping function called from invalid context in mmc_free_host 2026/08/06 06:47 2026/08/07 02:10 2026/08/07 03:36 c38879ea
c58c1f2b assessment-security 💥 BUG: sleeping function called from invalid context in mmc_free_host 2026/08/05 00:02 2026/08/05 00:02 2026/08/05 00:02 d4abbeac
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [mmc?] [mm?] BUG: sleeping function called from invalid context in mmc_free_host 0 (1) 2026/08/05 22:45
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.6 BUG: sleeping function called from invalid context in mmc_free_host 5 6 2d10h 2d18h 0/2 upstream: reported on 2026/08/04 22:46

Sample crash report:
BUG: sleeping function called from invalid context at kernel/workqueue.c:4487
in_atomic(): 1, irqs_disabled(): 0, non_block: 0, pid: 0, name: swapper/1
preempt_count: 101, expected: 0
RCU nest depth: 0, expected: 0
1 lock held by swapper/1/0:
 #0: ffffc90000a08cc0 ((&vub300->inactivity_timer)){+.-.}-{0:0}, at: call_timer_fn+0xd4/0x5e0 kernel/time/timer.c:1745
Preemption disabled at:
[<0000000000000000>] 0x0
CPU: 1 UID: 0 PID: 0 Comm: swapper/1 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/24/2026
Call Trace:
 <IRQ>
 dump_stack_lvl+0xe8/0x150 lib/dump_stack.c:120
 __might_resched+0x378/0x4d0 kernel/sched/core.c:9197
 __cancel_work_sync+0x6d/0x110 kernel/workqueue.c:4487
 mmc_free_host+0x19/0x30 drivers/mmc/core/host.c:700
 call_timer_fn+0x192/0x5e0 kernel/time/timer.c:1748
 expire_timers kernel/time/timer.c:1799 [inline]
 __run_timers kernel/time/timer.c:2374 [inline]
 __run_timer_base+0x652/0x8b0 kernel/time/timer.c:2386
 run_timer_base kernel/time/timer.c:2395 [inline]
 run_timer_softirq+0xb7/0x170 kernel/time/timer.c:2405
 handle_softirqs+0x225/0x840 kernel/softirq.c:622
 __do_softirq kernel/softirq.c:656 [inline]
 invoke_softirq kernel/softirq.c:496 [inline]
 __irq_exit_rcu+0xca/0x220 kernel/softirq.c:735
 irq_exit_rcu+0x9/0x30 kernel/softirq.c:752
 instr_sysvec_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1062 [inline]
 sysvec_apic_timer_interrupt+0xa6/0xc0 arch/x86/kernel/apic/apic.c:1062
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:674
RIP: 0010:pv_native_safe_halt+0xf/0x20 arch/x86/kernel/paravirt.c:64
Code: ac 7e 02 e9 93 06 03 00 cc cc cc 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 90 f3 0f 1e fa 66 90 0f 00 2d d3 3e 18 00 fb f4 <c3> cc cc cc cc cc cc cc cc cc cc cc cc cc cc cc cc 90 90 90 90 90
RSP: 0018:ffffc90000197e40 EFLAGS: 00000246
RAX: 000000000005e681 RBX: ffffffff819b5450 RCX: 0000000080000001
RDX: 0000000000000001 RSI: ffffffff8e22f174 RDI: ffffffff8c4bdd80
RBP: ffffc90000197f10 R08: ffff8880b87338db R09: 1ffff110170e671b
R10: dffffc0000000000 R11: ffffed10170e671c R12: 0000000000000000
R13: 1ffff11003c56000 R14: 1ffff92000032fd0 R15: dffffc0000000000
 arch_safe_halt arch/x86/kernel/process.c:767 [inline]
 default_idle+0x9/0x20 arch/x86/kernel/process.c:768
 default_idle_call+0x72/0xb0 kernel/sched/idle.c:122
 cpuidle_idle_call kernel/sched/idle.c:199 [inline]
 do_idle+0x2e0/0x540 kernel/sched/idle.c:355
 cpu_startup_entry+0x43/0x60 kernel/sched/idle.c:454
 start_secondary+0x101/0x110 arch/x86/kernel/smpboot.c:312
 common_startup_64+0x13e/0x157
 </TASK>
ODEBUG: object ffffc90000a08a80 is NOT on stack ffffc90000190000, but annotated.

======================================================
----------------
Code disassembly (best guess):
   0:	ac                   	lods   %ds:(%rsi),%al
   1:	7e 02                	jle    0x5
   3:	e9 93 06 03 00       	jmp    0x3069b
   8:	cc                   	int3
   9:	cc                   	int3
   a:	cc                   	int3
   b:	90                   	nop
   c:	90                   	nop
   d:	90                   	nop
   e:	90                   	nop
   f:	90                   	nop
  10:	90                   	nop
  11:	90                   	nop
  12:	90                   	nop
  13:	90                   	nop
  14:	90                   	nop
  15:	90                   	nop
  16:	90                   	nop
  17:	90                   	nop
  18:	90                   	nop
  19:	90                   	nop
  1a:	90                   	nop
  1b:	f3 0f 1e fa          	endbr64
  1f:	66 90                	xchg   %ax,%ax
  21:	0f 00 2d d3 3e 18 00 	verw   0x183ed3(%rip)        # 0x183efb
  28:	fb                   	sti
  29:	f4                   	hlt
* 2a:	c3                   	ret <-- trapping instruction
  2b:	cc                   	int3
  2c:	cc                   	int3
  2d:	cc                   	int3
  2e:	cc                   	int3
  2f:	cc                   	int3
  30:	cc                   	int3
  31:	cc                   	int3
  32:	cc                   	int3
  33:	cc                   	int3
  34:	cc                   	int3
  35:	cc                   	int3
  36:	cc                   	int3
  37:	cc                   	int3
  38:	cc                   	int3
  39:	cc                   	int3
  3a:	cc                   	int3
  3b:	90                   	nop
  3c:	90                   	nop
  3d:	90                   	nop
  3e:	90                   	nop
  3f:	90                   	nop

Crashes (30):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2026/08/05 01:10 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 23:21 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 21:45 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 20:09 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 18:37 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 16:58 upstream 848acc8ffe1b d4abbeac .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/07 08:08 upstream f9a2394a2348 c38879ea .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/06 16:29 upstream 0d8395707651 c38879ea .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/06 16:28 upstream 0d8395707651 c38879ea .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/06 09:38 upstream 0d8395707651 cd5b1963 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/05 07:40 upstream c21bb4193868 b3eac40e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/05 03:42 upstream c21bb4193868 d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 18:10 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 17:48 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 17:26 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 17:24 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 16:21 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:47 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:21 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:20 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:19 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:11 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:11 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 14:11 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 16:24 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-386 BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 16:18 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-386 BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 16:10 upstream 848acc8ffe1b d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-386 BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 18:31 linux-next cc2b5f627e8c d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 18:24 linux-next cc2b5f627e8c d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
2026/08/04 15:36 linux-next cc2b5f627e8c d4abbeac .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce BUG: sleeping function called from invalid context in mmc_free_host
* Struck through repros no longer work on HEAD.