On Thu, 22 May 2008 22:17:13 +0400
Anton Vorontsov <[EMAIL PROTECTED]> wrote:
> On Wed, May 21, 2008 at 09:28:31PM +0200, Pierre Ossman wrote:
> >
> > Fair enough. You should probably add a comment about this somewhere so
> > that people do not call get_cd() in the core request function and
> > similar places. Place it so that both get_cd() and get_ro() are covered
> > though, as it should be relevant for both.
>
> I think this is applicable to the .set_ios() too.
>
Indeed. That tends to be more obvious that it is costly though.
> >
> > This can be solved by allowing get_cd() to return an error that will be
> > treated as if get_cd() wasn't defined. -ENODEV seems suitable.
>
> -ENOSYS (not implemented) sounds better for this purpose...
>
Even better. :)
> > (get_ro() needs the same treatment, but I haven't gotten around to
> > that)
>
> Ok. How about this version?
>
Perfect. Unless there is some way you can pass flags in platform data?
Using the lack of an init() to determine the need for polling is a bit
circumstantial.
Rgds
--
-- Pierre Ossman
Linux kernel, MMC maintainer http://www.kernel.org
rdesktop, core developer http://www.rdesktop.org
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
spi-devel-general mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/spi-devel-general