From: Baurzhan Ismagulov <ibr-Y2X99Y6vBNTR7s880joybQ@public.gmane.org>
To: Jochen Friedrich <jochen-NIgtFMG+Po8@public.gmane.org>
Cc: linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: status of i2c-cpm and ds2482
Date: Fri, 8 Jan 2010 14:43:39 +0100 [thread overview]
Message-ID: <20100108134339.GE4004@radix50.net> (raw)
In-Reply-To: <4B4726CF.9020605-NIgtFMG+Po8@public.gmane.org>
On Fri, Jan 08, 2010 at 01:36:31PM +0100, Jochen Friedrich wrote:
>> How did it work in 2.6.25.7?
>
> It was probably probed by some userspace tool.
Nope, it worked directly after booting. The initialization sequence
looked like this:
w1_add_master_device
ds2482_attach_adapter
i2c_register_driver
sensors_ds2482_init
kernel_init
kernel_thread
> This has been turned off as probing i2c might be problematic on Soc
> boards. See:
> http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=0a346dacee18ff69f6162d9860d723a058f47321
>
> You could try to add the property "linux,i2c-class=1" to the i2c
> controller in your dts to see if this commit is the cause of difference.
I've added "linux,i2c-class = <1>;" to i2c@860; this has set i2c-cpm's
class to I2C_CLASS_HWMON. You are probably right in that the problem
seems to be partly related to that.
That said, the default class of i2c-cpm is I2C_CLASS_HWMON |
I2C_CLASS_SPD, whereas the one of ds2482 is not set and thus zero (I'm
using 2.6.27.25), so if (!(adapter->class & driver->class)) in
i2c_detect goes to exit_free. So yesterday I had to set ds2482's class
to I2C_CLASS_SPD since the classes have to match.
However, it still goes to exit_free immediately after that since ds2482
doesn't provide I2C_FUNC_SMBUS_QUICK. IIUC, drivers are not required to
provide that, so I'm still looking why cpm_i2c_probe and ds2482_probe
don't get called.
> You should definitely add your ds2482 to the device tree so it is auto
> loaded by the i2c subsystem.
You mean, in dts? Do you have a template for that? I could look up the
necessary values in the working 2.6.25.7 kernel if I knew which ones I
need. Which routine reads it and calls probe?
Gruß,
Baurzhan.
next prev parent reply other threads:[~2010-01-08 13:43 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-08 2:02 status of i2c-cpm and ds2482 Baurzhan Ismagulov
[not found] ` <20100108020253.GJ3388-Y2X99Y6vBNTR7s880joybQ@public.gmane.org>
2010-01-08 11:25 ` Jochen Friedrich
[not found] ` <4B471647.8050806-NIgtFMG+Po8@public.gmane.org>
2010-01-08 12:17 ` Baurzhan Ismagulov
[not found] ` <20100108121723.GD4004-Y2X99Y6vBNTR7s880joybQ@public.gmane.org>
2010-01-08 12:36 ` Jochen Friedrich
[not found] ` <4B4726CF.9020605-NIgtFMG+Po8@public.gmane.org>
2010-01-08 13:43 ` Baurzhan Ismagulov [this message]
2010-01-08 12:52 ` Jean Delvare
[not found] ` <20100108135222.49d7b834-ig7AzVSIIG7kN2dkZ6Wm7A@public.gmane.org>
2010-01-08 14:01 ` Baurzhan Ismagulov
[not found] ` <20100108140111.GF4004-Y2X99Y6vBNTR7s880joybQ@public.gmane.org>
2010-01-08 14:06 ` Jochen Friedrich
[not found] ` <4B473BCE.8060803-NIgtFMG+Po8@public.gmane.org>
2010-01-08 23:19 ` Baurzhan Ismagulov
[not found] ` <20100108231942.GA3699-Y2X99Y6vBNTR7s880joybQ@public.gmane.org>
2010-01-09 8:12 ` Jean Delvare
2010-01-08 14:11 ` Jochen Friedrich
2010-01-08 17:54 ` 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=20100108134339.GE4004@radix50.net \
--to=ibr-y2x99y6vbntr7s880joybq@public.gmane.org \
--cc=jochen-NIgtFMG+Po8@public.gmane.org \
--cc=linux-i2c-u79uwXL29TY76Z2rM5mHXA@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