Skip to content

Instantly share code, notes, and snippets.

@kragniz
Created November 13, 2019 13:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kragniz/30edb98d1b870ba59acbdc0f1ea14f47 to your computer and use it in GitHub Desktop.
Save kragniz/30edb98d1b870ba59acbdc0f1ea14f47 to your computer and use it in GitHub Desktop.
How to use vscode for linux kernel module development against linux git
{
"configurations": [
{
"name": "Linux",
"includePath": [
"${workspaceFolder}/**",
"/home/kgz/git/linux/include/generated",
"/home/kgz/git/linux/arch/x86/include/generated",
"/home/kgz/git/linux/arch/x86/include",
"/home/kgz/git/linux/include"
],
"defines": [
"__KERNEL__"
],
"compilerPath": "/usr/bin/gcc",
"cStandard": "c11",
"cppStandard": "c++17",
"intelliSenseMode": "gcc-x64"
}
],
"version": 4
}
@cnnrznn
Copy link

cnnrznn commented Jan 13, 2024

For me I had to define defines as [ "__KERNEL__", "MODULE"] as well

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment