All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: bamv2005@gmail.com, linus.walleij@linaro.org, bgolaszewski@baylibre.com
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Thierry Reding <thierry.reding@gmail.com>,
	Jonathan Hunter <jonathanh@nvidia.com>,
	linux-gpio@vger.kernel.org, linux-tegra@vger.kernel.org
Subject: [PATCH 2/3] gpio: tegra:  no need to cast away return value of debugfs_create_file()
Date: Tue, 18 Jun 2019 17:50:46 +0200	[thread overview]
Message-ID: <20190618155047.16894-2-gregkh@linuxfoundation.org> (raw)
In-Reply-To: <20190618155047.16894-1-gregkh@linuxfoundation.org>

It is fine to ignore the return value (and encouraged), so need to cast
away the return value, you will not get a build warning at all.

Cc: Linus Walleij <linus.walleij@linaro.org>
Cc: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: Jonathan Hunter <jonathanh@nvidia.com>
Cc: linux-gpio@vger.kernel.org
Cc: linux-tegra@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 drivers/gpio/gpio-tegra.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c
index 6d9b6906b9d0..a54bba1bda6c 100644
--- a/drivers/gpio/gpio-tegra.c
+++ b/drivers/gpio/gpio-tegra.c
@@ -550,8 +550,8 @@ DEFINE_SHOW_ATTRIBUTE(tegra_dbg_gpio);
 
 static void tegra_gpio_debuginit(struct tegra_gpio_info *tgi)
 {
-	(void) debugfs_create_file("tegra_gpio", 0444,
-				   NULL, tgi, &tegra_dbg_gpio_fops);
+	debugfs_create_file("tegra_gpio", 0444, NULL, tgi,
+			    &tegra_dbg_gpio_fops);
 }
 
 #else
-- 
2.22.0


  reply	other threads:[~2019-06-18 15:51 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-18 15:50 [PATCH 1/3] gpiolib: no need to cast away return value of debugfs_create_file() Greg Kroah-Hartman
2019-06-18 15:50 ` Greg Kroah-Hartman [this message]
2019-06-18 16:26   ` [PATCH 2/3] gpio: tegra: " Jon Hunter
2019-06-18 17:17     ` Greg Kroah-Hartman
2019-06-18 17:49       ` Jon Hunter
2019-06-18 18:05         ` Greg Kroah-Hartman
2019-06-19  8:19   ` Thierry Reding
2019-06-25 12:45   ` Linus Walleij
2019-06-18 15:50 ` [PATCH 3/3] gpio: mockup: no need to check return value of debugfs_create functions Greg Kroah-Hartman
2019-06-20  7:25   ` [PATCH v2] " Greg Kroah-Hartman
2019-06-24  8:20     ` Bartosz Golaszewski
2019-06-25 12:29 ` [PATCH 1/3] gpiolib: no need to cast away return value of debugfs_create_file() Linus Walleij

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190618155047.16894-2-gregkh@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=bamv2005@gmail.com \
    --cc=bgolaszewski@baylibre.com \
    --cc=jonathanh@nvidia.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=thierry.reding@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.