public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
* Re: "fs/namei.c: keep track of nd->root refcount status" causes boot panic
       [not found] <7C6CCE98-1E22-433C-BF70-A3CBCDED4635@lca.pw>
@ 2019-09-03  8:13 ` Naresh Kamboju
  2019-09-03  9:08   ` Sachin Sant
  0 siblings, 1 reply; 2+ messages in thread
From: Naresh Kamboju @ 2019-09-03  8:13 UTC (permalink / raw)
  To: Qian Cai; +Cc: Al Viro, linux-fsdevel, LKML, Linux-Next Mailing List

On Tue, 3 Sep 2019 at 09:51, Qian Cai <cai@lca•pw> wrote:
>
> The linux-next commit "fs/namei.c: keep track of nd->root refcount status” [1] causes boot panic on all
> architectures here on today’s linux-next (0902). Reverted it will fix the issue.

I have same problem and reverting this patch fixed the kernel crash.

>
> [1] https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=e013ec23b8231cf7f95605cbb0e47aa0e3d047a4
>

FYI,
on x86_64 device I have noticed kernel bug [1].

[   12.941007] Run /sbin/init as init process
[   12.946381] random: fast init done
[   13.023482] BUG: kernel NULL pointer dereference, address: 0000000000000235
[   13.030444] #PF: supervisor read access in kernel mode
[   13.035576] #PF: error_code(0x0000) - not-present page
[   13.040725] PGD 0 P4D 0
[   13.043263] Oops: 0000 [#1] SMP PTI
[   13.046755] CPU: 2 PID: 1 Comm: systemd Not tainted
5.3.0-rc6-next-20190902 #1
[   13.053966] Hardware name: Supermicro SYS-5019S-ML/X11SSH-F, BIOS
2.0b 07/27/2017
[   13.061438] RIP: 0010:dput+0x72/0x4a0
[   13.065101] Code: 68 0d 5f 41 56 31 d2 45 31 c9 45 31 c0 31 f6 b9
02 00 00 00 48 c7 c7 e0 dd 66 a2 e8 48 6c e1 ff e8 e3 9f e3 ff 85 c0
5a 75 76 <f6> 03 08 4c 8d a3 80 00 00 00 4c 89 e7 0f 85 7b 01 00 00 e8
16 66
[   13.083838] RSP: 0018:ffffb16100027c00 EFLAGS: 00010202
[   13.089055] RAX: 0000000000000001 RBX: 0000000000000235 RCX: 00000000fff78e19
[   13.096180] RDX: ffffffffa0f3f630 RSI: 00000000ffffffff RDI: 0000000000000000
[   13.103301] RBP: ffffb16100027c30 R08: 0000000000000000 R09: 0000000000000000
[   13.110425] R10: 0000000000000000 R11: 0000000000000000 R12: ffffb16100027e30
[   13.117550] R13: ffffffffa23a557f R14: ffffffffa0f3f630 R15: ffffb16100027e30
[   13.124685] FS:  00007f2541dc4840(0000) GS:ffff9983dfb00000(0000)
knlGS:0000000000000000
[   13.132767] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   13.138506] CR2: 0000000000000235 CR3: 000000045a2fe003 CR4: 00000000003606e0
[   13.145630] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[   13.152752] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
[   13.159875] Call Trace:
[   13.162323]  terminate_walk+0x104/0x160
[   13.166162]  path_lookupat+0xa4/0x210
[   13.169828]  filename_lookup+0xb6/0x180
[   13.173682]  ? fs_reclaim_release.part.107+0x5/0x30
[   13.178581]  ? getname_flags+0x4b/0x1e0
[   13.182419]  ? rcu_read_lock_sched_held+0x4f/0x80
[   13.187116]  ? kmem_cache_alloc+0x290/0x2c0
[   13.191293]  ? __might_fault+0x85/0x90
[   13.195037]  user_path_at_empty+0x36/0x40
[   13.199041]  ? user_path_at_empty+0x36/0x40
[   13.203217]  vfs_statx+0x76/0xe0
[   13.206442]  __do_sys_newfstatat+0x35/0x70
[   13.210535]  ? entry_SYSCALL_64_after_hwframe+0x3e/0xbe
[   13.215758]  ? trace_hardirqs_off_caller+0x22/0xf0
[   13.220542]  ? do_syscall_64+0x17/0x1c0
[   13.224374]  ? lockdep_hardirqs_on+0xf6/0x190
[   13.228730]  ? do_syscall_64+0x17/0x1c0
[   13.232564]  ? trace_hardirqs_on+0x4c/0x100
[   13.236747]  __x64_sys_newfstatat+0x1e/0x20
[   13.240925]  do_syscall_64+0x55/0x1c0
[   13.244582]  entry_SYSCALL_64_after_hwframe+0x49/0xbe
[   13.249625] RIP: 0033:0x7f25405bba09
[   13.253196] Code: 64 c7 00 16 00 00 00 b8 ff ff ff ff c3 0f 1f 40
00 89 f0 48 89 d6 83 ff 01 77 36 89 c7 45 89 c2 48 89 ca b8 06 01 00
00 0f 05 <48> 3d 00 f0 ff ff 77 07 c3 66 0f 1f 44 00 00 48 8b 15 59 94
2c 00
[   13.271934] RSP: 002b:00007ffd6722dfc8 EFLAGS: 00000246 ORIG_RAX:
0000000000000106
[   13.279490] RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 00007f25405bba09
[   13.286614] RDX: 00007ffd6722e090 RSI: 00007f25418c06d6 RDI: 0000000000000004
[   13.293738] RBP: 0000000000000004 R08: 0000000000001000 R09: 0000000000000001
[   13.300860] R10: 0000000000001000 R11: 0000000000000246 R12: 000055bd9f667281
[   13.307984] R13: 0000000000000400 R14: 00007ffd6722e518 R15: 0000000000000001
[   13.315111] Modules linked in:
[   13.318170] CR2: 0000000000000235
[   13.321489] ---[ end trace 2f1042f3cbf26726 ]---
[   13.326107] RIP: 0010:dput+0x72/0x4a0
[   13.329763] Code: 68 0d 5f 41 56 31 d2 45 31 c9 45 31 c0 31 f6 b9
02 00 00 00 48 c7 c7 e0 dd 66 a2 e8 48 6c e1 ff e8 e3 9f e3 ff 85 c0
5a 75 76 <f6> 03 08 4c 8d a3 80 00 00 00 4c 89 e7 0f 85 7b 01 00 00 e8
16 66
[   13.348499] RSP: 0018:ffffb16100027c00 EFLAGS: 00010202
[   13.353740] RAX: 0000000000000001 RBX: 0000000000000235 RCX: 00000000fff78e19
[   13.360865] RDX: ffffffffa0f3f630 RSI: 00000000ffffffff RDI: 0000000000000000
[   13.367990] RBP: ffffb16100027c30 R08: 0000000000000000 R09: 0000000000000000
[   13.375115] R10: 0000000000000000 R11: 0000000000000000 R12: ffffb16100027e30
[   13.382238] R13: ffffffffa23a557f R14: ffffffffa0f3f630 R15: ffffb16100027e30
[   13.389361] FS:  00007f2541dc4840(0000) GS:ffff9983dfb00000(0000)
knlGS:0000000000000000
[   13.397439] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[   13.403176] CR2: 0000000000000235 CR3: 000000045a2fe003 CR4: 00000000003606e0
[   13.410301] DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
[   13.417422] DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
[   13.424549] BUG: sleeping function called from invalid context at
/usr/src/kernel/include/linux/percpu-rwsem.h:38
[   13.434793] in_atomic(): 1, irqs_disabled(): 1, pid: 1, name: systemd
[   13.441222] INFO: lockdep is turned off.
[   13.445138] irq event stamp: 1373108
[   13.448740] hardirqs last  enabled at (1373107):
[<ffffffffa0f3216b>] path_init+0x21b/0x520
[   13.457083] hardirqs last disabled at (1373108):
[<ffffffffa0c01c9a>] trace_hardirqs_off_thunk+0x1a/0x20
[   13.466555] softirqs last  enabled at (1373040):
[<ffffffffa16ea835>] release_sock+0x85/0xb0
[   13.474985] softirqs last disabled at (1373038):
[<ffffffffa16ea7ce>] release_sock+0x1e/0xb0
[   13.483409] CPU: 2 PID: 1 Comm: systemd Tainted: G      D
5.3.0-rc6-next-20190902 #1
[   13.492007] Hardware name: Supermicro SYS-5019S-ML/X11SSH-F, BIOS
2.0b 07/27/2017
[   13.499478] Call Trace:
[   13.501923]  dump_stack+0x70/0xa5
[   13.505243]  ___might_sleep+0x152/0x240
[   13.509080]  __might_sleep+0x4a/0x80
[   13.512679]  exit_signals+0x33/0x2e0
[   13.516273]  do_exit+0xb1/0xce0
[   13.519410]  ? do_syscall_64+0x17/0x1c0
[   13.523240]  ? trace_hardirqs_on+0x4c/0x100
[   13.527419]  rewind_stack_do_exit+0x17/0x20
[   13.531595] RIP: 0033:0x7f25405bba09
[   13.535166] Code: 64 c7 00 16 00 00 00 b8 ff ff ff ff c3 0f 1f 40
00 89 f0 48 89 d6 83 ff 01 77 36 89 c7 45 89 c2 48 89 ca b8 06 01 00
00 0f 05 <48> 3d 00 f0 ff ff 77 07 c3 66 0f 1f 44 00 00 48 8b 15 59 94
2c 00
[   13.553900] RSP: 002b:00007ffd6722dfc8 EFLAGS: 00000246 ORIG_RAX:
0000000000000106
[   13.561459] RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 00007f25405bba09
[   13.568581] RDX: 00007ffd6722e090 RSI: 00007f25418c06d6 RDI: 0000000000000004
[   13.575735] RBP: 0000000000000004 R08: 0000000000001000 R09: 0000000000000001
[   13.582865] R10: 0000000000001000 R11: 0000000000000246 R12: 000055bd9f667281
[   13.589990] R13: 0000000000000400 R14: 00007ffd6722e518 R15: 0000000000000001
[   13.597146] note: systemd[1] exited with preempt_count 1
[   13.602674] Kernel panic - not syncing: Attempted to kill init!
exitcode=0x00000009
[   13.610402] Kernel Offset: 0x1fc00000 from 0xffffffff81000000
(relocation range: 0xffffffff80000000-0xffffffffbfffffff)


Full test log,
[1] https://lkft.validation.linaro.org/scheduler/job/896370#L970


Best regards
Naresh Kamboju

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: "fs/namei.c: keep track of nd->root refcount status" causes boot panic
  2019-09-03  8:13 ` "fs/namei.c: keep track of nd->root refcount status" causes boot panic Naresh Kamboju
@ 2019-09-03  9:08   ` Sachin Sant
  0 siblings, 0 replies; 2+ messages in thread
From: Sachin Sant @ 2019-09-03  9:08 UTC (permalink / raw)
  To: linux-fsdevel, Linux-Next Mailing List; +Cc: Qian Cai, Al Viro, LKML



> On 03-Sep-2019, at 1:43 PM, Naresh Kamboju <naresh.kamboju@linaro•org> wrote:
> 
> On Tue, 3 Sep 2019 at 09:51, Qian Cai <cai@lca•pw> wrote:
>> 
>> The linux-next commit "fs/namei.c: keep track of nd->root refcount status” [1] causes boot panic on all
>> architectures here on today’s linux-next (0902). Reverted it will fix the issue.

Similar problem is seen on ppc64le arch.

[    0.493235] BUG: Kernel NULL pointer dereference at 0x00000cc0
[    0.493241] Faulting instruction address: 0xc0000000003e9260
[    0.493245] Oops: Kernel access of bad area, sig: 11 [#1]
[    0.493250] LE PAGE_SIZE=64K MMU=Hash SMP NR_CPUS=2048 NUMA pSeries
[    0.493254] Modules linked in:
[    0.493260] CPU: 1 PID: 1 Comm: systemd Not tainted 5.3.0-rc6-next-20190902-autotest-autotest #1
[    0.493265] NIP:  c0000000003e9260 LR: c0000000003e925c CTR: 00000000000001fc
[    0.493270] REGS: c0000004f85038c0 TRAP: 0300   Not tainted  (5.3.0-rc6-next-20190902-autotest-autotest)
[    0.493274] MSR:  8000000000009033 <SF,EE,ME,IR,DR,RI,LE>  CR: 28002842  XER: 00000000
[    0.493282] CFAR: c00000000000df44 DAR: 0000000000000cc0 DSISR: 40000000 IRQMASK: 0 
[    0.493282] GPR00: c0000000003e925c c0000004f8503b50 c000000001458e00 0000000000000000 
[    0.493282] GPR04: c0000004f8503ce0 0000000000000000 0000000000000064 0000000000000000 
[    0.493282] GPR08: 0000000000000000 c000000000ff7a65 0000000000000000 c0000004f70100c0 
[    0.493282] GPR12: 0000000000002200 c00000001ecaee00 0000000000000000 0000000000000000 
[    0.493282] GPR16: 0000000000000000 0000000000000000 0000000000000000 0000000000000000 
[    0.493282] GPR20: 0000000000077624 0000000000000000 0000000000000000 00007fffa1099e20 
[    0.493282] GPR24: 0000000000000000 000000010f9572a4 0000000000000000 0000000000000001 
[    0.493282] GPR28: 0000000000080060 0000000000080040 0000000000000000 0000000000000cc0 
[    0.493327] NIP [c0000000003e9260] dput+0x70/0x4e0
[    0.493332] LR [c0000000003e925c] dput+0x6c/0x4e0
[    0.493334] Call Trace:
[    0.493338] [c0000004f8503b50] [c0000000003e925c] dput+0x6c/0x4e0 (unreliable)
[    0.493345] [c0000004f8503bc0] [c0000000003d5da4] terminate_walk+0x104/0x130
[    0.493351] [c0000004f8503c00] [c0000000003da9d8] path_lookupat+0xe8/0x2b0
[    0.493356] [c0000004f8503c70] [c0000000003dd668] filename_lookup+0xa8/0x1c0
[    0.493362] [c0000004f8503da0] [c00000000046c4d4] sys_name_to_handle_at+0xe4/0x2d0
[    0.493369] [c0000004f8503e20] [c00000000000b378] system_call+0x5c/0x68
[    0.493373] Instruction dump:
[    0.493376] f8010010 f821ff91 7c7f1b79 41820050 3d200008 3b600001 613c0060 613d0040 
[    0.493383] 3b400000 3b000000 48707b11 60000000 <813f0000> 3bdf0058 7fc3f378 71390008 
[    0.493391] ---[ end trace 7701d360352c734d ]—

Reverting the mentioned commit allows next to boot.

Thanks
-Sachin

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-09-03  9:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <7C6CCE98-1E22-433C-BF70-A3CBCDED4635@lca.pw>
2019-09-03  8:13 ` "fs/namei.c: keep track of nd->root refcount status" causes boot panic Naresh Kamboju
2019-09-03  9:08   ` Sachin Sant

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox