From patchwork Tue Jun 20 20:48:44 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 106026 Delivered-To: patch@linaro.org Received: by 10.182.29.35 with SMTP id g3csp1508121obh; Tue, 20 Jun 2017 13:49:16 -0700 (PDT) X-Received: by 10.98.156.131 with SMTP id u3mr32754405pfk.16.1497991756606; Tue, 20 Jun 2017 13:49:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1497991756; cv=none; d=google.com; s=arc-20160816; b=d3+eTs1UcZyleZm5y/xeXcB4GGoxIu5TVPRF3Ck1Qo4o1SDcYan5Gq3GIfH0fEh4EY 6lwxCamPE41DXEuOId4LMs0i6/Uo0cCi+9JPHEyWl9oolKFolzz6jo4neVks2tQ9qOJy CfM0Ga2f8uL4wA4QGEmy+I+ds0usZKpUiCPh5a6vU3szF7POATUZGtPGsSs8o3qe3HYk HykNphQjkH9jWbT8eHZwYJ5hgORL1I9LoehWhB+H54KBWMZoafqdLAn+u/4laUd0TfQN jLvpWTKy3LAUDUjZax+Aa6xDUiCKNMBwt2SwoTeyTlUOffRDNKiZPHPU1PtNjw2RAw+f 7ufg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :arc-authentication-results; bh=7H2YzoEwoWop8SJJ+tRrlEvmIjiDXbLh+3NVIQGkoEM=; b=rb+W2VKEJxBq2AUo9JdgtG26+JpYPqFVMVoPOEdY3YXEI7ohIGUpIT9b0u/HdWMtT9 vzIXPhKxqSThwKB0rsuF4ZKNcmCofynwsjH0qyivR5aUK0xxJU08cM6m6UdnklojT7l9 oUaGI4fy7MGStoZZ0gUQj1vUVYVKlD8jSYqLe5iwfl5sTqMgDvgdvvdM81D52/bm+zCr 2SOOqpy+Jo5o1Q7JWDXyAunmSJHgXhhJnJT5VwyhyhFZSmwt8cGmNnrWzOlkSdBaLmfJ 0hUPWZHbsV44ryXQN7ZPq1uBgbkBb3q2HgLlZ4Uj34m8FTcuwYAu6W8Nsl0Ua8CaL2Dm mfzw== 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 k6si11754223pgs.523.2017.06.20.13.49.16; Tue, 20 Jun 2017 13:49:16 -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 S1752528AbdFTUtO (ORCPT + 25 others); Tue, 20 Jun 2017 16:49:14 -0400 Received: from mout.kundenserver.de ([212.227.17.10]:59512 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751090AbdFTUtN (ORCPT ); Tue, 20 Jun 2017 16:49:13 -0400 Received: from wuerfel.lan ([5.56.224.194]) by mrelayeu.kundenserver.de (mreue103 [212.227.15.145]) with ESMTPA (Nemesis) id 0MVasZ-1dIJHT1i7b-00YvGY; Tue, 20 Jun 2017 22:48:56 +0200 From: Arnd Bergmann To: Andrew Morton Cc: Arnd Bergmann , Don Zickus , Ingo Molnar , Babu Moger , Nicholas Piggin , Konstantin Khlebnikov , linux-kernel@vger.kernel.org Subject: [PATCH] kernel/watchdog: hide unused function Date: Tue, 20 Jun 2017 22:48:44 +0200 Message-Id: <20170620204854.966601-1-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 X-Provags-ID: V03:K0:bPb8430Cne7J3I/j1EkZPp43P5m14MA1l6yD5dzJOZh3D6apX1F /ZICs+HV03+7Mp7ElUFJw5RDDyoSUrmgeEmI4a9JXV3bXNTtbCim1d70tQ8s1NC5acDDHmr 2S3fClGksLC058nFdgBG+AV7jzTRZhOTOo6dbehtkAIvZk+GzH+il+Gqm9U3BSBEJ+rrRqL fvK2YfpsCS7aIFOHRzQZg== X-UI-Out-Filterresults: notjunk:1; V01:K0:8Ay9HAQWDcg=:3+n9cfaCa4m1sT6GndT6oq JWniLId0UDuoFpwMW0FY0TS6rNd1RPhmQR+HBF61nUTZxq+6p3mnNy23qHwjiLijPxgIPoiK4 HSzbyzKkiecmd9IcJD1ph2mI2w58swtaHjLaHG4Wf2XVJbDot8xi1LoixYdc5Yv1CqEYS+Zmd UlTfua4ILWNQoXsjEPFGJIFUf3Ca0lFeA2rTYqThRsANWr4p1nR8v0ycmtmKDI19OYV93bn7C Wn/xPiLIedxBnt+06Q5OdNbH41musLccB7Zvaf3lU8NbCdtfUAAg901ubLYM5BvG1p0+LOCGh EBUWW9KyiKj2x4Sgzao3HtC8JuP0slLM28XUwF1nPBu8jVc+fG10RWJXs/qd4fs0rHT/BfaB+ iyzFTVVSnMX1g7qw0FlzRHb9Yctauk1gAiuyQUx5tGkqaurQeS4do1JmVMOmeQxCYheRybd6m HNp5f3ZYfcR20reMvKpKa/Gn7xldGmQbSWwDXACIZMetxPHRYH9yAoFPnr8LiCi/WEiocouAV 6OyblZMxEFrwUQMoAaP466SwDxf8uj+KaCxaKkudNgipp0VwfQoMk1uSPyTr3getlwRG+kqXo upiwhRchSGWbu6D1IiY4qt8XWSvi0vVUtynwuF5hZg8A1+1xc95P2BPTeu8XgX2d6K5/x0GkV PqgrXzq2VczJEvkhhZXc4ErYj3T9Mb6Iq0NvI6xtjsUv/H9MsNxlDOHjP1DrRZAO8974= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org watchdog_update_cpus() is defined unconditionally, but only used when CONFIG_SYSCTL is defined: kernel/watchdog.c:608:12: error: 'watchdog_update_cpus' defined but not used [-Werror=unused-function] This adds another #ifdef around it. Fixes: mmotm ("kernel/watchdog: provide watchdog_nmi_reconfigure() for arch watchdogs") Signed-off-by: Arnd Bergmann --- kernel/watchdog.c | 4 ++++ 1 file changed, 4 insertions(+) -- 2.9.0 Acked-by: Don Zickus diff --git a/kernel/watchdog.c b/kernel/watchdog.c index 06cd965f64d2..95361f9f3f40 100644 --- a/kernel/watchdog.c +++ b/kernel/watchdog.c @@ -605,11 +605,13 @@ static void watchdog_disable_all_cpus(void) } } +#ifdef CONFIG_SYSCTL static int watchdog_update_cpus(void) { return smpboot_update_cpumask_percpu_thread( &watchdog_threads, &watchdog_cpumask); } +#endif #else /* SOFTLOCKUP */ static int watchdog_park_threads(void) @@ -630,10 +632,12 @@ static void watchdog_disable_all_cpus(void) { } +#ifdef CONFIG_SYSCTL static int watchdog_update_cpus(void) { return 0; } +#endif static void set_sample_period(void) {