diff options
Diffstat (limited to 'sys/dev/xen/blkback/blkback.c')
-rw-r--r-- | sys/dev/xen/blkback/blkback.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/xen/blkback/blkback.c b/sys/dev/xen/blkback/blkback.c index 88017093c592..bd7a013f8039 100644 --- a/sys/dev/xen/blkback/blkback.c +++ b/sys/dev/xen/blkback/blkback.c @@ -3166,7 +3166,7 @@ xbb_alloc_requests(struct xbb_softc *xbb) /* * Allocate request book keeping datastructures. */ - xbb->requests = mallocarray(xbb->max_requests, sizeof(*xbb->requests), + xbb->requests = malloc(xbb->max_requests * sizeof(*xbb->requests), M_XENBLOCKBACK, M_NOWAIT|M_ZERO); if (xbb->requests == NULL) { xenbus_dev_fatal(xbb->dev, ENOMEM, @@ -3194,7 +3194,7 @@ xbb_alloc_request_lists(struct xbb_softc *xbb) * If no requests can be merged, we need 1 request list per * in flight request. */ - xbb->request_lists = mallocarray(xbb->max_requests, + xbb->request_lists = malloc(xbb->max_requests * sizeof(*xbb->request_lists), M_XENBLOCKBACK, M_NOWAIT|M_ZERO); if (xbb->request_lists == NULL) { xenbus_dev_fatal(xbb->dev, ENOMEM, @@ -3222,7 +3222,7 @@ xbb_alloc_request_lists(struct xbb_softc *xbb) } #endif /* XBB_USE_BOUNCE_BUFFERS */ - reqlist->gnt_handles = mallocarray(xbb->max_reqlist_segments, + reqlist->gnt_handles = malloc(xbb->max_reqlist_segments * sizeof(*reqlist->gnt_handles), M_XENBLOCKBACK, M_NOWAIT|M_ZERO); if (reqlist->gnt_handles == NULL) { |