[U-Boot] [PATCH 26/55] dm: pmic: Correct the pmic_reg_write() implementation
Przemyslaw Marczak
p.marczak at samsung.com
Fri Jul 10 13:53:12 CEST 2015
Hello Simon,
On 07/03/2015 02:16 AM, Simon Glass wrote:
> This should write the register, not read it. Fix this bug.
>
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
>
> drivers/power/pmic/pmic-uclass.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/power/pmic/pmic-uclass.c b/drivers/power/pmic/pmic-uclass.c
> index d99cb9a..49709f3 100644
> --- a/drivers/power/pmic/pmic-uclass.c
> +++ b/drivers/power/pmic/pmic-uclass.c
> @@ -142,7 +142,7 @@ int pmic_reg_write(struct udevice *dev, uint reg, uint value)
> u8 byte = value;
>
> debug("%s: reg=%x, value=%x\n", __func__, reg, value);
> - return pmic_read(dev, reg, &byte, 1);
> + return pmic_write(dev, reg, &byte, 1);
> }
>
> int pmic_clrsetbits(struct udevice *dev, uint reg, uint clr, uint set)
>
Acked-by: Przemyslaw Marczak <p.marczak at samsung.com>
Regards
--
Przemyslaw Marczak
Samsung R&D Institute Poland
Samsung Electronics
p.marczak at samsung.com
More information about the U-Boot
mailing list