mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-25 11:55:37 +00:00
hwmon: (emc1403) Add support for EMC1442
Add support for EMC1442 which is compatible with EMC1402. Signed-off-by: Delphine CC Chiu <Delphine_CC_Chiu@wiwynn.com> Reviewed-by: Patrick Williams <patrick@stwcx.xyz> Link: https://lore.kernel.org/r/20231102090808.427351-1-Delphine_CC_Chiu@wiwynn.com [groeck: compatible with EMC1402, not EMC1403] Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
parent
34c76a5120
commit
9350163aff
1 changed files with 5 additions and 1 deletions
|
@ -346,6 +346,9 @@ static int emc1403_detect(struct i2c_client *client,
|
||||||
case 0x27:
|
case 0x27:
|
||||||
strscpy(info->type, "emc1424", I2C_NAME_SIZE);
|
strscpy(info->type, "emc1424", I2C_NAME_SIZE);
|
||||||
break;
|
break;
|
||||||
|
case 0x60:
|
||||||
|
strscpy(info->type, "emc1442", I2C_NAME_SIZE);
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
return -ENODEV;
|
return -ENODEV;
|
||||||
}
|
}
|
||||||
|
@ -430,7 +433,7 @@ static int emc1403_probe(struct i2c_client *client)
|
||||||
}
|
}
|
||||||
|
|
||||||
static const unsigned short emc1403_address_list[] = {
|
static const unsigned short emc1403_address_list[] = {
|
||||||
0x18, 0x1c, 0x29, 0x4c, 0x4d, 0x5c, I2C_CLIENT_END
|
0x18, 0x1c, 0x29, 0x3c, 0x4c, 0x4d, 0x5c, I2C_CLIENT_END
|
||||||
};
|
};
|
||||||
|
|
||||||
/* Last digit of chip name indicates number of channels */
|
/* Last digit of chip name indicates number of channels */
|
||||||
|
@ -444,6 +447,7 @@ static const struct i2c_device_id emc1403_idtable[] = {
|
||||||
{ "emc1422", emc1402 },
|
{ "emc1422", emc1402 },
|
||||||
{ "emc1423", emc1403 },
|
{ "emc1423", emc1403 },
|
||||||
{ "emc1424", emc1404 },
|
{ "emc1424", emc1404 },
|
||||||
|
{ "emc1442", emc1402 },
|
||||||
{ }
|
{ }
|
||||||
};
|
};
|
||||||
MODULE_DEVICE_TABLE(i2c, emc1403_idtable);
|
MODULE_DEVICE_TABLE(i2c, emc1403_idtable);
|
||||||
|
|
Loading…
Reference in a new issue