diff options
author | Jiri Olsa <jolsa@kernel.org> | 2022-03-16 13:24:07 +0100 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2022-03-17 20:17:18 -0700 |
commit | a0019cd7d41a191253859349535d76ee28ab7d96 (patch) | |
tree | 7bb57e20da6fb84f931f6f62396148da53539136 /include/linux/sort.h | |
parent | 245d94965520a808f749a62f5ec41c9ae425925a (diff) |
lib/sort: Add priv pointer to swap function
Adding support to have priv pointer in swap callback function.
Following the initial change on cmp callback functions [1]
and adding SWAP_WRAPPER macro to identify sort call of sort_r.
Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Reviewed-by: Masami Hiramatsu <mhiramat@kernel.org>
Link: https://lore.kernel.org/bpf/20220316122419.933957-2-jolsa@kernel.org
[1] 4333fb96ca10 ("media: lib/sort.c: implement sort() variant taking context argument")
Diffstat (limited to 'include/linux/sort.h')
-rw-r--r-- | include/linux/sort.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/sort.h b/include/linux/sort.h index b5898725fe9d..e163287ac6c1 100644 --- a/include/linux/sort.h +++ b/include/linux/sort.h @@ -6,7 +6,7 @@ void sort_r(void *base, size_t num, size_t size, cmp_r_func_t cmp_func, - swap_func_t swap_func, + swap_r_func_t swap_func, const void *priv); void sort(void *base, size_t num, size_t size, |