Commit | Line | Data |
---|---|---|
1 | /* | |
2 | * hello-1.c - The simplest kernel module. | |
3 | */ | |
4 | #include <linux/module.h> /* Needed by all modules */ | |
5 | #include <linux/kernel.h> /* Needed for KERN_INFO */ | |
6 | ||
7 | MODULE_DESCRIPTION("Simple HelloWorld LKM"); | |
8 | MODULE_AUTHOR("Thomas 'Harvie' Mudrunka <harvie@email.cz>"); | |
9 | MODULE_LICENSE("Dual BSD/GPL"); | |
10 | ||
11 | int init_module(void) | |
12 | { | |
13 | printk(KERN_INFO "Hello world 1.\n"); | |
14 | return 0; | |
15 | } | |
16 | ||
17 | void cleanup_module(void) | |
18 | { | |
19 | printk(KERN_INFO "Goodbye world 1.\n"); | |
20 | } |