lkml.org 
[lkml]   [2021]   [Oct]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v1 1/1] gpio: mlxbf2.c: Add check for bgpio_init failure
On Fri, Oct 22, 2021 at 3:44 PM Asmaa Mnebhi <asmaa@nvidia.com> wrote:
>
> Add a check if bgpio_init fails.
>
> Signed-off-by: Asmaa Mnebhi <asmaa@nvidia.com>
> ---
> drivers/gpio/gpio-mlxbf2.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/gpio/gpio-mlxbf2.c b/drivers/gpio/gpio-mlxbf2.c
> index 177d03ef4529..40a052bc6784 100644
> --- a/drivers/gpio/gpio-mlxbf2.c
> +++ b/drivers/gpio/gpio-mlxbf2.c
> @@ -256,6 +256,11 @@ mlxbf2_gpio_probe(struct platform_device *pdev)
> NULL,
> 0);
>
> + if (ret) {
> + dev_err(dev, "bgpio_init failed\n");
> + return ret;
> + }
> +
> gc->direction_input = mlxbf2_gpio_direction_input;
> gc->direction_output = mlxbf2_gpio_direction_output;
> gc->ngpio = npins;
> --
> 2.30.1
>

Queued for fixes, thanks!

Bart

\
 
 \ /
  Last update: 2021-10-25 10:16    [W:0.059 / U:0.188 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site