diff options
| author | Ken Helias <kenhelias@firemail.de> | 2014-08-06 19:09:14 -0400 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-08-06 21:01:24 -0400 |
| commit | bc18dd335a161f9229ed3aaab88ce0706cbd9867 (patch) | |
| tree | d3dd9ad2bb3f24f8df02e1faaeac3cbca0ec3ba8 /include/linux | |
| parent | d25d9feced6c94398979a035868f03e8e8d49ce8 (diff) | |
list: make hlist_add_after() argument names match hlist_add_after_rcu()
The argument names for hlist_add_after() are poorly chosen because they
look the same as the ones for hlist_add_before() but have to be used
differently.
hlist_add_after_rcu() has made a better choice.
Signed-off-by: Ken Helias <kenhelias@firemail.de>
Cc: "Paul E. McKenney" <paulmck@linux.vnet.ibm.com>
Cc: Christoph Hellwig <hch@infradead.org>
Cc: Hugh Dickins <hughd@google.com>
Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/list.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/include/linux/list.h b/include/linux/list.h index ef9594171062..624ec7f48293 100644 --- a/include/linux/list.h +++ b/include/linux/list.h | |||
| @@ -654,15 +654,15 @@ static inline void hlist_add_before(struct hlist_node *n, | |||
| 654 | *(n->pprev) = n; | 654 | *(n->pprev) = n; |
| 655 | } | 655 | } |
| 656 | 656 | ||
| 657 | static inline void hlist_add_after(struct hlist_node *n, | 657 | static inline void hlist_add_after(struct hlist_node *prev, |
| 658 | struct hlist_node *next) | 658 | struct hlist_node *n) |
| 659 | { | 659 | { |
| 660 | next->next = n->next; | 660 | n->next = prev->next; |
| 661 | n->next = next; | 661 | prev->next = n; |
| 662 | next->pprev = &n->next; | 662 | n->pprev = &prev->next; |
| 663 | 663 | ||
| 664 | if(next->next) | 664 | if (n->next) |
| 665 | next->next->pprev = &next->next; | 665 | n->next->pprev = &n->next; |
| 666 | } | 666 | } |
| 667 | 667 | ||
| 668 | /* after that we'll appear to be on some hlist and hlist_del will work */ | 668 | /* after that we'll appear to be on some hlist and hlist_del will work */ |
