From: Bin Meng Date: Thu, 20 Aug 2015 13:40:25 +0000 (-0700) Subject: fdtdec: Fix possible infinite loop in fdtdec_get_pci_vendev() X-Git-Tag: v2015.10-rc3~92^2~20 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bc6351eb48c116e9d38329c06f7e5a87ea8ec8ac;p=platform%2Fkernel%2Fu-boot.git fdtdec: Fix possible infinite loop in fdtdec_get_pci_vendev() When there is no valid compatible string in current list, we should advance to next one in the compatible string list. Signed-off-by: Bin Meng Acked-by: Simon Glass --- diff --git a/lib/fdtdec.c b/lib/fdtdec.c index b65e1e6..81b54f8 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -207,9 +207,8 @@ int fdtdec_get_pci_vendev(const void *blob, int node, u16 *vendor, u16 *device) return 0; } - } else { - list += (len + 1); } + list += (len + 1); } return -ENOENT;