diff options
| author | christos <christos@NetBSD.org> | 2019-02-10 17:13:33 +0000 |
|---|---|---|
| committer | christos <christos@NetBSD.org> | 2019-02-10 17:13:33 +0000 |
| commit | c9026edaa7b785b67f4c37a4b7114a37a904ebde (patch) | |
| tree | 2e45294b757f2107dbaa20cbb2b2b5af30a17aa3 /sys/dev/raidframe/rf_diskqueue.c | |
| parent | e995f016c5cff6a75387243c9f1d1314aff94c1e (diff) | |
Introduce PR_ZERO to avoid open-coding memset()s everywhere. OK riastradh@.
Diffstat (limited to 'sys/dev/raidframe/rf_diskqueue.c')
| -rw-r--r-- | sys/dev/raidframe/rf_diskqueue.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/raidframe/rf_diskqueue.c b/sys/dev/raidframe/rf_diskqueue.c index f4e39cb8054..14e5f2b4297 100644 --- a/sys/dev/raidframe/rf_diskqueue.c +++ b/sys/dev/raidframe/rf_diskqueue.c @@ -1,4 +1,4 @@ -/* $NetBSD: rf_diskqueue.c,v 1.54 2019/02/09 03:34:00 christos Exp $ */ +/* $NetBSD: rf_diskqueue.c,v 1.55 2019/02/10 17:13:33 christos Exp $ */ /* * Copyright (c) 1995 Carnegie-Mellon University. * All rights reserved. @@ -66,7 +66,7 @@ ****************************************************************************/ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.54 2019/02/09 03:34:00 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.55 2019/02/10 17:13:33 christos Exp $"); #include <dev/raidframe/raidframevar.h> @@ -367,11 +367,10 @@ rf_CreateDiskQueueData(RF_IoType_t typ, RF_SectorNum_t ssect, { RF_DiskQueueData_t *p; - p = pool_get(&rf_pools.dqd, waitflag); + p = pool_get(&rf_pools.dqd, waitflag | PR_ZERO); if (p == NULL) return (NULL); - memset(p, 0, sizeof(*p)); if (waitflag == PR_WAITOK) { p->bp = getiobuf(NULL, true); } else { |
