aboutsummaryrefslogtreecommitdiff
path: root/drivers/of/platform.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/of/platform.c')
-rw-r--r--drivers/of/platform.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/of/platform.c b/drivers/of/platform.c
index 10acf98f75fa..ddf5c2b5c89c 100644
--- a/drivers/of/platform.c
+++ b/drivers/of/platform.c
@@ -140,9 +140,8 @@ struct platform_device *of_device_alloc(struct device_node *np,
return NULL;
/* count the io and irq resources */
- if (of_can_translate_address(np))
- while (of_address_to_resource(np, num_reg, &temp_res) == 0)
- num_reg++;
+ while (of_address_to_resource(np, num_reg, &temp_res) == 0)
+ num_reg++;
num_irq = of_irq_count(np);
/* Populate the resource table */