提交 bd97a63f 编写于 作者: B Ben Hutchings 提交者: David S. Miller

sfc: Log clearer error messages for hardware monitor

Signed-off-by: NBen Hutchings <bhutchings@solarflare.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 477e54eb
......@@ -108,10 +108,15 @@ static int efx_check_lm87(struct efx_nic *efx, unsigned mask)
if (alarms1 || alarms2) {
netif_err(efx, hw, efx->net_dev,
"LM87 detected a hardware failure (status %02x:%02x)"
"%s%s\n",
"%s%s%s\n",
alarms1, alarms2,
(alarms1 & LM87_ALARM_TEMP_INT) ? " INTERNAL" : "",
(alarms1 & LM87_ALARM_TEMP_EXT1) ? " EXTERNAL" : "");
(alarms1 & LM87_ALARM_TEMP_INT) ?
"; board is overheating" : "",
(alarms1 & LM87_ALARM_TEMP_EXT1) ?
"; controller is overheating" : "",
(alarms1 & ~(LM87_ALARM_TEMP_INT | LM87_ALARM_TEMP_EXT1)
|| alarms2) ?
"; electrical fault" : "");
return -ERANGE;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册