diff options
author | Lee Jones <lee.jones@linaro.org> | 2014-02-03 03:24:20 -0500 |
---|---|---|
committer | Lee Jones <lee.jones@linaro.org> | 2014-02-19 08:30:30 -0500 |
commit | 5c6fbd56d16f38fddec629e1dccdeee5ad7f5a42 (patch) | |
tree | d496431bf5f56087ada87ead69f4909cb3dc2c15 | |
parent | 7f8279ce04589a2e0f29b865c3af40609b0ea08d (diff) |
mfd: tps65217: Naturalise cross-architecture discrepancies
If we compile the TPS65217 for a 64bit architecture we receive the following
warnings:
drivers/mfd/tps65217.c: In function ‘tps65217_probe’:
drivers/mfd/tps65217.c:173:13:
warning: cast from pointer to integer of different size
chip_id = (unsigned int)match->data;
^
Signed-off-by: Lee Jones <lee.jones@linaro.org>
-rw-r--r-- | drivers/mfd/tps65217.c | 4 | ||||
-rw-r--r-- | include/linux/mfd/tps65217.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/mfd/tps65217.c b/drivers/mfd/tps65217.c index 966cf65c5c36..3cc4c7084b92 100644 --- a/drivers/mfd/tps65217.c +++ b/drivers/mfd/tps65217.c | |||
@@ -158,7 +158,7 @@ static int tps65217_probe(struct i2c_client *client, | |||
158 | { | 158 | { |
159 | struct tps65217 *tps; | 159 | struct tps65217 *tps; |
160 | unsigned int version; | 160 | unsigned int version; |
161 | unsigned int chip_id = ids->driver_data; | 161 | unsigned long chip_id = ids->driver_data; |
162 | const struct of_device_id *match; | 162 | const struct of_device_id *match; |
163 | bool status_off = false; | 163 | bool status_off = false; |
164 | int ret; | 164 | int ret; |
@@ -170,7 +170,7 @@ static int tps65217_probe(struct i2c_client *client, | |||
170 | "Failed to find matching dt id\n"); | 170 | "Failed to find matching dt id\n"); |
171 | return -EINVAL; | 171 | return -EINVAL; |
172 | } | 172 | } |
173 | chip_id = (unsigned int)(unsigned long)match->data; | 173 | chip_id = (unsigned long)match->data; |
174 | status_off = of_property_read_bool(client->dev.of_node, | 174 | status_off = of_property_read_bool(client->dev.of_node, |
175 | "ti,pmic-shutdown-controller"); | 175 | "ti,pmic-shutdown-controller"); |
176 | } | 176 | } |
diff --git a/include/linux/mfd/tps65217.h b/include/linux/mfd/tps65217.h index a5a7f0130e96..54b5458ec084 100644 --- a/include/linux/mfd/tps65217.h +++ b/include/linux/mfd/tps65217.h | |||
@@ -252,7 +252,7 @@ struct tps65217_board { | |||
252 | struct tps65217 { | 252 | struct tps65217 { |
253 | struct device *dev; | 253 | struct device *dev; |
254 | struct tps65217_board *pdata; | 254 | struct tps65217_board *pdata; |
255 | unsigned int id; | 255 | unsigned long id; |
256 | struct regulator_desc desc[TPS65217_NUM_REGULATOR]; | 256 | struct regulator_desc desc[TPS65217_NUM_REGULATOR]; |
257 | struct regulator_dev *rdev[TPS65217_NUM_REGULATOR]; | 257 | struct regulator_dev *rdev[TPS65217_NUM_REGULATOR]; |
258 | struct regmap *regmap; | 258 | struct regmap *regmap; |
@@ -263,7 +263,7 @@ static inline struct tps65217 *dev_to_tps65217(struct device *dev) | |||
263 | return dev_get_drvdata(dev); | 263 | return dev_get_drvdata(dev); |
264 | } | 264 | } |
265 | 265 | ||
266 | static inline int tps65217_chip_id(struct tps65217 *tps65217) | 266 | static inline unsigned long tps65217_chip_id(struct tps65217 *tps65217) |
267 | { | 267 | { |
268 | return tps65217->id; | 268 | return tps65217->id; |
269 | } | 269 | } |