From 941d2cf431d0534ec53f90e627bb0445b6f0260e Mon Sep 17 00:00:00 2001 From: Jon Smirl Date: Wed, 15 Sep 2004 16:06:50 +0000 Subject: [PATCH] Don't use module_param if it isn't defined in older kernels. --- linux-core/drm_stub.c | 8 ++++++-- linux/drm_stub.h | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/linux-core/drm_stub.c b/linux-core/drm_stub.c index 8fd690d..c70de9b 100644 --- a/linux-core/drm_stub.c +++ b/linux-core/drm_stub.c @@ -39,11 +39,15 @@ static unsigned int debug = 0; /* 1 to enable debug output */ MODULE_AUTHOR( DRIVER_AUTHOR ); MODULE_DESCRIPTION( DRIVER_DESC ); MODULE_LICENSE("GPL and additional rights"); -module_param(cards_limit, int, 0444); MODULE_PARM_DESC(cards_limit, "Maximum number of graphics cards"); -module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Enable debug output"); +#ifdef module_param +module_param(cards_limit, int, 0444); +module_param(debug, int, 0644); +#endif + +MODULE_AUTHOR( DRIVER_AUTHOR ); drm_global_t *DRM(global); /** diff --git a/linux/drm_stub.h b/linux/drm_stub.h index 8fd690d..c70de9b 100644 --- a/linux/drm_stub.h +++ b/linux/drm_stub.h @@ -39,11 +39,15 @@ static unsigned int debug = 0; /* 1 to enable debug output */ MODULE_AUTHOR( DRIVER_AUTHOR ); MODULE_DESCRIPTION( DRIVER_DESC ); MODULE_LICENSE("GPL and additional rights"); -module_param(cards_limit, int, 0444); MODULE_PARM_DESC(cards_limit, "Maximum number of graphics cards"); -module_param(debug, int, 0644); MODULE_PARM_DESC(debug, "Enable debug output"); +#ifdef module_param +module_param(cards_limit, int, 0444); +module_param(debug, int, 0644); +#endif + +MODULE_AUTHOR( DRIVER_AUTHOR ); drm_global_t *DRM(global); /** -- 2.7.4