mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-24 18:51:36 +01:00
cannot insmoe workqueue: module already loaded, even though lsmod says otherwise
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
obj-m += $(addsuffix .o, $(notdir $(basename $(wildcard $(BR2_EXTERNAL_KERNEL_MODULE_PATH)/*.c))))
|
||||
obj-m += workqueue.o
|
||||
ccflags-y := -Wno-declaration-after-statement -std=gnu99
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
13
kernel_module/workqueue.c
Normal file
13
kernel_module/workqueue.c
Normal file
@@ -0,0 +1,13 @@
|
||||
#include <linux/module.h>
|
||||
#include <linux/kernel.h>
|
||||
|
||||
int init_module(void)
|
||||
{
|
||||
printk(KERN_INFO "hello init\n");
|
||||
return 0;
|
||||
}
|
||||
|
||||
void cleanup_module(void)
|
||||
{
|
||||
printk(KERN_INFO "hello cleanup\n");
|
||||
}
|
||||
Reference in New Issue
Block a user