diff options
author | Zhihao Cheng <chengzhihao1@huawei.com> | 2024-02-02 10:22:53 +0800 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2024-09-25 15:03:08 +0200 |
commit | a3b803747b363b0ececd329583e0412672e7f30b (patch) | |
tree | a2b48674f2e28235f89d787c16e0917f7236ed7b /jffsX-utils/compr.h | |
parent | 6ff8739a6bf5fce30e9d99ee4b35322313300dcb (diff) |
mtd-utils: Extract list implementation to common lib and add list_sort support
Current list implementation code is put under jffs utils, extract it into
common lib, and add more list operations(eg. list_move, list_splice, etc.).
Besides, add list sorting support in new source file lib/list_sort.c.
This is a preparation for replacing implementation of UBIFS utils with
linux kernel libs.
Signed-off-by: Zhihao Cheng <chengzhihao1@huawei.com>
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'jffsX-utils/compr.h')
-rw-r--r-- | jffsX-utils/compr.h | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/jffsX-utils/compr.h b/jffsX-utils/compr.h index f1f5975..6969952 100644 --- a/jffsX-utils/compr.h +++ b/jffsX-utils/compr.h @@ -15,6 +15,7 @@ #include <stdlib.h> #include <stdint.h> #include "linux/jffs2.h" +#include "list.h" #define CONFIG_JFFS2_RTIME @@ -49,10 +50,6 @@ #define KERN_INFO #define KERN_DEBUG -struct list_head { - struct list_head *next, *prev; -}; - void jffs2_set_compression_mode(int mode); int jffs2_get_compression_mode(void); int jffs2_set_compression_mode_name(const char *mode_name); |