Whamcloud - gitweb
git://git.whamcloud.com
/
fs
/
lustre-release.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
b=22980 improve obdfilter-survey performance on multi-core system
[fs/lustre-release.git]
/
lustre
/
obdclass
/
darwin
/
darwin-module.c
diff --git
a/lustre/obdclass/darwin/darwin-module.c
b/lustre/obdclass/darwin/darwin-module.c
index
9269abe
..
3a6cf5d
100644
(file)
--- a/
lustre/obdclass/darwin/darwin-module.c
+++ b/
lustre/obdclass/darwin/darwin-module.c
@@
-80,9
+80,7
@@
int obd_ioctl_getdata(char **buf, int *len, void *arg)
RETURN(-EINVAL);
}
RETURN(-EINVAL);
}
- /* XXX allocate this more intelligently, using kmalloc when
- * appropriate */
- OBD_VMALLOC(*buf, hdr->ioc_len);
+ OBD_ALLOC_LARGE(*buf, hdr->ioc_len);
if (*buf == NULL) {
CERROR("Cannot allocate control buffer of len %d\n",
hdr->ioc_len);
if (*buf == NULL) {
CERROR("Cannot allocate control buffer of len %d\n",
hdr->ioc_len);
@@
-99,6
+97,7
@@
int obd_ioctl_getdata(char **buf, int *len, void *arg)
if (obd_ioctl_is_invalid(data)) {
CERROR("ioctl not correctly formatted\n");
if (obd_ioctl_is_invalid(data)) {
CERROR("ioctl not correctly formatted\n");
+ OBD_FREE_LARGE(*buf, hdr->ioc_len);
return -EINVAL;
}
return -EINVAL;
}