lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAJKOXPc7HA58+zxny3fWJr7mVMqOx9xsKck+-7EHLsfymhfjcQ@mail.gmail.com>
Date:   Tue, 20 Nov 2018 13:51:59 +0100
From:   Krzysztof Kozlowski <krzk@...nel.org>
To:     Marek Szyprowski <m.szyprowski@...sung.com>
Cc:     linux-kernel@...r.kernel.org, broonie@...nel.org,
        lgirdwood@...il.com, sbkim73@...sung.com,
        Bartłomiej Żołnierkiewicz 
        <b.zolnierkie@...sung.com>,
        "linux-samsung-soc@...r.kernel.org" 
        <linux-samsung-soc@...r.kernel.org>
Subject: Re: [PATCH] regulator: s2mps11: Fix GPIO descriptor initialization

On Tue, 20 Nov 2018 at 13:39, Marek Szyprowski <m.szyprowski@...sung.com> wrote:
>
> GPIO descriptor array must be zero initialized to ensure that core will
> properly handle also the case when no external GPIO pin is defined.
>
> Fixes: 1c984942f0a4 ("regulator: s2mps11: Pass descriptor instead of GPIO number")
> Signed-off-by: Marek Szyprowski <m.szyprowski@...sung.com>
> ---
> This fixes broken eMMC boot on Artik, Rinato and Odroid XU3/XU4/HC1
> boards.

I missed that on my review. Now it looks fine, thanks for fixing it!
Reviewed-by: Krzysztof Kozlowski <krzk@...nel.org>

Best regards,
Krzysztof


> ---
>  drivers/regulator/s2mps11.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/regulator/s2mps11.c b/drivers/regulator/s2mps11.c
> index 6fec45897194..63e66f485cc0 100644
> --- a/drivers/regulator/s2mps11.c
> +++ b/drivers/regulator/s2mps11.c
> @@ -1134,9 +1134,8 @@ static int s2mps11_pmic_probe(struct platform_device *pdev)
>                 return -EINVAL;
>         }
>
> -       s2mps11->ext_control_gpiod = devm_kmalloc_array(&pdev->dev,
> -                       rdev_num, sizeof(*s2mps11->ext_control_gpiod),
> -                       GFP_KERNEL);
> +       s2mps11->ext_control_gpiod = devm_kcalloc(&pdev->dev, rdev_num,
> +                              sizeof(*s2mps11->ext_control_gpiod), GFP_KERNEL);
>         if (!s2mps11->ext_control_gpiod)
>                 return -ENOMEM;
>
> --
> 2.17.1
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ