diff options
| author | Ingo Molnar <mingo@kernel.org> | 2012-04-13 03:50:21 -0400 |
|---|---|---|
| committer | Ingo Molnar <mingo@kernel.org> | 2012-04-13 03:50:21 -0400 |
| commit | 659c36fcda403013a01b85da07cf2d9711e6d6c7 (patch) | |
| tree | ece2e7d0e2c19ea5a3d0ec172ad0b81a8a19021d /include/linux/skbuff.h | |
| parent | 9521d830b6341d1887dcfc2aebde23fbfa5f1473 (diff) | |
| parent | 5a7ed29c7572d00a75e8c4529e30c5ac2ef82271 (diff) | |
Merge tag 'perf-core-for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/acme/linux into perf/core
Fixes and improvements for perf/core:
. Overhaul the tools/ makefiles, gluing them to the top level Makefile, from
Borislav Petkov.
. Move the UI files from tools/perf/util/ui/ to tools/perf/ui/. Also move
the GTK+ browser to tools/perf/ui/gtk/, from Namhyung Kim.
. Only fallback to sw cycles counter on ENOENT for the hw cycles, from
Robert Richter
. Trivial fixes from Robert Richter
. Handle the autogenerated bison/flex files better, from Namhyung and Jiri Olsa.
. Navigate jump instructions in the annotate browser, just press enter or ->,
still needs support for a jump navigation history, i.e. to go back.
. Search string in the annotate browser: same keys as vim:
/ forward
n next backward/forward
? backward
. Clarify number of events/samples in the report header, from Ashay Rane
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'include/linux/skbuff.h')
| -rw-r--r-- | include/linux/skbuff.h | 47 |
1 files changed, 38 insertions, 9 deletions
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index ae86adee3746..3fcb204a2612 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
| @@ -18,6 +18,7 @@ | |||
| 18 | #include <linux/kmemcheck.h> | 18 | #include <linux/kmemcheck.h> |
| 19 | #include <linux/compiler.h> | 19 | #include <linux/compiler.h> |
| 20 | #include <linux/time.h> | 20 | #include <linux/time.h> |
| 21 | #include <linux/bug.h> | ||
| 21 | #include <linux/cache.h> | 22 | #include <linux/cache.h> |
| 22 | 23 | ||
| 23 | #include <linux/atomic.h> | 24 | #include <linux/atomic.h> |
| @@ -94,6 +95,13 @@ | |||
| 94 | * about CHECKSUM_UNNECESSARY. 8) | 95 | * about CHECKSUM_UNNECESSARY. 8) |
| 95 | * NETIF_F_IPV6_CSUM about as dumb as the last one but does IPv6 instead. | 96 | * NETIF_F_IPV6_CSUM about as dumb as the last one but does IPv6 instead. |
| 96 | * | 97 | * |
| 98 | * UNNECESSARY: device will do per protocol specific csum. Protocol drivers | ||
| 99 | * that do not want net to perform the checksum calculation should use | ||
| 100 | * this flag in their outgoing skbs. | ||
| 101 | * NETIF_F_FCOE_CRC this indicates the device can do FCoE FC CRC | ||
| 102 | * offload. Correspondingly, the FCoE protocol driver | ||
| 103 | * stack should use CHECKSUM_UNNECESSARY. | ||
| 104 | * | ||
| 97 | * Any questions? No questions, good. --ANK | 105 | * Any questions? No questions, good. --ANK |
| 98 | */ | 106 | */ |
| 99 | 107 | ||
| @@ -361,6 +369,7 @@ typedef unsigned char *sk_buff_data_t; | |||
| 361 | * ports. | 369 | * ports. |
| 362 | * @wifi_acked_valid: wifi_acked was set | 370 | * @wifi_acked_valid: wifi_acked was set |
| 363 | * @wifi_acked: whether frame was acked on wifi or not | 371 | * @wifi_acked: whether frame was acked on wifi or not |
| 372 | * @no_fcs: Request NIC to treat last 4 bytes as Ethernet FCS | ||
| 364 | * @dma_cookie: a cookie to one of several possible DMA operations | 373 | * @dma_cookie: a cookie to one of several possible DMA operations |
| 365 | * done by skb DMA functions | 374 | * done by skb DMA functions |
| 366 | * @secmark: security marking | 375 | * @secmark: security marking |
| @@ -438,6 +447,11 @@ struct sk_buff { | |||
| 438 | #endif | 447 | #endif |
| 439 | 448 | ||
| 440 | int skb_iif; | 449 | int skb_iif; |
| 450 | |||
| 451 | __u32 rxhash; | ||
| 452 | |||
| 453 | __u16 vlan_tci; | ||
| 454 | |||
| 441 | #ifdef CONFIG_NET_SCHED | 455 | #ifdef CONFIG_NET_SCHED |
| 442 | __u16 tc_index; /* traffic control index */ | 456 | __u16 tc_index; /* traffic control index */ |
| 443 | #ifdef CONFIG_NET_CLS_ACT | 457 | #ifdef CONFIG_NET_CLS_ACT |
| @@ -445,8 +459,6 @@ struct sk_buff { | |||
| 445 | #endif | 459 | #endif |
| 446 | #endif | 460 | #endif |
| 447 | 461 | ||
| 448 | __u32 rxhash; | ||
| 449 | |||
| 450 | __u16 queue_mapping; | 462 | __u16 queue_mapping; |
| 451 | kmemcheck_bitfield_begin(flags2); | 463 | kmemcheck_bitfield_begin(flags2); |
| 452 | #ifdef CONFIG_IPV6_NDISC_NODETYPE | 464 | #ifdef CONFIG_IPV6_NDISC_NODETYPE |
| @@ -456,7 +468,8 @@ struct sk_buff { | |||
| 456 | __u8 l4_rxhash:1; | 468 | __u8 l4_rxhash:1; |
| 457 | __u8 wifi_acked_valid:1; | 469 | __u8 wifi_acked_valid:1; |
| 458 | __u8 wifi_acked:1; | 470 | __u8 wifi_acked:1; |
| 459 | /* 10/12 bit hole (depending on ndisc_nodetype presence) */ | 471 | __u8 no_fcs:1; |
| 472 | /* 9/11 bit hole (depending on ndisc_nodetype presence) */ | ||
| 460 | kmemcheck_bitfield_end(flags2); | 473 | kmemcheck_bitfield_end(flags2); |
| 461 | 474 | ||
| 462 | #ifdef CONFIG_NET_DMA | 475 | #ifdef CONFIG_NET_DMA |
| @@ -470,8 +483,6 @@ struct sk_buff { | |||
| 470 | __u32 dropcount; | 483 | __u32 dropcount; |
| 471 | }; | 484 | }; |
| 472 | 485 | ||
| 473 | __u16 vlan_tci; | ||
| 474 | |||
| 475 | sk_buff_data_t transport_header; | 486 | sk_buff_data_t transport_header; |
| 476 | sk_buff_data_t network_header; | 487 | sk_buff_data_t network_header; |
| 477 | sk_buff_data_t mac_header; | 488 | sk_buff_data_t mac_header; |
| @@ -876,6 +887,24 @@ static inline struct sk_buff *skb_peek(const struct sk_buff_head *list_) | |||
| 876 | } | 887 | } |
| 877 | 888 | ||
| 878 | /** | 889 | /** |
| 890 | * skb_peek_next - peek skb following the given one from a queue | ||
| 891 | * @skb: skb to start from | ||
| 892 | * @list_: list to peek at | ||
| 893 | * | ||
| 894 | * Returns %NULL when the end of the list is met or a pointer to the | ||
| 895 | * next element. The reference count is not incremented and the | ||
| 896 | * reference is therefore volatile. Use with caution. | ||
| 897 | */ | ||
| 898 | static inline struct sk_buff *skb_peek_next(struct sk_buff *skb, | ||
| 899 | const struct sk_buff_head *list_) | ||
| 900 | { | ||
| 901 | struct sk_buff *next = skb->next; | ||
| 902 | if (next == (struct sk_buff *)list_) | ||
| 903 | next = NULL; | ||
| 904 | return next; | ||
| 905 | } | ||
| 906 | |||
| 907 | /** | ||
| 879 | * skb_peek_tail - peek at the tail of an &sk_buff_head | 908 | * skb_peek_tail - peek at the tail of an &sk_buff_head |
| 880 | * @list_: list to peek at | 909 | * @list_: list to peek at |
| 881 | * | 910 | * |
| @@ -1152,7 +1181,7 @@ static inline struct sk_buff *__skb_dequeue_tail(struct sk_buff_head *list) | |||
| 1152 | } | 1181 | } |
| 1153 | 1182 | ||
| 1154 | 1183 | ||
| 1155 | static inline int skb_is_nonlinear(const struct sk_buff *skb) | 1184 | static inline bool skb_is_nonlinear(const struct sk_buff *skb) |
| 1156 | { | 1185 | { |
| 1157 | return skb->data_len; | 1186 | return skb->data_len; |
| 1158 | } | 1187 | } |
| @@ -2055,7 +2084,7 @@ static inline void skb_frag_add_head(struct sk_buff *skb, struct sk_buff *frag) | |||
| 2055 | for (iter = skb_shinfo(skb)->frag_list; iter; iter = iter->next) | 2084 | for (iter = skb_shinfo(skb)->frag_list; iter; iter = iter->next) |
| 2056 | 2085 | ||
| 2057 | extern struct sk_buff *__skb_recv_datagram(struct sock *sk, unsigned flags, | 2086 | extern struct sk_buff *__skb_recv_datagram(struct sock *sk, unsigned flags, |
| 2058 | int *peeked, int *err); | 2087 | int *peeked, int *off, int *err); |
| 2059 | extern struct sk_buff *skb_recv_datagram(struct sock *sk, unsigned flags, | 2088 | extern struct sk_buff *skb_recv_datagram(struct sock *sk, unsigned flags, |
| 2060 | int noblock, int *err); | 2089 | int noblock, int *err); |
| 2061 | extern unsigned int datagram_poll(struct file *file, struct socket *sock, | 2090 | extern unsigned int datagram_poll(struct file *file, struct socket *sock, |
| @@ -2448,12 +2477,12 @@ static inline struct sec_path *skb_sec_path(struct sk_buff *skb) | |||
| 2448 | } | 2477 | } |
| 2449 | #endif | 2478 | #endif |
| 2450 | 2479 | ||
| 2451 | static inline int skb_is_gso(const struct sk_buff *skb) | 2480 | static inline bool skb_is_gso(const struct sk_buff *skb) |
| 2452 | { | 2481 | { |
| 2453 | return skb_shinfo(skb)->gso_size; | 2482 | return skb_shinfo(skb)->gso_size; |
| 2454 | } | 2483 | } |
| 2455 | 2484 | ||
| 2456 | static inline int skb_is_gso_v6(const struct sk_buff *skb) | 2485 | static inline bool skb_is_gso_v6(const struct sk_buff *skb) |
| 2457 | { | 2486 | { |
| 2458 | return skb_shinfo(skb)->gso_type & SKB_GSO_TCPV6; | 2487 | return skb_shinfo(skb)->gso_type & SKB_GSO_TCPV6; |
| 2459 | } | 2488 | } |
