* [patch] tokenring: remove unneeded NULL checks
@ 2010-08-19 10:04 Dan Carpenter
2010-08-22 7:54 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2010-08-19 10:04 UTC (permalink / raw)
To: netdev; +Cc: David S. Miller, kernel-janitors
"fw_entry" is always non-NULL at this point and anyway
release_firmware() handles NULL parameters.
Signed-off-by: Dan Carpenter <error27@gmail.com>
diff --git a/drivers/net/tokenring/tms380tr.c b/drivers/net/tokenring/tms380tr.c
index 435ef7d..08182fd 100644
--- a/drivers/net/tokenring/tms380tr.c
+++ b/drivers/net/tokenring/tms380tr.c
@@ -1321,14 +1321,12 @@ static int tms380tr_reset_adapter(struct net_device *dev)
/* Clear CPHALT and start BUD */
SIFWRITEW(c, SIFACL);
- if (fw_entry)
- release_firmware(fw_entry);
+ release_firmware(fw_entry);
return (1);
}
} while(count == 0);
- if (fw_entry)
- release_firmware(fw_entry);
+ release_firmware(fw_entry);
printk(KERN_INFO "%s: Adapter Download Failed\n", dev->name);
return (-1);
}
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [patch] tokenring: remove unneeded NULL checks
2010-08-19 10:04 [patch] tokenring: remove unneeded NULL checks Dan Carpenter
@ 2010-08-22 7:54 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2010-08-22 7:54 UTC (permalink / raw)
To: error27; +Cc: netdev, kernel-janitors
From: Dan Carpenter <error27@gmail.com>
Date: Thu, 19 Aug 2010 12:04:38 +0200
> "fw_entry" is always non-NULL at this point and anyway
> release_firmware() handles NULL parameters.
>
> Signed-off-by: Dan Carpenter <error27@gmail.com>
Applied, thanks Dan.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-08-22 8:01 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-19 10:04 [patch] tokenring: remove unneeded NULL checks Dan Carpenter
2010-08-22 7:54 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).