All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ben Dooks <ben-linux-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org>
To: Richard R?jfors
	<richard.rojfors.lists-gfIc91nka+FZroRs9YW3xA@public.gmane.org>
Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: Registering I2C devices on X86
Date: Mon, 14 Jun 2010 08:26:47 +0100	[thread overview]
Message-ID: <20100614072647.GN32401@fluff.org.uk> (raw)
In-Reply-To: <4C062E70.3090409-gfIc91nka+FZroRs9YW3xA@public.gmane.org>

On Wed, Jun 02, 2010 at 12:12:00PM +0200, Richard R?jfors wrote:
> Hi,
> 
> I have a general question regarding the best way of registering I2C devices on a X86 system.
> 
> On ARM I would have done it in the board config, pretty straight forward.
> 
> On this X86 system the I2C bus is a PCI device, and different I2C
> devices might be tied into the bus depending on which board the
> device is populated on.

Hmm, if it is a PCI device, then surely you should know the PCI ID
you are binding too?
 
> So my idea is to create a "mapping" driver. It opens the I2C
> adapter, creates platform data for each I2C device and add them by
> calling i2c_new_device. I don't find any better way since platform
> data must be created and also translation from GPIO pins to
> interrupt numbers.

That might be a way, however there's not really a good way to add
interrupts dynamically.

-- 
Ben (ben-elnMNo+KYs3YtjvyW6yDsg@public.gmane.org, http://www.fluff.org/)

  'a smiley only costs 4 bytes'

      parent reply	other threads:[~2010-06-14  7:26 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-02 10:12 Registering I2C devices on X86 Richard Röjfors
     [not found] ` <4C062E70.3090409-gfIc91nka+FZroRs9YW3xA@public.gmane.org>
2010-06-02 10:36   ` Wolfram Sang
     [not found]     ` <20100602103650.GA4876-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2010-06-02 11:04       ` Jean Delvare
     [not found]         ` <20100602130408.1e732a0a-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2010-06-02 11:29           ` Richard Röjfors
     [not found]             ` <4C0640A0.9070103-gfIc91nka+FZroRs9YW3xA@public.gmane.org>
2010-06-03  6:21               ` Jean Delvare
     [not found]                 ` <20100603082103.4bdccd85-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2010-06-03 12:39                   ` Richard Röjfors
     [not found]                     ` <4C07A26C.3070708-gfIc91nka+FZroRs9YW3xA@public.gmane.org>
2010-06-20  8:34                       ` Jean Delvare
2010-06-14  7:26   ` Ben Dooks [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=20100614072647.GN32401@fluff.org.uk \
    --to=ben-linux-elnmno+kys3ytjvyw6ydsg@public.gmane.org \
    --cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=richard.rojfors.lists-gfIc91nka+FZroRs9YW3xA@public.gmane.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.