From patchwork Mon Jul 8 12:38:17 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 168620 Delivered-To: patch@linaro.org Received: by 2002:a92:4782:0:0:0:0:0 with SMTP id e2csp7110353ilk; Mon, 8 Jul 2019 05:38:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqwDblEOsbv8Dg0etW9/iAj2l2CGQguO02zBryG7tvx1f22ZL6gTvkcS5c+BB/3OgNe9NRp/ X-Received: by 2002:a17:90a:b387:: with SMTP id e7mr25945405pjr.113.1562589533364; Mon, 08 Jul 2019 05:38:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1562589533; cv=none; d=google.com; s=arc-20160816; b=E69az/jpJC+3i2lxlsoD/4Wx5oIiRCTkEDVJuQAHj+tQ60UrSSl0EIFbGL+3Cnk76j sFYdXyN1JPE17025NjGMFdeRWIo+1b94dWadD8OFVcvy6icgfUYWd9Mdz5spNDaAnLCK OEVRxEHm88szanW+iCbfrh8zo1uGJfenl34REQGvqdHpP9WgGlSo8tykZ5b+pXozIo8D QyIdZjRFPp3QD3Plq0ZjRLDPAq8dRyqpqL76YSrf39ezaM0hUR8nQFcsFtJpPlNgCR/m ascxz9ybKhRLz3FHV0xZqD5ZUYbjnPAQWo2/2ZjE2fJK2NLu5z00WiWnYkc+DrOCgFJe j6gA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=vHu80zeZ3Y4EWXIa1lNYzSy/4zmY02F15HXP920WWz8=; b=JjPNWAwN+i1j9DyBC5rJU+vcijy/soJt2rFKkgx+XsXjpuch8YuTi6cqoApXW77Hcg cl4TAkS1BJYmSdN7+ELYzbBrHWHoOUKQgHJMmKah/3anY/zGPrW1jXP+liatiOXWny8f 86hflkNjBCWhbg6fhrxlZvCq6ayrfzTAGS7olQvkwpdhacVxXDIdDXj7TcWv2BiwqZAJ sMrM6qMQNlPPvRX6/u2R7zGnyC9LBYTa+yBqvHLonMxHAhz/vq/w0UCFdHo9HOZe0DVP DA/w2TaU1Aw4ZouT85HDOPlE1f/7NOFoYL64yzM+27s6bpJvlkB4C8CrgnIwySub7cRh 8MMg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-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 q7si14597151pgk.456.2019.07.08.05.38.53; Mon, 08 Jul 2019 05:38:53 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-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-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729605AbfGHMiw (ORCPT + 5 others); Mon, 8 Jul 2019 08:38:52 -0400 Received: from mout.kundenserver.de ([212.227.126.130]:49197 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727544AbfGHMiw (ORCPT ); Mon, 8 Jul 2019 08:38:52 -0400 Received: from threadripper.lan ([149.172.19.189]) by mrelayeu.kundenserver.de (mreue012 [212.227.15.129]) with ESMTPA (Nemesis) id 1MFsAJ-1hiUBN3Zux-00HNox; Mon, 08 Jul 2019 14:38:46 +0200 From: Arnd Bergmann To: Linus Walleij , Bartosz Golaszewski , Thierry Reding , Jonathan Hunter Cc: Arnd Bergmann , Dmitry Osipenko , linux-gpio@vger.kernel.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] gpio: tegra: fix debugfs compile error Date: Mon, 8 Jul 2019 14:38:17 +0200 Message-Id: <20190708123843.3302581-1-arnd@arndb.de> X-Mailer: git-send-email 2.20.0 MIME-Version: 1.0 X-Provags-ID: V03:K1:MSFUKXJPI4w10gi5nIw9N7d6gTewK6MnUXHlro7LaCUr6eFZ32c CVfIwEp/Yeh2OhpLrwyRjgIVMO5VvpaD6HE4pdXXoesHctLKVesrcGNX3JbJ6V3xjVERn4J HOMNBm2NYE9hdU2W600TMEH9qHk6BmEGTny9CIIUUpNcQIOXNYjfwNPvwMo8T72gXkgDl7p /yuw1mdSJjFQ3zuMGWqxg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1; V03:K0:mtajkxsIi98=:gEYCd7m+A0QSVqeIysMG6+ I8KyaNRiW26n1eB4lByLWF3jJDDBdojMUsI8iWNqG5k14EE4JQjWZQ9EmVlVcvnxnQsxdZ2wu FNorKrqPUQugWbe/QePFvtdkYuJzJnmiermFLrmcVmerxfgluQ6TvLBO7XeOL5DU6O2bweKMt QjnyHD/caoKBS0idl3Fe7rNHZJYKjtR2HcRHwgcxK5sfDOVu/Uvy5gXv2OC2nDbXGTVDVfMjl kteR5fl9+Pg26kS94OxE1Yte7HjN8fE1kOJyci1ZeLyLqWBFnVnIbcFtSRvxGPvdomm8bsNqT wKFkMIb8fsu33boEPOKVabhv8CtTpCjeTZNzFYlKs9uov/q36g1sh1jBrmIA9a/Zv7fjPZBvZ HZFjfgvLkKXmM46gLB5MnHr5k580PHUxeXC/JU2fEQ9EeeA4qO9KOUjAgaFRdUzsM1Kpq/il+ iYJ/k+CTAWbS+rJ4tnFbvJjjpZk4JdGgJArWxWyTmDObvIKiQQ7jgUxD66jei+D7mNDP/fIcU Z+l8SVz/wzV26Swqw4hjwH1DNYpWoIf4DSXwnyfq3lg7Bn1XmOJt8taMG/LWZkbmq7Mmk5Bkh WeThMPl4iiExHOuV9hjB40mqH9kmJD074vp6D7VltBZ8CEm41qR1G2Tn+xKT6c1uaCC4f11dN A87qC0mjojL7s73TRNLtqdfDs9KS3d4DAYrnGRrynd+FV0Fp7lVjyNe0lMx1jMBl4hVtl6B+N e9g0ypuomU8RZxnrqaMknmUTJbgRJaGrglSwwQ== Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org Without this header, some configurations now run into a build failure: drivers/gpio/gpio-tegra.c:665:2: error: implicit declaration of function 'debugfs_create_file' [-Werror,-Wimplicit-function-declaration] debugfs_create_file("tegra_gpio", 0444, NULL, tgi, ^ drivers/gpio/gpio-tegra.c:665:2: error: this function declaration is not a prototype [-Werror,-Wstrict-prototypes] drivers/gpio/gpio-tegra.c:666:9: error: use of undeclared identifier 'tegra_dbg_gpio_fops' Remove the #ifdef here and let the compiler drop the unused functions itself when debugfs_create_file() is an empty inline function. Fixes: a4de43049a1d ("gpio: tegra: Clean-up debugfs initialisation") Signed-off-by: Arnd Bergmann --- drivers/gpio/gpio-tegra.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) -- 2.20.0 diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c index 59b99d8c3647..dbcecbe5f52f 100644 --- a/drivers/gpio/gpio-tegra.c +++ b/drivers/gpio/gpio-tegra.c @@ -9,6 +9,7 @@ * Erik Gilling */ +#include #include #include #include @@ -22,6 +23,7 @@ #include #include #include +#include #define GPIO_BANK(x) ((x) >> 5) #define GPIO_PORT(x) (((x) >> 3) & 0x3) @@ -508,10 +510,6 @@ static int tegra_gpio_irq_set_wake(struct irq_data *d, unsigned int enable) } #endif -#ifdef CONFIG_DEBUG_FS - -#include -#include static int tegra_dbg_gpio_show(struct seq_file *s, void *unused) { @@ -538,7 +536,6 @@ static int tegra_dbg_gpio_show(struct seq_file *s, void *unused) } DEFINE_SHOW_ATTRIBUTE(tegra_dbg_gpio); -#endif static const struct dev_pm_ops tegra_gpio_pm_ops = { SET_SYSTEM_SLEEP_PM_OPS(tegra_gpio_suspend, tegra_gpio_resume)