Commit 651d4bc7 authored by Devendra Naga's avatar Devendra Naga Committed by Greg Kroah-Hartman

staging: slicoss: return early before calling request_firmware with empty firmware filename

when the device id doesn't match in slic_card_download_gbrcv the filename is "",
i.e an empty name, and we try calling request_firmware with that name,
actually we can just fail out at default case before even calling request_firmware
Signed-off-by: default avatarDevendra Naga <devendra.aaru@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 623c2bb2
...@@ -514,8 +514,7 @@ static int slic_card_download_gbrcv(struct adapter *adapter) ...@@ -514,8 +514,7 @@ static int slic_card_download_gbrcv(struct adapter *adapter)
file = "slicoss/gbrcvucode.sys"; file = "slicoss/gbrcvucode.sys";
break; break;
default: default:
ASSERT(0); return -ENOENT;
break;
} }
ret = request_firmware(&fw, file, &adapter->pcidev->dev); ret = request_firmware(&fw, file, &adapter->pcidev->dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment