Commit b7af4e6c authored by Bhaktipriya Shridhar's avatar Bhaktipriya Shridhar Committed by Greg Kroah-Hartman

staging: rtl8712: os_intfs: Change form of NULL comparisons

Change null comparisons of the form x == NULL to !x.
This was done using Coccinelle.
@@ expression e;
@@
- e == NULL
+ !e
Signed-off-by: default avatarBhaktipriya Shridhar <bhaktipriya96@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d08073d9
...@@ -389,7 +389,7 @@ static int netdev_open(struct net_device *pnetdev) ...@@ -389,7 +389,7 @@ static int netdev_open(struct net_device *pnetdev)
padapter->bup = true; padapter->bup = true;
if (rtl871x_hal_init(padapter) != _SUCCESS) if (rtl871x_hal_init(padapter) != _SUCCESS)
goto netdev_open_error; goto netdev_open_error;
if (r8712_initmac == NULL) if (!r8712_initmac)
/* Use the mac address stored in the Efuse */ /* Use the mac address stored in the Efuse */
memcpy(pnetdev->dev_addr, memcpy(pnetdev->dev_addr,
padapter->eeprompriv.mac_addr, ETH_ALEN); padapter->eeprompriv.mac_addr, ETH_ALEN);
...@@ -413,7 +413,7 @@ static int netdev_open(struct net_device *pnetdev) ...@@ -413,7 +413,7 @@ static int netdev_open(struct net_device *pnetdev)
} }
if (start_drv_threads(padapter) != _SUCCESS) if (start_drv_threads(padapter) != _SUCCESS)
goto netdev_open_error; goto netdev_open_error;
if (padapter->dvobjpriv.inirp_init == NULL) if (!padapter->dvobjpriv.inirp_init)
goto netdev_open_error; goto netdev_open_error;
else else
padapter->dvobjpriv.inirp_init(padapter); padapter->dvobjpriv.inirp_init(padapter);
......
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