Skip to contentSkip to conversation

staging: gdm724x: Remove print following unsuccessful kmalloc

PATCH New Sanjana Sanikommu 1 participant 1 message Apr 2, 2019 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: gdm724x: Remove print following unsuccessful kmalloc

Challenge suggested by Coccinelle
Remove print statement following unsuccessful kmalloc when there is not enough memory. Kmalloc and variants normally produce a backtrace in such a case. Hence, a print statement is not necessary

---
 drivers/staging/gdm724x/gdm_lte.c | 1 -
 1 file changed, 1 deletion(-)
drivers/staging/gdm724x/gdm_lte.c +0 -1
index 3c2aab7a921e..db11498f6fc7 100644
@@ -871,7 +871,6 @@ int register_lte_device(struct phy_dev *phy_dev,
 		net = alloc_netdev(sizeof(struct nic), pdn_dev_name,
 				   NET_NAME_UNKNOWN, ether_setup);
 		if (!net) {
-			pr_err("alloc_netdev failed\n");
 			ret = -ENOMEM;
 			goto err;
 		}
Signature · 1 line
2.17.1