]> git.ipfire.org Git - thirdparty/iproute2.git/commitdiff
list: add list_add_tail helper
authorJiri Pirko <jiri@mellanox.com>
Fri, 15 Apr 2016 07:51:45 +0000 (09:51 +0200)
committerStephen Hemminger <stephen@networkplumber.org>
Tue, 19 Apr 2016 15:01:05 +0000 (08:01 -0700)
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
include/list.h

index b549c3ec80ada3b2a3675bf43510f14d24aa2a2b..5b529dc6e5211a8e191ebe78a80e4d8d97e109fa 100644 (file)
@@ -33,6 +33,11 @@ static inline void list_add(struct list_head *new, struct list_head *head)
        __list_add(new, head, head->next);
 }
 
+static inline void list_add_tail(struct list_head *new, struct list_head *head)
+{
+       __list_add(new, head->prev, head);
+}
+
 static inline void __list_del(struct list_head *prev, struct list_head *next)
 {
        next->prev = prev;