Skip to contentSkip to conversation

powerpc/mpc8xxx_gpio: simplify searching for 'fsl, qoriq-gpio' compatiable

PATCH Applied Anatolij Gustschin 2 participants 2 messages Jan 8, 2011 – Mar 15, 2011 PowerPC

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 powerpc/mpc8xxx_gpio: simplify searching for 'fsl, qoriq-gpio' compatiable

Commit da3ed89e7ce272ebcc918487e2a28736ca0dd6bb added 'fsl,qoriq-gpio' compatiable searching in the old way using for_each_compatible_node(). But the driver have previously been changed to use a struct of_device_id compatible list passed to for_each_matching_node().

Add 'fsl,qoriq-gpio' compatiable to the existing compatible list instead of adding another for_each_compatible_node() loop.

---
 arch/powerpc/sysdev/mpc8xxx_gpio.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)
arch/powerpc/sysdev/mpc8xxx_gpio.c +1 -3
index c48cd81..0c2a91a 100644
@@ -310,6 +310,7 @@ static struct of_device_id mpc8xxx_gpio_ids[] __initdata = {
 	{ .compatible = "fsl,mpc8572-gpio", },
 	{ .compatible = "fsl,mpc8610-gpio", },
 	{ .compatible = "fsl,mpc5121-gpio", .data = mpc512x_irq_set_type, },
+	{ .compatible = "fsl,qoriq-gpio",   },
 	{}
 };
 
@@ -389,9 +390,6 @@ static int __init mpc8xxx_add_gpiochips(void)
 	for_each_matching_node(np, mpc8xxx_gpio_ids)
 		mpc8xxx_add_controller(np);
 
-	for_each_compatible_node(np, NULL, "fsl,qoriq-gpio")
-		mpc8xxx_add_controller(np);
-
 	return 0;
 }
 arch_initcall(mpc8xxx_add_gpiochips);
Signature · 1 line
1.7.1
Applied
#1 lore raw
Quoted 6 lines · Anatolij Gustschin

Commit da3ed89e7ce272ebcc918487e2a28736ca0dd6bb added 'fsl,qoriq-gpio' compatiable searching in the old way using for_each_compatible_node(). But the driver have previously been changed to use a struct of_device_id compatible list passed to for_each_matching_node().

Quoted 8 lines

Add 'fsl,qoriq-gpio' compatiable to the existing compatible list instead of adding another for_each_compatible_node() loop.

---
arch/powerpc/sysdev/mpc8xxx_gpio.c | 4 +---

1 files changed, 1 insertions(+), 3 deletions(-)

applied

- k