mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
Convert 'alloc_obj' family to use the new default GFP_KERNEL argument
This was done entirely with mindless brute force, using
git grep -l '\<k[vmz]*alloc_objs*(.*, GFP_KERNEL)' |
xargs sed -i 's/\(alloc_objs*(.*\), GFP_KERNEL)/\1)/'
to convert the new alloc_obj() users that had a simple GFP_KERNEL
argument to just drop that argument.
Note that due to the extreme simplicity of the scripting, any slightly
more complex cases spread over multiple lines would not be triggered:
they definitely exist, but this covers the vast bulk of the cases, and
the resulting diff is also then easier to check automatically.
For the same reason the 'flex' versions will be done as a separate
conversion.
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
@@ -1048,7 +1048,7 @@ static int dlm_send_regions(struct dlm_ctxt *dlm, unsigned long *node_map)
|
||||
if (find_first_bit(node_map, O2NM_MAX_NODES) >= O2NM_MAX_NODES)
|
||||
goto bail;
|
||||
|
||||
qr = kzalloc_obj(struct dlm_query_region, GFP_KERNEL);
|
||||
qr = kzalloc_obj(struct dlm_query_region);
|
||||
if (!qr) {
|
||||
ret = -ENOMEM;
|
||||
mlog_errno(ret);
|
||||
@@ -1220,7 +1220,7 @@ static int dlm_send_nodeinfo(struct dlm_ctxt *dlm, unsigned long *node_map)
|
||||
if (find_first_bit(node_map, O2NM_MAX_NODES) >= O2NM_MAX_NODES)
|
||||
goto bail;
|
||||
|
||||
qn = kzalloc_obj(struct dlm_query_nodeinfo, GFP_KERNEL);
|
||||
qn = kzalloc_obj(struct dlm_query_nodeinfo);
|
||||
if (!qn) {
|
||||
ret = -ENOMEM;
|
||||
mlog_errno(ret);
|
||||
@@ -1592,7 +1592,7 @@ static int dlm_try_to_join_domain(struct dlm_ctxt *dlm)
|
||||
|
||||
mlog(0, "%p", dlm);
|
||||
|
||||
ctxt = kzalloc_obj(*ctxt, GFP_KERNEL);
|
||||
ctxt = kzalloc_obj(*ctxt);
|
||||
if (!ctxt) {
|
||||
status = -ENOMEM;
|
||||
mlog_errno(status);
|
||||
@@ -1946,7 +1946,7 @@ static struct dlm_ctxt *dlm_alloc_ctxt(const char *domain,
|
||||
int ret;
|
||||
struct dlm_ctxt *dlm = NULL;
|
||||
|
||||
dlm = kzalloc_obj(*dlm, GFP_KERNEL);
|
||||
dlm = kzalloc_obj(*dlm);
|
||||
if (!dlm) {
|
||||
ret = -ENOMEM;
|
||||
mlog_errno(ret);
|
||||
|
||||
Reference in New Issue
Block a user