public inbox for linux-sh@vger.kernel.org
 help / color / mirror / Atom feed
From: David Brownell <david-b@pacbell.net>
To: linux-sh@vger.kernel.org
Subject: Re: [PATCH 00/04] sh: gpio update
Date: Fri, 26 Dec 2008 19:10:13 +0000	[thread overview]
Message-ID: <200812261110.13717.david-b@pacbell.net> (raw)
In-Reply-To: <20081225091701.7670.10659.sendpatchset@rx1.opensource.se>

On Thursday 25 December 2008, Magnus Damm wrote:
> sh: gpio update
> 
> [PATCH 01/04] sh: make gpio_get/set_value() O(1)

More than doubling the speed.  Good.


> [PATCH 02/04] sh: lockless gpio_get_value()

Lockless register reads ... generally safe.  :)
I'll trust you refactored this right.


> [PATCH 03/04] sh: lockless gpio_set_value()

I'm not clear how "lockless" here could be safe though;
these all use software for register read/modify/write,
which means an IRQ could arrive in the middle and, by
reentering that code, invalidate what's being written.


> [PATCH 04/04] sh: use gpiolib
> 
> This patchset improves the performance of the SuperH gpio
> implementation and converts it to make use of gpiolib.
> 
> The patches have been tested on Migo-R with the spi_gpio driver
> together with mmc_spi. Bitbanging mmc performance is improved
> from about 11 KBytes/s to 40 KBytes/s.

Sounds good.  The mmc_spi code won't be what I'd call fast,
especially when bitbanging, so every little bit helps.

If those ganged GPIO calls ever happen, MMC would seem to
be a decent candidate to use them:  get a 4x improvement in
raw data rate by implementing the native protocol not the
SPI version.

- Dave


> Signed-off-by: Magnus Damm <damm@igel.co.jp>
> ---
> 
>  arch/sh/Kconfig            |    7 
>  arch/sh/boards/Kconfig     |    4 
>  arch/sh/include/asm/gpio.h |   70 ++++---
>  arch/sh/kernel/Makefile_32 |    2 
>  arch/sh/kernel/Makefile_64 |    2 
>  arch/sh/kernel/gpio.c      |  386 ++++++++++++++++++++++++++------------------
>  drivers/serial/sh-sci.h    |    2 
>  7 files changed, 288 insertions(+), 185 deletions(-)
> 
> 



      reply	other threads:[~2008-12-26 19:10 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-25  9:17 [PATCH 00/04] sh: gpio update Magnus Damm
2008-12-26 19:10 ` David Brownell [this message]

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=200812261110.13717.david-b@pacbell.net \
    --to=david-b@pacbell.net \
    --cc=linux-sh@vger.kernel.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