Commit 39af455d authored by Markus Elfring's avatar Markus Elfring Committed by David S. Miller

net: cassini: Deletion of an unnecessary check before the function call "vfree"

The vfree() function performs also input parameter validation.
Thus the test around the call is not needed.

This issue was detected by using the Coccinelle software.
Signed-off-by: default avatarMarkus Elfring <elfring@users.sourceforge.net>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c4b2b9a8
...@@ -5179,8 +5179,7 @@ static void cas_remove_one(struct pci_dev *pdev) ...@@ -5179,8 +5179,7 @@ static void cas_remove_one(struct pci_dev *pdev)
cp = netdev_priv(dev); cp = netdev_priv(dev);
unregister_netdev(dev); unregister_netdev(dev);
if (cp->fw_data) vfree(cp->fw_data);
vfree(cp->fw_data);
mutex_lock(&cp->pm_mutex); mutex_lock(&cp->pm_mutex);
cancel_work_sync(&cp->reset_task); cancel_work_sync(&cp->reset_task);
......
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