From nobody Sun Dec 28 02:52:39 2025 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0E444C4167D for ; Wed, 13 Dec 2023 21:54:21 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1442662AbjLMVyM (ORCPT ); Wed, 13 Dec 2023 16:54:12 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58094 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233861AbjLMVyC (ORCPT ); Wed, 13 Dec 2023 16:54:02 -0500 Received: from mx0b-002e3701.pphosted.com (mx0b-002e3701.pphosted.com [148.163.143.35]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8C337E3; Wed, 13 Dec 2023 13:54:08 -0800 (PST) Received: from pps.filterd (m0150245.ppops.net [127.0.0.1]) by mx0b-002e3701.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 3BDL31A1016672; Wed, 13 Dec 2023 21:53:53 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=hpe.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-transfer-encoding; s=pps0720; bh=/mc35BB7pN+bTQ14JgWZrfQ8eiHQQLtvFVxq/fsszlc=; b=OouDOYdHgXHG5XVl+pyVtruSEruAJaAe9d1QiBESMEYxdBkAnqKNV1mfCV7HOm9e1URD E9lI8KbQprBhvhfz/9nn+oZ/X1igO2s46E5CGAf8Gm/OUZPQ7jS92uiO4XMgYTCIGhQR +QBPdv8x4GBPrisYqTKqbFYZOtqtcHbhgQUFO12Yrl9b5yDeh9nEOczJzE6SFwheeT4w vYFWibI8lfF8d/NMFBrS00R23ZUe7+ZdURC58YddzgwAOKpZBkz7VGNbggLL5gjZr8C/ Tw7zdzJSURrFy1cyZZf8Dihq6K7z1kOnkcQ9x5dgk9vke1dIzgkTUaZe7jy4z5KWUbze Gw== Received: from p1lg14878.it.hpe.com ([16.230.97.204]) by mx0b-002e3701.pphosted.com (PPS) with ESMTPS id 3uydkrc49m-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 13 Dec 2023 21:53:52 +0000 Received: from p1lg14885.dc01.its.hpecorp.net (unknown [10.119.18.236]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by p1lg14878.it.hpe.com (Postfix) with ESMTPS id 02BD213152; Wed, 13 Dec 2023 21:53:52 +0000 (UTC) Received: from anatevka.americas.hpqcorp.net (unknown [16.231.227.39]) by p1lg14885.dc01.its.hpecorp.net (Postfix) with ESMTP id 91C64800472; Wed, 13 Dec 2023 21:53:51 +0000 (UTC) From: Jerry Hoemann To: linux@roeck-us.net Cc: wim@linux-watchdog.org, linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, Jerry Hoemann Subject: [PATCH v2 1/3] watchdog/hpwdt: Only claim UNKNOWN NMI if from iLO Date: Wed, 13 Dec 2023 14:53:38 -0700 Message-ID: <20231213215340.495734-2-jerry.hoemann@hpe.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20231213215340.495734-1-jerry.hoemann@hpe.com> References: <20231213215340.495734-1-jerry.hoemann@hpe.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Proofpoint-ORIG-GUID: lQKZrEfkl6YnOP9D1O6kyoL07T5tlA7I X-Proofpoint-GUID: lQKZrEfkl6YnOP9D1O6kyoL07T5tlA7I X-HPE-SCL: -1 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.997,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2023-12-13_14,2023-12-13_01,2023-05-22_02 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 mlxscore=0 clxscore=1015 mlxlogscore=999 priorityscore=1501 malwarescore=0 suspectscore=0 impostorscore=0 spamscore=0 adultscore=0 phishscore=0 lowpriorityscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2311290000 definitions=main-2312130154 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Avoid unnecessary crashes by claiming only NMIs that are due to ERROR signalling or generated by the hpwdt hardware device. The code does this, but only for iLO5. The intent was to preserve legacy, Gen9 and earlier, semantics of using hpwdt for error containtment as hardware/firmware would signal fatal IO errors as an NMI with the expectation of hpwdt crashing the system. Howerver, these IO errors should be received by hpwdt as an NMI_IO_CHECK. So the test is overly permissive and should not be limited to only ilo5. We need to enable this protection for future iLOs not matching the current PCI IDs. Fixes: 62290a5c194b ("watchdog: hpwdt: Claim NMIs generated by iLO5") Signed-off-by: Jerry Hoemann Reviewed-by: Guenter Roeck --- drivers/watchdog/hpwdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c index f79f932bca14..79ed1626d8ea 100644 --- a/drivers/watchdog/hpwdt.c +++ b/drivers/watchdog/hpwdt.c @@ -178,7 +178,7 @@ static int hpwdt_pretimeout(unsigned int ulReason, stru= ct pt_regs *regs) "3. OA Forward Progress Log\n" "4. iLO Event Log"; =20 - if (ilo5 && ulReason =3D=3D NMI_UNKNOWN && !mynmi) + if (ulReason =3D=3D NMI_UNKNOWN && !mynmi) return NMI_DONE; =20 if (ilo5 && !pretimeout && !mynmi) --=20 2.41.0