diff --git a/src/libdt.c b/src/libdt.c index 55c46d1..952fd65 100644 --- a/src/libdt.c +++ b/src/libdt.c @@ -2324,13 +2324,14 @@ return udev_parse_eeprom(dev, devpath); } else if (!udev_parse_mtd(dev, devpath, size)) { return 0; - } else { - /* try to find a block device */ - ret = device_find_block_device(dev, devpath); - if (ret) - return ret; + } else if (device_find_block_device(dev, devpath)) { return of_parse_partition(partition_node, offset, size); } + + /* + * If we found a device but couldn't classify it above, we fall + * through. + */ } /*