Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=46f8914e53c28d0716c586e08a7c819d8ebb9d54 Commit: 46f8914e53c28d0716c586e08a7c819d8ebb9d54 Parent: 04b090d50c88ac8e5ec9c2e985bb65bd153893aa Author: James Chapman <[EMAIL PROTECTED]> AuthorDate: Mon Apr 30 00:07:31 2007 -0700 Committer: David S. Miller <[EMAIL PROTECTED]> CommitDate: Mon Apr 30 00:07:31 2007 -0700
[SKB]: Introduce skb_queue_walk_safe() This patch provides a method for walking skb lists while inserting or removing skbs from the list. Signed-off-by: James Chapman <[EMAIL PROTECTED]> Signed-off-by: David S. Miller <[EMAIL PROTECTED]> --- include/linux/skbuff.h | 5 +++++ 1 files changed, 5 insertions(+), 0 deletions(-) diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index 2694cb3..253a2b9 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h @@ -1471,6 +1471,11 @@ static inline int pskb_trim_rcsum(struct sk_buff *skb, unsigned int len) prefetch(skb->next), (skb != (struct sk_buff *)(queue)); \ skb = skb->next) +#define skb_queue_walk_safe(queue, skb, tmp) \ + for (skb = (queue)->next, tmp = skb->next; \ + skb != (struct sk_buff *)(queue); \ + skb = tmp, tmp = skb->next) + #define skb_queue_reverse_walk(queue, skb) \ for (skb = (queue)->prev; \ prefetch(skb->prev), (skb != (struct sk_buff *)(queue)); \ - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html