kernel - Fix bug in pmap_unwire()
commit62443eb51da14fee24c103cbb98d533c93da0b3e
authorMatthew Dillon <dillon@apollo.backplane.com>
Tue, 14 Feb 2017 07:21:09 +0000 (13 23:21 -0800)
committerMatthew Dillon <dillon@apollo.backplane.com>
Tue, 14 Feb 2017 07:21:09 +0000 (13 23:21 -0800)
tree4153587b55af09f4c123c24d6c8b1a64bbf5ee4c
parent54ba75e6bbc563cf3be1a4d7b45dc967995a8857
kernel - Fix bug in pmap_unwire()

* Fix a bug introduced in the recent pmap work.  For kernel pages,
  pmap_unwire() was not testing the V bit and would return a bogus
  vm_page_t for PTE values of 0, instead of returning NULL.

* Triggered by the mpipe code, used primarily by the crypto subsystem.
  Also used for IP fragment reassembly and by tcp_maketemplate().  A
  failed M_NOWAIT slab allocation tries to delete the partially filled
  map_entry_t, encounters 0 PTEs, and gets confused.

Reported-by: Tim Darby, Antonio Huete Jimenez
sys/platform/pc64/x86_64/pmap.c