
pmap_enter() cannot allocate the segmap return failure if PMAP_CANFAIL instead of sleeping. Otherwise panic. Both alpha and i386 do this. Do not pmap_enter_pv() until after this is done so the data structures are not partially allocated. This should prevent pmap_page_protect() from getting stuck when called from pagedaemon.