From: Mark Brown <broonie@kernel.org>
To: Marc Kleine-Budde <mkl@pengutronix.de>
Cc: "Tim Harvey" <tharvey@gateworks.com>,
"open list" <linux-kernel@vger.kernel.org>,
linux-can@vger.kernel.org,
"Wolfgang Grandegger" <wg@grandegger.com>,
"Timo Schlüßler" <schluessler@krause.de>,
"Andy Shevchenko" <andriy.shevchenko@linux.intel.com>,
linux-spi@vger.kernel.org, "Jan Glauber" <jglauber@marvell.com>,
"Robert Richter" <rrichter@marvell.com>
Subject: Re: [PATCH] can: mcp251x: convert to half-duplex SPI
Date: Mon, 25 May 2020 12:31:06 +0100 [thread overview]
Message-ID: <20200525113106.GB4544@sirena.org.uk> (raw)
In-Reply-To: <e0f641bc-5473-792d-fea9-0a2e81fe1e38@pengutronix.de>
[-- Attachment #1: Type: text/plain, Size: 996 bytes --]
On Mon, May 25, 2020 at 01:17:01PM +0200, Marc Kleine-Budde wrote:
> On 5/21/20 10:19 PM, Tim Harvey wrote:
>
> > Should I be submitting this patch with logic that only does
> > half-duplex if the spi controller doesn't support it (if
> > (spi->controller->flags & SPI_CONTROLLER_HALF_DUPLEX)) or is it
> > acceptable to simply make the driver half-duplex like this for all
> > cases?
> Please make half duplex transfers depending on SPI_CONTROLLER_HALF_DUPLEX as
> most drivers have a considerable overhead at the end of a transfer.
> Most of them wait for a transfer complete interrupt. Which might take longer
> than the actual SPI transfer. Splitting one full duplex read-register transfer
> (which is a write followed by a read) into two half duplex transfers would kill
> performance on full duplex capable controllers.
This isn't something that every individual driver should be doing, such
rewriting should happen in the core so that everything sees the benefit.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2020-05-25 11:31 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-25 18:35 [PATCH] can: mcp251x: convert to half-duplex SPI Tim Harvey
2020-02-25 21:43 ` Marc Kleine-Budde
2020-02-25 22:25 ` Tim Harvey
2020-02-26 7:37 ` Marc Kleine-Budde
2020-02-26 10:19 ` Marc Kleine-Budde
[not found] ` <7b85e098-b9a9-dd14-203f-100cdf2e703e-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2020-05-21 20:19 ` Tim Harvey
[not found] ` <CAJ+vNU06DHVS25OQR1Kqyzy2ZxLVq-HdwenGv-jN5Rb3r8F86Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2020-05-21 21:08 ` Mark Brown
2020-05-25 11:17 ` Marc Kleine-Budde
2020-05-25 11:31 ` Mark Brown [this message]
[not found] ` <20200525113106.GB4544-GFdadSzt00ze9xe1eoZjHA@public.gmane.org>
2020-05-25 12:41 ` Marc Kleine-Budde
[not found] ` <a337c8ea-66e2-13c2-f625-fbe93e367d44-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2020-05-25 12:57 ` Mark Brown
2020-05-25 13:12 ` Marc Kleine-Budde
2020-05-25 13:27 ` Mark Brown
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=20200525113106.GB4544@sirena.org.uk \
--to=broonie@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=jglauber@marvell.com \
--cc=linux-can@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-spi@vger.kernel.org \
--cc=mkl@pengutronix.de \
--cc=rrichter@marvell.com \
--cc=schluessler@krause.de \
--cc=tharvey@gateworks.com \
--cc=wg@grandegger.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