[i2c] "driver forgot to specify physical device"
Jean Delvare
khali at linux-fr.org
Tue Apr 17 09:30:00 CEST 2007
On Mon, 16 Apr 2007 22:06:44 +0200, Till Harbaum / Lists wrote:
> Am Montag 16 April 2007 schrieb Jean Delvare:
> > Easy, in the i2c_tiny_usb_probe(), before you call i2c_add_adapter(),
> > add:
> > dev->i2c_adap.dev.parent = &dev->dev;
> I am afraid i dont understand that. Ok, i understand i have to assign
> something to dev->i2c_adap.dev.parent. But what do you mean by &dev->dev?
> This is my own structure and it just doesn't contain any further entry named
> dev. Do you mean: dev->i2c_adap.dev.parent = &dev->i2c_adap.dev ?? But that
> would make my driver its own parent, wouldn't it?
Argh, yes, sorry, I misread your code. "parent" should point to the
struct device associated with your USB device, or more likely USB
interface, although I'm not familiar with USB. That would probably be:
dev->i2c_adap.dev.parent = &interface->dev;
--
Jean Delvare
More information about the i2c
mailing list