Received: by 10.213.65.68 with SMTP id h4csp510975imn; Fri, 16 Mar 2018 09:59:23 -0700 (PDT) X-Google-Smtp-Source: AG47ELvL6cU8EtebnUOghDAI/Cn1O0mbe1ZvL8Q54MZVRA0M65cTOoLxRvHze9C7lH7lHzVoDxdQ X-Received: by 10.101.97.139 with SMTP id c11mr1976201pgv.435.1521219563558; Fri, 16 Mar 2018 09:59:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521219563; cv=none; d=google.com; s=arc-20160816; b=ijn2urbuPnx6fypivKscOkG3MsyyPbJH5OrPs2dI1k1bOavmyup65QdwPZON2SRiAP EQIe70r3gz5qlV6lYVoZIjx6uCs8wmqhTtsk1k3FiTeFX/Bi/SKjf7xht9JQJ98Now0B qszK6kHxEJT2UKx0zEgEeNL0PaQeyyWHyYDRwGGvyl9LSEiTZZS5VEojqO/BQpxiTma1 1yuTVjVN9YZTh4l+1xf//2GRsXmto2Lz9QIXBHm0Za+ZbEQz4FXd+Rdr5ua80h/CuxPN HOMpCP2GzTi2LBCdc8yw0OpxAtnIGnnz0B692R/oZ8lT1CW19QjygrfOUd21FKe8tE6Y SkLA== 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=EPy6aBtOYfqDhw/JzAppY9imvH5x12hz0EAXYAn3sPw=; b=hd+N20dMTPaJjwdNblbTOVaRCcEWbrwRO8tSdbD5IgtxcapbaCDMFU/hsGo9hxXHqm DOd5yTdfZYWI94rqWe83IwdKc9suS06q9NE93ZD4w7/C3ce379w4hsXPTeKXS2i6Jchm rxiKH2pGYGsnCea7/gsTXxAHD7oKVriihTFlIlaooabeTctB/1hrPHM3d0TaF4c7r0o3 zmzsriyBFVVrw3RfypZVoTwg5oMRQ4d51tBQCxM5yMAvcND3qNRDZMtI3BbM2MxqYi/8 nOf+yNghL6pnmz2aFRilPWu9tytjHoFO9z2fzpPatVvwFbjM7jq3wwhHv2vUcku2W7EI q67g== 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 t10-v6si1996352plq.531.2018.03.16.09.59.09; Fri, 16 Mar 2018 09:59: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 S1753586AbeCPQ44 (ORCPT + 99 others); Fri, 16 Mar 2018 12:56:56 -0400 Received: from mail.linuxfoundation.org ([140.211.169.12]:39026 "EHLO mail.linuxfoundation.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933773AbeCPPdc (ORCPT ); Fri, 16 Mar 2018 11:33:32 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id 63FFCD1D; Fri, 16 Mar 2018 15:33:31 +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.9 49/86] watchdog: hpwdt: fix unused variable warning Date: Fri, 16 Mar 2018 16:23:12 +0100 Message-Id: <20180316152320.712143050@linuxfoundation.org> X-Mailer: git-send-email 2.16.2 In-Reply-To: <20180316152317.167709497@linuxfoundation.org> References: <20180316152317.167709497@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.9-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 */