/* * hello.c - Hello World sample Linux kernel module. * */ #include #include #include MODULE_AUTHOR("Tigran Aivazian"); MODULE_DESCRIPTION("The simplest Linux kernel module"); #define NR_PROGS 4 static char * prognames[NR_PROGS] = {NULL, }; MODULE_PARM(prognames, "1-" __MODULE_STRING(NR_PROGS) "s"); static int __init hello_init(void) { int i; printk(KERN_ERR "hello_init()\n"); for (i=0; i\n", i, prognames[i]); else break; } return 0; } static void __exit hello_exit(void) { printk(KERN_ERR "hello_exit()\n"); } module_init(hello_init); module_exit(hello_exit);