diff options
Diffstat (limited to 'linux/tdfx_drv.c')
-rw-r--r-- | linux/tdfx_drv.c | 41 |
1 files changed, 12 insertions, 29 deletions
diff --git a/linux/tdfx_drv.c b/linux/tdfx_drv.c index 6c7c5f02c..f102757b2 100644 --- a/linux/tdfx_drv.c +++ b/linux/tdfx_drv.c @@ -106,46 +106,29 @@ static drm_ioctl_desc_t tdfx_ioctls[] = { #define TDFX_IOCTL_COUNT DRM_ARRAY_SIZE(tdfx_ioctls) #ifdef MODULE -int init_module(void); -void cleanup_module(void); static char *tdfx = NULL; +#endif -MODULE_AUTHOR("Precision Insight, Inc., Cedar Park, Texas."); +MODULE_AUTHOR("VA Linux Systems, Inc."); MODULE_DESCRIPTION("tdfx"); MODULE_PARM(tdfx, "s"); -/* init_module is called when insmod is used to load the module */ - -int init_module(void) -{ - return tdfx_init(); -} - -/* cleanup_module is called when rmmod is used to unload the module */ - -void cleanup_module(void) -{ - tdfx_cleanup(); -} -#endif +module_init(tdfx_init); +module_exit(tdfx_cleanup); #ifndef MODULE -/* tdfx_setup is called by the kernel to parse command-line options passed - * via the boot-loader (e.g., LILO). It calls the insmod option routine, - * drm_parse_drm. - * - * This is not currently supported, since it requires changes to - * linux/init/main.c. */ - +/* tdfx_options is called by the kernel to parse command-line options + * passed via the boot-loader (e.g., LILO). It calls the insmod option + * routine, drm_parse_drm. + */ -void __init tdfx_setup(char *str, int *ints) +static int __init tdfx_options(char *str, int *ints) { - if (ints[0] != 0) { - DRM_ERROR("Illegal command line format, ignored\n"); - return; - } drm_parse_options(str); + return 1; } + +__setup("tdfx=", tdfx_options); #endif static int tdfx_setup(drm_device_t *dev) |