Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mac802154: cleanup in rx path

This patch replace the sizeof(struct rx_work) with sizeof(*work)
and directly passing the skb in mac802154_subif_rx()

Signed-off-by: Varka Bhadram <varkab@cdac.in>
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>

authored by

Varka Bhadram and committed by
Marcel Holtmann
24bbd44a 6f48e260

+2 -3
+2 -3
net/mac802154/rx.c
··· 86 86 static void mac802154_rx_worker(struct work_struct *work) 87 87 { 88 88 struct rx_work *rw = container_of(work, struct rx_work, work); 89 - struct sk_buff *skb = rw->skb; 90 89 91 - mac802154_subif_rx(rw->dev, skb, rw->lqi); 90 + mac802154_subif_rx(rw->dev, rw->skb, rw->lqi); 92 91 kfree(rw); 93 92 } 94 93 ··· 100 101 if (!skb) 101 102 return; 102 103 103 - work = kzalloc(sizeof(struct rx_work), GFP_ATOMIC); 104 + work = kzalloc(sizeof(*work), GFP_ATOMIC); 104 105 if (!work) 105 106 return; 106 107