mirror of
https://github.com/torvalds/linux.git
synced 2024-11-17 01:22:07 +00:00
MFD fixes due for the v3.14 -rcs
Couple of small issues solved: - Suspend/Resume call-backs require CONFIG_PM_SLEEP - Some drivers written for 32bit architectures fail when compiled with a 64bit compiler. The fixes will future proof the drivers. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) iQIcBAABAgAGBQJTBLjhAAoJEFGvii+H/HdhRn4P/2ovuuE0pGm4OkwIi+5yOM0S ABrW3UhHXfEW9S8rj6ZpDsgOjio+ZfojIbeeK59j01KkqC3l1mzz66wIfRUpjisk CPtERrSj/BzGgXiJpMgBEdugYIegSlygZOCTSj1fESDG4T3XMShaHvlZPj6Oe87x YF83wyqxd59+SFTnmwRnNo2RqXKSgkO+Gl0Rx6/CHQdHk3IXIforC0pLPPx5pNmZ FuIN8+hWBree6ih8nCPLmQI05KwU74U+NKWO+CKBkdAt+SJ8+3cr16+zfoFu351m 4ZedKAVZ7O3KUpdhIzDAQZzenz5VaVuo0KvQc4ZEgPlAWP3RmOsaUBaoCKI8LWlm Th2kkBTRleZuxA6psb3craXIasvkVLfLcVVYVAfPU/i+VqVDp9c24BeWDPVoJOLa //09ND+TokHjBWB+NnITO6dH240k7j6QY09pOpWJnJdWGwZSIo7/rZgDDKFIFes+ EcuN4nrurG379xsffMKNXgtYgLj7Okvn3lPZp1E+c7KF8MMd2o13mAQdGQFl+7V1 bbIKBY5nuL95pCS2DQktuu4WiQaQ5ONWFFdJ3iTpB5lv27eU6FyAPK2GmVU2xwT+ +tAjVwldww1JInNZrDsdLPn+PSKUGKAZWcNOSedjdHUzV0I2emYzXUAttLVjtp3m 380u+hdzHAd959XT2Mie =705r -----END PGP SIGNATURE----- Merge tag 'mfd-fixes-3.14-1' of git://git.linaro.org/people/lee.jones/mfd Pull MFD fixes from Lee Jones: "Couple of small issues solved: - Suspend/Resume call-backs require CONFIG_PM_SLEEP - Some drivers written for 32bit architectures fail when compiled with a 64bit compiler. The fixes will future proof the drivers" * tag 'mfd-fixes-3.14-1' of git://git.linaro.org/people/lee.jones/mfd: mfd: sec-core: sec_pmic_{suspend,resume}() should depend on CONFIG_PM_SLEEP mfd: max14577: max14577_{suspend,resume}() should depend on CONFIG_PM_SLEEP mfd: tps65217: Naturalise cross-architecture discrepancies mfd: wm8994-core: Naturalise cross-architecture discrepancies mfd: max8998: Naturalise cross-architecture discrepancies mfd: max8997: Naturalise cross-architecture discrepancies
This commit is contained in:
commit
981adacd39
@ -173,6 +173,7 @@ static const struct i2c_device_id max14577_i2c_id[] = {
|
||||
};
|
||||
MODULE_DEVICE_TABLE(i2c, max14577_i2c_id);
|
||||
|
||||
#ifdef CONFIG_PM_SLEEP
|
||||
static int max14577_suspend(struct device *dev)
|
||||
{
|
||||
struct i2c_client *i2c = container_of(dev, struct i2c_client, dev);
|
||||
@ -208,6 +209,7 @@ static int max14577_resume(struct device *dev)
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif /* CONFIG_PM_SLEEP */
|
||||
|
||||
static struct of_device_id max14577_dt_match[] = {
|
||||
{ .compatible = "maxim,max14577", },
|
||||
|
@ -164,15 +164,15 @@ static struct max8997_platform_data *max8997_i2c_parse_dt_pdata(
|
||||
return pd;
|
||||
}
|
||||
|
||||
static inline int max8997_i2c_get_driver_data(struct i2c_client *i2c,
|
||||
static inline unsigned long max8997_i2c_get_driver_data(struct i2c_client *i2c,
|
||||
const struct i2c_device_id *id)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_OF) && i2c->dev.of_node) {
|
||||
const struct of_device_id *match;
|
||||
match = of_match_node(max8997_pmic_dt_match, i2c->dev.of_node);
|
||||
return (int)match->data;
|
||||
return (unsigned long)match->data;
|
||||
}
|
||||
return (int)id->driver_data;
|
||||
return id->driver_data;
|
||||
}
|
||||
|
||||
static int max8997_i2c_probe(struct i2c_client *i2c,
|
||||
|
@ -169,16 +169,16 @@ static struct max8998_platform_data *max8998_i2c_parse_dt_pdata(
|
||||
return pd;
|
||||
}
|
||||
|
||||
static inline int max8998_i2c_get_driver_data(struct i2c_client *i2c,
|
||||
static inline unsigned long max8998_i2c_get_driver_data(struct i2c_client *i2c,
|
||||
const struct i2c_device_id *id)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_OF) && i2c->dev.of_node) {
|
||||
const struct of_device_id *match;
|
||||
match = of_match_node(max8998_dt_match, i2c->dev.of_node);
|
||||
return (int)(long)match->data;
|
||||
return (unsigned long)match->data;
|
||||
}
|
||||
|
||||
return (int)id->driver_data;
|
||||
return id->driver_data;
|
||||
}
|
||||
|
||||
static int max8998_i2c_probe(struct i2c_client *i2c,
|
||||
|
@ -315,6 +315,7 @@ static int sec_pmic_remove(struct i2c_client *i2c)
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PM_SLEEP
|
||||
static int sec_pmic_suspend(struct device *dev)
|
||||
{
|
||||
struct i2c_client *i2c = container_of(dev, struct i2c_client, dev);
|
||||
@ -349,6 +350,7 @@ static int sec_pmic_resume(struct device *dev)
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif /* CONFIG_PM_SLEEP */
|
||||
|
||||
static SIMPLE_DEV_PM_OPS(sec_pmic_pm_ops, sec_pmic_suspend, sec_pmic_resume);
|
||||
|
||||
|
@ -158,7 +158,7 @@ static int tps65217_probe(struct i2c_client *client,
|
||||
{
|
||||
struct tps65217 *tps;
|
||||
unsigned int version;
|
||||
unsigned int chip_id = ids->driver_data;
|
||||
unsigned long chip_id = ids->driver_data;
|
||||
const struct of_device_id *match;
|
||||
bool status_off = false;
|
||||
int ret;
|
||||
@ -170,7 +170,7 @@ static int tps65217_probe(struct i2c_client *client,
|
||||
"Failed to find matching dt id\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
chip_id = (unsigned int)(unsigned long)match->data;
|
||||
chip_id = (unsigned long)match->data;
|
||||
status_off = of_property_read_bool(client->dev.of_node,
|
||||
"ti,pmic-shutdown-controller");
|
||||
}
|
||||
|
@ -636,7 +636,7 @@ static int wm8994_i2c_probe(struct i2c_client *i2c,
|
||||
if (i2c->dev.of_node) {
|
||||
of_id = of_match_device(wm8994_of_match, &i2c->dev);
|
||||
if (of_id)
|
||||
wm8994->type = (int)of_id->data;
|
||||
wm8994->type = (enum wm8994_type)of_id->data;
|
||||
} else {
|
||||
wm8994->type = id->driver_data;
|
||||
}
|
||||
|
@ -387,7 +387,7 @@ struct max8997_dev {
|
||||
struct i2c_client *muic; /* slave addr 0x4a */
|
||||
struct mutex iolock;
|
||||
|
||||
int type;
|
||||
unsigned long type;
|
||||
struct platform_device *battery; /* battery control (not fuel gauge) */
|
||||
|
||||
int irq;
|
||||
|
@ -163,7 +163,7 @@ struct max8998_dev {
|
||||
int ono;
|
||||
u8 irq_masks_cur[MAX8998_NUM_IRQ_REGS];
|
||||
u8 irq_masks_cache[MAX8998_NUM_IRQ_REGS];
|
||||
int type;
|
||||
unsigned long type;
|
||||
bool wakeup;
|
||||
};
|
||||
|
||||
|
@ -252,7 +252,7 @@ struct tps65217_board {
|
||||
struct tps65217 {
|
||||
struct device *dev;
|
||||
struct tps65217_board *pdata;
|
||||
unsigned int id;
|
||||
unsigned long id;
|
||||
struct regulator_desc desc[TPS65217_NUM_REGULATOR];
|
||||
struct regulator_dev *rdev[TPS65217_NUM_REGULATOR];
|
||||
struct regmap *regmap;
|
||||
@ -263,7 +263,7 @@ static inline struct tps65217 *dev_to_tps65217(struct device *dev)
|
||||
return dev_get_drvdata(dev);
|
||||
}
|
||||
|
||||
static inline int tps65217_chip_id(struct tps65217 *tps65217)
|
||||
static inline unsigned long tps65217_chip_id(struct tps65217 *tps65217)
|
||||
{
|
||||
return tps65217->id;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user