net: qualcomm: rmnet: Remove redundant check when stamping map header
authorSubash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Sun, 7 Jan 2018 18:36:31 +0000 (11:36 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 8 Jan 2018 18:58:48 +0000 (13:58 -0500)
We already check the headroom once in rmnet_map_egress_handler(),
so this is not needed.

Signed-off-by: Subash Abhinov Kasiviswanathan <subashab@codeaurora.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qualcomm/rmnet/rmnet_map_data.c

index 86b8c758f94e1fb19cc7d56e52b6b59260ce8565..978ce2679b235f1c417ce3ad7d1f7efc3dc6b93b 100644 (file)
@@ -32,9 +32,6 @@ struct rmnet_map_header *rmnet_map_add_map_header(struct sk_buff *skb,
        u32 padding, map_datalen;
        u8 *padbytes;
 
-       if (skb_headroom(skb) < sizeof(struct rmnet_map_header))
-               return NULL;
-
        map_datalen = skb->len - hdrlen;
        map_header = (struct rmnet_map_header *)
                        skb_push(skb, sizeof(struct rmnet_map_header));