diff options
Diffstat (limited to 'drivers/i2c/i2c-dev.c')
-rw-r--r-- | drivers/i2c/i2c-dev.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/i2c/i2c-dev.c b/drivers/i2c/i2c-dev.c index 307d976c9b69..c171988a9f51 100644 --- a/drivers/i2c/i2c-dev.c +++ b/drivers/i2c/i2c-dev.c | |||
@@ -521,9 +521,9 @@ static int i2cdev_attach_adapter(struct i2c_adapter *adap) | |||
521 | return PTR_ERR(i2c_dev); | 521 | return PTR_ERR(i2c_dev); |
522 | 522 | ||
523 | /* register this i2c device with the driver core */ | 523 | /* register this i2c device with the driver core */ |
524 | i2c_dev->dev = device_create_drvdata(i2c_dev_class, &adap->dev, | 524 | i2c_dev->dev = device_create(i2c_dev_class, &adap->dev, |
525 | MKDEV(I2C_MAJOR, adap->nr), | 525 | MKDEV(I2C_MAJOR, adap->nr), NULL, |
526 | NULL, "i2c-%d", adap->nr); | 526 | "i2c-%d", adap->nr); |
527 | if (IS_ERR(i2c_dev->dev)) { | 527 | if (IS_ERR(i2c_dev->dev)) { |
528 | res = PTR_ERR(i2c_dev->dev); | 528 | res = PTR_ERR(i2c_dev->dev); |
529 | goto error; | 529 | goto error; |