summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorShyam Saini <mayhs11saini@gmail.com>2017-01-15 18:21:46 +0530
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-01-16 18:08:57 +0100
commit686ef485d5a3ec735b60b35d31133692bfe98223 (patch)
treecc760bdc93bd8d291e9c1b083fe26a0c93fe61a4
parent679da8ac44772d70fabf257270a0757efdb1a492 (diff)
downloadblackbird-op-linux-686ef485d5a3ec735b60b35d31133692bfe98223.tar.gz
blackbird-op-linux-686ef485d5a3ec735b60b35d31133692bfe98223.zip
staging: rtl8192e: rtl8192e: Remove NULL test before vfree
vfree frees the virtually continuous block of memory beginning at addr. If addr is NULL, no operation is performed. So, NULL test is not needed before vfree. Signed-off-by: Shyam Saini <mayhs11saini@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/staging/rtl8192e/rtl8192e/rtl_core.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
index 2e05ec92ae20..4c0caa6701a9 100644
--- a/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
+++ b/drivers/staging/rtl8192e/rtl8192e/rtl_core.c
@@ -2695,10 +2695,8 @@ static void _rtl92e_pci_disconnect(struct pci_dev *pdev)
priv->polling_timer_on = 0;
_rtl92e_down(dev, true);
rtl92e_dm_deinit(dev);
- if (priv->pFirmware) {
- vfree(priv->pFirmware);
- priv->pFirmware = NULL;
- }
+ vfree(priv->pFirmware);
+ priv->pFirmware = NULL;
_rtl92e_free_rx_ring(dev);
for (i = 0; i < MAX_TX_QUEUE_COUNT; i++)
_rtl92e_free_tx_ring(dev, i);
OpenPOWER on IntegriCloud