aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched
diff options
context:
space:
mode:
Diffstat (limited to 'net/sched')
-rw-r--r--net/sched/cls_rsvp.h2
-rw-r--r--net/sched/sch_atm.c4
-rw-r--r--net/sched/sch_dsmark.c4
-rw-r--r--net/sched/sch_sfq.c2
4 files changed, 6 insertions, 6 deletions
diff --git a/net/sched/cls_rsvp.h b/net/sched/cls_rsvp.h
index b6ac0e287872..cb8cf5bfa053 100644
--- a/net/sched/cls_rsvp.h
+++ b/net/sched/cls_rsvp.h
@@ -145,7 +145,7 @@ static int rsvp_classify(struct sk_buff *skb, struct tcf_proto *tp,
145#if RSVP_DST_LEN == 4 145#if RSVP_DST_LEN == 4
146 struct ipv6hdr *nhptr = skb->nh.ipv6h; 146 struct ipv6hdr *nhptr = skb->nh.ipv6h;
147#else 147#else
148 struct iphdr *nhptr = skb->nh.iph; 148 struct iphdr *nhptr = ip_hdr(skb);
149#endif 149#endif
150 150
151restart: 151restart:
diff --git a/net/sched/sch_atm.c b/net/sched/sch_atm.c
index afb3bbd571f2..baca8743c12b 100644
--- a/net/sched/sch_atm.c
+++ b/net/sched/sch_atm.c
@@ -503,7 +503,7 @@ static void sch_atm_dequeue(unsigned long data)
503 } 503 }
504 D2PRINTK("atm_tc_dequeue: sending on class %p\n",flow); 504 D2PRINTK("atm_tc_dequeue: sending on class %p\n",flow);
505 /* remove any LL header somebody else has attached */ 505 /* remove any LL header somebody else has attached */
506 skb_pull(skb,(char *) skb->nh.iph-(char *) skb->data); 506 skb_pull(skb, skb_network_offset(skb));
507 if (skb_headroom(skb) < flow->hdr_len) { 507 if (skb_headroom(skb) < flow->hdr_len) {
508 struct sk_buff *new; 508 struct sk_buff *new;
509 509
@@ -513,7 +513,7 @@ static void sch_atm_dequeue(unsigned long data)
513 skb = new; 513 skb = new;
514 } 514 }
515 D2PRINTK("sch_atm_dequeue: ip %p, data %p\n", 515 D2PRINTK("sch_atm_dequeue: ip %p, data %p\n",
516 skb->nh.iph,skb->data); 516 skb_network_header(skb), skb->data);
517 ATM_SKB(skb)->vcc = flow->vcc; 517 ATM_SKB(skb)->vcc = flow->vcc;
518 memcpy(skb_push(skb,flow->hdr_len),flow->hdr, 518 memcpy(skb_push(skb,flow->hdr_len),flow->hdr,
519 flow->hdr_len); 519 flow->hdr_len);
diff --git a/net/sched/sch_dsmark.c b/net/sched/sch_dsmark.c
index 96324cf4e6a9..45b5734dd72a 100644
--- a/net/sched/sch_dsmark.c
+++ b/net/sched/sch_dsmark.c
@@ -216,7 +216,7 @@ static int dsmark_enqueue(struct sk_buff *skb,struct Qdisc *sch)
216 /* FIXME: Safe with non-linear skbs? --RR */ 216 /* FIXME: Safe with non-linear skbs? --RR */
217 switch (skb->protocol) { 217 switch (skb->protocol) {
218 case __constant_htons(ETH_P_IP): 218 case __constant_htons(ETH_P_IP):
219 skb->tc_index = ipv4_get_dsfield(skb->nh.iph) 219 skb->tc_index = ipv4_get_dsfield(ip_hdr(skb))
220 & ~INET_ECN_MASK; 220 & ~INET_ECN_MASK;
221 break; 221 break;
222 case __constant_htons(ETH_P_IPV6): 222 case __constant_htons(ETH_P_IPV6):
@@ -292,7 +292,7 @@ static struct sk_buff *dsmark_dequeue(struct Qdisc *sch)
292 292
293 switch (skb->protocol) { 293 switch (skb->protocol) {
294 case __constant_htons(ETH_P_IP): 294 case __constant_htons(ETH_P_IP):
295 ipv4_change_dsfield(skb->nh.iph, p->mask[index], 295 ipv4_change_dsfield(ip_hdr(skb), p->mask[index],
296 p->value[index]); 296 p->value[index]);
297 break; 297 break;
298 case __constant_htons(ETH_P_IPV6): 298 case __constant_htons(ETH_P_IPV6):
diff --git a/net/sched/sch_sfq.c b/net/sched/sch_sfq.c
index 66f32051a99b..02081bc9e0d1 100644
--- a/net/sched/sch_sfq.c
+++ b/net/sched/sch_sfq.c
@@ -137,7 +137,7 @@ static unsigned sfq_hash(struct sfq_sched_data *q, struct sk_buff *skb)
137 switch (skb->protocol) { 137 switch (skb->protocol) {
138 case __constant_htons(ETH_P_IP): 138 case __constant_htons(ETH_P_IP):
139 { 139 {
140 struct iphdr *iph = skb->nh.iph; 140 const struct iphdr *iph = ip_hdr(skb);
141 h = iph->daddr; 141 h = iph->daddr;
142 h2 = iph->saddr^iph->protocol; 142 h2 = iph->saddr^iph->protocol;
143 if (!(iph->frag_off&htons(IP_MF|IP_OFFSET)) && 143 if (!(iph->frag_off&htons(IP_MF|IP_OFFSET)) &&