Received: by 10.213.65.68 with SMTP id h4csp451811imn; Tue, 13 Mar 2018 09:28:56 -0700 (PDT) X-Google-Smtp-Source: AG47ELvqQ4ZahSJ4gcGlou7khyvJApW9uDVfNmFGi6/7D+yb1tqivdXhGSDo8QIVEsEuHqrVMYDf X-Received: by 10.98.79.90 with SMTP id d87mr1176774pfb.41.1520958536443; Tue, 13 Mar 2018 09:28:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520958536; cv=none; d=google.com; s=arc-20160816; b=zvun9T6MtKnciTali3waXP/WHhFs8lUI4vzDsA+wtUn9RCJSq6X0z/Kahp6a7ZHJiX R5CaPMnRvGIacad+5ffUlKR0KpMEI2uHOKmsU33wnsK8yHCCXiWJG81SzQu3gphMUYg9 PYs87lh9n8d/f2coUnoUqgK4CaYlDhx3Iiygwsk1VfzStfBFvzxhWzPd4Em1N+tBgtef suzoPXL46F5P7EcCi7iTkeCGdngYekuj3EvLa7tZbPYNXo0u3Yk1KhqYxRzjVlRs0omQ tMTopKxtttalw3XCCKHcxd8rFE1h4hB9Jr9qnnuJOcBeN3hLLH12L2CezOqnWDFTnk+M l5CQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from :arc-authentication-results; bh=rJa5enpvuauSh7Y6GKnJg9a8Ump+zcvo5n2lk3GBt8g=; b=vqW655lWU0xaYsJQce6k48wnuRFbEx8aQx9NcJJZxlhoguQpLKJGgSmrWCt1tdp4Zq 8PBWqhQM8iSjxpRPtIx/U1KpOec+YdhjNUyfnsEG4DLgvu6EBgjgVBluyH48xbpDxRP9 aGDHGsDHzmlvEoQ2SQ6esLqMB8iMq5QBnXU9l9sNtB5rv6fPM2+4ycmD//A/82mccOm2 yeeR7mig0l9Vpu2MvBTAFrTavHVR1VtROI2/T+cSkGSYOICFIConrpTTS+3MPh8xzYNp 2kp7kRuMg1XeXsRY3jZSGZovN3DrscL3fgN0v7L2MwA+0ElbXP1UUZyhe2lBps99FLjz IxhQ== 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 j17si275295pga.495.2018.03.13.09.28.42; Tue, 13 Mar 2018 09:28:56 -0700 (PDT) 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 S1753165AbeCMQ1P (ORCPT + 99 others); Tue, 13 Mar 2018 12:27:15 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:60830 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933608AbeCMPdq (ORCPT ); Tue, 13 Mar 2018 11:33:46 -0400 Received: from localhost (LFbn-1-12258-90.w90-92.abo.wanadoo.fr [90.92.71.90]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id ABB9BDE7; Tue, 13 Mar 2018 15:33:45 +0000 (UTC) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Arnd Bergmann , Jerry Hoemann , Guenter Roeck , Wim Van Sebroeck Subject: [PATCH 4.15 106/146] watchdog: hpwdt: fix unused variable warning Date: Tue, 13 Mar 2018 16:24:33 +0100 Message-Id: <20180313152328.603942038@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180313152320.439085687@linuxfoundation.org> References: <20180313152320.439085687@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Arnd Bergmann commit aeebc6ba88ba3758ad95467ff6191fabf2074c13 upstream. The new hpwdt_my_nmi() function is used conditionally, which produces a harmless warning in some configurations: drivers/watchdog/hpwdt.c:478:12: error: 'hpwdt_my_nmi' defined but not used [-Werror=unused-function] This moves it inside of the #ifdef that protects its caller, to silence the warning. Fixes: 621174a92851 ("watchdog: hpwdt: Check source of NMI") Signed-off-by: Arnd Bergmann Reviewed-by: Jerry Hoemann Reviewed-by: Guenter Roeck Signed-off-by: Guenter Roeck Signed-off-by: Wim Van Sebroeck Signed-off-by: Greg Kroah-Hartman --- drivers/watchdog/hpwdt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/watchdog/hpwdt.c +++ b/drivers/watchdog/hpwdt.c @@ -475,12 +475,12 @@ static int hpwdt_time_left(void) return TICKS_TO_SECS(ioread16(hpwdt_timer_reg)); } +#ifdef CONFIG_HPWDT_NMI_DECODING static int hpwdt_my_nmi(void) { return ioread8(hpwdt_nmistat) & 0x6; } -#ifdef CONFIG_HPWDT_NMI_DECODING /* * NMI Handler */