New-style I2C driver not getting probed because of_register_i2c_devices() is not setting info.driver_name

flat view

From: Timur Tabi <hidden>
Date: 2008-05-14 20:48:28

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
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help