Received: by 10.223.185.116 with SMTP id b49csp3302217wrg; Sun, 25 Feb 2018 19:26:08 -0800 (PST) X-Google-Smtp-Source: AH8x226Y6WKFuVvmvsuWwlSMblxjsZ8iS00cfbSKf0pFxnMjEvaonZUM+gSZSW8z9QPTW1dFDXy+ X-Received: by 10.99.5.197 with SMTP id 188mr7297338pgf.196.1519615567980; Sun, 25 Feb 2018 19:26:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519615567; cv=none; d=google.com; s=arc-20160816; b=iHNI7m1EupIokr0Q+TfqWJ/2APE3FsWn42L+3j6EXa3SqxLBeXQykocKXI7DUr5g/D +LTzxnBPsz8k/vhMl1TZ66s3iR0ykh8ovVlDI2w1xFNKG3hXpMJeDDEWdwg+OyuMXec1 OsTzAGJgai/TzE1ar5d93LnXsn1lCnluEjY4aMyWjaE+7dkNn9D8bFqNqAkVHhvt/CbT /00ECGDODhWW/fMwuIJRZgzY1b+s6QfX+u2CBowtLbTi81fC9BfcCwwaSMClpYJ1205w D+ZLcDdkqcul4pSh30IZzP92IBiwTtmObfh99Xe2CAtClv6GaeQNfPqKuhdjVWZSAFkH w7MA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=6ZYRjm9822XClLvcZyM2zDKXaDqCq1yaTiAeZCKoikc=; b=fJTwo5zPGZb5otBV9wOeuyUA6+MSaIQy+rAlNaMax+iN8MhoiGlsN0K4bAq+T5PLEA md4JjYTIIiA+we8uJ/wumyIESQV98zPNetpuisM7uQnUF6Qh8ph4r5Elqn3LTXvSgmRY 6/D+AS8wYFHzs/lEaro7d0e16MlasNX3NHabQ3YKHmn/pBJq1EVxuSSQGLSZlONcS6Vc acLFdidMsTXayMTrn2ReokerfoTcbw+AET+dxATBB8fL37i0QinRiz80QF7jcek16u/l 0aRll+RcOfkgnSl2IDfpXOhS7hPMitqNKTOK+eBjz7/ljFWJMELwhqY1ZxPfyMtTSOAP HSfQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f5si4933066pgq.806.2018.02.25.19.25.53; Sun, 25 Feb 2018 19:26:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752363AbeBZDYF (ORCPT + 99 others); Sun, 25 Feb 2018 22:24:05 -0500 Received: from g4t3425.houston.hpe.com ([15.241.140.78]:3742 "EHLO g4t3425.houston.hpe.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751958AbeBZDWf (ORCPT ); Sun, 25 Feb 2018 22:22:35 -0500 Received: from g9t2301.houston.hpecorp.net (g9t2301.houston.hpecorp.net [16.220.97.129]) by g4t3425.houston.hpe.com (Postfix) with ESMTP id 405E99A; Mon, 26 Feb 2018 03:22:34 +0000 (UTC) Received: from anatevka.ftc.rdlabs.hpecorp.net (anatevka.americas.hpqcorp.net [10.34.81.6]) by g9t2301.houston.hpecorp.net (Postfix) with ESMTP id BF8704E; Mon, 26 Feb 2018 03:22:33 +0000 (UTC) From: Jerry Hoemann To: wim@linux-watchdog.org, linux@roeck-us.net Cc: linux-watchdog@vger.kernel.org, linux-kernel@vger.kernel.org, rwright@hpe.com, maurice.a.saldivar@hpe.com, mingo@kernel.org, marcus.folkesson@gmail.com, Jerry Hoemann Subject: [PATCH v5 5/9] watchdog/hpwdt: condition early return of NMI handler on iLO5 Date: Sun, 25 Feb 2018 20:22:23 -0700 Message-Id: <20180226032227.14615-6-jerry.hoemann@hpe.com> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20180226032227.14615-1-jerry.hoemann@hpe.com> References: <20180226032227.14615-1-jerry.hoemann@hpe.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Modify prior change to not claim an NMI unless originated from iLO to apply only to iLO5 and later going forward. This restores hpwdt traditional behavior of calling panic if the NMI is NMI_IO_CHECK, NMI_SERR, or NMI_UNKNOWN for legacy hardware. Signed-off-by: Jerry Hoemann --- drivers/watchdog/hpwdt.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/watchdog/hpwdt.c b/drivers/watchdog/hpwdt.c index 0e35bb735d8e..171d5033d7b5 100644 --- a/drivers/watchdog/hpwdt.c +++ b/drivers/watchdog/hpwdt.c @@ -32,6 +32,7 @@ #define HPWDT_MAX_TIMER TICKS_TO_SECS(65535) #define DEFAULT_MARGIN 30 +static bool ilo5; static unsigned int soft_margin = DEFAULT_MARGIN; /* in seconds */ static unsigned int reload; /* the computed soft_margin */ static bool nowayout = WATCHDOG_NOWAYOUT; @@ -120,7 +121,7 @@ static int hpwdt_pretimeout(unsigned int ulReason, struct pt_regs *regs) "3. OA Forward Progress Log\n" "4. iLO Event Log"; - if ((ulReason == NMI_UNKNOWN) && mynmi) + if (ilo5 && ulReason == NMI_UNKNOWN && mynmi) return NMI_DONE; if (allow_kdump) @@ -277,6 +278,9 @@ static int hpwdt_init_one(struct pci_dev *dev, ", timer margin: %d seconds (nowayout=%d).\n", HPWDT_VERSION, hpwdt_dev.timeout, nowayout); + if (dev->subsystem_vendor == PCI_VENDOR_ID_HP_3PAR) + ilo5 = true; + return 0; error_wd_register: -- 2.13.6