* [PATCH] inet: fix inet_bind_bucket_for_each
@ 2009-11-12 15:07 Lucian Adrian Grijincu
2009-11-14 4:49 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Lucian Adrian Grijincu @ 2009-11-12 15:07 UTC (permalink / raw)
To: netdev, Octavian Purdila
[-- Attachment #1: Type: text/plain, Size: 468 bytes --]
The first "node" is supposed to be the cursor used in the for_each.
The second "node" is ment literally and should not be macro expanded:
it's the name of the hlist_node field from the inet_bind_bucket.
This currently works because when inet_bind_bucket_for_each is called
it's argument is still "node".
Signed-off-by: Lucian Adrian Grijincu <lgrijincu@ixiacom.com>
---
include/net/inet_hashtables.h | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
[-- Attachment #2: 0001-inet-fix-inet_bind_bucket_for_each.patch --]
[-- Type: text/plain, Size: 542 bytes --]
diff --git a/include/net/inet_hashtables.h b/include/net/inet_hashtables.h
index 5b698b3..41cbddd 100644
--- a/include/net/inet_hashtables.h
+++ b/include/net/inet_hashtables.h
@@ -92,8 +92,8 @@ static inline struct net *ib_net(struct inet_bind_bucket *ib)
return read_pnet(&ib->ib_net);
}
-#define inet_bind_bucket_for_each(tb, node, head) \
- hlist_for_each_entry(tb, node, head, node)
+#define inet_bind_bucket_for_each(tb, pos, head) \
+ hlist_for_each_entry(tb, pos, head, node)
struct inet_bind_hashbucket {
spinlock_t lock;
^ permalink raw reply related [flat|nested] 2+ messages in thread* Re: [PATCH] inet: fix inet_bind_bucket_for_each
2009-11-12 15:07 [PATCH] inet: fix inet_bind_bucket_for_each Lucian Adrian Grijincu
@ 2009-11-14 4:49 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2009-11-14 4:49 UTC (permalink / raw)
To: lgrijincu; +Cc: netdev, opurdila
From: Lucian Adrian Grijincu <lgrijincu@ixiacom.com>
Date: Thu, 12 Nov 2009 17:07:26 +0200
> The first "node" is supposed to be the cursor used in the for_each.
>
> The second "node" is ment literally and should not be macro expanded:
> it's the name of the hlist_node field from the inet_bind_bucket.
>
> This currently works because when inet_bind_bucket_for_each is called
> it's argument is still "node".
>
> Signed-off-by: Lucian Adrian Grijincu <lgrijincu@ixiacom.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-11-14 4:49 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-11-12 15:07 [PATCH] inet: fix inet_bind_bucket_for_each Lucian Adrian Grijincu
2009-11-14 4:49 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox