提交 88ca2d07 编写于 作者: T Thomas Klein 提交者: Jeff Garzik

ehea: Fix skb header access

Adapt to new skb header access functions.
Signed-off-by: NThomas Klein <tklein@de.ibm.com>
Signed-off-by: NJeff Garzik <jeff@garzik.org>
上级 7dd976fc
......@@ -1803,10 +1803,10 @@ static inline int ehea_hash_skb(struct sk_buff *skb, int num_qps)
u32 tmp;
if ((skb->protocol == htons(ETH_P_IP)) &&
(skb->nh.iph->protocol == IPPROTO_TCP)) {
tcp = (struct tcphdr*)(skb->nh.raw + (skb->nh.iph->ihl * 4));
(ip_hdr(skb)->protocol == IPPROTO_TCP)) {
tcp = (struct tcphdr*)(skb_network_header(skb) + (ip_hdr(skb)->ihl * 4));
tmp = (tcp->source + (tcp->dest << 16)) % 31;
tmp += skb->nh.iph->daddr % 31;
tmp += ip_hdr(skb)->daddr % 31;
return tmp % num_qps;
}
else
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册