Thread (1 message) 1 message, 1 author, 2015-07-05

Re: [PATCH 1/2] spi: bcm2835: add spi-bcm2835aux driver for the auxiliar spi1 and spi2

From: Martin Sperl <hidden>
Date: 2015-07-05 13:11:52
Also in: linux-spi

On 05.07.2015, at 20:37, Noralf Trønnes [off-list ref] wrote:

I have looked closer at the 8250 serial driver, and in fact it has a
framework for writing 8250 like drivers. This makes it easy to extend
it to include support for the mini uart.
drivers/tty/serial/8250/8250_dw.c is an example of a driver that
overrides the interrupt handler. So a 8250_bcm2835.c can easily be
made with interrupt sharing as you suggest (and aux enabling). But
this means that the irq status register has to be included in the
syscon regmap as well.
With the Module parameter share_irqs=1 the stock 8250 driver will
request a shared irq, but you can also control it via:
CONFIG_SERIAL_8250_SHARE_IRQ

As for regmap support - the driver only uses the status register of
the uart so it does not need access to the shared interrupt flag register.
(If no irq condition is detected then IRQ_NoNE is returned and the
Shared irq system will call the next irq handler in the list)

So all that is left to do is enabling the uart device in the aux-enable
registers using regmap and then the uart can get used.

Martin--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help