diff --git a/drivers/i2c/muxes/i2c-mux-pca954x.c b/drivers/i2c/muxes/i2c-mux-pca954x.c index 0d5515b..395254c 100644 --- a/drivers/i2c/muxes/i2c-mux-pca954x.c +++ b/drivers/i2c/muxes/i2c-mux-pca954x.c @@ -180,6 +180,7 @@ struct i2c_adapter *adap = to_i2c_adapter(client->dev.parent); int num, force; struct pca954x *data; + uintptr_t tmp; int ret = -ENODEV; int gpio; @@ -203,7 +204,8 @@ goto exit_free; } - ret = dev_get_drvdata(dev, (const void **)&data->type); + ret = dev_get_drvdata(dev, (const void **)&tmp); + data->type = tmp; if (ret) goto exit_free;