bnxt_en: Fix invoking hwmon_notify_event
authorKalesh AP <kalesh-anakkur.purayil@broadcom.com>
Fri, 20 Oct 2023 21:27:51 +0000 (14:27 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 22 Oct 2023 10:41:46 +0000 (11:41 +0100)
commitfd78ec3fbc470d33c42a312fd22506e3f3704374
treea8d728307f742d739f933ce8e153caff9be659df
parent55862094a9d0d14f607eec00b925401407d61070
bnxt_en: Fix invoking hwmon_notify_event

FW sends the async event to the driver when the device temperature goes
above or below the threshold values.  Only notify hwmon if the
temperature is increasing to the next alert level, not when it is
decreasing.

Cc: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Kashyap Desai <kashyap.desai@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Signed-off-by: Michael Chan <michael.chan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnxt/bnxt.c