Skip to content

Commit

Permalink
Remove on_each_cpu() wrapper
Browse files Browse the repository at this point in the history
The on_each_cpu() function has been available since Linux 2.6.27.
There is no longer a need to maintain this compatibility code.

Signed-off-by: Brian Behlendorf <[email protected]>
  • Loading branch information
behlendorf committed Oct 17, 2014
1 parent b652d16 commit 50e41ab
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 66 deletions.
23 changes: 0 additions & 23 deletions config/spl-build.m4
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ AC_DEFUN([SPL_AC_CONFIG_KERNEL], [
SPL_AC_PDE_DATA
SPL_AC_MUTEX_OWNER
SPL_AC_MUTEX_OWNER_TASK_STRUCT
SPL_AC_3ARGS_ON_EACH_CPU
SPL_AC_KALLSYMS_LOOKUP_NAME
SPL_AC_GET_VMALLOC_INFO
SPL_AC_PGDAT_HELPERS
Expand Down Expand Up @@ -972,28 +971,6 @@ AC_DEFUN([SPL_AC_MUTEX_OWNER_TASK_STRUCT], [
EXTRA_KCFLAGS="$tmp_flags"
])

dnl #
dnl # 2.6.27 API change,
dnl # on_each_cpu() uses 3 args, no 'retry' argument
dnl #
AC_DEFUN([SPL_AC_3ARGS_ON_EACH_CPU], [
AC_MSG_CHECKING([whether on_each_cpu() wants 3 args])
SPL_LINUX_TRY_COMPILE([
#include <linux/interrupt.h>
#include <linux/smp.h>
void on_each_cpu_func(void *data) { return; }
],[
on_each_cpu(on_each_cpu_func, NULL, 0);
],[
AC_MSG_RESULT(yes)
AC_DEFINE(HAVE_3ARGS_ON_EACH_CPU, 1,
[on_each_cpu wants 3 args])
],[
AC_MSG_RESULT(no)
])
])

dnl #
dnl # 2.6.18 API change,
dnl # kallsyms_lookup_name no longer exported
Expand Down
1 change: 0 additions & 1 deletion include/linux/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ KERNEL_H = \
$(top_srcdir)/include/linux/module_compat.h \
$(top_srcdir)/include/linux/proc_compat.h \
$(top_srcdir)/include/linux/rwsem_compat.h \
$(top_srcdir)/include/linux/smp_compat.h \
$(top_srcdir)/include/linux/sysctl_compat.h \
$(top_srcdir)/include/linux/wait_compat.h \
$(top_srcdir)/include/linux/zlib_compat.h
Expand Down
40 changes: 0 additions & 40 deletions include/linux/smp_compat.h

This file was deleted.

1 change: 0 additions & 1 deletion include/sys/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
#include <linux/file_compat.h>
#include <linux/list_compat.h>
#include <linux/bitops_compat.h>
#include <linux/smp_compat.h>
#include <linux/kallsyms_compat.h>
#include <linux/module_compat.h>
#include <linux/sysctl_compat.h>
Expand Down
2 changes: 1 addition & 1 deletion module/spl/spl-kmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -1391,7 +1391,7 @@ spl_cache_age(void *data)
atomic_inc(&skc->skc_ref);

if (!(skc->skc_flags & KMC_NOMAGAZINE))
spl_on_each_cpu(spl_magazine_age, skc, 1);
on_each_cpu(spl_magazine_age, skc, 1);

spl_slab_reclaim(skc, skc->skc_reap, 0);

Expand Down

0 comments on commit 50e41ab

Please sign in to comment.