From dc0f920710ecaa023df893216987c318c2e2b721 Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Tue, 23 Dec 2008 13:25:52 -0800 Subject: Minor updates --- include/sys/list.h | 35 +++++++++++++++++++++++++++++++++++ include/sys/u8_textprep.h | 4 ++++ 2 files changed, 39 insertions(+) create mode 100644 include/sys/u8_textprep.h (limited to 'include') diff --git a/include/sys/list.h b/include/sys/list.h index 465576d5c..73bbca0c9 100644 --- a/include/sys/list.h +++ b/include/sys/list.h @@ -1,4 +1,39 @@ #ifndef _SPL_LIST_H #define _SPL_LIST_H +#include + +typedef struct list_node { + struct list_node *list_next; + struct list_node *list_prev; +} list_node_t; + +typedef struct list { + size_t list_size; + size_t list_offset; + struct list_node list_head; +} list_t; + +void list_create(list_t *, size_t, size_t); +void list_destroy(list_t *); + +void list_insert_after(list_t *, void *, void *); +void list_insert_before(list_t *, void *, void *); +void list_insert_head(list_t *, void *); +void list_insert_tail(list_t *, void *); +void list_remove(list_t *, void *); +void *list_remove_head(list_t *); +void *list_remove_tail(list_t *); + +void *list_head(list_t *); +void *list_tail(list_t *); +void *list_next(list_t *, void *); +void *list_prev(list_t *, void *); +int list_is_empty(list_t *); + +void list_link_init(list_node_t *); +void list_link_replace(list_node_t *, list_node_t *); + +int list_link_active(list_node_t *); + #endif /* SPL_LIST_H */ diff --git a/include/sys/u8_textprep.h b/include/sys/u8_textprep.h new file mode 100644 index 000000000..e659548e3 --- /dev/null +++ b/include/sys/u8_textprep.h @@ -0,0 +1,4 @@ +#ifndef _SPL_U8_TEXTPREP_H +#define _SPL_U8_TEXTPREP_H + +#endif /* SPL_U8_TEXTPREP_H */ -- cgit v1.2.3