Hi mọi người,
Em là sinh viên mới tự học linux device driver, em code 1 bài mở đầu trong phần Linux kernel module thì gặp lỗi :
- "expected a type specifierexpected a type specifier" ở dòng MODULE_LICENSE("GPL");
Anh/Chị trong nhóm cho em hỏi cách cấu hình trong VScode như thế nào để project nhận các Linux kernel headers với ạ?
code em để ở dưới ạ, em cảm ơn ạ.
#include <linux/module.h>
static int __init init_hello(void){
printk("hello");
return 0;
}
static void __exit exit_hello(void){
printk("say goodbye");
}
molude_init(init_hello);
molude_exit(exit_hello);
MODULE_LICENSE("GPL");