summaryrefslogtreecommitdiff
path: root/sys/dev/ic/nvme.c
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2014-07-12 18:48:54 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2014-07-12 18:48:54 +0000
commit9355adab6702f4798111e38a2e7e7be541270937 (patch)
tree1fda49353b276c780d60c7609e331839f2c13505 /sys/dev/ic/nvme.c
parent48b6cac396e42c57b5037f5a67d6cd7afb1733d6 (diff)
add a size argument to free. will be used soon, but for now default to 0.
after discussions with beck deraadt kettenis.
Diffstat (limited to 'sys/dev/ic/nvme.c')
-rw-r--r--sys/dev/ic/nvme.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/dev/ic/nvme.c b/sys/dev/ic/nvme.c
index 59f7fb9f881..8e2ae166171 100644
--- a/sys/dev/ic/nvme.c
+++ b/sys/dev/ic/nvme.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nvme.c,v 1.4 2014/04/16 01:28:02 dlg Exp $ */
+/* $OpenBSD: nvme.c,v 1.5 2014/07/12 18:48:17 tedu Exp $ */
/*
* Copyright (c) 2014 David Gwynne <dlg@openbsd.org>
@@ -571,7 +571,7 @@ nvme_ccbs_free(struct nvme_softc *sc)
bus_dmamap_destroy(sc->sc_dmat, ccb->ccb_dmamap);
}
- free(sc->sc_ccbs, M_DEVBUF);
+ free(sc->sc_ccbs, M_DEVBUF, 0);
}
struct nvme_queue *
@@ -615,7 +615,7 @@ nvme_q_alloc(struct nvme_softc *sc, u_int idx, u_int entries, u_int dstrd)
free_sq:
nvme_dmamem_free(sc, q->q_sq_dmamem);
free:
- free(q, M_DEVBUF);
+ free(q, M_DEVBUF, 0);
return (NULL);
}
@@ -629,7 +629,7 @@ nvme_q_free(struct nvme_softc *sc, struct nvme_queue *q)
0, NVME_DMA_LEN(q->q_sq_dmamem), BUS_DMASYNC_POSTWRITE);
nvme_dmamem_free(sc, q->q_cq_dmamem);
nvme_dmamem_free(sc, q->q_sq_dmamem);
- free(q, M_DEVBUF);
+ free(q, M_DEVBUF, 0);
}
int
@@ -677,7 +677,7 @@ free:
destroy:
bus_dmamap_destroy(sc->sc_dmat, ndm->ndm_map);
ndmfree:
- free(ndm, M_DEVBUF);
+ free(ndm, M_DEVBUF, 0);
return (NULL);
}
@@ -689,6 +689,6 @@ nvme_dmamem_free(struct nvme_softc *sc, struct nvme_dmamem *ndm)
bus_dmamem_unmap(sc->sc_dmat, ndm->ndm_kva, ndm->ndm_size);
bus_dmamem_free(sc->sc_dmat, &ndm->ndm_seg, 1);
bus_dmamap_destroy(sc->sc_dmat, ndm->ndm_map);
- free(ndm, M_DEVBUF);
+ free(ndm, M_DEVBUF, 0);
}