summaryrefslogtreecommitdiffstats
path: root/sys/contrib/altq/altq/altq_rio.c
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2012-09-22 12:49:36 +0000
committerglebius <glebius@FreeBSD.org>2012-09-22 12:49:36 +0000
commitd91f23ae3d2beb18cedf81e4ec13451d7db9c172 (patch)
tree197d64d42f3fccc7f64d63a5c2f9f5072f465828 /sys/contrib/altq/altq/altq_rio.c
parent66da4b41b33657686a22e405117852035b6cc042 (diff)
downloadFreeBSD-src-d91f23ae3d2beb18cedf81e4ec13451d7db9c172.zip
FreeBSD-src-d91f23ae3d2beb18cedf81e4ec13451d7db9c172.tar.gz
Convert more M_WAITOK malloc() to M_NOWAIT.
Reported by: Kim Culhan <w8hdkim gmail.com>
Diffstat (limited to 'sys/contrib/altq/altq/altq_rio.c')
-rw-r--r--sys/contrib/altq/altq/altq_rio.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/contrib/altq/altq/altq_rio.c b/sys/contrib/altq/altq/altq_rio.c
index f80d766..a48cd6d 100644
--- a/sys/contrib/altq/altq/altq_rio.c
+++ b/sys/contrib/altq/altq/altq_rio.c
@@ -204,10 +204,9 @@ rio_alloc(int weight, struct redparams *params, int flags, int pkttime)
int w, i;
int npkts_per_sec;
- rp = malloc(sizeof(rio_t), M_DEVBUF, M_WAITOK);
+ rp = malloc(sizeof(rio_t), M_DEVBUF, M_NOWAIT | M_ZERO);
if (rp == NULL)
return (NULL);
- bzero(rp, sizeof(rio_t));
rp->rio_flags = flags;
if (pkttime == 0)
OpenPOWER on IntegriCloud