linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Jean Delvare <khali@linux-fr.org>
To: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
Cc: linuxppc-dev@ozlabs.org, linux-kernel@vger.kernel.org,
	i2c@lm-sensors.org
Subject: Re: [i2c] [PATCH] update module-init-tools to support the i2c subsystem
Date: Mon, 14 Jan 2008 17:38:35 +0100	[thread overview]
Message-ID: <20080114173835.5fe907db@hyperion.delvare> (raw)
In-Reply-To: <Pine.LNX.4.64.0801141154420.3058@vixen.sonytel.be>

Hi Geert,

On Mon, 14 Jan 2008 11:57:52 +0100 (CET), Geert Uytterhoeven wrote:
> On Sun, 13 Jan 2008, Jon Smirl wrote:
> > I don't know exactly what those modules tables are used for. I just
> > copied what the other subsystems do. Maybe they are used when you make
> > an initrd to know which drivers to copy into the image.
> 
> Module-init-tools needs those table to create module aliases in the *.ko
> files from the MODULE_DEVICE_TABLE(), so udev can load the modules based
> on the device IDs when the devices appear in sysfs.

I thought that the module aliases were generated by
scripts/mod/modpost? As a matter of fact, I did not apply Jon's patch
to module-init-tools, and "modinfo" shows me module aliases properly
for i2c drivers that call MODULE_DEVICE_TABLE():

$ /sbin/modinfo lm90
filename:       /lib/modules/2.6.24-rc7-git4/kernel/drivers/hwmon/lm90.ko
author:         Jean Delvare <khali@linux-fr.org>
description:    LM90/ADM1032 driver
license:        GPL
vermagic:       2.6.24-rc7-git4 mod_unload
depends:        hwmon
alias:          i2c:Nlm90*
alias:          i2c:Nadm1032*
alias:          i2c:Nlm99*
alias:          i2c:Nlm86*
alias:          i2c:Nmax6657*
alias:          i2c:Nadt7461*
alias:          i2c:Nmax6680*
$

"modprobe i2c:Nadm1032" loads the lm90 driver as expected.

> That's the generic part. How this applies to i2c devices on platforms
> without Open Firmware device trees is another question. I guess that's
> where Jean gets confused (i2c_device_id got _removed_ last year,
> because it didn't make sense (at the time?)).

The way it was implemented back then did not make sense. As it was not
clear whether we would implement something different or nothing at all,
I decided to plain remove it. Now that it seems that we want to
implement it differently, I'm looking into it again.

-- 
Jean Delvare

  parent reply	other threads:[~2008-01-14 16:38 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-18  2:39 [PATCH] update module-init-tools to support the i2c subsystem Jon Smirl
2008-01-13 14:27 ` [i2c] " Jean Delvare
2008-01-13 15:14   ` Jon Smirl
2008-01-13 15:35     ` Jean Delvare
2008-01-13 16:26       ` Jon Smirl
2008-01-13 17:43         ` Jean Delvare
2008-01-13 18:04           ` Jon Smirl
2008-01-14 10:57             ` Geert Uytterhoeven
2008-01-14 14:25               ` Jon Smirl
2008-01-14 16:38               ` Jean Delvare [this message]
2008-01-14 17:08                 ` Geert Uytterhoeven
2008-01-14 17:50                   ` Jean Delvare
2008-01-14 19:38                     ` Kay Sievers
2008-01-14 19:46                       ` Jean Delvare

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=20080114173835.5fe907db@hyperion.delvare \
    --to=khali@linux-fr.org \
    --cc=Geert.Uytterhoeven@sonycom.com \
    --cc=i2c@lm-sensors.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.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;
as well as URLs for NNTP newsgroup(s).