diff options
| author | David S. Miller <davem@davemloft.net> | 2020-01-14 11:48:41 -0800 |
|---|---|---|
| committer | David S. Miller <davem@davemloft.net> | 2020-01-14 11:48:41 -0800 |
| commit | 2b133adfcf8eac354f2a801dc408dc48246e7718 (patch) | |
| tree | b729808d3dbbfa9f5c5c4ba583ee99d1ad7f97ae /include | |
| parent | ec22ab00750d462dae19272610623abe9534b674 (diff) | |
| parent | 9f3ef3d7026fe0aef5c2d649e21b8c71c17d8fc2 (diff) | |
Merge branch 'skb_list_walk_safe-refactoring'
Jason A. Donenfeld says:
====================
skb_list_walk_safe refactoring for net/*'s skb_gso_segment usage
This patchset adjusts all return values of skb_gso_segment in net/* to
use the new skb_list_walk_safe helper.
First we fix a minor bug in the helper macro that didn't come up in the
last patchset's uses. Then we adjust several cases throughout net/. The
xfrm changes were a bit hairy, but doable. Reading and thinking about
the code in mac80211 indicates a memory leak, which the commit
addresses. All the other cases were pretty trivial.
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/skbuff.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 016b3c4ab99a..aaf73b34f72f 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -1479,9 +1479,9 @@ static inline void skb_mark_not_on_list(struct sk_buff *skb) } /* Iterate through singly-linked GSO fragments of an skb. */ -#define skb_list_walk_safe(first, skb, next) \ - for ((skb) = (first), (next) = (skb) ? (skb)->next : NULL; (skb); \ - (skb) = (next), (next) = (skb) ? (skb)->next : NULL) +#define skb_list_walk_safe(first, skb, next_skb) \ + for ((skb) = (first), (next_skb) = (skb) ? (skb)->next : NULL; (skb); \ + (skb) = (next_skb), (next_skb) = (skb) ? (skb)->next : NULL) static inline void skb_list_del_init(struct sk_buff *skb) { |
