Linux I2C development
 help / color / mirror / Atom feed
From: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
To: khali-PUYAD+kWke1g9hUCZPvPmw@public.gmane.org
Cc: i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org
Subject: Re: [PATCH 4/6]: i2c-pcf: Add a way for bus driver to ask for no smbus quick mode support.
Date: Wed, 15 Oct 2008 15:57:13 -0700 (PDT)	[thread overview]
Message-ID: <20081015.155713.44275434.davem@davemloft.net> (raw)
In-Reply-To: <20081015.143452.114860633.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>

From: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
Date: Wed, 15 Oct 2008 14:34:52 -0700 (PDT)

> From: Jean Delvare <khali-PUYAD+kWke1g9hUCZPvPmw@public.gmane.org>
> Date: Wed, 15 Oct 2008 14:33:21 +0200
> 
> > For another, with the introduction of I2C classes several years ago,
> > I2C device drivers should no longer probe random I2C adapters.  
> 
> Jean, they do, that's why I wrote this change.
> 
> > They should only probe adapters which share a class bit with them,
> 
> The pcf driver sets the class bit used by FAN and temperature sensors,
> so the I2C layer goes poking around all of the standard address
> locations each of those drivers list.
> 
> I don't want that to happen, ever.  I know exactly what address each
> and every I2C device sits at, so I don't want auto probing at all even
> even if the class bits match.

BTW, the powerpc folks want things the same exact way.

Look at the following change below which went into Linus's tree today.

Arguing against this is pointless.  With openfirmware device trees
describing exactly where every I2C device is, we want none of the
class based auto-probing stuff, we never ever want it.

Openfirmware platforms automatically trigger the device discovery
based upon the openfirmware device tree nodes.  None of the I2C
layer class based probing infrastructure is necessary nor wanted.

commit 618b26d52843c0f85b8eb143cf2695d7f6fd072d
Author: Wolfgang Grandegger <wg-5Yr1BZd7O62+XT7JhA+gdA@public.gmane.org>
Date:   Wed Oct 8 11:36:42 2008 -0600

    i2c-mpc: suppress I2C device probing
    
    This patch suppresses I2C device probing by clearing the class field
    of the "struct i2c_adapter" for the MPC I2C bus adapters. Some board
    configurations which rely on probing must be fixed up by adding a
    proper I2C device node to the DTS file, like the TQM85xx modules.
    
    Signed-off-by: Wolfgang Grandegger <wg-5Yr1BZd7O62+XT7JhA+gdA@public.gmane.org>
    Signed-off-by: Grant Likely <grant.likely-s3s/WqlpOiPyB63q8FvJNQ@public.gmane.org>

diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 27443f0..a9a45fc 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -312,7 +312,6 @@ static struct i2c_adapter mpc_ops = {
 	.name = "MPC adapter",
 	.id = I2C_HW_MPC107,
 	.algo = &mpc_algo,
-	.class = I2C_CLASS_HWMON | I2C_CLASS_SPD,
 	.timeout = 1,
 };
 

_______________________________________________
i2c mailing list
i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org
http://lists.lm-sensors.org/mailman/listinfo/i2c

  parent reply	other threads:[~2008-10-15 22:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-21  9:43 [PATCH 4/6]: i2c-pcf: Add a way for bus driver to ask for no smbus quick mode support David Miller
     [not found] ` <20080821.024327.144744678.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2008-10-15 12:33   ` Jean Delvare
     [not found]     ` <20081015143321.7df02b35-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2008-10-15 21:34       ` David Miller
     [not found]         ` <20081015.143452.114860633.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2008-10-15 22:57           ` David Miller [this message]
2008-10-16 10:13           ` Jean Delvare
     [not found]             ` <20081016121315.2adb5de1-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2008-10-16 10:46               ` Wolfram Sang
     [not found]                 ` <20081016104623.GB3432-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2008-10-16 11:35                   ` Jean Delvare
2008-10-16 19:25               ` David Miller
     [not found]                 ` <20081016.122542.30729839.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2008-10-16 19:34                   ` Jean Delvare
     [not found]                     ` <20081016213407.34d9eaa8-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2008-10-16 19:38                       ` David Miller

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=20081015.155713.44275434.davem@davemloft.net \
    --to=davem-ft/pcqaiutieiz0/mpfg9q@public.gmane.org \
    --cc=i2c-GZX6beZjE8VD60Wz+7aTrA@public.gmane.org \
    --cc=khali-PUYAD+kWke1g9hUCZPvPmw@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox