Don't try to free() map in bus_dmamap_destroy() when it's

set to &nobounce_dmamap.  A similar bug was fixed by wpaul
in revision 1.19 of sys/alpha/alpha/busdma_machdep.c.
This commit is contained in:
Maxime Henrion 2003-01-18 18:33:56 +00:00
parent 411359429f
commit 1d8dc7e4a3

View File

@ -325,7 +325,7 @@ bus_dmamap_destroy(bus_dma_tag_t dmat, bus_dmamap_t map)
#endif
}
if (map != NULL) {
if (map != NULL && map != &nobounce_dmamap) {
if (STAILQ_FIRST(&map->bpages) != NULL)
return (EBUSY);
free(map, M_DEVBUF);