mirror of
https://github.com/sysprog21/lkmpg.git
synced 2024-11-22 14:18:35 +08:00
10c7a9433a
This patch makes source listing shorter and more compact, that helps when browsing.
26 lines
572 B
C
26 lines
572 B
C
/*
|
|
* hello-4.c - Demonstrates module documentation.
|
|
*/
|
|
#include <linux/init.h> /* Needed for the macros */
|
|
#include <linux/kernel.h> /* Needed for KERN_INFO */
|
|
#include <linux/module.h> /* Needed by all modules */
|
|
|
|
MODULE_LICENSE("GPL");
|
|
MODULE_AUTHOR("LKMPG");
|
|
MODULE_DESCRIPTION("A sample driver");
|
|
MODULE_SUPPORTED_DEVICE("testdevice");
|
|
|
|
static int __init init_hello_4(void)
|
|
{
|
|
pr_info("Hello, world 4\n");
|
|
return 0;
|
|
}
|
|
|
|
static void __exit cleanup_hello_4(void)
|
|
{
|
|
pr_info("Goodbye, world 4\n");
|
|
}
|
|
|
|
module_init(init_hello_4);
|
|
module_exit(cleanup_hello_4);
|