* [U-Boot] [PATCH 1/1] usb: xhci-exynos5: correct error checking
@ 2018-03-18 12:51 Heinrich Schuchardt
2018-03-19 3:00 ` Bin Meng
0 siblings, 1 reply; 3+ messages in thread
From: Heinrich Schuchardt @ 2018-03-18 12:51 UTC (permalink / raw)
To: u-boot
If fdtdec_next_compatible_subnode() fails it returns a negative value.
The check (node <= 0) cannot identify this if node is unsigned.
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
drivers/usb/host/xhci-exynos5.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/host/xhci-exynos5.c b/drivers/usb/host/xhci-exynos5.c
index 6f08d5d5a2..4cbfbdee3d 100644
--- a/drivers/usb/host/xhci-exynos5.c
+++ b/drivers/usb/host/xhci-exynos5.c
@@ -55,7 +55,7 @@ static int xhci_usb_ofdata_to_platdata(struct udevice *dev)
{
struct exynos_xhci_platdata *plat = dev_get_platdata(dev);
const void *blob = gd->fdt_blob;
- unsigned int node;
+ int node;
int depth;
/*
--
2.16.2
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [U-Boot] [PATCH 1/1] usb: xhci-exynos5: correct error checking
2018-03-18 12:51 [U-Boot] [PATCH 1/1] usb: xhci-exynos5: correct error checking Heinrich Schuchardt
@ 2018-03-19 3:00 ` Bin Meng
2018-03-19 3:11 ` Bin Meng
0 siblings, 1 reply; 3+ messages in thread
From: Bin Meng @ 2018-03-19 3:00 UTC (permalink / raw)
To: u-boot
On Sun, Mar 18, 2018 at 8:51 PM, Heinrich Schuchardt <xypron.glpk@gmx.de> wrote:
> If fdtdec_next_compatible_subnode() fails it returns a negative value.
> The check (node <= 0) cannot identify this if node is unsigned.
>
> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
> ---
> drivers/usb/host/xhci-exynos5.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* [U-Boot] [PATCH 1/1] usb: xhci-exynos5: correct error checking
2018-03-19 3:00 ` Bin Meng
@ 2018-03-19 3:11 ` Bin Meng
0 siblings, 0 replies; 3+ messages in thread
From: Bin Meng @ 2018-03-19 3:11 UTC (permalink / raw)
To: u-boot
On Mon, Mar 19, 2018 at 11:00 AM, Bin Meng <bmeng.cn@gmail.com> wrote:
> On Sun, Mar 18, 2018 at 8:51 PM, Heinrich Schuchardt <xypron.glpk@gmx.de> wrote:
>> If fdtdec_next_compatible_subnode() fails it returns a negative value.
>> The check (node <= 0) cannot identify this if node is unsigned.
>>
>> Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
>> ---
>> drivers/usb/host/xhci-exynos5.c | 2 +-
>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>
>
> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
applied to u-boot-usb/topic-xhci, thanks!
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-03-19 3:11 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-03-18 12:51 [U-Boot] [PATCH 1/1] usb: xhci-exynos5: correct error checking Heinrich Schuchardt
2018-03-19 3:00 ` Bin Meng
2018-03-19 3:11 ` Bin Meng
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.