Since id is u32 the comparsion < 0 will fail. The right way would be to check the return value of of_property_read_u32
Tested on ml507 board. Signed-off-by: Gernot Vormayr <gvorm...@gmail.com> --- drivers/block/xsysace.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/block/xsysace.c b/drivers/block/xsysace.c index 1a17e33..b115e1f 100644 --- a/drivers/block/xsysace.c +++ b/drivers/block/xsysace.c @@ -1162,8 +1162,7 @@ static int __devinit ace_probe(struct platform_device *dev) dev_dbg(&dev->dev, "ace_probe(%p)\n", dev); /* device id and bus width */ - of_property_read_u32(dev->dev.of_node, "port-number", &id); - if (id < 0) + if (of_property_read_u32(dev->dev.of_node, "port-number", &id)) id = 0; if (of_find_property(dev->dev.of_node, "8-bit", NULL)) bus_width = ACE_BUS_WIDTH_8; -- 1.7.9.5 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/