diff options
author | Luca Coelho <luciano.coelho@intel.com> | 2018-02-18 15:24:52 +0200 |
---|---|---|
committer | Johannes Berg <johannes.berg@intel.com> | 2018-02-23 12:33:30 +0100 |
commit | 3b0d02e17c0c063f3893d7fcb0caa66954a75c8c (patch) | |
tree | 1fef6f882cbb7f8d908bd0b3b0c15243904c999d /backport/backport-include/linux | |
parent | 1c96e546c821aef6e0fb5028d93cc6735a6f3b1c (diff) |
backport: include lib/bucket_locks.c
The alloc/free_bucket_spinlocks() functions were moved to a new lib
file, namely bucket_locks.c. Add an auto-backport for the
bucket_locks.c file and move the patching of the code that moved from
rhashtable to bucket_locks.c.
Signed-off-by: Luca Coelho <luciano.coelho@intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'backport/backport-include/linux')
-rw-r--r-- | backport/backport-include/linux/spinlock.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/backport/backport-include/linux/spinlock.h b/backport/backport-include/linux/spinlock.h new file mode 100644 index 00000000..07daa358 --- /dev/null +++ b/backport/backport-include/linux/spinlock.h @@ -0,0 +1,13 @@ +#ifndef __BACKPORT_SPINLOCK_H +#define __BACKPORT_SPINLOCK_H +#include_next <linux/spinlock.h> + +#if LINUX_VERSION_IS_LESS(4,16,0) +int alloc_bucket_spinlocks(spinlock_t **locks, unsigned int *lock_mask, + size_t max_size, unsigned int cpu_mult, + gfp_t gfp); + +void free_bucket_spinlocks(spinlock_t *locks); +#endif /* LINUX_VERSION_IS_LESS(4,16,0) */ + +#endif /* __BACKPORT_SPINLOCK_H */ |