The variable node is assigned to the return value of a function that
returns an int. It is tested for being negative and then passed as an
argument to a function that takes an int. So 'node' should not be
declared as unsigned. Correct it.

This issue was found by Smatch.

Signed-off-by: Andrew Goodbody <[email protected]>
---
 drivers/usb/host/xhci-exynos5.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/usb/host/xhci-exynos5.c b/drivers/usb/host/xhci-exynos5.c
index 
6a2d422c4b8e510bf485c3069287000f8cf77aef..c509ce1620a079d684146d6f3470a1d10663e3c5
 100644
--- a/drivers/usb/host/xhci-exynos5.c
+++ b/drivers/usb/host/xhci-exynos5.c
@@ -56,8 +56,7 @@ static int xhci_usb_of_to_plat(struct udevice *dev)
 {
        struct exynos_xhci_plat *plat = dev_get_plat(dev);
        const void *blob = gd->fdt_blob;
-       unsigned int node;
-       int depth;
+       int node, depth;
 
        /*
         * Get the base address for XHCI controller from the device node

---
base-commit: 9710d98e8942151fc0c62d54100d9d27e8263d04
change-id: 20250930-xhci_exynos5-f53b987584c3

Best regards,
-- 
Andrew Goodbody <[email protected]>

Reply via email to