diff options
author | Josh Boyer <jwboyer@linux.vnet.ibm.com> | 2007-09-14 14:54:12 -0400 |
---|---|---|
committer | Josh Boyer <jwboyer@gmail.com> | 2007-09-19 22:13:16 -0400 |
commit | 8d9ae994d8fce807fc90fb8e3b6ac8df1cc7dce6 (patch) | |
tree | f2b46b7d8830e9802e80b5134e48e75eadecb455 /drivers/mtd | |
parent | 658e81701970a82d33f46241f20be416ebd5e930 (diff) |
[POWERPC] Make partitions optional in physmap_of
The latest physmap_of driver has a small error where it will fail the probe
with:
physmap-flash: probe of fff00000.small-flas failed with error -2
if there are no partition subnodes in the device tree and the old style binding
is not used. Since partition definitions are optional, the probe should still
succeed.
Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
Acked-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/maps/physmap_of.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/mtd/maps/physmap_of.c b/drivers/mtd/maps/physmap_of.c index 3df001bfee36..096dd47b5d5d 100644 --- a/drivers/mtd/maps/physmap_of.c +++ b/drivers/mtd/maps/physmap_of.c | |||
@@ -142,6 +142,8 @@ static int __devinit process_partitions(struct physmap_flash_info *info, | |||
142 | } | 142 | } |
143 | } else { | 143 | } else { |
144 | nr_parts = parse_obsolete_partitions(dev, info, dp); | 144 | nr_parts = parse_obsolete_partitions(dev, info, dp); |
145 | if (nr_parts == -ENOENT) | ||
146 | nr_parts = 0; | ||
145 | } | 147 | } |
146 | 148 | ||
147 | if (nr_parts < 0) | 149 | if (nr_parts < 0) |