summaryrefslogtreecommitdiffstats
path: root/firmware/common/linked_list.c
diff options
context:
space:
mode:
authorAidan MacDonald <amachronic@protonmail.com>2022-09-24 14:38:04 +0100
committerAidan MacDonald <amachronic@protonmail.com>2022-10-16 16:10:24 +0100
commitee9679993bddead1341bf7f36a97ef982f25a396 (patch)
treed009889b9e2c7389430f1d859fb214bb4c5c105d /firmware/common/linked_list.c
parent8bf80360212358591aa92af1591bddc7abaa47fb (diff)
downloadrockbox-ee9679993b.tar.gz
rockbox-ee9679993b.zip
linked list: inline list init functions
These functions are so trivial it's always cheaper to inline them. Change-Id: Ie0c77c8b6e7a716312105445a22e62ff57a76d90
Diffstat (limited to 'firmware/common/linked_list.c')
-rw-r--r--firmware/common/linked_list.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/firmware/common/linked_list.c b/firmware/common/linked_list.c
index b8f2dd181c..7697a052ca 100644
--- a/firmware/common/linked_list.c
+++ b/firmware/common/linked_list.c
@@ -46,15 +46,6 @@ static struct ll_node * ll_search_prev(struct ll_head *list,
}
/**
- * Initializes the singly-linked list
- */
-void ll_init(struct ll_head *list)
-{
- list->head = NULL;
- list->tail = NULL;
-}
-
-/**
* Adds a node to s singly-linked list using "insert next"
*/
void ll_insert_next(struct ll_head *list, struct ll_node *node,
@@ -143,18 +134,6 @@ void ll_remove(struct ll_head *list, struct ll_node *node)
/** (L)inked (L)ist (D)ouble **/
/**
- * Initializes the doubly-linked list
- */
-void lld_init(struct lld_head *list)
-{
- list->head = NULL;
- list->tail = NULL;
-
- /* tail could be stored in first item's prev pointer but this simplifies
- the routines and maintains the non-circularity */
-}
-
-/**
* Adds a node to a doubly-linked list using "insert first"
*/
void lld_insert_first(struct lld_head *list, struct lld_node *node)
@@ -238,14 +217,6 @@ static inline struct lldc_node * lldc_insert(struct lldc_head *list,
}
/**
- * Initializes the doubly-linked circular list
- */
-void lldc_init(struct lldc_head *list)
-{
- list->head = NULL;
-}
-
-/**
* Adds a node to a doubly-linked circular list using "insert first"
*/
void lldc_insert_first(struct lldc_head *list, struct lldc_node *node)