aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2007-03-10 13:56:08 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2007-04-26 01:24:43 -0400
commit797659fb4a4a511649cd71028141c32ad1698a12 (patch)
tree370361e706de99e3c176b343e9f2db5a1a9df2a3 /include
parent37e6636669b0b996681586facee8034f7f674f6a (diff)
[PPPOE]: Introduce pppoe_hdr()
For consistency with all the other skb->nh.raw accessors. Also do some really obvious simplifications in pppoe_recvmsg, well the kfree_skb one is not so obvious, but free() and kfree() have the same behaviour (hint :-) ). Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/linux/if_pppox.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/linux/if_pppox.h b/include/linux/if_pppox.h
index e33ee763c052..7044f8ab30a0 100644
--- a/include/linux/if_pppox.h
+++ b/include/linux/if_pppox.h
@@ -112,6 +112,13 @@ struct pppoe_hdr {
112} __attribute__ ((packed)); 112} __attribute__ ((packed));
113 113
114#ifdef __KERNEL__ 114#ifdef __KERNEL__
115#include <linux/skbuff.h>
116
117static inline struct pppoe_hdr *pppoe_hdr(const struct sk_buff *skb)
118{
119 return (struct pppoe_hdr *)skb->nh.raw;
120}
121
115struct pppoe_opt { 122struct pppoe_opt {
116 struct net_device *dev; /* device associated with socket*/ 123 struct net_device *dev; /* device associated with socket*/
117 int ifindex; /* ifindex of device associated with socket */ 124 int ifindex; /* ifindex of device associated with socket */