[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110510214518.GB5315@n2100.arm.linux.org.uk>
Date: Tue, 10 May 2011 22:45:18 +0100
From: Russell King - ARM Linux <linux@....linux.org.uk>
To: Linus Walleij <linus.walleij@...aro.org>
Cc: linux-kernel@...r.kernel.org,
Grant Likely <grant.likely@...retlab.ca>,
Martin Persson <martin.persson@...ricsson.com>,
Lee Jones <lee.jones@...aro.org>,
linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH 0/4] Pinmux subsystem
On Tue, May 10, 2011 at 11:25:44PM +0200, Linus Walleij wrote:
> It can, basically:
>
> struct pinmux *pmx;
>
> pmx = pinmux_get(dev, "irda-uart");
> pinmux_enable(pmx);
> (... SIR UART operations ...)
> pinmux_disable(pmx);
> pinmux_put(pmx);
> (... stuff to init FIR silicon ...)
> pmx = pinmux_get(dev, "irda-fir");
> pinmux_enable(pmx);
> (... etc ...)
You really don't want to do this. It's not that SIR and FIR are that
exclusive. You only switch to FIR mode when you've negotiated in SIR
mode, and then there's tight timings for doing that. Essentially you
agree in SIR mode to switch to FIR mode, switch to FIR mode and expect
a response in FIR mode from the remote end.
Calling out to lots of functions to perform the switch is asking for
that response to be missed because you've not set things up for it.
You'd want to have SIR and FIR mode 'got', and then switch as quickly
as possible between them.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists