Created
October 3, 2019 10:43
-
-
Save TheLittleNaruto/aaec4bcbed24370c1e8062ebf934074b to your computer and use it in GitHub Desktop.
Hello Driver
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<linux/module.h> | |
#include<linux/init.h> | |
#include<linux/kernel.h> | |
static int hello_init(void){ | |
printk(KERN_ALERT "Hello TheLittleNaruto; it's your first driver which d oes no shit :/\n"); | |
return 0; | |
} | |
static void hello_exit(void){ | |
printk(KERN_INFO "Goodbye TheLittleNaruto; No point in keeping this driv er running.\n"); | |
} | |
module_init(hello_init); | |
module_exit(hello_exit); | |
MODULE_AUTHOR("TheLittleNaruto"); | |
MODULE_LICENSE("GPL"); | |
MODULE_DESCRIPTION("TheLittleNaruto's first driver with GPL licence."); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment