]> Git Repo - J-u-boot.git/commit
pinctrl: bcm283x: Store the return value of dev_read_u32_default to int
authorOvidiu Panait <[email protected]>
Tue, 29 Sep 2020 17:27:13 +0000 (20:27 +0300)
committerMatthias Brugger <[email protected]>
Fri, 2 Oct 2020 15:32:28 +0000 (17:32 +0200)
commit0db912de153743e2ec97bd022640c5722eb07737
treef1f38e647653c7de53d0d2b6080fe9427f14ead2
parente020c07a020000d9b9cbba8ea56109b37c3926c6
pinctrl: bcm283x: Store the return value of dev_read_u32_default to int

Currently, the return value of dev_read_u32_default is stored in an u32,
causing the subsequent "if (function < 0)" to always be false:

u32 function;
...
function = dev_read_u32_default(config, "brcm,function", -1);
if (function < 0) {
        debug("Failed reading function for pinconfig %s (%d)\n",
                      config->name, function);
        return -EINVAL;
}

Make "function" variable an int to fix this.

Cc: Matthias Brugger <[email protected]>
Signed-off-by: Ovidiu Panait <[email protected]>
Signed-off-by: Matthias Brugger <[email protected]>
drivers/pinctrl/broadcom/pinctrl-bcm283x.c
This page took 0.035418 seconds and 4 git commands to generate.