linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* Re: KASAN: null-ptr-deref Read in PageHuge
       [not found] <0000000000000cea4605af946f8c@google.com>
@ 2020-09-18 19:42 ` Mike Kravetz
  2020-09-18 20:04   ` Matthew Wilcox
  0 siblings, 1 reply; 2+ messages in thread
From: Mike Kravetz @ 2020-09-18 19:42 UTC (permalink / raw)
  To: syzbot, akpm, linux-kernel, linux-mm, syzkaller-bugs, Matthew Wilcox

On 9/18/20 4:02 AM, syzbot wrote:
> Hello,
> 
> syzbot found the following issue on:
> 
> HEAD commit:    6b02addb Add linux-next specific files for 20200915
> git tree:       linux-next
> console output: https://syzkaller.appspot.com/x/log.txt?x=17a7441d900000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=7086d0e9e44d4a14
> dashboard link: https://syzkaller.appspot.com/bug?extid=3a21fd5ecfc677248e77
> compiler:       gcc (GCC) 10.1.0-syz 20200507
> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=141489f1900000
> C reproducer:   https://syzkaller.appspot.com/x/repro.c?x=1694fd55900000
> 
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+3a21fd5ecfc677248e77@syzkaller.appspotmail.com
> 
> ==================================================================
> BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:71 [inline]
> BUG: KASAN: null-ptr-deref in test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
> BUG: KASAN: null-ptr-deref in PageCompound include/linux/page-flags.h:196 [inline]
> BUG: KASAN: null-ptr-deref in PageHuge+0x19/0x170 mm/hugetlb.c:1551
> Read of size 8 at addr 0000000000000000 by task syz-executor410/6864
> 
> CPU: 1 PID: 6864 Comm: syz-executor410 Not tainted 5.9.0-rc5-next-20200915-syzkaller #0
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
> Call Trace:
>  __dump_stack lib/dump_stack.c:77 [inline]
>  dump_stack+0x198/0x1fb lib/dump_stack.c:118
>  __kasan_report mm/kasan/report.c:549 [inline]
>  kasan_report.cold+0x5/0x37 mm/kasan/report.c:562
>  check_memory_region_inline mm/kasan/generic.c:186 [inline]
>  check_memory_region+0x13d/0x180 mm/kasan/generic.c:192
>  instrument_atomic_read include/linux/instrumented.h:71 [inline]
>  test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
>  PageCompound include/linux/page-flags.h:196 [inline]
>  PageHuge+0x19/0x170 mm/hugetlb.c:1551
>  find_subpage include/linux/pagemap.h:410 [inline]
>  find_get_incore_page+0x165/0x2e0 mm/swap_state.c:435
>  mincore_page+0x1e/0x310 mm/mincore.c:62
>  __mincore_unmapped_range+0x171/0x2c0 mm/mincore.c:82
>  mincore_pte_range+0x69f/0x980 mm/mincore.c:125
>  walk_pmd_range mm/pagewalk.c:89 [inline]
>  walk_pud_range mm/pagewalk.c:160 [inline]
>  walk_p4d_range mm/pagewalk.c:193 [inline]
>  walk_pgd_range mm/pagewalk.c:229 [inline]
>  __walk_page_range+0xeed/0x22c0 mm/pagewalk.c:331
>  walk_page_range+0x20d/0x400 mm/pagewalk.c:427
>  do_mincore mm/mincore.c:199 [inline]
>  __do_sys_mincore+0x279/0x7a0 mm/mincore.c:264
>  do_syscall_64+0x2d/0x70 arch/x86/entry/common.c:46
>  entry_SYSCALL_64_after_hwframe+0x44/0xa9
> RIP: 0033:0x440329
> Code: 18 89 d0 c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 0f 83 7b 13 fc ff c3 66 2e 0f 1f 84 00 00 00 00
> RSP: 002b:00007ffe6fca7ae8 EFLAGS: 00000246 ORIG_RAX: 000000000000001b
> RAX: ffffffffffffffda RBX: 00000000004002c8 RCX: 0000000000440329
> RDX: 0000000000000000 RSI: 0000000000004000 RDI: 0000000020001000
> RBP: 00000000006ca018 R08: 0000000000000000 R09: 0000000000000000
> R10: 0000000000000003 R11: 0000000000000246 R12: 0000000000401b30
> R13: 0000000000401bc0 R14: 0000000000000000 R15: 0000000000000000
> ==================================================================

I assume this would also be fixed by 5d1903f712ac
("mm-convert-find_get_entry-to-return-the-head-page-fix")

-- 
Mike Kravetz


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

* Re: KASAN: null-ptr-deref Read in PageHuge
  2020-09-18 19:42 ` KASAN: null-ptr-deref Read in PageHuge Mike Kravetz
@ 2020-09-18 20:04   ` Matthew Wilcox
  0 siblings, 0 replies; 2+ messages in thread
From: Matthew Wilcox @ 2020-09-18 20:04 UTC (permalink / raw)
  To: Mike Kravetz; +Cc: syzbot, akpm, linux-kernel, linux-mm, syzkaller-bugs

On Fri, Sep 18, 2020 at 12:42:24PM -0700, Mike Kravetz wrote:
> On 9/18/20 4:02 AM, syzbot wrote:
> > ==================================================================
> > BUG: KASAN: null-ptr-deref in instrument_atomic_read include/linux/instrumented.h:71 [inline]
> > BUG: KASAN: null-ptr-deref in test_bit include/asm-generic/bitops/instrumented-non-atomic.h:134 [inline]
> > BUG: KASAN: null-ptr-deref in PageCompound include/linux/page-flags.h:196 [inline]
> > BUG: KASAN: null-ptr-deref in PageHuge+0x19/0x170 mm/hugetlb.c:1551
> > Read of size 8 at addr 0000000000000000 by task syz-executor410/6864
> > 
> 
> I assume this would also be fixed by 5d1903f712ac
> ("mm-convert-find_get_entry-to-return-the-head-page-fix")

That's a good bet.


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

end of thread, other threads:[~2020-09-18 20:04 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <0000000000000cea4605af946f8c@google.com>
2020-09-18 19:42 ` KASAN: null-ptr-deref Read in PageHuge Mike Kravetz
2020-09-18 20:04   ` Matthew Wilcox

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).