Discussion:
WARNING in kobject_add_internal
(too old to reply)
syzbot
2017-10-31 12:54:01 UTC
Permalink
Hello,

syzkaller hit the following crash on
833e0e2f24fd0525090878f71e129a8a4cb8bf78
git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next.git/master
compiler: gcc (GCC) 7.1.1 20170620
.config is attached
Raw console output is attached.




kobject_add_internal failed for brport (error: -12 parent: syz6)
------------[ cut here ]------------
WARNING: CPU: 1 PID: 3485 at lib/kobject.c:244
kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
Kernel panic - not syncing: panic_on_warn set ...

CPU: 1 PID: 3485 Comm: syz-executor6 Not tainted 4.14.0-rc4+ #80
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:16 [inline]
dump_stack+0x194/0x257 lib/dump_stack.c:52
panic+0x1e4/0x417 kernel/panic.c:181
__warn+0x1c4/0x1d9 kernel/panic.c:542
report_bug+0x211/0x2d0 lib/bug.c:183
fixup_bug+0x40/0x90 arch/x86/kernel/traps.c:178
do_trap_no_signal arch/x86/kernel/traps.c:212 [inline]
do_trap+0x260/0x390 arch/x86/kernel/traps.c:261
do_error_trap+0x120/0x390 arch/x86/kernel/traps.c:298
do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:311
invalid_op+0x18/0x20 arch/x86/entry/entry_64.S:905
RIP: 0010:kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
RSP: 0018:ffff8801bf816900 EFLAGS: 00010282
RAX: 0000000000000040 RBX: ffff8801c09b4620 RCX: 0000000000000000
RDX: 0000000000000040 RSI: ffffffff8158d38e RDI: ffffed0037f02d14
RBP: ffff8801bf8169f8 R08: ffff8801bf816070 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 1ffff10037f02d26
R13: 00000000fffffff4 R14: ffff8801cb9b0b30 R15: ffff8801cd01c000
kobject_add_varg lib/kobject.c:366 [inline]
kobject_init_and_add+0xf9/0x150 lib/kobject.c:438
br_add_if+0x786/0x1990 net/bridge/br_if.c:533
br_add_slave+0x29/0x30 net/bridge/br_device.c:349
do_set_master+0x19c/0x1f0 net/core/rtnetlink.c:1986
do_setlink+0xa98/0x38e0 net/core/rtnetlink.c:2119
rtnl_newlink+0xf0d/0x1a40 net/core/rtnetlink.c:2661
rtnetlink_rcv_msg+0x733/0x1090 net/core/rtnetlink.c:4301
netlink_rcv_skb+0x216/0x440 net/netlink/af_netlink.c:2409
rtnetlink_rcv+0x1c/0x20 net/core/rtnetlink.c:4313
netlink_unicast_kernel net/netlink/af_netlink.c:1273 [inline]
netlink_unicast+0x4e8/0x6f0 net/netlink/af_netlink.c:1299
netlink_sendmsg+0xa4a/0xe70 net/netlink/af_netlink.c:1862
sock_sendmsg_nosec net/socket.c:633 [inline]
sock_sendmsg+0xca/0x110 net/socket.c:643
sock_write_iter+0x320/0x5e0 net/socket.c:912
call_write_iter include/linux/fs.h:1770 [inline]
do_iter_readv_writev+0x531/0x7f0 fs/read_write.c:673
do_iter_write+0x15a/0x540 fs/read_write.c:952
vfs_writev+0x18a/0x340 fs/read_write.c:997
do_writev+0xfc/0x2a0 fs/read_write.c:1032
SYSC_writev fs/read_write.c:1105 [inline]
SyS_writev+0x27/0x30 fs/read_write.c:1102
entry_SYSCALL_64_fastpath+0x1f/0xbe
RIP: 0033:0x4520a9
RSP: 002b:00007f4633db3c08 EFLAGS: 00000216 ORIG_RAX: 0000000000000014
RAX: ffffffffffffffda RBX: 0000000000718000 RCX: 00000000004520a9
RDX: 0000000000000001 RSI: 00000000205d9000 RDI: 0000000000000005
RBP: 0000000000000086 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000216 R12: 00000000004b6c37
R13: 00007f4633db3b48 R14: 00000000004b6c47 R15: 0000000000000000
Dumping ftrace buffer:
(ftrace buffer empty)
Kernel Offset: disabled
Rebooting in 86400 seconds..


---
This bug is generated by a dumb bot. It may contain errors.
See https://goo.gl/tpsmEJ for details.
Direct all questions to ***@googlegroups.com.
Please credit me with: Reported-by: syzbot <***@googlegroups.com>

syzbot will keep track of this bug report.
Once a fix for this bug is committed, please reply to this email with:
#syz fix: exact-commit-title
To mark this as a duplicate of another syzbot report, please reply with:
#syz dup: exact-subject-of-another-report
If it's a one-off invalid bug report, please reply with:
#syz invalid
Note: if the crash happens again, it will cause creation of a new bug
report.
Note: all commands must start from beginning of the line.
syzbot
2018-01-05 21:41:00 UTC
Permalink
syzkaller has found reproducer for the following crash on
89876f275e8d562912d9c238cd888b52065cf25c
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/master
compiler: gcc (GCC) 7.1.1 20170620
.config is attached
Raw console output is attached.
C reproducer is attached
syzkaller reproducer is attached. See https://goo.gl/kgGztJ
for information about syzkaller reproducers


IMPORTANT: if you fix the bug, please add the following tag to the commit:
Reported-by:
syzbot+***@syzkaller.appspotmail.com
It will help syzbot understand when the bug is fixed.

------------[ cut here ]------------
kobject_add_internal failed for  (error: -12 parent: net)
WARNING: CPU: 1 PID: 3494 at lib/kobject.c:244
kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
Kernel panic - not syncing: panic_on_warn set ...

CPU: 1 PID: 3494 Comm: syzkaller425998 Not tainted 4.15.0-rc6+ #249
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS
Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:17 [inline]
dump_stack+0x194/0x257 lib/dump_stack.c:53
panic+0x1e4/0x41c kernel/panic.c:183
__warn+0x1dc/0x200 kernel/panic.c:547
report_bug+0x211/0x2d0 lib/bug.c:184
fixup_bug.part.11+0x37/0x80 arch/x86/kernel/traps.c:178
fixup_bug arch/x86/kernel/traps.c:247 [inline]
do_error_trap+0x2d7/0x3e0 arch/x86/kernel/traps.c:296
do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:315
invalid_op+0x22/0x40 arch/x86/entry/entry_64.S:1079
RIP: 0010:kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
RSP: 0018:ffff8801c53c76f0 EFLAGS: 00010286
RAX: dffffc0000000008 RBX: ffff8801bf5a88d8 RCX: ffffffff8159da9e
RDX: 0000000000000000 RSI: 1ffff10038a78e99 RDI: ffff8801c53c73f8
RBP: ffff8801c53c77e8 R08: 1ffff10038a78e5b R09: 0000000000000000
R10: ffff8801c53c74b0 R11: 0000000000000000 R12: 1ffff10038a78ee4
R13: 00000000fffffff4 R14: ffff8801d8359a80 R15: ffffffff86201980
kobject_add_varg lib/kobject.c:366 [inline]
kobject_add+0x132/0x1f0 lib/kobject.c:411
device_add+0x35d/0x1650 drivers/base/core.c:1787
netdev_register_kobject+0x183/0x360 net/core/net-sysfs.c:1604
register_netdevice+0xb2b/0x1010 net/core/dev.c:7698
tun_set_iff drivers/net/tun.c:2319 [inline]
__tun_chr_ioctl+0x1d89/0x3dd0 drivers/net/tun.c:2524
tun_chr_ioctl+0x2a/0x40 drivers/net/tun.c:2773
vfs_ioctl fs/ioctl.c:46 [inline]
do_vfs_ioctl+0x1b1/0x1520 fs/ioctl.c:686
SYSC_ioctl fs/ioctl.c:701 [inline]
SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692
entry_SYSCALL_64_fastpath+0x23/0x9a
RIP: 0033:0x444fc9
RSP: 002b:00007fff53389dc8 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 0000000000444fc9
RDX: 0000000020533000 RSI: 00000000400454ca RDI: 0000000000000004
RBP: 0000000000000005 R08: 0000000000000002 R09: 0000006f00003131
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402500
R13: 0000000000402590 R14: 0000000000000000 R15: 0000000000000000
Dumping ftrace buffer:
(ftrace buffer empty)
Kernel Offset: disabled
Rebooting in 86400 seconds..
Yuan, Linyu (NSB - CN/Shanghai)
2018-04-12 00:29:40 UTC
Permalink
Hi,

I have a question,
"can syzbot auto test each tree with newest changeset" ?
-----Original Message-----
On Behalf Of Dmitry Vyukov
Sent: Wednesday, April 11, 2018 10:58 PM
To: syzbot
LKML; netdev; stephen hemminger; syzkaller-bugs
Subject: Re: WARNING in kobject_add_internal
On Fri, Jan 5, 2018 at 10:41 PM, syzbot
il.com>
Post by syzbot
syzkaller has found reproducer for the following crash on
89876f275e8d562912d9c238cd888b52065cf25c
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/master
compiler: gcc (GCC) 7.1.1 20170620
.config is attached
Raw console output is attached.
C reproducer is attached
syzkaller reproducer is attached. See https://goo.gl/kgGztJ
for information about syzkaller reproducers
.com
Post by syzbot
It will help syzbot understand when the bug is fixed.
#syz dup: WARNING: kobject bug in device_add
Post by syzbot
------------[ cut here ]------------
kobject_add_internal failed for (error: -12 parent: net)
WARNING: CPU: 1 PID: 3494 at lib/kobject.c:244
kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
Kernel panic - not syncing: panic_on_warn set ...
CPU: 1 PID: 3494 Comm: syzkaller425998 Not tainted 4.15.0-rc6+ #249
Hardware name: Google Google Compute Engine/Google Compute Engine,
BIOS
Post by syzbot
Google 01/01/2011
__dump_stack lib/dump_stack.c:17 [inline]
dump_stack+0x194/0x257 lib/dump_stack.c:53
panic+0x1e4/0x41c kernel/panic.c:183
__warn+0x1dc/0x200 kernel/panic.c:547
report_bug+0x211/0x2d0 lib/bug.c:184
fixup_bug.part.11+0x37/0x80 arch/x86/kernel/traps.c:178
fixup_bug arch/x86/kernel/traps.c:247 [inline]
do_error_trap+0x2d7/0x3e0 arch/x86/kernel/traps.c:296
do_invalid_op+0x1b/0x20 arch/x86/kernel/traps.c:315
invalid_op+0x22/0x40 arch/x86/entry/entry_64.S:1079
RIP: 0010:kobject_add_internal+0x3f6/0xbc0 lib/kobject.c:242
RSP: 0018:ffff8801c53c76f0 EFLAGS: 00010286
RAX: dffffc0000000008 RBX: ffff8801bf5a88d8 RCX: ffffffff8159da9e
RDX: 0000000000000000 RSI: 1ffff10038a78e99 RDI: ffff8801c53c73f8
RBP: ffff8801c53c77e8 R08: 1ffff10038a78e5b R09: 0000000000000000
R10: ffff8801c53c74b0 R11: 0000000000000000 R12: 1ffff10038a78ee4
R13: 00000000fffffff4 R14: ffff8801d8359a80 R15: ffffffff86201980
kobject_add_varg lib/kobject.c:366 [inline]
kobject_add+0x132/0x1f0 lib/kobject.c:411
device_add+0x35d/0x1650 drivers/base/core.c:1787
netdev_register_kobject+0x183/0x360 net/core/net-sysfs.c:1604
register_netdevice+0xb2b/0x1010 net/core/dev.c:7698
tun_set_iff drivers/net/tun.c:2319 [inline]
__tun_chr_ioctl+0x1d89/0x3dd0 drivers/net/tun.c:2524
tun_chr_ioctl+0x2a/0x40 drivers/net/tun.c:2773
vfs_ioctl fs/ioctl.c:46 [inline]
do_vfs_ioctl+0x1b1/0x1520 fs/ioctl.c:686
SYSC_ioctl fs/ioctl.c:701 [inline]
SyS_ioctl+0x8f/0xc0 fs/ioctl.c:692
entry_SYSCALL_64_fastpath+0x23/0x9a
RIP: 0033:0x444fc9
0000000000000010
Post by syzbot
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 0000000000444fc9
RDX: 0000000020533000 RSI: 00000000400454ca RDI: 0000000000000004
RBP: 0000000000000005 R08: 0000000000000002 R09: 0000006f00003131
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000402500
R13: 0000000000402590 R14: 0000000000000000 R15: 0000000000000000
(ftrace buffer empty)
Kernel Offset: disable
Continue reading on narkive:
Loading...