tokenring: remove unneeded NULL checks
authorDan Carpenter <error27@gmail.com>
Sun, 22 Aug 2010 07:54:30 +0000 (00:54 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sun, 22 Aug 2010 07:54:30 +0000 (00:54 -0700)
"fw_entry" is always non-NULL at this point and anyway
release_firmware() handles NULL parameters.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/tokenring/tms380tr.c

index 435ef7d5470fd8e8e6c4849c1d3dc930a13e1b3f..08182fde3dcdd5684044c860cc564fd17f6497f2 100644 (file)
@@ -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);
 }