syzbot


panic: malloc: allocation too large, type = 2, size = ADDRp4a4n07ic3:LINE 0k95er5n0e3l3 diagnostic assertion "!_kernel_l

Status: closed as dup on 2019/09/01 09:01
Reported-by: syzbot+00dac47b20d6d1a88c61@syzkaller.appspotmail.com
First crash: 1938d, last: 1938d
Duplicate of
Title Repro Cause bisect Fix bisect Count Last Reported
panic: malloc: allocation too large, type = 2, size = ADDR (2) C 16842 1928d 1946d

Sample crash report:
panic: malloc: allocation too large, type = 2, size = 184467p4a4n07ic3:7 0k95er5n0e3l3 diagnostic assertion "!_kernel_lock_held()" failed: file "/syzkaller/managers/multicore/kernel/sys/kern/kern_fork.c", line 690
Stopped at      db_enter+0x18:  addq    $0x8,%rsp
    TID    PID    UID     PRFLAGS     PFLAGS  CPU  COMMAND
 184487  21242      0           0  0x4000000    0  syz-executor.0
*483940  54024      0           0  0x4000000    1  syz-executor.1
db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398
panic() at panic+0x15c sys/kern/subr_prf.c:207
__assert(ffffffff82201755,ffffffff821eedab,2b2,ffffffff821d32a3) at __assert+0x2b sys/kern/subr_prf.c:154
proc_trampoline_mp() at proc_trampoline_mp+0x123
end trace frame: 0x0, count: 11
https://www.openbsd.org/ddb.html describes the minimum info required in bug
reports.  Insufficient info makes it difficult to find and fix bugs.
ddb{1}> 
ddb{1}> set $lines = 0
ddb{1}> set $maxwidth = 0
ddb{1}> show panic
malloc: allocation too large, type = 2, size = 18446744073709550336

ddb{1}> trace
db_enter() at db_enter+0x18 sys/arch/amd64/amd64/db_interface.c:398
panic() at panic+0x15c sys/kern/subr_prf.c:207
__assert(ffffffff82201755,ffffffff821eedab,2b2,ffffffff821d32a3) at __assert+0x2b sys/kern/subr_prf.c:154
proc_trampoline_mp() at proc_trampoline_mp+0x123
end trace frame: 0x0, count: -4
ddb{1}> show registers
rdi                                0
rsi                              0x1
rbp               0xffff800022d6d7c0
rbx               0xffff800022d6d870
rdx               0xffff800020ab09f8
rcx                                0
rax                                0
r8                0xffffffff810af37f    kprintf+0x16f
r9                               0x1
r10                             0x25
r11               0x3ee75d74eb813f73
r12                     0x3000000008
r13               0xffff800022d6d7d0
r14                            0x104
r15                              0x1
rip               0xffffffff8193b028    db_enter+0x18
cs                               0x8
rflags                         0x246
rsp               0xffff800022d6d7b0
ss                              0x10
db_enter+0x18:  addq    $0x8,%rsp
ddb{1}> show proc
PROC (syz-executor.1) pid=483940 stat=onproc
    flags process=0 proc=4000000<THREAD>
    pri=81, usrpri=81, nice=20
    forw=0xffffffffffffffff, list=0xffff800020ab0ee8,0xffff800020ab1170
    process=0xffff800020adce00 user=0xffff800022d68000, vmspace=0xfffffd807f00ba10
    estcpu=36, cpticks=1, pctcpu=0.0
    user=0, sys=1, intr=0
ddb{1}> ps
   PID     TID   PPID    UID  S       FLAGS  WAIT          COMMAND
 21242  371769   9444      0  2           0                syz-executor.0
 21242  184487   9444      0  7   0x4000000                syz-executor.0
 54024  363031  80489      0  2           0                syz-executor.1
*54024  483940  80489      0  7   0x4000000                syz-executor.1
 66210  448336      0      0  3     0x14200  acct          acct
  9444  232352  23762      0  3        0x82  nanosleep     syz-executor.0
 80489  278747  23762      0  3        0x82  nanosleep     syz-executor.1
 80820   78877      0      0  3     0x14200  bored         sosplice
 23762  199467  74085      0  3        0x82  thrsleep      syz-fuzzer
 23762   91210  74085      0  3   0x4000082  nanosleep     syz-fuzzer
 23762  292914  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762  104817  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762  420285  74085      0  3   0x4000082  kqread        syz-fuzzer
 23762  168630  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762   54191  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762   45438  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762  125705  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 23762  451736  74085      0  3   0x4000082  thrsleep      syz-fuzzer
 74085  285207  16783      0  3    0x10008a  pause         ksh
 16783  512343  62571      0  3        0x92  select        sshd
 96921  320136      1      0  3    0x100083  ttyin         getty
 62571  227093      1      0  3        0x80  select        sshd
 76547   64201  88305     74  3    0x100092  bpf           pflogd
 88305  498039      1      0  3        0x80  netio         pflogd
 66793  152446  82587     73  3    0x100090  kqread        syslogd
 82587  420247      1      0  3    0x100082  netio         syslogd
 42223  156821      1     77  3    0x100090  poll          dhclient
 97871   70499      1      0  3        0x80  poll          dhclient
 92458   52367      0      0  2     0x14200                zerothread
 69878  277299      0      0  3     0x14200  aiodoned      aiodoned
 37470  169119      0      0  3     0x14200  syncer        update
 82567  516131      0      0  3     0x14200  cleaner       cleaner
 21824  449957      0      0  3     0x14200  reaper        reaper
 24768  204468      0      0  3     0x14200  pgdaemon      pagedaemon
 17151  394682      0      0  3     0x14200  bored         crynlk
 16192  147541      0      0  3     0x14200  bored         crypto
 80313  441908      0      0  3  0x40014200  acpi0         acpi0
 75891  239869      0      0  3  0x40014200                idle1
 13182  288979      0      0  3     0x14200  bored         softnet
 71033  335930      0      0  3     0x14200  bored         systqmp
 86003  360261      0      0  3     0x14200  bored         systq
 76184  332303      0      0  3  0x40014200  bored         softclock
 65642  323393      0      0  3  0x40014200                idle0
 83401  124577      0      0  3     0x14200  bored         smr
     1  245579      0      0  3        0x82  wait          init
     0       0     -1      0  3     0x10200  scheduler     swapper
ddb{1}> show all locks
Process 21242 (syz-executor.0) thread 0xffff800020ab1160 (184487)
shared rwlock vmlistlock r = 0 (0xffff80000066f478)
#0  witness_lock+0x52e sys/kern/subr_witness.c:1163
#1  vm_get_info+0x39 sys/arch/amd64/amd64/vmm.c:3712
#2  VOP_IOCTL+0x88 sys/kern/vfs_vops.c:291
#3  vn_ioctl+0xb7 sys/kern/vfs_vnops.c:524
#4  sys_ioctl+0x5b9
#5  syscall+0x4a4 mi_syscall sys/sys/syscall_mi.h:92 [inline]
#5  syscall+0x4a4 sys/arch/amd64/amd64/trap.c:555
#6  Xsyscall+0x128
exclusive kernel_lock &kernel_lock r = 0 (0xffffffff82620e88)
#0  witness_lock+0x52e sys/kern/subr_witness.c:1163
#1  syscall+0x400 mi_syscall sys/sys/syscall_mi.h:83 [inline]
#1  syscall+0x400 sys/arch/amd64/amd64/trap.c:555
#2  Xsyscall+0x128
ddb{1}> show malloc
           Type InUse  MemUse  HighUse   Limit  Requests Type Lim Kern Lim
         devbuf  9568   6515K    7156K  78643K     18114        0        0
            pcb    13      8K       8K  78643K       289        0        0
         rtable   119     12K      13K  78643K      3562        0        0
         ifaddr    72     22K      27K  78643K      1791        0        0
       counters    39     33K      33K  78643K        39        0        0
       ioctlops     0      0K       4K  78643K      1585        0        0
            iov     0      0K      16K  78643K       156        0        0
          mount     1      1K       1K  78643K         1        0        0
         vnodes  1207     76K      77K  78643K      3987        0        0
      UFS quota     1     32K      32K  78643K         1        0        0
      UFS mount     5     36K      36K  78643K         5        0        0
            shm     2      1K       5K  78643K        37        0        0
         VM map     2      1K       1K  78643K        10        0        0
            sem    12      1K       1K  78643K      2395        0        0
        dirhash    12      2K       2K  78643K        12        0        0
           ACPI  1809    196K     290K  78643K     12843        0        0
      file desc     6     17K      25K  78643K      3129        0        0
          sigio     0      0K       0K  78643K        15        0        0
           proc    61     63K      95K  78643K      1043        0        0
        subproc    32      2K       2K  78643K       189        0        0
    NFS srvsock     1      0K       0K  78643K         1        0        0
     NFS daemon     1     16K      16K  78643K         1        0        0
    ip_moptions     0      0K       0K  78643K       182        0        0
       in_multi    33      2K       2K  78643K       208        0        0
    ether_multi     1      0K       0K  78643K        12        0        0
            mrt     0      0K       0K  78643K         4        0        0
    ISOFS mount     1     32K      32K  78643K         1        0        0
  MSDOSFS mount     1     16K      16K  78643K         1        0        0
           ttys    84    371K     371K  78643K        84        0        0
           exec     0      0K       1K  78643K       544        0        0
     pfkey data     0      0K       4K  78643K         2        0        0
        pagedep     1      8K       8K  78643K         1        0        0
       inodedep     1     32K      32K  78643K         1        0        0
         newblk     1      0K       0K  78643K         1        0        0
        VM swap     7     26K      26K  78643K         7        0        0
       UVM amap   100     21K      30K  78643K     10501        0        0
       UVM aobj    96      3K       3K  78643K       119        0        0
        memdesc     1      4K       4K  78643K         1        0        0
    crypto data     1      1K       1K  78643K         1        0        0
    ip6_options     0      0K       0K  78643K       259        0        0
            NDP    16      0K       0K  78643K       530        0        0
           temp   200   3560K    4200K  78643K     43621        0        0
         kqueue     0      0K       0K  78643K        18        0        0
      SYN cache     2     16K      16K  78643K         2        0        0
ddb{1}> show all pools
Name      Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle
arp         64       25    0       19     1     0     1     1     0     8    0
plcache    128       20    0        0     1     0     1     1     0     8    0
rtpcb       80      114    0      112     1     0     1     1     0     8    0
rtentry    112      142    0       96     2     0     2     2     0     8    0
unpcb      120      727    0      717     1     0     1     1     0     8    0
syncache   264        4    0        4     1     1     0     1     0     8    0
sackhl      24        1    0        1     1     1     0     1     0     8    0
tcpqe       32     6121    0     6121     2     2     0     2     0     8    0
tcpcb      544      458    0      454     1     0     1     1     0     8    0
inpcb      280     1386    0     1379     5     3     2     2     0     8    1
nd6         48       22    0       18     1     0     1     1     0     8    0
pkpcb       40       11    0       11     5     5     0     1     0     8    0
swfcl       56        4    0        0     1     0     1     1     0     8    0
ppxss      1128     472    0      472     8     7     1     1     0     8    1
pffrag     232        4    0        4     3     3     0     1     0   482    0
pffrnode    88        4    0        4     3     3     0     1     0     8    0
pffrent     40        8    0        8     3     3     0     1     0     8    0
pfosfp      40      846    0      423     5     0     5     5     0     8    0
pfosfpen   112     1428    0      714    21     0    21    21     0     8    0
pfstitem    24       66    0       49     1     0     1     1     0     8    0
pfstkey    112       67    0       50     1     0     1     1     0     8    0
pfstate    328       67    0       48     2     0     2     2     0     8    0
pfrule     1360      21    0       16     2     1     1     2     0     8    0
art_heap8  4096       1    0        0     1     0     1     1     0     8    0
art_heap4  256      665    0      417    21     5    16    16     0     8    0
art_table   32      666    0      417     3     0     3     3     0     8    0
art_node    16      137    0       95     1     0     1     1     0     8    0
sysvmsgpl   40       11    0        7     1     0     1     1     0     8    0
semupl     112        3    0        3     1     1     0     1     0     8    0
semapl     112     2393    0     2383     1     0     1     1     0     8    0
shmpl      112      117    0       23     3     0     3     3     0     8    0
dirhash    1024      17    0        0     3     0     3     3     0     8    0
dino1pl    128     6860    0     5464    46     0    46    46     0     8    0
ffsino     272     6860    0     5464    94     0    94    94     0     8    0
nchpl      144    10811    0     9206    61     1    60    61     0     8    0
uvmvnodes   72     6096    0        0   111     0   111   111     0     8    0
vnodes     208     6096    0        0   321     0   321   321     0     8    0
namei      1024   38484    0    38484     2     1     1     1     0     8    1
percpumem   16       30    0        0     1     0     1     1     0     8    0
vmpool     552        8    0        8     4     4     0     1     0     8    0
scsiplug    64        5    0        5     4     3     1     1     0     8    1
scxspl     192    29768    0    29768    15    11     4     7     0     8    4
plimitpl   152      222    0      214     1     0     1     1     0     8    0
sigapl     432     3302    0     3286     4     2     2     3     0     8    0
futexpl     56    46260    0    46260     1     0     1     1     0     8    1
knotepl    112      608    0      589     1     0     1     1     0     8    0
kqueuepl   104      504    0      502     1     0     1     1     0     8    0
pipepl     112     1272    0     1253     1     0     1     1     0     8    0
fdescpl    488     3303    0     3286     3     0     3     3     0     8    0
filepl     152    20737    0    20634     6     1     5     5     0     8    1
lockfpl    104     2197    0     2195     1     0     1     1     0     8    0
lockfspl    48      816    0      814     1     0     1     1     0     8    0
sessionpl  112       27    0       16     1     0     1     1     0     8    0
pgrppl      48       51    0       40     1     0     1     1     0     8    0
ucredpl     96     4789    0     4780     1     0     1     1     0     8    0
zombiepl   144     3288    0     3288     2     1     1     1     0     8    1
processpl  896     3322    0     3288     4     0     4     4     0     8    0
procpl     632     9338    0     9293     8     3     5     5     0     8    1
srpgc       64       18    0       18     6     6     0     1     0     8    0
sosppl     128       22    0       22     6     5     1     1     0     8    1
sockpl     384     2254    0     2235     6     3     3     4     0     8    1
mcl64k     65536     13    0        0     2     0     2     2     0     8    0
mcl16k     16384      5    0        0     1     0     1     1     0     8    0
mcl12k     12288     16    0        0     2     0     2     2     0     8    0
mcl9k      9216       6    0        0     1     0     1     1     0     8    0
mcl8k      8192      18    0        0     3     0     3     3     0     8    0
mcl4k      4096      12    0        0     2     0     2     2     0     8    0
mcl2k2     2112       5    0        0     1     0     1     1     0     8    0
mcl2k      2048     235    0        0    26     2    24    26     0     8    0
mtagpl      80       29    0        0     1     0     1     1     0     8    0
mbufpl     256      276    0        0    16     1    15    15     0     8    0
bufpl      256    13079    0     6031   441     0   441   441     0     8    0
anonpl      16   281523    0   268747   109    41    68    68     0   124   15
amapchunkpl 152   18463    0    18351    33    27     6    19     0   158    0
amappl16   192    15274    0    14577    97    54    43    47     0     8    8
amappl15   184        1    0        1     1     1     0     1     0     8    0
amappl14   176      100    0       96     1     0     1     1     0     8    0
amappl13   168      432    0      432     2     2     0     1     0     8    0
amappl12   160      509    0      509     3     3     0     1     0     8    0
amappl11   152      623    0      604     1     0     1     1     0     8    0
amappl10   144      136    0      131     1     0     1     1     0     8    0
amappl9    136     2041    0     2033     1     0     1     1     0     8    0
amappl8    128     1534    0     1506     1     0     1     1     0     8    0
amappl7    120      201    0      193     1     0     1     1     0     8    0
amappl6    112      610    0      597     1     0     1     1     0     8    0
amappl5    104      701    0      688     1     0     1     1     0     8    0
amappl4     96     3486    0     3453     1     0     1     1     0     8    0
amappl3     88      677    0      672     1     0     1     1     0     8    0
amappl2     80    25456    0    25372     3     1     2     3     0     8    0
amappl1     72    79328    0    78880    26    16    10    20     0     8    0
amappl      80     9726    0     9687     1     0     1     1     0    84    0
dma4096    4096       1    0        1     1     1     0     1     0     8    0
dma256     256        6    0        6     1     1     0     1     0     8    0
dma64       64      259    0      259     1     1     0     1     0     8    0
dma32       32        7    0        7     1     1     0     1     0     8    0
dma16       16       17    0       17     1     1     0     1     0     8    0
aobjpl      64      118    0       23     2     0     2     2     0     8    0
uaddrrnd    24     3311    0     3286     1     0     1     1     0     8    0
uaddrbest   32        2    0        0     1     0     1     1     0     8    0
uaddr       24     3311    0     3286     1     0     1     1     0     8    0
vmmpekpl   168    27357    0    27324     3     1     2     2     0     8    0
vmmpepl    168   404696    0   402759   197   101    96   106     0   357   11
vmsppl     368     3302    0     3286     2     0     2     2     0     8    0
pdppl      4096    6629    0     6588     7     1     6     6     0     8    0
pvpl        32   812328    0   796278   278   111   167   170     0   265   37
pmappl     232     3310    0     3294     4     3     1     2     0     8    0
extentpl    40       38    0       22     1     0     1     1     0     8    0
phpool     112      626    0       13    18     0    18    18     0     8    0

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2019/08/31 14:49 openbsd d9ff79beba61 bad3cce2 .config console log report ci-openbsd-multicore
* Struck through repros no longer work on HEAD.