-/* $OpenBSD: bus_dma.c,v 1.9 2014/11/16 12:30:56 deraadt Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.10 2014/12/24 22:48:27 miod Exp $ */
/* $NetBSD: bus_dma.c,v 1.2 2001/06/10 02:31:25 briggs Exp $ */
/*-
bus_dma_tag_t t;
bus_dmamap_t map;
{
+ size_t mapsize;
- free(map, M_DEVBUF, 0);
+ mapsize = sizeof(struct m88k_bus_dmamap) +
+ (sizeof(bus_dma_segment_t) * (map->_dm_segcnt - 1));
+ free(map, M_DEVBUF, mapsize);
}
/*
-/* $OpenBSD: disksubr.c,v 1.59 2014/07/12 18:44:41 tedu Exp $ */
+/* $OpenBSD: disksubr.c,v 1.60 2014/12/24 22:48:27 miod Exp $ */
/*
* Copyright (c) 2013 Miodrag Vallat.
}
done:
- free(vdit_storage, M_DEVBUF, 0);
+ free(vdit_storage, M_DEVBUF, vdit_size);
if (sbp != NULL) {
sbp->b_flags |= B_INVAL;
brelse(sbp);
-/* $OpenBSD: dma.c,v 1.2 2014/07/12 18:44:41 tedu Exp $ */
+/* $OpenBSD: dma.c,v 1.3 2014/12/24 22:48:27 miod Exp $ */
/*
* Copyright (c) 2013 Miodrag Vallat.
if (req->cbdone != NULL)
(*req->cbdone)(req->cbarg);
- free(req, M_DEVBUF, 0);
+ free(req, M_DEVBUF, sizeof *req);
} else {
req->mem += req->lastcnt;
}
-/* $OpenBSD: vme.c,v 1.15 2014/11/16 12:30:56 deraadt Exp $ */
+/* $OpenBSD: vme.c,v 1.16 2014/12/24 22:48:27 miod Exp $ */
/*
* Copyright (c) 2006, 2007, 2010 Miodrag Vallat.
*
void
vmebus_release_bst(struct device *vsc, bus_space_tag_t b)
{
- free((void *)b, M_DEVBUF, 0);
+ free((void *)b, M_DEVBUF, sizeof(struct aviion_bus_space_tag));
}
/*
-/* $OpenBSD: softintr.c,v 1.4 2014/07/12 18:44:42 tedu Exp $ */
+/* $OpenBSD: softintr.c,v 1.5 2014/12/24 22:48:27 miod Exp $ */
/* $NetBSD: softintr.c,v 1.2 2003/07/15 00:24:39 lukem Exp $ */
/*
}
mtx_leave(&siq->siq_mtx);
- free(sih, M_DEVBUF, 0);
+ free(sih, M_DEVBUF, sizeof(*sih));
}
/*