]> git.karo-electronics.de Git - linux-beck.git/commitdiff
iwlwifi: use reset to set transport header
authorZhang Shengju <zhangshengju@cmss.chinamobile.com>
Fri, 2 Dec 2016 01:51:06 +0000 (09:51 +0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 3 Dec 2016 20:49:16 +0000 (15:49 -0500)
Since offset is zero, it's not necessary to use set function. Reset
function is straightforward, and will remove the unnecessary add
operation in set function.

Signed-off-by: Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/wireless/intel/iwlwifi/pcie/tx.c

index 5f840f16f40bd955478196397f8dcff481e88077..e44e5adc2b95871ed300df60ae71b7d98a1c9f4c 100644 (file)
@@ -2196,7 +2196,7 @@ static int iwl_fill_data_tbs_amsdu(struct iwl_trans *trans, struct sk_buff *skb,
 
                        memcpy(skb_put(csum_skb, tcp_hdrlen(skb)),
                               tcph, tcp_hdrlen(skb));
-                       skb_set_transport_header(csum_skb, 0);
+                       skb_reset_transport_header(csum_skb);
                        csum_skb->csum_start =
                                (unsigned char *)tcp_hdr(csum_skb) -
                                                 csum_skb->head;