linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* gpio irqs broken on imx27 with dt
@ 2012-04-27 12:50 Uwe Kleine-König
  2012-04-27 13:18 ` Dong Aisheng
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Uwe Kleine-König @ 2012-04-27 12:50 UTC (permalink / raw)
  To: linux-arm-kernel

Hello,

I experience problems on using gpio irqs on an imx27 based machine
booting with dt.

I think one problem is:

        if (mxc_gpio_hwtype == IMX21_GPIO) {
                /* setup one handler for all GPIO interrupts */
                if (pdev->id == 0)
                        irq_set_chained_handler(port->irq,
                                                mx2_gpio_irq_handler);
	} ...

because the inner if doesn't trigger as dt-created gpio devices have all
pdev->id == -1.

I havn't looked deeper into it yet, but I think another problem is that
gpios don't start at 0 and so the usual

	#define OTG_PHY_CS_GPIO (GPIO_PORTB + 23)

doesn't work either (which might be expected, but doesn't necessarily
needs to fail?!). (You could argue I shouldn't hardcode gpio numbers any
more, but as not all device drivers are oftree aware yet I need to get
of the ground somehow.)

I'm leaving for the weekend now, so just wanted you to inform that there
is a problem. Shawn, maybe you have an idea?

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-K?nig            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

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

end of thread, other threads:[~2012-04-28 10:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-27 12:50 gpio irqs broken on imx27 with dt Uwe Kleine-König
2012-04-27 13:18 ` Dong Aisheng
2012-04-27 21:16 ` Fabio Estevam
2012-04-27 21:50 ` Sascha Hauer
2012-04-28 10:31   ` Uwe Kleine-König

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).