SUPERH platform development
 help / color / mirror / Atom feed
* [PATCH] gpio: em: Use irq_domain_add_simple() to fix runtime error
@ 2013-02-12 15:56 Magnus Damm
  2013-02-13  8:11 ` Simon Horman
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Magnus Damm @ 2013-02-12 15:56 UTC (permalink / raw)
  To: linux-sh

From: Magnus Damm <damm@opensource.se>

Adjust the gpio-em.c driver to reconsider the pdata->irq_base
variable. Non-DT board code like for instance board-kzm9d.c
needs to operate of a static IRQ range for platform devices.

So this patch is updating the code to make use of the function
irq_domain_add_simple() instead of irq_domain_add_linear().

Fixes a EMEV2 / KZM9D runtime error caused by the following commit:
7385500 gpio/em: convert to linear IRQ domain

Signed-off-by: Magnus Damm <damm@opensource.se>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
---

 drivers/gpio/gpio-em.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- 0001/drivers/gpio/gpio-em.c
+++ work/drivers/gpio/gpio-em.c	2013-02-12 22:40:16.000000000 +0900
@@ -299,8 +299,9 @@ static int em_gio_probe(struct platform_
 	irq_chip->irq_set_type = em_gio_irq_set_type;
 	irq_chip->flags	= IRQCHIP_SKIP_SET_WAKE;
 
-	p->irq_domain = irq_domain_add_linear(pdev->dev.of_node,
+	p->irq_domain = irq_domain_add_simple(pdev->dev.of_node,
 					      pdata->number_of_pins,
+					      pdata->irq_base,
 					      &em_gio_irq_domain_ops, p);
 	if (!p->irq_domain) {
 		ret = -ENXIO;

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-02-14 23:22 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-02-12 15:56 [PATCH] gpio: em: Use irq_domain_add_simple() to fix runtime error Magnus Damm
2013-02-13  8:11 ` Simon Horman
2013-02-14 12:30 ` Magnus Damm
2013-02-14 15:55 ` Simon Horman
2013-02-14 16:45 ` Linus Walleij
2013-02-14 23:22 ` Simon Horman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox