summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Braun <rbraun@sceen.net>2018-01-04 22:21:30 +0100
committerRichard Braun <rbraun@sceen.net>2018-01-04 22:21:30 +0100
commita6c056ce150bd0339d5325edc18717b2d02a5b8d (patch)
treee25263fcfd024991fb784850f5ba0be5bb82aedf
parent102eb0d251ce4e0155906224ab60263d0cd792b0 (diff)
list: update from upstream
-rw-r--r--lib/list.h8
-rw-r--r--src/timer.c2
2 files changed, 5 insertions, 5 deletions
diff --git a/lib/list.h b/lib/list.h
index 6e9c599..80afd71 100644
--- a/lib/list.h
+++ b/lib/list.h
@@ -257,7 +257,7 @@ list_insert_tail(struct list *list, struct list *node)
* Insert a node before another node.
*/
static inline void
-list_insert_before(struct list *next, struct list *node)
+list_insert_before(struct list *node, struct list *next)
{
list_add(next->prev, next, node);
}
@@ -266,7 +266,7 @@ list_insert_before(struct list *next, struct list *node)
* Insert a node after another node.
*/
static inline void
-list_insert_after(struct list *prev, struct list *node)
+list_insert_after(struct list *node, struct list *prev)
{
list_add(prev, prev->next, node);
}
@@ -451,7 +451,7 @@ list_llsync_insert_tail(struct list *list, struct list *node)
* Insert a node before another node.
*/
static inline void
-list_llsync_insert_before(struct list *next, struct list *node)
+list_llsync_insert_before(struct list *node, struct list *next)
{
list_llsync_add(next->prev, next, node);
}
@@ -460,7 +460,7 @@ list_llsync_insert_before(struct list *next, struct list *node)
* Insert a node after another node.
*/
static inline void
-list_llsync_insert_after(struct list *prev, struct list *node)
+list_llsync_insert_after(struct list *node, struct list *prev)
{
list_llsync_add(prev, prev->next, node);
}
diff --git a/src/timer.c b/src/timer.c
index b663e10..a9fc6f7 100644
--- a/src/timer.c
+++ b/src/timer.c
@@ -283,7 +283,7 @@ timer_schedule(struct timer *timer, unsigned long ticks)
}
}
- list_insert_before(&tmp->node, &timer->node);
+ list_insert_before(&timer->node, &tmp->node);
timer = list_first_entry(&timer_list, typeof(*timer), node);