From: Greg Kroah-Hartman Date: Sat, 30 Aug 2014 23:49:05 +0000 (-0700) Subject: greybus: i2c: tie to the proper place on the greybus_device X-Git-Tag: v4.9-rc1~119^2~378^2~21^2~2176 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=e7e0782c41681856740fbdd63972fba6ec08f943;p=karo-tx-linux.git greybus: i2c: tie to the proper place on the greybus_device --- diff --git a/drivers/staging/greybus/i2c-gb.c b/drivers/staging/greybus/i2c-gb.c index 929243e15954..8b99e8a083a3 100644 --- a/drivers/staging/greybus/i2c-gb.c +++ b/drivers/staging/greybus/i2c-gb.c @@ -107,7 +107,7 @@ int gb_i2c_probe(struct greybus_device *gdev, i2c_gb_dev->gdev = gdev; i2c_gb_dev->adapter = adapter; - greybus_set_drvdata(gdev, i2c_gb_dev); + gdev->gb_i2c_dev = i2c_gb_dev; return 0; error: kfree(adapter); @@ -119,7 +119,7 @@ void gb_i2c_disconnect(struct greybus_device *gdev) { struct gb_i2c_device *i2c_gb_dev; - i2c_gb_dev = greybus_get_drvdata(gdev); + i2c_gb_dev = gdev->gb_i2c_dev; i2c_del_adapter(i2c_gb_dev->adapter); kfree(i2c_gb_dev->adapter); kfree(i2c_gb_dev);