diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 16:37:42 -0800 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2026-02-21 17:09:51 -0800 |
| commit | bf4afc53b77aeaa48b5409da5c8da6bb4eff7f43 (patch) | |
| tree | 01fdd9d27f1b272bef0127966e08eac44d134d0a /drivers/platform/raspberrypi/vchiq-interface | |
| parent | e19e1b480ac73c3e62ffebbca1174f0f511f43e7 (diff) | |
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>
Diffstat (limited to 'drivers/platform/raspberrypi/vchiq-interface')
4 files changed, 8 insertions, 8 deletions
diff --git a/drivers/platform/raspberrypi/vchiq-interface/vchiq_arm.c b/drivers/platform/raspberrypi/vchiq-interface/vchiq_arm.c index 1e72dc819e2a..e78641703252 100644 --- a/drivers/platform/raspberrypi/vchiq-interface/vchiq_arm.c +++ b/drivers/platform/raspberrypi/vchiq-interface/vchiq_arm.c @@ -358,7 +358,7 @@ int vchiq_initialise(struct vchiq_state *state, struct vchiq_instance **instance __func__, i); } - instance = kzalloc_obj(*instance, GFP_KERNEL); + instance = kzalloc_obj(*instance); if (!instance) { ret = -ENOMEM; goto failed; @@ -618,7 +618,7 @@ vchiq_blocking_bulk_transfer(struct vchiq_instance *instance, unsigned int handl } } } else { - waiter = kzalloc_obj(*waiter, GFP_KERNEL); + waiter = kzalloc_obj(*waiter); if (!waiter) return -ENOMEM; } @@ -1249,7 +1249,7 @@ vchiq_dump_service_use_state(struct vchiq_state *state) if (!arm_state) return; - service_data = kmalloc_objs(*service_data, MAX_SERVICES, GFP_KERNEL); + service_data = kmalloc_objs(*service_data, MAX_SERVICES); if (!service_data) return; diff --git a/drivers/platform/raspberrypi/vchiq-interface/vchiq_bus.c b/drivers/platform/raspberrypi/vchiq-interface/vchiq_bus.c index 616e05a36918..011105f1318d 100644 --- a/drivers/platform/raspberrypi/vchiq-interface/vchiq_bus.c +++ b/drivers/platform/raspberrypi/vchiq-interface/vchiq_bus.c @@ -68,7 +68,7 @@ vchiq_device_register(struct device *parent, const char *name) struct vchiq_device *device; int ret; - device = kzalloc_obj(*device, GFP_KERNEL); + device = kzalloc_obj(*device); if (!device) return NULL; diff --git a/drivers/platform/raspberrypi/vchiq-interface/vchiq_core.c b/drivers/platform/raspberrypi/vchiq-interface/vchiq_core.c index 1dac7d1ffaa2..48d6b1d74329 100644 --- a/drivers/platform/raspberrypi/vchiq-interface/vchiq_core.c +++ b/drivers/platform/raspberrypi/vchiq-interface/vchiq_core.c @@ -2723,7 +2723,7 @@ vchiq_add_service_internal(struct vchiq_state *state, if (ret) return NULL; - service = kzalloc_obj(*service, GFP_KERNEL); + service = kzalloc_obj(*service); if (!service) return service; diff --git a/drivers/platform/raspberrypi/vchiq-interface/vchiq_dev.c b/drivers/platform/raspberrypi/vchiq-interface/vchiq_dev.c index 18bcb8c133d1..f1c9c0d4b96a 100644 --- a/drivers/platform/raspberrypi/vchiq-interface/vchiq_dev.c +++ b/drivers/platform/raspberrypi/vchiq-interface/vchiq_dev.c @@ -149,7 +149,7 @@ static int vchiq_ioc_create_service(struct vchiq_instance *instance, if (args->is_open && !instance->connected) return -ENOTCONN; - user_service = kmalloc_obj(*user_service, GFP_KERNEL); + user_service = kmalloc_obj(*user_service); if (!user_service) return -ENOMEM; @@ -298,7 +298,7 @@ static int vchiq_irq_queue_bulk_tx_rx(struct vchiq_instance *instance, return -EINVAL; if (args->mode == VCHIQ_BULK_MODE_BLOCKING) { - waiter = kzalloc_obj(*waiter, GFP_KERNEL); + waiter = kzalloc_obj(*waiter); if (!waiter) { ret = -ENOMEM; goto out; @@ -1185,7 +1185,7 @@ static int vchiq_open(struct inode *inode, struct file *file) return -ENOTCONN; } - instance = kzalloc_obj(*instance, GFP_KERNEL); + instance = kzalloc_obj(*instance); if (!instance) return -ENOMEM; |
