staging: vc04_services: Do not log error on kzalloc()
authorUmang Jain <umang.jain@ideasonboard.com>
Thu, 21 Mar 2024 13:07:35 +0000 (18:37 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 25 Mar 2024 18:09:19 +0000 (19:09 +0100)
Do not log any error for kzalloc() error path. kzalloc() already reports
such errors.

Signed-off-by: Umang Jain <umang.jain@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
Link: https://lore.kernel.org/r/20240321130737.898154-4-umang.jain@ideasonboard.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c

index b3021739b170d1fb15a25acd63afef684a0696fc..ad506016fc93ed047c722d40cd41dfd56d28681d 100644 (file)
@@ -690,7 +690,6 @@ int vchiq_initialise(struct vchiq_instance **instance_out)
 
        instance = kzalloc(sizeof(*instance), GFP_KERNEL);
        if (!instance) {
-               dev_err(state->dev, "core: %s: Cannot allocate vchiq instance\n", __func__);
                ret = -ENOMEM;
                goto failed;
        }
@@ -956,10 +955,8 @@ vchiq_blocking_bulk_transfer(struct vchiq_instance *instance, unsigned int handl
                }
        } else {
                waiter = kzalloc(sizeof(*waiter), GFP_KERNEL);
-               if (!waiter) {
-                       dev_err(service->state->dev, "core: %s: - Out of memory\n", __func__);
+               if (!waiter)
                        return -ENOMEM;
-               }
        }
 
        status = vchiq_bulk_transfer(instance, handle, data, NULL, size,