Skip to content

Commit

Permalink
vmxnet: trivial annotation of protocol constant
Browse files Browse the repository at this point in the history
Noticed by sparse:
drivers/net/vmxnet3/vmxnet3_drv.c:876:38: warning: cast from restricted __be16
drivers/net/vmxnet3/vmxnet3_drv.c:876:38: warning: cast from restricted __be16
drivers/net/vmxnet3/vmxnet3_drv.c:876:24: warning: restricted __be16 degrades to integer

Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Harvey Harrison authored and David S. Miller committed Oct 30, 2010
1 parent b8744ca commit 1b803fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/vmxnet3/vmxnet3_drv.c
Original file line number Diff line number Diff line change
Expand Up @@ -873,7 +873,7 @@ vmxnet3_tq_xmit(struct sk_buff *skb, struct vmxnet3_tx_queue *tq,
count = VMXNET3_TXD_NEEDED(skb_headlen(skb)) +
skb_shinfo(skb)->nr_frags + 1;

ctx.ipv4 = (skb->protocol == __constant_ntohs(ETH_P_IP));
ctx.ipv4 = (skb->protocol == cpu_to_be16(ETH_P_IP));

ctx.mss = skb_shinfo(skb)->gso_size;
if (ctx.mss) {
Expand Down

0 comments on commit 1b803fb

Please sign in to comment.