Re: [PATCH 2/4] hwmon: Add Qualcomm PMIC BCL hardware monitor driver
From: Daniel Lezcano
Date: Fri Mar 20 2026 - 12:17:16 EST
Hi Guenter,
On 3/20/26 16:22, Guenter Roeck wrote:
On 3/20/26 07:52, Daniel Lezcano wrote:
[ ... ]
+
+ADD_BCL_HWMON_ALARM_MAPS(in, min, lcrit);
+ADD_BCL_HWMON_ALARM_MAPS(curr, max, crit);
+
+/* Interrupt names for each alarm level */
+static const char * const bcl_int_names[ALARM_MAX] = {
+ [LVL0] = "bcl-max-min",
+ [LVL1] = "bcl-critical",
+};
IIUC there are three levels of alarms but the hwmon only has max/min
and critical. Would it make sense to do adaptative min / max ? So when
hwmon has lcrit, min, max, and crit alarms for all sensor types, plus
an additional _cap_alarm for power attributes and _emergency_alarm
for temperature attributes. There is also a generic _alarm attribute
for each sensor, which is supposed to be used if the specific alarm
type is not known.
What exactly are the three levels of alarms ?
Manaf can give more clarifications, but it is like we have yellow, orange and red alarms. So there is an additional alarm comparing to what is available in hwmon. The proposed driver maps orange and red alarms, respectively to bcl-max and bcl-critical.
I'm just asking if it is important to have this 'yellow' alarm ? And as there is a missing alarm to describe it in hwmon, how can we use it ?