* [PATCH] trivial: some fixes in spi documentation @ 2009-10-30 21:28 Thadeu Lima de Souza Cascardo 2009-11-02 12:13 ` [spi-devel-general] " Wolfram Sang 0 siblings, 1 reply; 3+ messages in thread From: Thadeu Lima de Souza Cascardo @ 2009-10-30 21:28 UTC (permalink / raw) To: trivial Cc: Thadeu Lima de Souza Cascardo, David Brownell, Randy Dunlap, spi-devel-general, linux-kernel, linux-doc Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> --- Documentation/spi/spi-summary | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Documentation/spi/spi-summary b/Documentation/spi/spi-summary index deab51d..607aa97 100644 --- a/Documentation/spi/spi-summary +++ b/Documentation/spi/spi-summary @@ -121,7 +121,7 @@ active. So the master must set the clock to inactive before selecting a slave, and the slave can tell the chosen polarity by sampling the clock level when its select line goes active. That's why many devices support for example both modes 0 and 3: they don't care about polarity, -and alway clock data in/out on rising clock edges. +and always clock data in/out on rising clock edges. How do these driver programming interfaces work? @@ -236,7 +236,7 @@ And SOC-specific utility code might look something like: struct mysoc_spi_data *pdata2; pdata2 = kmalloc(sizeof *pdata2, GFP_KERNEL); - *pdata2 = pdata; + *pdata2 = *pdata; ... if (n == 2) { spi2->dev.platform_data = pdata2; @@ -427,8 +427,8 @@ any more such messages. it, should only be used with small amounts of data where the cost of an extra copy may be ignored. It's designed to support common RPC-style requests, such as writing an eight bit command - and reading a sixteen bit response -- spi_w8r16() being one its - wrappers, doing exactly that. + and reading a sixteen bit response -- spi_w8r16() being one of + its wrappers, doing exactly that. Some drivers may need to modify spi_device characteristics like the transfer mode, wordsize, or clock rate. This is done with spi_setup(), -- 1.6.3.3 ^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [spi-devel-general] [PATCH] trivial: some fixes in spi documentation 2009-10-30 21:28 [PATCH] trivial: some fixes in spi documentation Thadeu Lima de Souza Cascardo @ 2009-11-02 12:13 ` Wolfram Sang 2009-11-02 16:54 ` Thadeu Lima de Souza Cascardo 0 siblings, 1 reply; 3+ messages in thread From: Wolfram Sang @ 2009-11-02 12:13 UTC (permalink / raw) To: Thadeu Lima de Souza Cascardo Cc: trivial, David Brownell, linux-doc, linux-kernel, Randy Dunlap, spi-devel-general [-- Attachment #1: Type: text/plain, Size: 2919 bytes --] Hi, the typo fixes look good, still... On Fri, Oct 30, 2009 at 07:28:14PM -0200, Thadeu Lima de Souza Cascardo wrote: > Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> > --- > Documentation/spi/spi-summary | 8 ++++---- > 1 files changed, 4 insertions(+), 4 deletions(-) > > diff --git a/Documentation/spi/spi-summary b/Documentation/spi/spi-summary > index deab51d..607aa97 100644 > --- a/Documentation/spi/spi-summary > +++ b/Documentation/spi/spi-summary > @@ -121,7 +121,7 @@ active. So the master must set the clock to inactive before selecting > a slave, and the slave can tell the chosen polarity by sampling the > clock level when its select line goes active. That's why many devices > support for example both modes 0 and 3: they don't care about polarity, > -and alway clock data in/out on rising clock edges. > +and always clock data in/out on rising clock edges. > > > How do these driver programming interfaces work? > @@ -236,7 +236,7 @@ And SOC-specific utility code might look something like: > struct mysoc_spi_data *pdata2; > > pdata2 = kmalloc(sizeof *pdata2, GFP_KERNEL); > - *pdata2 = pdata; > + *pdata2 = *pdata; ... this looks correct, because a few lines above it is stated: static struct mysoc_spi_data __initdata pdata = { ... }; No pointer here. But yeah, pretty confusing for an example. > ... > if (n == 2) { > spi2->dev.platform_data = pdata2; > @@ -427,8 +427,8 @@ any more such messages. > it, should only be used with small amounts of data where the > cost of an extra copy may be ignored. It's designed to support > common RPC-style requests, such as writing an eight bit command > - and reading a sixteen bit response -- spi_w8r16() being one its > - wrappers, doing exactly that. > + and reading a sixteen bit response -- spi_w8r16() being one of > + its wrappers, doing exactly that. > > Some drivers may need to modify spi_device characteristics like the > transfer mode, wordsize, or clock rate. This is done with spi_setup(), > -- > 1.6.3.3 > > > ------------------------------------------------------------------------------ > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > is the only developer event you need to attend this year. Jumpstart your > developing skills, take BlackBerry mobile applications to market and stay > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > http://p.sf.net/sfu/devconference > _______________________________________________ > spi-devel-general mailing list > spi-devel-general@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/spi-devel-general -- Pengutronix e.K. | Wolfram Sang | Industrial Linux Solutions | http://www.pengutronix.de/ | [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 197 bytes --] ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [spi-devel-general] [PATCH] trivial: some fixes in spi documentation 2009-11-02 12:13 ` [spi-devel-general] " Wolfram Sang @ 2009-11-02 16:54 ` Thadeu Lima de Souza Cascardo 0 siblings, 0 replies; 3+ messages in thread From: Thadeu Lima de Souza Cascardo @ 2009-11-02 16:54 UTC (permalink / raw) To: Wolfram Sang Cc: trivial, David Brownell, linux-doc, linux-kernel, Randy Dunlap, spi-devel-general [-- Attachment #1: Type: text/plain, Size: 3291 bytes --] On Mon, Nov 02, 2009 at 01:13:34PM +0100, Wolfram Sang wrote: > Hi, > > the typo fixes look good, still... > > On Fri, Oct 30, 2009 at 07:28:14PM -0200, Thadeu Lima de Souza Cascardo wrote: > > Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> > > --- > > Documentation/spi/spi-summary | 8 ++++---- > > 1 files changed, 4 insertions(+), 4 deletions(-) > > > > diff --git a/Documentation/spi/spi-summary b/Documentation/spi/spi-summary > > index deab51d..607aa97 100644 > > --- a/Documentation/spi/spi-summary > > +++ b/Documentation/spi/spi-summary > > @@ -121,7 +121,7 @@ active. So the master must set the clock to inactive before selecting > > a slave, and the slave can tell the chosen polarity by sampling the > > clock level when its select line goes active. That's why many devices > > support for example both modes 0 and 3: they don't care about polarity, > > -and alway clock data in/out on rising clock edges. > > +and always clock data in/out on rising clock edges. > > > > > > How do these driver programming interfaces work? > > @@ -236,7 +236,7 @@ And SOC-specific utility code might look something like: > > struct mysoc_spi_data *pdata2; > > > > pdata2 = kmalloc(sizeof *pdata2, GFP_KERNEL); > > - *pdata2 = pdata; > > + *pdata2 = *pdata; > > ... this looks correct, because a few lines above it is stated: > > static struct mysoc_spi_data __initdata pdata = { ... }; > > No pointer here. But yeah, pretty confusing for an example. > Oh. Right. I may have thought that was an array or something. I will resend without it or think of a more clear example (perhaps, get some real but simple code). > > ... > > if (n == 2) { > > spi2->dev.platform_data = pdata2; > > @@ -427,8 +427,8 @@ any more such messages. > > it, should only be used with small amounts of data where the > > cost of an extra copy may be ignored. It's designed to support > > common RPC-style requests, such as writing an eight bit command > > - and reading a sixteen bit response -- spi_w8r16() being one its > > - wrappers, doing exactly that. > > + and reading a sixteen bit response -- spi_w8r16() being one of > > + its wrappers, doing exactly that. > > > > Some drivers may need to modify spi_device characteristics like the > > transfer mode, wordsize, or clock rate. This is done with spi_setup(), > > -- > > 1.6.3.3 > > > > > > ------------------------------------------------------------------------------ > > Come build with us! The BlackBerry(R) Developer Conference in SF, CA > > is the only developer event you need to attend this year. Jumpstart your > > developing skills, take BlackBerry mobile applications to market and stay > > ahead of the curve. Join us from November 9 - 12, 2009. Register now! > > http://p.sf.net/sfu/devconference > > _______________________________________________ > > spi-devel-general mailing list > > spi-devel-general@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/spi-devel-general > > -- > Pengutronix e.K. | Wolfram Sang | > Industrial Linux Solutions | http://www.pengutronix.de/ | [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 197 bytes --] ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2009-11-02 16:54 UTC | newest] Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2009-10-30 21:28 [PATCH] trivial: some fixes in spi documentation Thadeu Lima de Souza Cascardo 2009-11-02 12:13 ` [spi-devel-general] " Wolfram Sang 2009-11-02 16:54 ` Thadeu Lima de Souza Cascardo
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).