summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2015-02-05 16:33:09 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-03-18 16:56:40 +0100
commit533726f736c2c32956d78ad6f49ffaada110cbfd (patch)
tree816a5a24cdf390fe905324d5d70cde4251f349b7 /drivers
parent28ed20755897b3726f07a0418c3d2fe17b3e5c86 (diff)
downloadop-kernel-dev-533726f736c2c32956d78ad6f49ffaada110cbfd.zip
op-kernel-dev-533726f736c2c32956d78ad6f49ffaada110cbfd.tar.gz
ueagle-atm: Delete unnecessary checks before the function call "release_firmware"
The release_firmware() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/usb/atm/ueagle-atm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/atm/ueagle-atm.c b/drivers/usb/atm/ueagle-atm.c
index 5a45937..888998a 100644
--- a/drivers/usb/atm/ueagle-atm.c
+++ b/drivers/usb/atm/ueagle-atm.c
@@ -952,7 +952,7 @@ static void uea_load_page_e1(struct work_struct *work)
int i;
/* reload firmware when reboot start and it's loaded already */
- if (ovl == 0 && pageno == 0 && sc->dsp_firm) {
+ if (ovl == 0 && pageno == 0) {
release_firmware(sc->dsp_firm);
sc->dsp_firm = NULL;
}
@@ -1074,7 +1074,7 @@ static void uea_load_page_e4(struct work_struct *work)
uea_dbg(INS_TO_USBDEV(sc), "sending DSP page %u\n", pageno);
/* reload firmware when reboot start and it's loaded already */
- if (pageno == 0 && sc->dsp_firm) {
+ if (pageno == 0) {
release_firmware(sc->dsp_firm);
sc->dsp_firm = NULL;
}
OpenPOWER on IntegriCloud