M_NOWAIT can only be used in a driver where a failed memory allocation is
authorMatthew Dillon <dillon@dragonflybsd.org>
Sun, 3 Jun 2007 04:48:29 +0000 (04:48 +0000)
committerMatthew Dillon <dillon@dragonflybsd.org>
Sun, 3 Jun 2007 04:48:29 +0000 (04:48 +0000)
commita01741bbbdb5b181e319e741937c4f791ccd58e2
tree50d12b834d4db410023fc64b127c067d6d4930d7
parentf0c34d2363c95704050a5926f55dd2712385fb69
M_NOWAIT can only be used in a driver where a failed memory allocation is
recoverable, such as in a network driver.  FreeBSD seems to have a looser
definition but in DragonFly M_NOWAIT really means M_NOWAIT ... any blocking
at all, including waiting on the BGL or getting the kernel_map lock,
will result in a failure NULL.

Change all M_NOWAIT's to either M_WAITOK or M_INTWAIT.
sys/dev/disk/nata/ata-chipset.c
sys/dev/disk/nata/ata-disk.c
sys/dev/disk/nata/ata-dma.c
sys/dev/disk/nata/atapi-cam.c
sys/dev/disk/nata/atapi-cd.c
sys/dev/disk/nata/atapi-fd.c
sys/dev/disk/nata/atapi-tape.c