summaryrefslogtreecommitdiff
path: root/drivers/staging/rtl8723au
diff options
context:
space:
mode:
authorBhumika Goyal <bhumirks@gmail.com>2016-02-28 20:25:29 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2016-03-12 09:09:09 +0300
commitc15cc49810fe2547cbf3ac58f6939f0f69a6c1c5 (patch)
tree7e66582e51d8dff9ce217a1904d9d2b7ba2a9429 /drivers/staging/rtl8723au
parentb32f6fdc9b82296c22d0bd0896f11643fb3e0cd5 (diff)
downloadlinux-c15cc49810fe2547cbf3ac58f6939f0f69a6c1c5.tar.xz
Staging: rtl8723au: Remove print statements and debug messages
The memory allocation functions generates a call stack containing all the context information on failure, so print statements and debug messages can be removed on failure of these functions. Also remove unwanted {} around if block after removal of these messages. Done using coccinelle: @@ expression e; @@ e=\(kmalloc\|kmalloc\|kmalloc_array\|alloc_netdev\|kzalloc\| devm_kzalloc\|devm_ioremap\)(...); ... if(!e){ - \(DBG_8723A\|printk\|pr_err\|CERROR\|DBG_88E\)(...); ...when any } Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/rtl8723au')
-rw-r--r--drivers/staging/rtl8723au/hal/usb_ops_linux.c6
-rw-r--r--drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c3
2 files changed, 1 insertions, 8 deletions
diff --git a/drivers/staging/rtl8723au/hal/usb_ops_linux.c b/drivers/staging/rtl8723au/hal/usb_ops_linux.c
index 371e6b373420..5c81ff48252e 100644
--- a/drivers/staging/rtl8723au/hal/usb_ops_linux.c
+++ b/drivers/staging/rtl8723au/hal/usb_ops_linux.c
@@ -256,12 +256,8 @@ static void usb_read_interrupt_complete(struct urb *purb)
c2w = kmalloc(sizeof(struct evt_work),
GFP_ATOMIC);
- if (!c2w) {
- printk(KERN_WARNING "%s: unable to "
- "allocate work buffer\n",
- __func__);
+ if (!c2w)
goto urb_submit;
- }
c2w->adapter = padapter;
INIT_WORK(&c2w->work, rtw_evt_work);
diff --git a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
index e64b7e14341e..12d18440e824 100644
--- a/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
+++ b/drivers/staging/rtl8723au/os_dep/ioctl_cfg80211.c
@@ -2610,8 +2610,6 @@ static int rtw_cfg80211_add_monitor_if(struct rtw_adapter *padapter, char *name,
/* wdev */
mon_wdev = kzalloc(sizeof(struct wireless_dev), GFP_KERNEL);
if (!mon_wdev) {
- DBG_8723A("%s(%s): allocate mon_wdev fail\n", __func__,
- padapter->pnetdev->name);
ret = -ENOMEM;
goto out;
}
@@ -3262,7 +3260,6 @@ int rtw_wdev_alloc(struct rtw_adapter *padapter, struct device *dev)
/* wdev */
wdev = kzalloc(sizeof(struct wireless_dev), GFP_KERNEL);
if (!wdev) {
- DBG_8723A("Couldn't allocate wireless device\n");
ret = -ENOMEM;
goto free_wiphy;
}