diff options
author | Arvind Yadav <arvind.yadav.cs@gmail.com> | 2017-09-23 13:39:15 +0530 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-09-29 15:39:22 +0200 |
commit | 1cd5929ab675b285e2179ec33cb0fef185aaabd1 (patch) | |
tree | 8893aacc8ddec459fac536d6678e618e80aebaba /drivers/staging/greybus/light.c | |
parent | 04820da21050b35eed68aa046115d810163ead0c (diff) |
staging: greybus: light: remove unnecessary error check
It is not necessary to check return value of gb_lights_channel_flash_config.
gb_lights_channel_config returns both successful and error value.
Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Reviewed-by: Rui Miguel Silva <rmfrfs@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/greybus/light.c')
-rw-r--r-- | drivers/staging/greybus/light.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/staging/greybus/light.c b/drivers/staging/greybus/light.c index 0f538b8c3a07..d7da475f9d33 100644 --- a/drivers/staging/greybus/light.c +++ b/drivers/staging/greybus/light.c @@ -1000,11 +1000,7 @@ static int gb_lights_channel_config(struct gb_light *light, light->has_flash = true; - ret = gb_lights_channel_flash_config(channel); - if (ret < 0) - return ret; - - return ret; + return gb_lights_channel_flash_config(channel); } static int gb_lights_light_config(struct gb_lights *glights, u8 id) |