From: Baruch Siach <baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org>
To: Geert Uytterhoeven <geert-Td1EMuHUCqxL1ZNQvxDV9g@public.gmane.org>
Cc: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
linux-spi <linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
Subject: Re: [PATCH 1/3] spi: spi.h: clarify the documentation of transfer_one
Date: Fri, 24 Jan 2014 10:12:46 +0200 [thread overview]
Message-ID: <20140124081246.GN12751@tarshish> (raw)
In-Reply-To: <CAMuHMdW05ANcRJW8dPwLuvONoXD+Fny=Txd-wuwXVJHCqmva1A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
Hi Gerrt,
On Fri, Jan 24, 2014 at 08:44:32AM +0100, Geert Uytterhoeven wrote:
> On Fri, Jan 24, 2014 at 7:28 AM, Baruch Siach <baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org> wrote:
> > --- a/include/linux/spi/spi.h
> > +++ b/include/linux/spi/spi.h
> > @@ -285,7 +285,9 @@ static inline void spi_unregister_driver(struct spi_driver *sdrv)
> > * @transfer_one: transfer a single spi_transfer. When the
> > * driver is finished with this transfer it must call
> > * spi_finalize_current_transfer() so the subsystem can issue
> > - * the next transfer
> > + * the next transfer. Note: transfer_one and
> > + * transfer_one_message are mutually exclusive; when both are
> > + * set, transfer_one takes precedence.
>
> I find this a bit difficult to grasp. What does "take precedence" mean in
> this context?
>
> The default spi_transfer_one_message() uses .transfer_one().
> But if .transfer_one_message() is set, it depends on your own driver if
> .transfer_one() is used or not.
Of course. I misread the code. How about this:
Note: transfer_one and transfer_one_message are mutually exclusive; when both
are set, the transfer_one callback is not called by the generic subsystem.
Thanks again,
baruch
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org - tel: +972.2.679.5364, http://www.tkos.co.il -
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2014-01-24 8:12 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-24 6:28 [PATCH 0/3] spi: documentation improvements Baruch Siach
[not found] ` <cover.1390544495.git.baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org>
2014-01-24 6:28 ` [PATCH 1/3] spi: spi.h: clarify the documentation of transfer_one Baruch Siach
[not found] ` <39ffc897bd2e5fd48a3141ed4cd122a80c5bbb20.1390544495.git.baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org>
2014-01-24 7:44 ` Geert Uytterhoeven
[not found] ` <CAMuHMdW05ANcRJW8dPwLuvONoXD+Fny=Txd-wuwXVJHCqmva1A-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-01-24 8:12 ` Baruch Siach [this message]
2014-01-24 8:31 ` Geert Uytterhoeven
2014-01-24 6:28 ` [PATCH 2/3] Doc: spi: document the transfer_one spi_master callback Baruch Siach
[not found] ` <8b6ee8b5a08cd9fa9a94d16d2621e28b4f087098.1390544495.git.baruch-NswTu9S1W3P6gbPvEgmw2w@public.gmane.org>
2014-01-24 7:49 ` Geert Uytterhoeven
[not found] ` <CAMuHMdU=7knbuRQEpeCvkaE808i2GviTYqDX_vnEQm26aOvXTQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2014-01-24 8:02 ` Baruch Siach
2014-01-24 13:45 ` Gerhard Sittig
[not found] ` <20140124134517.GY20094-kDjWylLy9wD0K7fsECOQyeGNnDKD8DIp@public.gmane.org>
2014-01-25 18:52 ` Baruch Siach
2014-01-24 6:28 ` [PATCH 3/3] spi: correct the transfer_one_message documentation wording Baruch Siach
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20140124081246.GN12751@tarshish \
--to=baruch-nswtu9s1w3p6gbpvegmw2w@public.gmane.org \
--cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=geert-Td1EMuHUCqxL1ZNQvxDV9g@public.gmane.org \
--cc=linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).