Atlas - base.c

Home / systems / linux / kernel / modules Lines: 1 | Size: 508 bytes [Download] [Show on GitHub] [Search similar files] [Raw] [Raw (proxy)]
[FILE BEGIN]
1/* 2 * Hello world module 3 * 4 * This is really basic, mainly for a starting point for modules. 5 * 6 * 0x4248 7 */ 8 9#include <linux/kernel.h> 10#include <linux/module.h> 11#include <linux/kern_levels.h> 12 13#include "lib/log.h" 14 15 16static int demo_init(void) 17{ 18 LOG("base", KERN_INFO, "Hello"); 19 return 0; 20} 21 22static void demo_exit(void) 23{ 24 LOG("base", KERN_INFO, "Bye"); 25} 26 27module_init(demo_init); 28module_exit(demo_exit); 29 30MODULE_LICENSE("GPL"); 31MODULE_AUTHOR("0x4248"); 32MODULE_DESCRIPTION("A hello world driver"); 33
[FILE END]
(C) 2025 0x4248 (C) 2025 4248 Media and 4248 Systems, All part of 0x4248 See LICENCE files for more information. Not all files are by 0x4248 always check Licencing.