Thread (2 messages) 2 messages, 2 authors, 2014-05-27

Re: [linux-sunxi] Re: [PATCH 01/11] pinctrl: sunxi: create irq/pin mapping during init

From: Chen-Yu Tsai <hidden>
Date: 2014-05-27 08:35:03
Also in: linux-arm-kernel, linux-devicetree, linux-mmc

Possibly related (same subject, not in this thread)

On Tue, May 27, 2014 at 4:02 PM, Maxime Ripard
[off-list ref] wrote:
Hi,

On Mon, May 26, 2014 at 09:47:56AM +0200, Hans de Goede wrote:
quoted
From: Chen-Yu Tsai <redacted>

The irq/pin mapping is used to lookup the pin to mux to the irq
function when the irq is enabled. It is created when gpio_to_irq
is called. Creating the mapping during init allows us to map the
interrupts directly from the device tree.
Can you be a bit more precise on this?

What is the issue that this patch fix?
IIRC, originally the IRQ to pin mapping was created when gpio_to_irq
was called with a GPIO handle. The mapping in turn is used to mux
the pin into EINT mode.

If the mapping is created during gpio_to_irq, we can't use the
interrupts directly, i.e. through the DT with "interrupts = <&pio A 4>".

Instead we'd have to use "gpios = <&pio A B>", then pass the gpio
through to gpio_to_irq.


ChenYu
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help