public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH net-next] net: atm: Remove redundant check.
@ 2023-10-20 12:21 Gavrilov Ilia
  2023-10-23  7:50 ` patchwork-bot+netdevbpf
  0 siblings, 1 reply; 2+ messages in thread
From: Gavrilov Ilia @ 2023-10-20 12:21 UTC (permalink / raw)
  To: David S. Miller
  Cc: Eric Dumazet, Jakub Kicinski, Paolo Abeni, Greg Kroah-Hartman,
	Sebastian Reichel, Rafael J. Wysocki, Chas Williams,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	lvc-project@linuxtesting.org

Checking the 'adev' variable is unnecessary,
because 'cdev' has already been checked earlier.

Found by InfoTeCS on behalf of Linux Verification Center
(linuxtesting.org) with SVACE.

Fixes: 656d98b09d57 ("[ATM]: basic sysfs support for ATM devices")
Signed-off-by: Gavrilov Ilia <Ilia.Gavrilov@infotecs.ru>
---
 net/atm/atm_sysfs.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/net/atm/atm_sysfs.c b/net/atm/atm_sysfs.c
index 466353b3dde4..54e7fb1a4ee5 100644
--- a/net/atm/atm_sysfs.c
+++ b/net/atm/atm_sysfs.c
@@ -116,8 +116,6 @@ static int atm_uevent(const struct device *cdev, struct kobj_uevent_env *env)
 		return -ENODEV;
 
 	adev = to_atm_dev(cdev);
-	if (!adev)
-		return -ENODEV;
 
 	if (add_uevent_var(env, "NAME=%s%d", adev->type, adev->number))
 		return -ENOMEM;
-- 
2.39.2

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

* Re: [PATCH net-next] net: atm: Remove redundant check.
  2023-10-20 12:21 [PATCH net-next] net: atm: Remove redundant check Gavrilov Ilia
@ 2023-10-23  7:50 ` patchwork-bot+netdevbpf
  0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2023-10-23  7:50 UTC (permalink / raw)
  To: Gavrilov Ilia
  Cc: davem, edumazet, kuba, pabeni, gregkh, sre, rafael, chas, netdev,
	linux-kernel, lvc-project

Hello:

This patch was applied to netdev/net-next.git (main)
by David S. Miller <davem@davemloft.net>:

On Fri, 20 Oct 2023 12:21:16 +0000 you wrote:
> Checking the 'adev' variable is unnecessary,
> because 'cdev' has already been checked earlier.
> 
> Found by InfoTeCS on behalf of Linux Verification Center
> (linuxtesting.org) with SVACE.
> 
> Fixes: 656d98b09d57 ("[ATM]: basic sysfs support for ATM devices")
> Signed-off-by: Gavrilov Ilia <Ilia.Gavrilov@infotecs.ru>
> 
> [...]

Here is the summary with links:
  - [net-next] net: atm: Remove redundant check.
    https://git.kernel.org/netdev/net-next/c/92fc97ae9cfd

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



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

end of thread, other threads:[~2023-10-23  7:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-20 12:21 [PATCH net-next] net: atm: Remove redundant check Gavrilov Ilia
2023-10-23  7:50 ` patchwork-bot+netdevbpf

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