forked from Minki/linux
hwmon fixes for v6.0-rc1
Fix two regressions in nct6775 and lm90 drivers -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEiHPvMQj9QTOCiqgVyx8mb86fmYEFAmLztc8ACgkQyx8mb86f mYHj8Q/9EfRpWQfkkjEL2Nrn4ovBkS2B/y0JST1XFI5EY/BlXWRDF/RDIqDY7lRE k2eU0FiE3HX6Hfo0Y4IsMLi8pM1vpujVqRiwmyoTiArVzTcQEipDc9IKcDAZG/rJ l1oynjTpl5jJxUbtOL7/D4SgY6lQDUhxTtVSuXQzvWsmyE9k7qSizmBjnUz0Z0UK bH9EEc9oa8Br1trweio6lHWJXiwLdkCRcrLyLXaBHY4Dbi6nxR7/bcGkoXVhCKbJ hgFb6rxzJoGaUuxsKWy7ZNrLNnrskA4CVxF2di6eQjXBLj1YCosr7FoR9ljJ0Oqx ll42ZNK8HtoYnKHxpSbfCEXXjLr4HJaARgIEpyLiXOY7R8c8zU8QViqSHpxkvyW5 EhFs2MfVsSJQ8PxOMMnqw7oLQHiFx6Yvmlhvf9FWOlzwkBBbV5xZyrf3U4L/AvBA BTX/+tKGOezEKAeHqRGB6X40dRwnTClRag0pNMh+E7VKQXmcVhr0BrWAnJ8tz5wa pkEWq5mG31DyhaT8vuFvTN2CNliiTeQfc2hU780q5qZF2XX/fV+5lkipIO8j4xoe LFm6o4W1ySZXgyMiAao/ogT0fJyzkjmlic+PnoQHVrykvZKlEZzl7kM/CvNvfN+J EDuX42pm+yr1oVAgRa2If8qcNI4O6yAC6h9eiyP4hbUhjsKYdL4= =MMyB -----END PGP SIGNATURE----- Merge tag 'hwmon-fixes-for-v6.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging Pull hwmon fixes from Guenter Roeck: "Fix two regressions in nct6775 and lm90 drivers" * tag 'hwmon-fixes-for-v6.0-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging: hwmon: (nct6775) Fix platform driver suspend regression hwmon: (lm90) Fix error return value from detect function
This commit is contained in:
commit
f41445645a
@ -2321,7 +2321,7 @@ static const char *lm90_detect_nuvoton(struct i2c_client *client, int chip_id,
|
||||
const char *name = NULL;
|
||||
|
||||
if (config2 < 0)
|
||||
return ERR_PTR(-ENODEV);
|
||||
return NULL;
|
||||
|
||||
if (address == 0x4c && !(config1 & 0x2a) && !(config2 & 0xf8)) {
|
||||
if (chip_id == 0x01 && convrate <= 0x09) {
|
||||
|
@ -1480,7 +1480,7 @@ static int nct6775_update_pwm_limits(struct device *dev)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct nct6775_data *nct6775_update_device(struct device *dev)
|
||||
struct nct6775_data *nct6775_update_device(struct device *dev)
|
||||
{
|
||||
struct nct6775_data *data = dev_get_drvdata(dev);
|
||||
int i, j, err = 0;
|
||||
@ -1615,6 +1615,7 @@ out:
|
||||
mutex_unlock(&data->update_lock);
|
||||
return err ? ERR_PTR(err) : data;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(nct6775_update_device);
|
||||
|
||||
/*
|
||||
* Sysfs callback functions
|
||||
|
@ -359,7 +359,7 @@ static int __maybe_unused nct6775_suspend(struct device *dev)
|
||||
{
|
||||
int err;
|
||||
u16 tmp;
|
||||
struct nct6775_data *data = dev_get_drvdata(dev);
|
||||
struct nct6775_data *data = nct6775_update_device(dev);
|
||||
|
||||
if (IS_ERR(data))
|
||||
return PTR_ERR(data);
|
||||
|
@ -196,6 +196,8 @@ static inline int nct6775_write_value(struct nct6775_data *data, u16 reg, u16 va
|
||||
return regmap_write(data->regmap, reg, value);
|
||||
}
|
||||
|
||||
struct nct6775_data *nct6775_update_device(struct device *dev);
|
||||
|
||||
bool nct6775_reg_is_word_sized(struct nct6775_data *data, u16 reg);
|
||||
int nct6775_probe(struct device *dev, struct nct6775_data *data,
|
||||
const struct regmap_config *regmapcfg);
|
||||
|
Loading…
Reference in New Issue
Block a user