Commit b38e9030 authored by Leo Kim's avatar Leo Kim Committed by Greg Kroah-Hartman
Browse files

staging: wilc1000: fixes a struct allocation to match coding standards



This patch fixes the checks reported by checkpatch.pl
for prefer kmalloc(sizeof(*tx_data)...) over kmalloc(sizeof(struct tx_complete_data)...)

Signed-off-by: default avatarLeo Kim <leo.kim@atmel.com>
Signed-off-by: default avatarGlen Lee <glen.lee@atmel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 83231b72
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1236,7 +1236,7 @@ int mac_xmit(struct sk_buff *skb, struct net_device *ndev)
		return 0;
	}

	tx_data = kmalloc(sizeof(struct tx_complete_data), GFP_ATOMIC);
	tx_data = kmalloc(sizeof(*tx_data), GFP_ATOMIC);
	if (!tx_data) {
		PRINT_ER("Failed to allocate memory for tx_data structure\n");
		dev_kfree_skb(skb);