1 /*
2 * Copyright (c) Wipro Technologies Ltd, 2002. All Rights Reserved.
3 *
4 * This program is free software; you can redistribute it and/or modify it
5 * under the terms of version 2 of the GNU General Public License as
6 * published by the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it would be useful, but
9 * WITHOUT ANY WARRANTY; without even the implied warranty of
10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
11 *
12 * You should have received a copy of the GNU General Public License along
13 * with this program; if not, write the Free Software Foundation, Inc.,
14 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
15 *
16 */
17 /*************************************************************************
18 * Description: This is a kernel loadable module programme used by
19 * delete_module03 testcase which inserts this module as part
20 * setup.
21 *************************************************************************/
22
23 #ifndef MODULE
24 #define MODULE
25 #endif
26
27 /* #define __KERNEL__ Commented this line out b/c it causes errors with
28 * module.h when it calls /usr/include/linux/version.h
29 * -11/22/02 Robbie Williamson <robbiew@us.ibm.com>
30 */
31
32 #include <asm/atomic.h>
33 #include <linux/module.h>
34 #include <linux/init.h>
35 #include <linux/proc_fs.h>
36 #include <linux/kernel.h>
37
38 static int dummy_func_test(void);
39
40 /* Dummy function called by dependent module */
41
dummy_func_test()42 static int dummy_func_test()
43 {
44 return 0;
45 }
46
dummy_init(void)47 static int __init dummy_init(void)
48 {
49 struct proc_dir_entry *proc_dummy;
50
51 proc_dummy = proc_mkdir("dummy", 0);
52 return 0;
53 }
54
dummy_exit(void)55 static void __exit dummy_exit(void)
56 {
57
58 remove_proc_entry("dummy", 0);
59 }
60
61 module_init(dummy_init);
62 module_exit(dummy_exit);
63 EXPORT_SYMBOL(dummy_func_test);
64 MODULE_LICENSE("GPL");
65