The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Andrey Smirnov <andrew.smirnov@gmail.com>
Cc: linux-spi@vger.kernel.org, yurovsky@gmail.com,
	linux-kernel@vger.kernel.org
Subject: Re: [RFC, PATCH, RESEND] spi, spidev: Add support for long SPI transfers
Date: Tue, 25 Nov 2014 12:42:29 +0000	[thread overview]
Message-ID: <20141125124229.GY7712@sirena.org.uk> (raw)
In-Reply-To: <1416853893-1993-1-git-send-email-andrew.smirnov@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1253 bytes --]

On Mon, Nov 24, 2014 at 10:31:33AM -0800, Andrey Smirnov wrote:

> SPI controllers found on modern SoCs have rather large SPI FIFOs and
> allow for uninterrupted SPI transaction that are more then 255 bits
> long. This commit adds necessary plumbing for such SPI transfers.

I really don't follow how this change is connected to the changelog...

> As things are right now both SPI subsystem and SPIDEV driver are
> limited by their APIs to SPI transactions that are no longer than 255
> bits and that problem is exacerbated by the fact that transction
> length validity verification code does not have provisions for
> anything bigger than 32 bits.

No, that's not the case at all.  A spi_transfer can have a length that's
an unsigned integer number of bytes which is much larger than 255 bits.
What is the actual problem you're trying to solve here?  I suspect the
driver you are using is just badly implemented...

> +		if (!u_tmp->bits_per_word && u_tmp->bits_per_burst)
> +			k_tmp->bits_per_word = u_tmp->bits_per_burst;
> +		else
> +			k_tmp->bits_per_word = u_tmp->bits_per_word;

This is setting the number of bits per word which is nothing to do with
FIFOs or the lengths of transfers but instead concerns the formatting of
data onto the bus.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

  reply	other threads:[~2014-11-25 12:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-24 18:31 [RFC, PATCH, RESEND] spi, spidev: Add support for long SPI transfers Andrey Smirnov
2014-11-25 12:42 ` Mark Brown [this message]
2014-11-25 13:30   ` Andrey Smirnov
2014-11-25 13:40     ` Mark Brown
2014-11-25 21:18       ` Andrey Smirnov
2014-11-25 22:25         ` Mark Brown
2014-11-26 14:37           ` Andrey Smirnov

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=20141125124229.GY7712@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=andrew.smirnov@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=yurovsky@gmail.com \
    /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