linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* New-style I2C driver not getting probed because of_register_i2c_devices() is not setting info.driver_name
@ 2008-05-14 20:48 Timur Tabi
  0 siblings, 0 replies; only message in thread
From: Timur Tabi @ 2008-05-14 20:48 UTC (permalink / raw)
  To: linuxppc-dev list

I'm converting sound/soc/codecs/cs4270.c into a new-style I2C driver, and this
driver is not getting probed.  I believe the problem is that i2c_device_match()
is returning failure, because of this line:

	return strcmp(client->driver_name, drv->name) == 0;

when this line is executed, client->drivername is blank.  Therefore, the strcmp
never matches.

I think this string is blank because when of_register_i2c_devices() in fsl_soc.c
calls i2c_register_board_info(), the info.driver_name field is also blank.
i2c_new_device() copies info->driver_name to client->driver_name.

I don't understand why this code doesn't work for me.  Most of the core I2C code
has been in place for a year, and I can't see how my driver is different from
any other new-style I2C driver that works on OF platforms.

Can anyone help me?

-- 
Timur Tabi
Linux kernel developer at Freescale

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-05-14 20:48 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-14 20:48 New-style I2C driver not getting probed because of_register_i2c_devices() is not setting info.driver_name Timur Tabi

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).