public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: Tomoya MORINAGA <tomoya-linux@dsn.okisemi.com>
Cc: David Brownell <dbrownell@users.sourceforge.net>,
	spi-devel-general@lists.sourceforge.net,
	linux-kernel@vger.kernel.org, qi.wang@intel.com,
	yong.y.wang@intel.com, joel.clark@intel.com,
	kok.howg.ewe@intel.com,
	Toshiharu Okada <toshiharu-linux@dsn.okisemi.com>
Subject: Re: [PATCH 1/3] spi_topcliff_pch: support new device ML7213
Date: Wed, 5 Jan 2011 09:38:35 -0700	[thread overview]
Message-ID: <20110105163835.GD17272@angua.secretlab.ca> (raw)
In-Reply-To: <280596192AA74D208C2C5F6389DBE8C1@hacdom.okisemi.com>

On Wed, Jan 05, 2011 at 11:34:20AM +0900, Tomoya MORINAGA wrote:
> Hi Grant,
> 
> On Wednesday, December 29, 2010 3:49 PM, Grant Likely wrote:
> >As previously discussed on this list, I would like to see support for
> >multiple bus instances implemented differently.  Rather than storing
> >the spi_master instances in an array in the pci device private data,
> >the pci device should register a separate platform_device for each spi
> >bus instance, and each of those bus instances should get bound to a
> >topcliff_spi_bus driver which doesn't need to have any special
> >knowledge about how many spi_master instances actually exist.
> >
> >Basically, the way it is implemented in this patch isn't taking
> >advantage of the infrastructure and instance management provided by
> >the driver model.
> 
> I see.
> I will modify like your suggestion.
> Could you show the reference SPI driver using multi-instance ?

In an multi-instance scenario, the spi driver is just a plain-jane
platform_driver.  There isn't anything special about it.  Instead, the
pci_driver becomes responsible to register one or more platform
devices for the child busses.  Much like one of the multifunction
devices in drivers/mfd.

As far as examples go, drivers/mfd/timberdale.c seems reasonable, if a
bit larger than what you need.

g.

> 
> Thanks,
> ---
> Tomoya MORINAGA
> OKI SEMICONDUCTOR CO., LTD.
> 

  reply	other threads:[~2011-01-05 16:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-27 11:23 [PATCH 1/3] spi_topcliff_pch: support new device ML7213 Tomoya MORINAGA
2010-12-27 11:23 ` [PATCH 2/3] spi_topcliff_pch: change calling function order correctly in remove Tomoya MORINAGA
2010-12-27 11:23   ` [PATCH 3/3] spi_topcliff_pch: fix resource leak issue Tomoya MORINAGA
2010-12-29  6:51     ` Grant Likely
2010-12-29  6:51   ` [PATCH 2/3] spi_topcliff_pch: change calling function order correctly in remove Grant Likely
2010-12-29  6:49 ` [PATCH 1/3] spi_topcliff_pch: support new device ML7213 Grant Likely
2011-01-05  2:34   ` Tomoya MORINAGA
2011-01-05 16:38     ` Grant Likely [this message]
2011-01-07  6:40       ` Tomoya MORINAGA
2011-01-07  9:57         ` Milton Miller
     [not found]         ` <topcliff-split@mdm.bga.com>
2011-01-11  9:42           ` Tomoya MORINAGA
2011-01-12  5:27             ` Tomoya MORINAGA
2011-01-18 12:36               ` Tomoya MORINAGA
2011-01-19  6:25                 ` Grant Likely
2011-01-07  6:47       ` Tomoya MORINAGA

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=20110105163835.GD17272@angua.secretlab.ca \
    --to=grant.likely@secretlab.ca \
    --cc=dbrownell@users.sourceforge.net \
    --cc=joel.clark@intel.com \
    --cc=kok.howg.ewe@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=qi.wang@intel.com \
    --cc=spi-devel-general@lists.sourceforge.net \
    --cc=tomoya-linux@dsn.okisemi.com \
    --cc=toshiharu-linux@dsn.okisemi.com \
    --cc=yong.y.wang@intel.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