]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
board: gateworks: venice: add GW7903 PMIC
authorTim Harvey <tharvey@gateworks.com>
Thu, 11 Aug 2022 18:57:04 +0000 (11:57 -0700)
committerStefano Babic <sbabic@denx.de>
Mon, 24 Oct 2022 09:34:33 +0000 (11:34 +0200)
The GW7903 has a BD71847 PMIC on I2C1. Adjust the model compare strings
to add it.

Signed-off-by: Tim Harvey <tharvey@gateworks.com>
Reviewed-by: Fabio Estevam <festevam@denx.de>
Reviewed-by: Jaehoon Chung <jh80.chung@samsung.com>
board/gateworks/venice/spl.c

index da36f227bcc66c1ae94672b2e1de7c9b5a1bd31f..98931c04754e1efd673449062ee6472a3c7eba9f 100644 (file)
@@ -171,11 +171,12 @@ static int power_init_board(void)
        }
 
        else if ((!strncmp(model, "GW7901", 6)) ||
-                (!strncmp(model, "GW7902", 6))) {
-               if (!strncmp(model, "GW7901", 6))
-                       ret = uclass_get_device_by_seq(UCLASS_I2C, 1, &bus);
-               else
+                (!strncmp(model, "GW7902", 6)) ||
+                (!strncmp(model, "GW7903", 6))) {
+               if (!strncmp(model, "GW7902", 6))
                        ret = uclass_get_device_by_seq(UCLASS_I2C, 0, &bus);
+               else
+                       ret = uclass_get_device_by_seq(UCLASS_I2C, 1, &bus);
                if (ret) {
                        printf("PMIC    : failed I2C2 probe: %d\n", ret);
                        return ret;