#include <linux/kmod.h>
#include <linux/seq_file.h>
#include <linux/proc_compat.h>
+#include <linux/version.h>
#include <spl-debug.h>
#ifdef SS_DEBUG_SUBSYS
#define SS_DEBUG_SUBSYS SS_PROC
+#if defined(CONSTIFY_PLUGIN) && LINUX_VERSION_CODE >= KERNEL_VERSION(3,8,0)
+typedef struct ctl_table __no_const spl_ctl_table;
+#else
+typedef struct ctl_table spl_ctl_table;
+#endif
+
#ifdef DEBUG_KMEM
static unsigned long table_min = 0;
static unsigned long table_max = ~0;
SPL_PROC_HANDLER(proc_console_max_delay_cs)
{
int rc, max_delay_cs;
- struct ctl_table dummy = *table;
+ spl_ctl_table dummy = *table;
long d;
SENTRY;
SPL_PROC_HANDLER(proc_console_min_delay_cs)
{
int rc, min_delay_cs;
- struct ctl_table dummy = *table;
+ spl_ctl_table dummy = *table;
long d;
SENTRY;
SPL_PROC_HANDLER(proc_console_backoff)
{
int rc, backoff;
- struct ctl_table dummy = *table;
+ spl_ctl_table dummy = *table;
SENTRY;
dummy.data = &backoff;
{
int rc = 0;
unsigned long min = 0, max = ~0, val;
- struct ctl_table dummy = *table;
+ spl_ctl_table dummy = *table;
SENTRY;
dummy.data = &val;
{
int rc = 0;
unsigned long min = 0, max = ~0, val = 0, mask;
- struct ctl_table dummy = *table;
+ spl_ctl_table dummy = *table;
spl_kmem_cache_t *skc;
SENTRY;