Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp1474302rdb; Wed, 20 Sep 2023 10:02:59 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGulr279AWfLsKvajfxNgT9CbPXbFV9H9ZPDUwoTtSO4U4vfA+Qz080w/umRCGDcWHrBhFd X-Received: by 2002:a17:902:c409:b0:1c4:4a4d:cda with SMTP id k9-20020a170902c40900b001c44a4d0cdamr3487090plk.15.1695229379418; Wed, 20 Sep 2023 10:02:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695229379; cv=none; d=google.com; s=arc-20160816; b=TIrlYlIbpJ/PLQiWBLCqX8nm1w4fNrr47pEhIehnOrneTnQr4IrMKgMnVegO8lE3+p 4B5xlgY6ruymiDIiNLFuzfuQV29R95LYTTMn4L16TfuiiIkaVMhFS9FuqmSNQRa9fcZb tetYGCYgnM0c5vS/ZvlBXRWF73UvxtcGxI00iijFvHkUBsM+aoaOGcM62fjW5DNXdrny DEtAPA8PbzCcybhvhZpRtqL7YCfj5A16SxvqTLS9OwylDauj3OnEBWYZD8HpBpK+Kt77 Cjbur/j8EoWEU0CqNWQNnq17uybfzkhqBCKWF7zR5q9ms7uDPzLB8kduv9bzqbkjPwut f0jQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:from:subject:message-id:date:mime-version; bh=IZneNGLoZpE1aQ918Mnxcaup0nwMvcyoZT6gWdl0MxU=; fh=BDfMcUG5/bxLQNOoLEtBm0VaS97WYuszK7oEEGCiHtk=; b=VEPnZlkWtd8v1eopFLYnUh/EPsjY+YJepnFW1iBFNyB8hqxFNtNhwTKjGm6G5OwRmS Qvf3OzrDKZxggxhEQoD5yeqYzftaxFAkw6Uut2/oHtHvVUWs3p2lVX6KFruqn2j3LBG7 QHk3hUQqkjVCgrUyAl4W3d4DZWO/ciBKqDaCBWURxLFRkmxV9o7o1T1hnkf8MzHy+REP CSxtgXLfUJ1B1qyPT4qX+emJLCvXJmYust9WZkiNQPQ0wojUJxMCaSLv4HNvLNPlaII2 UfuBEIozaS2DqzxFpwnFwOwr4PDlGbApt96xxfJxsO61KJFFZBuH8nPopNKYvsZETRoN cUaA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id h12-20020a170902f54c00b001c2109a8576si12520523plf.652.2023.09.20.10.02.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 10:02:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=appspotmail.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id DA254826A919; Wed, 20 Sep 2023 09:36:21 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234501AbjITQgR (ORCPT + 99 others); Wed, 20 Sep 2023 12:36:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57664 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234463AbjITQgQ (ORCPT ); Wed, 20 Sep 2023 12:36:16 -0400 Received: from mail-oi1-f206.google.com (mail-oi1-f206.google.com [209.85.167.206]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2DC5D83 for ; Wed, 20 Sep 2023 09:36:10 -0700 (PDT) Received: by mail-oi1-f206.google.com with SMTP id 5614622812f47-3adc84193d7so5616923b6e.3 for ; Wed, 20 Sep 2023 09:36:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695227769; x=1695832569; h=to:from:subject:message-id:date:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=IZneNGLoZpE1aQ918Mnxcaup0nwMvcyoZT6gWdl0MxU=; b=vcfyEydAYc1WCtD54Ywb6NiynKmfCFHtbt1gdbPMxtEuMYhxvQsxlslPlNiH46SKKt 4M2yX3o8nk8HdJznfta/egnZkGcyj58pt8QYn0mGW+mxMzFyFAZXDy0ae2rLcV/IhnkV MS2KwPVlmgSkM0r403bU+aONVZefgEQOeEwF2yui4CjKxdw/bdONolzJunpN5QwN55FZ Ty2dCc8DHeDr/BSDZfPqlu3R0Ck/eMEBkP4ivwdW7cxWEbhMZsn4sQfpeGmhTcYJPzVP RywZDtZUyJYPtPbCVjZAljQHC0XnPsArTC8l/K1wyDUN6r7KxyWaZK6II7/s6L4QQI+m hTJA== X-Gm-Message-State: AOJu0YzAyOojkz0vAZYDpGLFLt4tf3Mh8IajSifNMxiHGwoLHWZvlz3s 2azdrZk8TIYV18Lt04FdqH+dkt/4UyAO6F+/vidAP06q8p4R MIME-Version: 1.0 X-Received: by 2002:a05:6808:1a13:b0:3a8:4311:3d7f with SMTP id bk19-20020a0568081a1300b003a843113d7fmr1409240oib.5.1695227769350; Wed, 20 Sep 2023 09:36:09 -0700 (PDT) Date: Wed, 20 Sep 2023 09:36:09 -0700 X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <0000000000000170df0605ccf91a@google.com> Subject: [syzbot] [serial?] KASAN: stack-out-of-bounds Read in sched_show_task From: syzbot To: gregkh@linuxfoundation.org, jirislaby@kernel.org, linux-kernel@vger.kernel.org, linux-serial@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-0.4 required=5.0 tests=FROM_LOCAL_HEX, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Wed, 20 Sep 2023 09:36:22 -0700 (PDT) Hello, syzbot found the following issue on: HEAD commit: 8eb8fe67e2c8 riscv: errata: fix T-Head dcache.cva encoding git tree: git://git.kernel.org/pub/scm/linux/kernel/git/riscv/linux.git fixes console output: https://syzkaller.appspot.com/x/log.txt?x=1206d6c4680000 kernel config: https://syzkaller.appspot.com/x/.config?x=89f0a88d4bc7f0f4 dashboard link: https://syzkaller.appspot.com/bug?extid=8d2757d62d403b2d9275 compiler: riscv64-linux-gnu-gcc (Debian 12.2.0-13) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40 userspace arch: riscv64 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=144d1154680000 C reproducer: https://syzkaller.appspot.com/x/repro.c?x=122a2a3c680000 Downloadable assets: disk image (non-bootable): https://storage.googleapis.com/syzbot-assets/a741b348759c/non_bootable_disk-8eb8fe67.raw.xz vmlinux: https://storage.googleapis.com/syzbot-assets/a41f94065e95/vmlinux-8eb8fe67.xz kernel image: https://storage.googleapis.com/syzbot-assets/29db706d00c4/Image-8eb8fe67.xz IMPORTANT: if you fix the issue, please add the following tag to the commit: Reported-by: syzbot+8d2757d62d403b2d9275@syzkaller.appspotmail.com [] context_switch kernel/sched/core.c:5382 [inline] [] __schedule+0x794/0x1884 kernel/sched/core.c:6695 [] schedule+0x78/0xfe kernel/sched/core.c:6771 [] do_nanosleep+0x18a/0x318 kernel/time/hrtimer.c:2047 ================================================================== BUG: KASAN: out-of-bounds in walk_stackframe+0x130/0x2f2 arch/riscv/kernel/stacktrace.c:59 Read of size 8 at addr ff20000006d37c38 by task swapper/1/0 CPU: 1 PID: 0 Comm: swapper/1 Not tainted 6.6.0-rc1-syzkaller-g8eb8fe67e2c8 #0 Hardware name: riscv-virtio,qemu (DT) Call Trace: [] dump_backtrace+0x2e/0x3c arch/riscv/kernel/stacktrace.c:121 [] show_stack+0x34/0x40 arch/riscv/kernel/stacktrace.c:127 [] __dump_stack lib/dump_stack.c:88 [inline] [] dump_stack_lvl+0xe8/0x154 lib/dump_stack.c:106 [] print_address_description mm/kasan/report.c:364 [inline] [] print_report+0x1e4/0x4f4 mm/kasan/report.c:475 [] kasan_report+0xf0/0x1ba mm/kasan/report.c:588 [] check_region_inline mm/kasan/generic.c:181 [inline] [] __asan_load8+0x80/0xa8 mm/kasan/generic.c:260 [] walk_stackframe+0x130/0x2f2 arch/riscv/kernel/stacktrace.c:59 [] dump_backtrace+0x2e/0x3c arch/riscv/kernel/stacktrace.c:121 [] show_stack+0x34/0x40 arch/riscv/kernel/stacktrace.c:127 [] sched_show_task kernel/sched/core.c:9182 [inline] [] sched_show_task+0x2ee/0x414 kernel/sched/core.c:9156 [] show_state_filter+0xa0/0x1e0 kernel/sched/core.c:9227 [] show_state include/linux/sched/debug.h:21 [inline] [] fn_show_state+0x1a/0x22 drivers/tty/vt/keyboard.c:614 [] k_spec drivers/tty/vt/keyboard.c:667 [inline] [] k_spec+0xce/0x102 drivers/tty/vt/keyboard.c:656 [] kbd_keycode drivers/tty/vt/keyboard.c:1524 [inline] [] kbd_event+0x5fa/0xa5e drivers/tty/vt/keyboard.c:1543 [] input_to_handler+0x246/0x24c drivers/input/input.c:132 [] input_pass_values+0x410/0x5fe drivers/input/input.c:161 [] input_event_dispose+0x1ee/0x2c8 drivers/input/input.c:378 [] input_handle_event+0xf0/0x972 drivers/input/input.c:406 [] input_event drivers/input/input.c:435 [inline] [] input_event+0x8a/0xb2 drivers/input/input.c:427 [] input_sync include/linux/input.h:450 [inline] [] hidinput_report_event+0x86/0xae drivers/hid/hid-input.c:1746 [] hid_report_raw_event+0x1be/0xa5c drivers/hid/hid-core.c:2016 [] hid_input_report+0x24e/0x2f4 drivers/hid/hid-core.c:2083 [] hid_irq_in+0x244/0x412 drivers/hid/usbhid/hid-core.c:284 [] __usb_hcd_giveback_urb+0x222/0x364 drivers/usb/core/hcd.c:1650 [] usb_hcd_giveback_urb+0x27a/0x290 drivers/usb/core/hcd.c:1733 [] dummy_timer+0xfc2/0x204a drivers/usb/gadget/udc/dummy_hcd.c:1987 [] call_timer_fn+0x15a/0x4f2 kernel/time/timer.c:1700 [] expire_timers kernel/time/timer.c:1751 [inline] [] __run_timers+0x57e/0x73c kernel/time/timer.c:2022 [] run_timer_softirq+0x46/0x80 kernel/time/timer.c:2035 [] __do_softirq+0x2ee/0x8a2 kernel/softirq.c:553 [] invoke_softirq kernel/softirq.c:427 [inline] [] __irq_exit_rcu+0xfa/0x1b0 kernel/softirq.c:632 [] irq_exit_rcu+0x10/0x72 kernel/softirq.c:644 [] handle_riscv_irq+0x40/0x4c arch/riscv/kernel/traps.c:349 [] do_irq+0x5c/0x86 arch/riscv/kernel/traps.c:359 The buggy address belongs to the virtual mapping at [ff20000006d30000, ff20000006d39000) created by: kernel_clone+0x118/0x896 kernel/fork.c:2909 The buggy address belongs to the physical page: page:ff1c00000250dbc0 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x9436f flags: 0xffe000000000000(node=0|zone=0|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 0ffe000000000000 0000000000000000 0000000000000122 0000000000000000 raw: 0000000000000000 0000000000000000 00000001ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 0, migratetype Unmovable, gfp_mask 0x2dc2(GFP_KERNEL|__GFP_HIGHMEM|__GFP_NOWARN|__GFP_ZERO), pid 32, tgid 32 (kworker/u6:1), ts 67487133600, free_ts 66877452400 __set_page_owner+0x32/0x18a mm/page_owner.c:192 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x8c/0xe2 mm/page_alloc.c:1536 prep_new_page mm/page_alloc.c:1543 [inline] get_page_from_freelist+0x84a/0x121e mm/page_alloc.c:3170 __alloc_pages+0x19c/0x142e mm/page_alloc.c:4426 alloc_pages+0x126/0x252 mm/mempolicy.c:2298 vm_area_alloc_pages mm/vmalloc.c:3063 [inline] __vmalloc_area_node mm/vmalloc.c:3139 [inline] __vmalloc_node_range+0x838/0xec2 mm/vmalloc.c:3320 alloc_thread_stack_node kernel/fork.c:309 [inline] dup_task_struct kernel/fork.c:1118 [inline] copy_process+0x225a/0x3f1e kernel/fork.c:2327 kernel_clone+0x118/0x896 kernel/fork.c:2909 user_mode_thread+0xea/0x11a kernel/fork.c:2987 call_usermodehelper_exec_work kernel/umh.c:172 [inline] call_usermodehelper_exec_work+0xc8/0x122 kernel/umh.c:158 process_one_work+0x54c/0xd66 kernel/workqueue.c:2630 process_scheduled_works kernel/workqueue.c:2703 [inline] worker_thread+0x506/0x980 kernel/workqueue.c:2784 kthread+0x1bc/0x22c kernel/kthread.c:388 ret_from_fork+0xa/0x1c arch/riscv/kernel/entry.S:264 page last free stack trace: __reset_page_owner+0x4c/0xf8 mm/page_owner.c:149 reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1136 [inline] free_unref_page_prepare+0x224/0x592 mm/page_alloc.c:2312 free_unref_page+0x5a/0x234 mm/page_alloc.c:2405 free_the_page mm/page_alloc.c:562 [inline] __free_pages+0x104/0x126 mm/page_alloc.c:4516 vfree+0x14c/0x68e mm/vmalloc.c:2842 delayed_vfree_work+0x42/0x58 mm/vmalloc.c:2763 process_one_work+0x54c/0xd66 kernel/workqueue.c:2630 process_scheduled_works kernel/workqueue.c:2703 [inline] worker_thread+0x506/0x980 kernel/workqueue.c:2784 kthread+0x1bc/0x22c kernel/kthread.c:388 ret_from_fork+0xa/0x1c arch/riscv/kernel/entry.S:264 Memory state around the buggy address: ff20000006d37b00: 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1 ff20000006d37b80: 00 00 f3 f3 00 00 00 00 00 00 00 00 00 00 00 00 >ff20000006d37c00: 00 00 00 00 00 00 00 00 00 00 00 00 f1 f1 f1 f1 ^ ff20000006d37c80: f1 f1 00 00 00 00 00 00 00 00 00 f3 f3 f3 f3 f3 ff20000006d37d00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== --- This report is generated by a bot. It may contain errors. See https://goo.gl/tpsmEJ for more information about syzbot. syzbot engineers can be reached at syzkaller@googlegroups.com. syzbot will keep track of this issue. See: https://goo.gl/tpsmEJ#status for how to communicate with syzbot. If the bug is already fixed, let syzbot know by replying with: #syz fix: exact-commit-title If you want syzbot to run the reproducer, reply with: #syz test: git://repo/address.git branch-or-commit-hash If you attach or paste a git patch, syzbot will apply it before testing. If you want to overwrite bug's subsystems, reply with: #syz set subsystems: new-subsystem (See the list of subsystem names on the web dashboard) If the bug is a duplicate of another bug, reply with: #syz dup: exact-subject-of-another-report If you want to undo deduplication, reply with: #syz undup