Received: by 10.213.65.68 with SMTP id h4csp447010imn; Tue, 13 Mar 2018 09:19:23 -0700 (PDT) X-Google-Smtp-Source: AG47ELuOujmJxPDBp+yVuIN2Z3rYQwdLIaUj3Ov3Pi0RsXPc/SXhVALG0zK8Wfw6fc7U9CFu3vxb X-Received: by 10.99.117.92 with SMTP id f28mr935719pgn.421.1520957963636; Tue, 13 Mar 2018 09:19:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1520957963; cv=none; d=google.com; s=arc-20160816; b=bDnJdx4vvAQnyo7c7+1S0DXCuntemZZ3yt1kI4QoWyKlZ4cBKeek8q6Sgdv5KwOOQ3 hgcCatLX4vmfHk2YySgOG0gG1pI4I5iYcFQcxuQJROz/d8Kf+QinAJsghu0hj7PMHNt+ igfMlWt9117S5LCgSgnaC21mU/57zEw8jM1xI7lwatcIty4YtBiDnQ6vXbPUCV+yZlaj kFsi61ufupJfH32tq4ilRLodmCS78aTEyA9PHXoKvW2op+KWjqsrln2jTKsKrUZ8Jw2B WxQpDWjS6eqNRLG/wJIZyGdoJxfT2YZ8vLku/4TB9iuFA39sNrF0mDlcahFVUZN3435f SgOw== 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=CCqHFv6ac79hnf8yC3c+OQiixSK9VYGpKFdXEv4DFN8=; b=0g5IVUYdeltb1Xl8RNg9CMHQgUTZ59X1BTCFj/mXETyTM0lGLC3mHtHuT6V7bUwSVP Bh0+Nau8N3s99bMNS/i6dagdbmXC/8/g+AMOL+HKqcQcHYrCO2FZd+gjtb/Tk4GZ5B3i uI79cWFHFkCHJ3Ue8Be9uNIVdUDJaPkYBivy8TJZ+5h5JIm6iPegGYeIVgY2lt8cOSEK wcz66krDrrm7J1Q6BvkJ1w4u/yvqS1IjpXAx9rnG/ALmnpT+hKtAP8ilQextu+36YQJO yAQd3MAJ+ajpjE3uQfyg5DT8xjhS9qDKBNURBxw3YVL+/PuEvgjFVIBcc803FedFPUNo bWgg== 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 q18si342192pfd.194.2018.03.13.09.19.08; Tue, 13 Mar 2018 09:19:23 -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 S933908AbeCMPfG (ORCPT + 99 others); Tue, 13 Mar 2018 11:35:06 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:33038 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933840AbeCMPfE (ORCPT ); Tue, 13 Mar 2018 11:35:04 -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 6AFE810AE; Tue, 13 Mar 2018 15:35:03 +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.14 004/140] watchdog: hpwdt: fix unused variable warning Date: Tue, 13 Mar 2018 16:23:27 +0100 Message-Id: <20180313152458.475865971@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180313152458.201155692@linuxfoundation.org> References: <20180313152458.201155692@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.14-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 */