Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to port some I2C device drivers I wrote for an other kernel to work with the newer I2C binding model. The kernel documentation goes through the steps of doing this: http://www.mjmwired.net/kernel/Documentation/i2c/upgrading-clients

The thing that I don't understand is when using this new model, how does one specify the I2C address of the device? It used to be done like this:

static unsigned short normal_i2c[] = { 0x67, I2C_CLIENT_END };


I don't think my bus/device supports detection.

share|improve this question
up vote 1 down vote accepted

I ended up registering all my I2C devices as platform devices. The entry in the board file looked something like:

static struct i2c_board_info __initdata my_i2c_device = {
        I2C_BOARD_INFO("my_i2c_device", 0x60)

(where I2C address = 0x60)

if (i2c_register_board_info(I2C_MY_BUS_ID, &my_i2c_device, 1) < 0) {
    printk(KERN_ERR "i2c_init: cannot register my I2C device\n");

See http://www.mjmwired.net/kernel/Documentation/driver-model/platform.txt

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.