public inbox for linux-tegra@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] host1x: debugfs_create_dir() can never return NULL
@ 2019-06-13 11:45 Greg Kroah-Hartman
  2019-06-13 16:35 ` Thierry Reding
  0 siblings, 1 reply; 2+ messages in thread
From: Greg Kroah-Hartman @ 2019-06-13 11:45 UTC (permalink / raw)
  To: Thierry Reding; +Cc: linux-tegra, dri-devel

So there is no need to check for a value that can never happen.  No need
to check the return value all anyway, as any debugfs call can take the
result of this function as an option just fine.

Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: dri-devel@lists.freedesktop.org
Cc: linux-tegra@vger.kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 drivers/gpu/host1x/debug.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/drivers/gpu/host1x/debug.c b/drivers/gpu/host1x/debug.c
index 329e4a3d8ae7..6c5ee3e39dc6 100644
--- a/drivers/gpu/host1x/debug.c
+++ b/drivers/gpu/host1x/debug.c
@@ -171,9 +171,6 @@ static void host1x_debugfs_init(struct host1x *host1x)
 {
 	struct dentry *de = debugfs_create_dir("tegra-host1x", NULL);
 
-	if (!de)
-		return;
-
 	/* Store the created entry */
 	host1x->debugfs = de;
 
-- 
2.22.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] host1x: debugfs_create_dir() can never return NULL
  2019-06-13 11:45 [PATCH] host1x: debugfs_create_dir() can never return NULL Greg Kroah-Hartman
@ 2019-06-13 16:35 ` Thierry Reding
  0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2019-06-13 16:35 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-tegra, dri-devel


[-- Attachment #1.1: Type: text/plain, Size: 575 bytes --]

On Thu, Jun 13, 2019 at 01:45:22PM +0200, Greg Kroah-Hartman wrote:
> So there is no need to check for a value that can never happen.  No need
> to check the return value all anyway, as any debugfs call can take the
> result of this function as an option just fine.
> 
> Cc: Thierry Reding <thierry.reding@gmail.com>
> Cc: dri-devel@lists.freedesktop.org
> Cc: linux-tegra@vger.kernel.org
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> ---
>  drivers/gpu/host1x/debug.c | 3 ---
>  1 file changed, 3 deletions(-)

Applied, thanks.

Thierry

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

[-- Attachment #2: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-06-13 16:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-13 11:45 [PATCH] host1x: debugfs_create_dir() can never return NULL Greg Kroah-Hartman
2019-06-13 16:35 ` Thierry Reding

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox