public inbox for linux-arm-kernel@lists.infradead.org
 help / color / mirror / Atom feed
From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] SPI: Unify simple platform data for some controllers
Date: Wed, 29 May 2013 15:26:34 +0200	[thread overview]
Message-ID: <201305291526.35099.arnd@arndb.de> (raw)
In-Reply-To: <20130529112002.GS3660@sirena.org.uk>

On Wednesday 29 May 2013, Mark Brown wrote:
> On Wed, May 29, 2013 at 12:49:13PM +0400, Alexander Shiyan wrote:
> > > On Wednesday 29 May 2013 10:42:22 Alexander Shiyan wrote:
> 
> > > Wouldn't it be better to kill off the platform_data for these drivers
> > > and pass the gpio number through spi->controller_data as the
> > > spi_gpio driver does?
> 
> > Interesting way. Just one question remains, for using not-dt variant,
> > how  we should specify num_chipselect parameter for master?
> > I see only way for specify maximum constant in the driver.
> 
> We should fix that to be dynamic, having a fixed number is not sensible
> when GPIOs are usable for chip select. 

Agreed (not that I have much of a say on this matter).

> We probably also want to make
> GPIO chip select support a standard thing that's available with every
> driver rather than something the driver has to know about but that's a
> separate bit of work.

That actually seems simpler than doing it in just one driver: if
we add a cs_gpio field to spi_board_info, spi_new_device could
just copy that information into the new spi_device instead of
taking it from master->cs_gpios.

	Arnd

  reply	other threads:[~2013-05-29 13:26 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-29  6:42 [PATCH] SPI: Unify simple platform data for some controllers Alexander Shiyan
2013-05-29  7:56 ` Arnd Bergmann
2013-05-29  8:49   ` Alexander Shiyan
2013-05-29 11:20     ` Mark Brown
2013-05-29 13:26       ` Arnd Bergmann [this message]
2013-05-29 14:49         ` Mark Brown
2013-05-29 17:05           ` Alexander Shiyan
2013-05-29 18:10             ` Arnd Bergmann
2013-05-30  1:50               ` Shawn Guo
     [not found]           ` <1369847430-10799-1-git-send-email-shc_work@mail.ru>
2013-05-30  2:05             ` [RFC 1/3] SPI: imx: Convert to devm_* API Shawn Guo
     [not found]               ` <1369885838.170762928@f286.mail.ru>
2013-05-30  4:06                 ` Shawn Guo
     [not found]             ` <1369847430-10799-2-git-send-email-shc_work@mail.ru>
2013-05-30  2:42               ` [RFC 2/3] SPI: imx: Using SPI-master "cs_gpios" field for array of chipselects instead of private Shawn Guo
2013-05-30  3:22               ` Shawn Guo
     [not found]             ` <1369847430-10799-3-git-send-email-shc_work@mail.ru>
2013-05-30  3:36               ` [RFC 3/3] SPI: imx: Using dynamic count of chipselects provided by of_spi_register_master Shawn Guo

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=201305291526.35099.arnd@arndb.de \
    --to=arnd@arndb.de \
    --cc=linux-arm-kernel@lists.infradead.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