syzbot


uvm_fault: pmap_page_remove (3)

Status: closed as invalid on 2022/02/15 06:33
Reported-by: syzbot+20b2695570939c4acf15@syzkaller.appspotmail.com
First crash: 1014d, last: 1014d
Similar bugs (4)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
openbsd uvm_fault: pmap_page_remove (4) 1 945d 945d 0/3 auto-closed as invalid on 2022/07/20 03:20
openbsd uvm_fault: pmap_page_remove (5) 16 38d 348d 0/3 upstream: reported on 2023/12/09 17:23
openbsd uvm_fault: pmap_page_remove 7 1889d 2146d 0/3 auto-closed as invalid on 2019/12/19 05:38
openbsd uvm_fault: pmap_page_remove (2) 5 1566d 1743d 0/3 auto-closed as invalid on 2020/11/06 07:50

Sample crash report:
uvm_fault(0xffffffff82a6df90, 0x7f843f93e530, 0, 2) -> e
kernel: page fault trap, code=0
Stopped at      pmap_page_remove+0x30d: xchgq   %rax,0(%r15,%rcx,1)
    TID    PID    UID     PRFLAGS     PFLAGS  CPU  COMMAND
*347058  85728      0     0x14000      0x200    0  reaper
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d _atomic_swap_64 machine/atomic.h:117 [inline]
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d sys/arch/amd64/amd64/pmap.c:1959
uvm_anfree_list(fffffd806bfee840,ffff8000215be9a8) at uvm_anfree_list+0x98
amap_wipeout(fffffd807af82210) at amap_wipeout+0x1b1 sys/uvm/uvm_amap.c:504
uvm_unmap_detach(ffff8000215bea70,1) at uvm_unmap_detach+0x7d sys/uvm/uvm_map.c:1607
uvm_map_teardown(fffffd8066ebf440) at uvm_map_teardown+0x232 sys/uvm/uvm_map.c:2808
uvmspace_free(fffffd8066ebf440) at uvmspace_free+0x86 sys/uvm/uvm_map.c:3707
reaper(ffff8000fffff500) at reaper+0x15e sys/kern/kern_exit.c:462
end trace frame: 0x0, count: 8
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> 
ddb> set $lines = 0
ddb> set $maxwidth = 0
ddb> show panic
*cpu0: uvm_fault(0xffffffff82a6df90, 0x7f843f93e530, 0, 2) -> e
ddb> trace
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d _atomic_swap_64 machine/atomic.h:117 [inline]
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d sys/arch/amd64/amd64/pmap.c:1959
uvm_anfree_list(fffffd806bfee840,ffff8000215be9a8) at uvm_anfree_list+0x98
amap_wipeout(fffffd807af82210) at amap_wipeout+0x1b1 sys/uvm/uvm_amap.c:504
uvm_unmap_detach(ffff8000215bea70,1) at uvm_unmap_detach+0x7d sys/uvm/uvm_map.c:1607
uvm_map_teardown(fffffd8066ebf440) at uvm_map_teardown+0x232 sys/uvm/uvm_map.c:2808
uvmspace_free(fffffd8066ebf440) at uvmspace_free+0x86 sys/uvm/uvm_map.c:3707
reaper(ffff8000fffff500) at reaper+0x15e sys/kern/kern_exit.c:462
end trace frame: 0x0, count: -7
ddb> show registers
rdi                                0
rsi                                0
rbp               0xffff8000215be950
rbx                                0
rdx                                0
rcx                   0x7f8000000000
rax                                0
r8                                 0
r9                                 0
r10               0x6cd36b6a9ad3bfc1
r11               0x17413fca9e591f5d
r12                                0
r13               0xfffffd806bb91f28
r14               0x800000007f7cf000
r15                      0x43f93e530
rip               0xffffffff813b220d    pmap_page_remove+0x30d
cs                               0x8
rflags                       0x10246    __ALIGN_SIZE+0xf246
rsp               0xffff8000215be8c0
ss                              0x10
pmap_page_remove+0x30d: xchgq   %rax,0(%r15,%rcx,1)
ddb> show proc
PROC (reaper) pid=347058 stat=onproc
    flags process=14000<NOZOMBIE,SYSTEM> proc=200<SYSTEM>
    pri=4, usrpri=51, nice=20
    forw=0xffffffffffffffff, list=0xffff8000ffffed20,0xffff8000fffff7b0
    process=0xffff8000ffffa7d8 user=0xffff8000215b9000, vmspace=0xffffffff82a6df90
    estcpu=1, cpticks=1, pctcpu=0.30
    user=0, sys=1, intr=0
ddb> ps
   PID     TID   PPID    UID  S       FLAGS  WAIT          COMMAND
 54065  246597  50263      0  2           0                syz-executor.3
 21435  260756  38311      0  2           0                syz-executor.0
 38148  488521  72335      0  2           0                syz-executor.6
 67638  185672   5614      0  2           0                syz-executor.2
 67638  325523   5614      0  3   0x4000080  fsleep        syz-executor.2
 50263  362171  58242      0  3        0x82  nanoslp       syz-executor.3
 31205  297474  58242      0  2         0x2                syz-executor.1
 55334  164905  58242      0  3        0x82  nanoslp       syz-executor.5
 23598  137653  58242      0  3        0x82  nanoslp       syz-executor.7
 58028  432196  58242      0  3         0x2  biowait       syz-executor.4
 72335  228903  58242      0  3        0x82  nanoslp       syz-executor.6
 38311  129382  58242      0  3        0x82  nanoslp       syz-executor.0
 51644  183885      0      0  3     0x14200  bored         sosplice
  5614  385293  58242      0  3        0x82  nanoslp       syz-executor.2
 58242  307334  44865      0  3        0x82  thrsleep      syz-fuzzer
 58242  503666  44865      0  3   0x4000082  nanoslp       syz-fuzzer
 58242  373428  44865      0  3   0x4000082  thrsleep      syz-fuzzer
 58242  192520  44865      0  3   0x4000082  thrsleep      syz-fuzzer
 58242  421645  44865      0  3   0x4000082  kqread        syz-fuzzer
 58242  490348  44865      0  3   0x4000082  thrsleep      syz-fuzzer
 58242   32054  44865      0  3   0x4000082  thrsleep      syz-fuzzer
 58242    7117  44865      0  3   0x4000082  thrsleep      syz-fuzzer
 44865   77621  42740      0  3    0x10008a  sigsusp       ksh
 42740  273736  86312      0  3        0x9a  kqread        sshd
  6815  125664      1      0  3    0x100083  ttyin         getty
 86312  126519      1      0  3        0x88  kqread        sshd
 83184  380203  82809     73  3    0x100090  kqread        syslogd
 82809  141427      1      0  3    0x100082  netio         syslogd
 71804  454010      1      0  3    0x100080  kqread        resolvd
 57866  487643  88042     77  3    0x100092  kqread        dhcpleased
  6263  162410  88042     77  3    0x100092  kqread        dhcpleased
 88042   56894      1      0  3        0x80  kqread        dhcpleased
 43030  383125      0      0  3     0x14200  bored         smr
 96013  462008      0      0  2     0x14200                zerothread
 65044   59942      0      0  3     0x14200  aiodoned      aiodoned
 88320  130149      0      0  3     0x14200  syncer        update
 54521  187784      0      0  3     0x14200  cleaner       cleaner
*85728  347058      0      0  7     0x14200                reaper
 92628  385272      0      0  3     0x14200  pgdaemon      pagedaemon
 41502  312426      0      0  3     0x14200  bored         viomb
  8346  334393      0      0  3  0x40014200  acpi0         acpi0
 51055  333003      0      0  3     0x14200  bored         softnet
  7078   96165      0      0  3     0x14200  bored         systqmp
 56671  332307      0      0  3     0x14200  bored         systq
 61481  500852      0      0  3  0x40014200  bored         softclock
 23436   25184      0      0  3  0x40014200                idle0
     1  285162      0      0  3     0x80082  wait          init
     0       0     -1      0  3     0x10200  scheduler     swapper
ddb> show all locks
No such command
ddb> show malloc
           Type InUse  MemUse  HighUse   Limit  Requests Type Lim
         devbuf 10173   6434K    7071K  78643K     18885        0
            pcb    13      8K       9K  78643K       348        0
         rtable   218      7K      10K  78643K      1027        0
         ifaddr    78     16K      17K  78643K       319        0
         sysctl     2      0K       0K  78643K         2        0
       counters    26     17K      17K  78643K        60        0
       ioctlops     0      0K       4K  78643K       659        0
            iov     0      0K      16K  78643K       142        0
          mount     1      1K       1K  78643K         1        0
            log     0      0K       0K  78643K         4        0
         vnodes  1330     83K      83K  78643K      4079        0
      UFS quota     1     32K      32K  78643K         1        0
      UFS mount     5     36K      36K  78643K         5        0
            shm     2      1K       9K  78643K        36        0
         VM map     2      0K       0K  78643K         2        0
            sem    10      0K       1K  78643K        16        0
        dirhash    12      2K       2K  78643K        12        0
           ACPI  1697    195K     286K  78643K     12548        0
      file desc    14     49K      89K  78643K      7972        0
          sigio     0      0K       0K  78643K        32        0
           proc    69     55K      87K  78643K       945        0
        subproc   104      6K       6K  78643K       286        0
    NFS srvsock     1      0K       0K  78643K         1        0
     NFS daemon     1     16K      16K  78643K         1        0
    ip_moptions     0      0K       0K  78643K       239        0
       in_multi    87      5K       6K  78643K       375        0
    ether_multi     1      0K       0K  78643K        58        0
            mrt     1      0K       0K  78643K        70        0
    ISOFS mount     1     32K      32K  78643K         1        0
  MSDOSFS mount     1     16K      16K  78643K         1        0
           ttys    79    360K     360K  78643K        79        0
           exec     0      0K       2K  78643K      1088        0
     pfkey data     0      0K       0K  78643K         1        0
            tdb     3      0K       0K  78643K         3        0
        pagedep     1      8K       8K  78643K         1        0
       inodedep     1     32K      32K  78643K         1        0
         newblk     1      0K       0K  78643K         1        0
        VM swap     7     26K      26K  78643K         7        0
       UVM amap   346    263K     329K  78643K     94779        0
       UVM aobj    32      2K       2K  78643K        32        0
        memdesc     1      4K       4K  78643K         1        0
    crypto data     1      1K       1K  78643K         1        0
    ip6_options     0      0K       0K  78643K       211        0
            NDP    11      0K       2K  78643K        89        0
           temp   126   4697K    4767K  78643K     30209        0
         kqueue    12     18K      24K  78643K       261        0
      SYN cache     2     16K      16K  78643K         2        0
ddb> show all pools
Name      Size Requests Fail Releases Pgreq Pgrel Npage Hiwat Minpg Maxpg Idle
rtpcb      120      116    0      113     1     0     1     1     0     8    0
rtentry    112      306    0      210     4     0     4     4     0     8    0
unpcb      136     1578    0     1565     8     7     1     5     0     8    0
syncache   296       33    0       33     8     8     0     1     0     8    0
tcpqe       32       17    0       17     6     6     0     1     0     8    0
tcpcb      736      817    0      813    26    25     1     7     0     8    0
arp         88       47    0       33     1     0     1     1     0     8    0
ipq         40        9    0        9     3     3     0     1     0     8    0
ipqe        40      313    0      313     3     3     0     1     0     8    0
inpcb      304     2111    0     2104    22    21     1     6     0     8    0
rttmr       72       19    0       19     1     1     0     1     0     8    0
ip6q        72        1    0        1     1     1     0     1     0     8    0
ip6af       40        1    0        1     1     1     0     1     0     8    0
nd6         48       68    0       46     1     0     1     1     0     8    0
pkpcb       40       36    0       36     4     4     0     1     0     8    0
kcovpl      48       22    0       14     1     0     1     1     0     8    0
ppxss      1152      13    0       13     4     4     0     1     0     8    0
pfstscr     40       13    0       13     1     1     0     1     0     8    0
pffrag     232       27    0        7     2     0     2     2     0   482    0
pffrnode    88       16    0        7     1     0     1     1     0     8    0
pffrent     40      166    0      146     1     0     1     1     0     8    0
pfosfp      40        1    0        0     1     0     1     1     0     8    0
pfosfpen   112        1    0        0     1     0     1     1     0     8    0
pfrktable  1344      29    0       29     1     1     0     1     0     8    0
pftag       88        5    0        2     1     0     1     1     0     8    0
pfstitem    24       20    0       20     1     1     0     1     0     8    0
pfstkey    112       28    0       28     1     1     0     1     0     8    0
pfstate    320       14    0       14     1     1     0     1     0     8    0
pfrule     1360      59    0       53     3     2     1     2     0     8    0
art_heap8  4096       1    0        0     1     0     1     1     0     8    0
art_heap4  256     1107    0      695    35     9    26    29     0     8    0
art_table   32     1108    0      695     4     0     4     4     0     8    0
art_node    16      299    0      212     1     0     1     1     0     8    0
sysvmsgpl   40        3    0        0     1     0     1     1     0     8    0
semapl     112        8    0        0     1     0     1     1     0     8    0
shmpl      112       29    0        0     1     0     1     1     0     8    0
dirhash    1024      17    0        0     3     0     3     3     0     8    0
dino2pl    256    10665    0     9234    91     0    91    91     0     8    0
ffsino     240    10665    0     9234    86     0    86    86     0     8    0
nchpl      144    19558    0    17941    62     0    62    62     0     8    0
uvmvnodes   80     5926    0        0   121     0   121   121     0     8    0
vnodes     224     5926    0        0   349     0   349   349     0     8    0
namei      1024   54075    0    54073     7     6     1     2     0     8    0
vcpupl     1984      15    0        4     2     0     2     2     0     8    0
vmpool     528       16    0        5     2     1     1     2     0     8    0
pfiaddrpl  120        8    0        8     1     1     0     1     0     8    0
scsiplug    72        6    0        6     1     1     0     1     0     8    0
scxspl     216    63925    0    63924    14    12     2     8     0     8    1
plimitpl   152      158    0      144     1     0     1     1     0     8    0
sigapl     424     8233    0     8194     6     1     5     6     0     8    0
futexpl     64    44235    0    44234     6     5     1     1     0     8    0
knotepl    120    65895    0    65815     6     3     3     4     0     8    0
kqueuepl   184      453    0      445     1     0     1     1     0     8    0
pipepl     304      427    0      399     3     0     3     3     0     8    0
fdescpl    432     8219    0     8194     4     0     4     4     0     8    0
filepl     120    24852    0    24617    27    16    11    12     0     8    3
lockfpl    104      599    0      597     1     0     1     1     0     8    0
lockfspl    48      190    0      188     1     0     1     1     0     8    0
sessionpl  144       37    0       21     1     0     1     1     0     8    0
pgrppl      48       61    0       45     1     0     1     1     0     8    0
ucredpl     96     5267    0     5257     1     0     1     1     0     8    0
zombiepl   144     8194    0     8192     1     0     1     1     0     8    0
processpl  1000    8233    0     8192     7     1     6     7     0     8    0
procpl     672    17132    0    17083    16    10     6     6     0     8    1
sosppl     168       64    0       64     8     8     0     1     0     8    0
sockpl     448     3843    0     3820    41    36     5    17     0     8    2
mcl64k     65536    159    0      159     9     8     1     2     0     8    1
mcl16k     16384     81    0       81    12    11     1     1     0     8    1
mcl12k     12288    103    0      103    11    10     1     1     0     8    1
mcl9k      9216      63    0       63     9     8     1     1     0     8    1
mcl8k      8192     349    0      349    12    11     1     1     0     8    1
mcl4k      4096     261    0      261    14    13     1     1     0     8    1
mcl2k2     2112      14    0       14     6     6     0     1     0     8    0
mcl2k      2048   31621    0    31544    44    32    12    14     0     8    0
mtagpl      96     1020    0      514    15     2    13    13     0     8    0
mbufpl     256   117060    0   116337    94    46    48    68     0     8    1
bufpl      288    14053    0     7645   458     0   458   458     0     8    0
anonpl      24  2083807    0  2074166   162    90    72   110     0   188    0
amapchunkpl 152  224570    0   224027    76    49    27    46     0   158    2
amappl16   200    18502    0    18239    86    71    15    32     0     8    0
amappl15   192     1656    0     1651     1     0     1     1     0     8    0
amappl14   184     1294    0     1290     1     0     1     1     0     8    0
amappl13   176     2086    0     2082     1     0     1     1     0     8    0
amappl12   168     1025    0     1021     1     0     1     1     0     8    0
amappl11   160     1342    0     1329     1     0     1     1     0     8    0
amappl10   152     1003    0      995     1     0     1     1     0     8    0
amappl9    144      796    0      791     1     0     1     1     0     8    0
amappl8    136     1681    0     1562     5     0     5     5     0     8    0
amappl7    128      794    0      784     1     0     1     1     0     8    0
amappl6    120      569    0      543     2     1     1     2     0     8    0
amappl5    112     6254    0     6241     1     0     1     1     0     8    0
amappl4    104     4480    0     4449     2     0     2     2     0     8    0
amappl3     96     2273    0     2259     1     0     1     1     0     8    0
amappl2     88     3022    0     2966     3     1     2     3     0     8    0
amappl1     80   138208    0   137698    27    14    13    18     0     8    1
amappl      88    93816    0    93617     6     0     6     6     0    92    0
dma4096    4096       1    0        1     1     1     0     1     0     8    0
dma1024    1024       1    0        0     1     0     1     1     0     8    0
dma256     256        6    0        6     1     1     0     1     0     8    0
dma128     128      253    0      253     1     1     0     1     0     8    0
dma64       64        6    0        6     1     1     0     1     0     8    0
dma32       32        7    0        7     1     1     0     1     0     8    0
dma16       16       18    0       17     1     0     1     1     0     8    0
aobjpl      72       31    0        0     1     0     1     1     0     8    0
uaddrrnd    24     8235    0     8199     1     0     1     1     0     8    0
uaddrbest   32        2    0        0     1     0     1     1     0     8    0
uaddr       24     8235    0     8199     1     0     1     1     0     8    0
vmmpekpl   168    45270    0    45226     3     0     3     3     0     8    0
vmmpepl    168   710884    0   708820   179    74   105   113     0   357    6
vmsppl     272     8234    0     8198     4     1     3     3     0     8    0
rwobjpl     24   163275    0   156106    47     2    45    46     0     8    0
pdppl      4096   16476    0    16407   346   271    75    79     0     8    6
pvpl        32  3726825    0  3713253   405   278   127   257     0   265    0
pmappl     216     8234    0     8198     3     0     3     3     0     8    0
extentpl    40       58    0       38     1     0     1     1     0     8    0
phpool     112     1289    0      473    25     0    25    25     0     8    0
ddb> machine ddbcpu 0
No such command
ddb> trace
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d _atomic_swap_64 machine/atomic.h:117 [inline]
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d sys/arch/amd64/amd64/pmap.c:1959
uvm_anfree_list(fffffd806bfee840,ffff8000215be9a8) at uvm_anfree_list+0x98
amap_wipeout(fffffd807af82210) at amap_wipeout+0x1b1 sys/uvm/uvm_amap.c:504
uvm_unmap_detach(ffff8000215bea70,1) at uvm_unmap_detach+0x7d sys/uvm/uvm_map.c:1607
uvm_map_teardown(fffffd8066ebf440) at uvm_map_teardown+0x232 sys/uvm/uvm_map.c:2808
uvmspace_free(fffffd8066ebf440) at uvmspace_free+0x86 sys/uvm/uvm_map.c:3707
reaper(ffff8000fffff500) at reaper+0x15e sys/kern/kern_exit.c:462
end trace frame: 0x0, count: -7
ddb> machine ddbcpu 1
No such command
ddb> trace
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d _atomic_swap_64 machine/atomic.h:117 [inline]
pmap_page_remove(fffffd8005d52f00) at pmap_page_remove+0x30d sys/arch/amd64/amd64/pmap.c:1959
uvm_anfree_list(fffffd806bfee840,ffff8000215be9a8) at uvm_anfree_list+0x98
amap_wipeout(fffffd807af82210) at amap_wipeout+0x1b1 sys/uvm/uvm_amap.c:504
uvm_unmap_detach(ffff8000215bea70,1) at uvm_unmap_detach+0x7d sys/uvm/uvm_map.c:1607
uvm_map_teardown(fffffd8066ebf440) at uvm_map_teardown+0x232 sys/uvm/uvm_map.c:2808
uvmspace_free(fffffd8066ebf440) at uvmspace_free+0x86 sys/uvm/uvm_map.c:3707
reaper(ffff8000fffff500) at reaper+0x15e sys/kern/kern_exit.c:462
end trace frame: 0x0, count: -7

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2022/02/11 08:13 openbsd 53baf8a7cf63 0b33604d .config console log report ci-openbsd-main uvm_fault: pmap_page_remove
* Struck through repros no longer work on HEAD.