I'm writing a kernel modul which should work on i2c.
The problem is:
the probe
function doesn't load automatically. AFAIK, it should be called with a correct device driver name. Please correct me if I'm wrong.
So my question is: what is the right device driver name for the i2c modul on Raspberry Pi?
As an example I have found this: http://home.hiwaay.net/~jeffj1/i2c-bcm2708.c and tried a lot, like bcm2708_i2c, i2c, i2c_dev
My code look like this:
#define DRV_NAME "bcm2708_i2c"
static struct platform_driver bcm2708_i2c_driver = {
.driver = {
.name = DRV_NAME,
.owner = THIS_MODULE,
},
.probe = bcm2708_i2c_probe,
.remove = __devexit_p(bcm2708_i2c_remove),
};
1 Answer 1
There are several modules associated with I2C on the Pi.
I guess you want i2c_bcm2708
lsmod | grep i2c
regmap_i2c 1661 3 snd_soc_pcm512x,snd_soc_wm8804,snd_soc_core
i2c_bcm2708 4943 0
i2c_dev