summaryrefslogtreecommitdiffstats
path: root/sys/dev/ofw
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2003-02-19 05:47:46 +0000
committerimp <imp@FreeBSD.org>2003-02-19 05:47:46 +0000
commitcf874b345d0f766fb64cf4737e1c85ccc78d2bee (patch)
tree9e20e320fe15ae4bf68f8335fcf9d3e71d3b3614 /sys/dev/ofw
parentb72619cecb8265d3efb3781b0acff1380762c173 (diff)
downloadFreeBSD-src-cf874b345d0f766fb64cf4737e1c85ccc78d2bee.zip
FreeBSD-src-cf874b345d0f766fb64cf4737e1c85ccc78d2bee.tar.gz
Back out M_* changes, per decision of the TRB.
Approved by: trb
Diffstat (limited to 'sys/dev/ofw')
-rw-r--r--sys/dev/ofw/openfirm.c4
-rw-r--r--sys/dev/ofw/openfirmio.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/sys/dev/ofw/openfirm.c b/sys/dev/ofw/openfirm.c
index 9ea97d3..7704109 100644
--- a/sys/dev/ofw/openfirm.c
+++ b/sys/dev/ofw/openfirm.c
@@ -292,7 +292,7 @@ OF_getprop(phandle_t package, char *propname, void *buf, int buflen)
/*
* Store the value of a property of a package into newly allocated memory (using
- * the M_OFWPROP malloc pool and 0). elsz is the size of a single element,
+ * the M_OFWPROP malloc pool and M_WAITOK). elsz is the size of a single element,
* the number of elements is return in number.
*/
int
@@ -305,7 +305,7 @@ OF_getprop_alloc(phandle_t package, char *propname, int elsz, void **buf)
len % elsz != 0)
return (-1);
- *buf = malloc(len, M_OFWPROP, 0);
+ *buf = malloc(len, M_OFWPROP, M_WAITOK);
if (OF_getprop(package, propname, *buf, len) == -1) {
free(*buf, M_OFWPROP);
*buf = NULL;
diff --git a/sys/dev/ofw/openfirmio.c b/sys/dev/ofw/openfirmio.c
index 8bd5c04..6f40619 100644
--- a/sys/dev/ofw/openfirmio.c
+++ b/sys/dev/ofw/openfirmio.c
@@ -115,7 +115,7 @@ openfirm_getstr(int len, const char *user, char **cpp)
if ((u_int)len > OFW_NAME_MAX)
return (ENAMETOOLONG);
- *cpp = cp = malloc(len + 1, M_TEMP, 0);
+ *cpp = cp = malloc(len + 1, M_TEMP, M_WAITOK);
if (cp == NULL)
return (ENOMEM);
error = copyin(user, cp, len);
@@ -183,7 +183,7 @@ openfirm_ioctl(dev_t dev, u_long cmd, caddr_t data, int flags,
/* -1 means no entry; 0 means no value */
if (len <= 0)
break;
- value = malloc(len, M_TEMP, 0);
+ value = malloc(len, M_TEMP, M_WAITOK);
if (value == NULL) {
error = ENOMEM;
break;
OpenPOWER on IntegriCloud