hwmon: (pmbus/core) Add support for NVIDIA nvidia195mv mode

Extend the PMBus core vrm_version handling to support NVIDIA nvidia195mv
VID mode. This adds a new VRM/VID encoding type and the corresponding
voltage conversion logic so devices reporting nvidia195mv can have their
VOUT/VID values interpreted correctly by the hwmon PMBus core.

Signed-off-by: Ashish Yadav <ashish.yadav@infineon.com>
Link: https://lore.kernel.org/r/20260223050804.4287-3-Ashish.Yadav@infineon.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
Ashish Yadav
2026-02-23 10:38:03 +05:30
committed by Guenter Roeck
parent 4c9d861b42
commit 969a4ec86c
2 changed files with 5 additions and 1 deletions

View File

@@ -416,7 +416,7 @@ enum pmbus_sensor_classes {
#define PMBUS_PAGE_VIRTUAL BIT(31) /* Page is virtual */
enum pmbus_data_format { linear = 0, ieee754, direct, vid };
enum vrm_version { vr11 = 0, vr12, vr13, imvp9, amd625mv };
enum vrm_version { vr11 = 0, vr12, vr13, imvp9, amd625mv, nvidia195mv };
/* PMBus revision identifiers */
#define PMBUS_REV_10 0x00 /* PMBus revision 1.0 */

View File

@@ -891,6 +891,10 @@ static s64 pmbus_reg2data_vid(struct pmbus_data *data,
if (val >= 0x0 && val <= 0xd8)
rv = DIV_ROUND_CLOSEST(155000 - val * 625, 100);
break;
case nvidia195mv:
if (val >= 0x01)
rv = 195 + (val - 1) * 5; /* VID step is 5mv */
break;
}
return rv;
}