diff options
Diffstat (limited to 'include/linux/list_sort.h')
| -rw-r--r-- | include/linux/list_sort.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/include/linux/list_sort.h b/include/linux/list_sort.h index 1a2df2efb771..453105f74e05 100644 --- a/include/linux/list_sort.h +++ b/include/linux/list_sort.h @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: GPL-2.0 */ #ifndef _LINUX_LIST_SORT_H #define _LINUX_LIST_SORT_H @@ -5,7 +6,9 @@ struct list_head; -void list_sort(void *priv, struct list_head *head, - int (*cmp)(void *priv, struct list_head *a, - struct list_head *b)); +typedef int __attribute__((nonnull(2,3))) (*list_cmp_func_t)(void *, + const struct list_head *, const struct list_head *); + +__attribute__((nonnull(2,3))) +void list_sort(void *priv, struct list_head *head, list_cmp_func_t cmp); #endif |
