diff options
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/ethtool.h | 2 | ||||
-rw-r--r-- | include/linux/netdevice.h | 27 | ||||
-rw-r--r-- | include/linux/netfilter/nf_conntrack_proto_gre.h | 18 | ||||
-rw-r--r-- | include/linux/netfilter_bridge.h | 25 | ||||
-rw-r--r-- | include/linux/parser.h | 8 | ||||
-rw-r--r-- | include/linux/pci_ids.h | 1 | ||||
-rw-r--r-- | include/linux/skbuff.h | 2 | ||||
-rw-r--r-- | include/linux/xfrm.h | 58 |
8 files changed, 71 insertions, 70 deletions
diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h index c6310aef5ab0..f2d248f8cc92 100644 --- a/include/linux/ethtool.h +++ b/include/linux/ethtool.h | |||
@@ -434,6 +434,7 @@ struct ethtool_ops { | |||
434 | #define SUPPORTED_10000baseT_Full (1 << 12) | 434 | #define SUPPORTED_10000baseT_Full (1 << 12) |
435 | #define SUPPORTED_Pause (1 << 13) | 435 | #define SUPPORTED_Pause (1 << 13) |
436 | #define SUPPORTED_Asym_Pause (1 << 14) | 436 | #define SUPPORTED_Asym_Pause (1 << 14) |
437 | #define SUPPORTED_2500baseX_Full (1 << 15) | ||
437 | 438 | ||
438 | /* Indicates what features are advertised by the interface. */ | 439 | /* Indicates what features are advertised by the interface. */ |
439 | #define ADVERTISED_10baseT_Half (1 << 0) | 440 | #define ADVERTISED_10baseT_Half (1 << 0) |
@@ -451,6 +452,7 @@ struct ethtool_ops { | |||
451 | #define ADVERTISED_10000baseT_Full (1 << 12) | 452 | #define ADVERTISED_10000baseT_Full (1 << 12) |
452 | #define ADVERTISED_Pause (1 << 13) | 453 | #define ADVERTISED_Pause (1 << 13) |
453 | #define ADVERTISED_Asym_Pause (1 << 14) | 454 | #define ADVERTISED_Asym_Pause (1 << 14) |
455 | #define ADVERTISED_2500baseX_Full (1 << 15) | ||
454 | 456 | ||
455 | /* The following are all involved in forcing a particular link | 457 | /* The following are all involved in forcing a particular link |
456 | * mode for the device for setting things. When getting the | 458 | * mode for the device for setting things. When getting the |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index ac0c92b1e002..30446222b396 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -304,7 +304,7 @@ struct net_device | |||
304 | 304 | ||
305 | unsigned long state; | 305 | unsigned long state; |
306 | 306 | ||
307 | struct net_device *next; | 307 | struct list_head dev_list; |
308 | 308 | ||
309 | /* The device initialization function. Called only once. */ | 309 | /* The device initialization function. Called only once. */ |
310 | int (*init)(struct net_device *dev); | 310 | int (*init)(struct net_device *dev); |
@@ -575,13 +575,36 @@ struct packet_type { | |||
575 | #include <linux/notifier.h> | 575 | #include <linux/notifier.h> |
576 | 576 | ||
577 | extern struct net_device loopback_dev; /* The loopback */ | 577 | extern struct net_device loopback_dev; /* The loopback */ |
578 | extern struct net_device *dev_base; /* All devices */ | 578 | extern struct list_head dev_base_head; /* All devices */ |
579 | extern rwlock_t dev_base_lock; /* Device list lock */ | 579 | extern rwlock_t dev_base_lock; /* Device list lock */ |
580 | 580 | ||
581 | #define for_each_netdev(d) \ | ||
582 | list_for_each_entry(d, &dev_base_head, dev_list) | ||
583 | #define for_each_netdev_safe(d, n) \ | ||
584 | list_for_each_entry_safe(d, n, &dev_base_head, dev_list) | ||
585 | #define for_each_netdev_continue(d) \ | ||
586 | list_for_each_entry_continue(d, &dev_base_head, dev_list) | ||
587 | #define net_device_entry(lh) list_entry(lh, struct net_device, dev_list) | ||
588 | |||
589 | static inline struct net_device *next_net_device(struct net_device *dev) | ||
590 | { | ||
591 | struct list_head *lh; | ||
592 | |||
593 | lh = dev->dev_list.next; | ||
594 | return lh == &dev_base_head ? NULL : net_device_entry(lh); | ||
595 | } | ||
596 | |||
597 | static inline struct net_device *first_net_device(void) | ||
598 | { | ||
599 | return list_empty(&dev_base_head) ? NULL : | ||
600 | net_device_entry(dev_base_head.next); | ||
601 | } | ||
602 | |||
581 | extern int netdev_boot_setup_check(struct net_device *dev); | 603 | extern int netdev_boot_setup_check(struct net_device *dev); |
582 | extern unsigned long netdev_boot_base(const char *prefix, int unit); | 604 | extern unsigned long netdev_boot_base(const char *prefix, int unit); |
583 | extern struct net_device *dev_getbyhwaddr(unsigned short type, char *hwaddr); | 605 | extern struct net_device *dev_getbyhwaddr(unsigned short type, char *hwaddr); |
584 | extern struct net_device *dev_getfirstbyhwtype(unsigned short type); | 606 | extern struct net_device *dev_getfirstbyhwtype(unsigned short type); |
607 | extern struct net_device *__dev_getfirstbyhwtype(unsigned short type); | ||
585 | extern void dev_add_pack(struct packet_type *pt); | 608 | extern void dev_add_pack(struct packet_type *pt); |
586 | extern void dev_remove_pack(struct packet_type *pt); | 609 | extern void dev_remove_pack(struct packet_type *pt); |
587 | extern void __dev_remove_pack(struct packet_type *pt); | 610 | extern void __dev_remove_pack(struct packet_type *pt); |
diff --git a/include/linux/netfilter/nf_conntrack_proto_gre.h b/include/linux/netfilter/nf_conntrack_proto_gre.h index 4e6bbce04ff8..535e4219d2bb 100644 --- a/include/linux/netfilter/nf_conntrack_proto_gre.h +++ b/include/linux/netfilter/nf_conntrack_proto_gre.h | |||
@@ -87,24 +87,6 @@ int nf_ct_gre_keymap_add(struct nf_conn *ct, enum ip_conntrack_dir dir, | |||
87 | /* delete keymap entries */ | 87 | /* delete keymap entries */ |
88 | void nf_ct_gre_keymap_destroy(struct nf_conn *ct); | 88 | void nf_ct_gre_keymap_destroy(struct nf_conn *ct); |
89 | 89 | ||
90 | /* get pointer to gre key, if present */ | ||
91 | static inline __be32 *gre_key(struct gre_hdr *greh) | ||
92 | { | ||
93 | if (!greh->key) | ||
94 | return NULL; | ||
95 | if (greh->csum || greh->routing) | ||
96 | return (__be32 *)(greh+sizeof(*greh)+4); | ||
97 | return (__be32 *)(greh+sizeof(*greh)); | ||
98 | } | ||
99 | |||
100 | /* get pointer ot gre csum, if present */ | ||
101 | static inline __sum16 *gre_csum(struct gre_hdr *greh) | ||
102 | { | ||
103 | if (!greh->csum) | ||
104 | return NULL; | ||
105 | return (__sum16 *)(greh+sizeof(*greh)); | ||
106 | } | ||
107 | |||
108 | extern void nf_ct_gre_keymap_flush(void); | 90 | extern void nf_ct_gre_keymap_flush(void); |
109 | extern void nf_nat_need_gre(void); | 91 | extern void nf_nat_need_gre(void); |
110 | 92 | ||
diff --git a/include/linux/netfilter_bridge.h b/include/linux/netfilter_bridge.h index 19060030bac9..533ee351a273 100644 --- a/include/linux/netfilter_bridge.h +++ b/include/linux/netfilter_bridge.h | |||
@@ -55,18 +55,25 @@ static inline int nf_bridge_maybe_copy_header(struct sk_buff *skb) | |||
55 | return 0; | 55 | return 0; |
56 | } | 56 | } |
57 | 57 | ||
58 | static inline unsigned int nf_bridge_encap_header_len(const struct sk_buff *skb) | ||
59 | { | ||
60 | switch (skb->protocol) { | ||
61 | case __constant_htons(ETH_P_8021Q): | ||
62 | return VLAN_HLEN; | ||
63 | case __constant_htons(ETH_P_PPP_SES): | ||
64 | return PPPOE_SES_HLEN; | ||
65 | default: | ||
66 | return 0; | ||
67 | } | ||
68 | } | ||
69 | |||
58 | /* This is called by the IP fragmenting code and it ensures there is | 70 | /* This is called by the IP fragmenting code and it ensures there is |
59 | * enough room for the encapsulating header (if there is one). */ | 71 | * enough room for the encapsulating header (if there is one). */ |
60 | static inline int nf_bridge_pad(const struct sk_buff *skb) | 72 | static inline unsigned int nf_bridge_pad(const struct sk_buff *skb) |
61 | { | 73 | { |
62 | int padding = 0; | 74 | if (skb->nf_bridge) |
63 | 75 | return nf_bridge_encap_header_len(skb); | |
64 | if (skb->nf_bridge && skb->protocol == htons(ETH_P_8021Q)) | 76 | return 0; |
65 | padding = VLAN_HLEN; | ||
66 | else if (skb->nf_bridge && skb->protocol == htons(ETH_P_PPP_SES)) | ||
67 | padding = PPPOE_SES_HLEN; | ||
68 | |||
69 | return padding; | ||
70 | } | 77 | } |
71 | 78 | ||
72 | struct bridge_skb_cb { | 79 | struct bridge_skb_cb { |
diff --git a/include/linux/parser.h b/include/linux/parser.h index fa3332861a09..86676f600992 100644 --- a/include/linux/parser.h +++ b/include/linux/parser.h | |||
@@ -11,10 +11,10 @@ | |||
11 | /* associates an integer enumerator with a pattern string. */ | 11 | /* associates an integer enumerator with a pattern string. */ |
12 | struct match_token { | 12 | struct match_token { |
13 | int token; | 13 | int token; |
14 | char *pattern; | 14 | const char *pattern; |
15 | }; | 15 | }; |
16 | 16 | ||
17 | typedef struct match_token match_table_t[]; | 17 | typedef const struct match_token match_table_t[]; |
18 | 18 | ||
19 | /* Maximum number of arguments that match_token will find in a pattern */ | 19 | /* Maximum number of arguments that match_token will find in a pattern */ |
20 | enum {MAX_OPT_ARGS = 3}; | 20 | enum {MAX_OPT_ARGS = 3}; |
@@ -29,5 +29,5 @@ int match_token(char *, match_table_t table, substring_t args[]); | |||
29 | int match_int(substring_t *, int *result); | 29 | int match_int(substring_t *, int *result); |
30 | int match_octal(substring_t *, int *result); | 30 | int match_octal(substring_t *, int *result); |
31 | int match_hex(substring_t *, int *result); | 31 | int match_hex(substring_t *, int *result); |
32 | void match_strcpy(char *, substring_t *); | 32 | void match_strcpy(char *, const substring_t *); |
33 | char *match_strdup(substring_t *); | 33 | char *match_strdup(const substring_t *); |
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 5a48e963d06b..ae849f0d4430 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h | |||
@@ -1926,6 +1926,7 @@ | |||
1926 | #define PCI_DEVICE_ID_TIGON3_5752 0x1600 | 1926 | #define PCI_DEVICE_ID_TIGON3_5752 0x1600 |
1927 | #define PCI_DEVICE_ID_TIGON3_5752M 0x1601 | 1927 | #define PCI_DEVICE_ID_TIGON3_5752M 0x1601 |
1928 | #define PCI_DEVICE_ID_NX2_5709 0x1639 | 1928 | #define PCI_DEVICE_ID_NX2_5709 0x1639 |
1929 | #define PCI_DEVICE_ID_NX2_5709S 0x163a | ||
1929 | #define PCI_DEVICE_ID_TIGON3_5700 0x1644 | 1930 | #define PCI_DEVICE_ID_TIGON3_5700 0x1644 |
1930 | #define PCI_DEVICE_ID_TIGON3_5701 0x1645 | 1931 | #define PCI_DEVICE_ID_TIGON3_5701 0x1645 |
1931 | #define PCI_DEVICE_ID_TIGON3_5702 0x1646 | 1932 | #define PCI_DEVICE_ID_TIGON3_5702 0x1646 |
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 253a2b9be9d6..e7367c74e1bb 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
@@ -197,7 +197,7 @@ typedef unsigned char *sk_buff_data_t; | |||
197 | * @tstamp: Time we arrived | 197 | * @tstamp: Time we arrived |
198 | * @dev: Device we arrived on/are leaving by | 198 | * @dev: Device we arrived on/are leaving by |
199 | * @iif: ifindex of device we arrived on | 199 | * @iif: ifindex of device we arrived on |
200 | * @h: Transport layer header | 200 | * @transport_header: Transport layer header |
201 | * @network_header: Network layer header | 201 | * @network_header: Network layer header |
202 | * @mac_header: Link layer header | 202 | * @mac_header: Link layer header |
203 | * @dst: destination entry | 203 | * @dst: destination entry |
diff --git a/include/linux/xfrm.h b/include/linux/xfrm.h index a5d53e0fe152..b58adc52448d 100644 --- a/include/linux/xfrm.h +++ b/include/linux/xfrm.h | |||
@@ -243,17 +243,6 @@ enum xfrm_ae_ftype_t { | |||
243 | #define XFRM_AE_MAX (__XFRM_AE_MAX - 1) | 243 | #define XFRM_AE_MAX (__XFRM_AE_MAX - 1) |
244 | }; | 244 | }; |
245 | 245 | ||
246 | /* SAD Table filter flags */ | ||
247 | enum xfrm_sad_ftype_t { | ||
248 | XFRM_SAD_UNSPEC, | ||
249 | XFRM_SAD_HMASK=1, | ||
250 | XFRM_SAD_HMAX=2, | ||
251 | XFRM_SAD_CNT=4, | ||
252 | __XFRM_SAD_MAX | ||
253 | |||
254 | #define XFRM_SAD_MAX (__XFRM_SAD_MAX - 1) | ||
255 | }; | ||
256 | |||
257 | struct xfrm_userpolicy_type { | 246 | struct xfrm_userpolicy_type { |
258 | __u8 type; | 247 | __u8 type; |
259 | __u16 reserved1; | 248 | __u16 reserved1; |
@@ -287,44 +276,41 @@ enum xfrm_attr_type_t { | |||
287 | 276 | ||
288 | enum xfrm_sadattr_type_t { | 277 | enum xfrm_sadattr_type_t { |
289 | XFRMA_SAD_UNSPEC, | 278 | XFRMA_SAD_UNSPEC, |
290 | XFRMA_SADHMASK, | 279 | XFRMA_SAD_CNT, |
291 | XFRMA_SADHMAX, | 280 | XFRMA_SAD_HINFO, |
292 | XFRMA_SADCNT, | ||
293 | __XFRMA_SAD_MAX | 281 | __XFRMA_SAD_MAX |
294 | 282 | ||
295 | #define XFRMA_SAD_MAX (__XFRMA_SAD_MAX - 1) | 283 | #define XFRMA_SAD_MAX (__XFRMA_SAD_MAX - 1) |
296 | }; | 284 | }; |
297 | 285 | ||
298 | /* SPD Table filter flags */ | 286 | struct xfrmu_sadhinfo { |
299 | enum xfrm_spd_ftype_t { | 287 | __u32 sadhcnt; /* current hash bkts */ |
300 | XFRM_SPD_UNSPEC, | 288 | __u32 sadhmcnt; /* max allowed hash bkts */ |
301 | XFRM_SPD_HMASK=1, | ||
302 | XFRM_SPD_HMAX=2, | ||
303 | XFRM_SPD_ICNT=4, | ||
304 | XFRM_SPD_OCNT=8, | ||
305 | XFRM_SPD_FCNT=16, | ||
306 | XFRM_SPD_ISCNT=32, | ||
307 | XFRM_SPD_OSCNT=64, | ||
308 | XFRM_SPD_FSCNT=128, | ||
309 | __XFRM_SPD_MAX | ||
310 | |||
311 | #define XFRM_SPD_MAX (__XFRM_SPD_MAX - 1) | ||
312 | }; | 289 | }; |
290 | |||
313 | enum xfrm_spdattr_type_t { | 291 | enum xfrm_spdattr_type_t { |
314 | XFRMA_SPD_UNSPEC, | 292 | XFRMA_SPD_UNSPEC, |
315 | XFRMA_SPDHMASK, | 293 | XFRMA_SPD_INFO, |
316 | XFRMA_SPDHMAX, | 294 | XFRMA_SPD_HINFO, |
317 | XFRMA_SPDICNT, | ||
318 | XFRMA_SPDOCNT, | ||
319 | XFRMA_SPDFCNT, | ||
320 | XFRMA_SPDISCNT, | ||
321 | XFRMA_SPDOSCNT, | ||
322 | XFRMA_SPDFSCNT, | ||
323 | __XFRMA_SPD_MAX | 295 | __XFRMA_SPD_MAX |
324 | 296 | ||
325 | #define XFRMA_SPD_MAX (__XFRMA_SPD_MAX - 1) | 297 | #define XFRMA_SPD_MAX (__XFRMA_SPD_MAX - 1) |
326 | }; | 298 | }; |
327 | 299 | ||
300 | struct xfrmu_spdinfo { | ||
301 | __u32 incnt; | ||
302 | __u32 outcnt; | ||
303 | __u32 fwdcnt; | ||
304 | __u32 inscnt; | ||
305 | __u32 outscnt; | ||
306 | __u32 fwdscnt; | ||
307 | }; | ||
308 | |||
309 | struct xfrmu_spdhinfo { | ||
310 | __u32 spdhcnt; | ||
311 | __u32 spdhmcnt; | ||
312 | }; | ||
313 | |||
328 | struct xfrm_usersa_info { | 314 | struct xfrm_usersa_info { |
329 | struct xfrm_selector sel; | 315 | struct xfrm_selector sel; |
330 | struct xfrm_id id; | 316 | struct xfrm_id id; |