kernel modules: add a quick scull port from LDD3

Also:

* fix fops.c on both kernels:
  * 5.9: the out of space error code was 1 not 8
  * 6.6: for whatever reason we can't read the user buffer as before on the
         diagnostic print, it leads to segfault and oops
* create memfile.c which is like fops.c but of unlimited size
This commit is contained in:
Ciro Santilli
2025-04-28 15:23:44 +01:00
parent 3d84eccc43
commit e4847e4b40
16 changed files with 2133 additions and 50 deletions

View File

@@ -0,0 +1,37 @@
// This workspace exists to work on C files formatted like the Linux kernel,
// notably using tabs instead of space. This is unlike the C files in our userland
// programs, and we couldn't find a better way to make this distinction
// https://stackoverflow.com/questions/47405315/visual-studio-code-and-subfolder-specific-settings
{
"folders": [
{
"path": "."
},
{
"path": "submodules/linux"
}
],
"settings": {
"files.watcherExclude": {
"data/**": true,
".git/**": true,
"out.docker/**": true,
"out/**": true,
"submodules/**": true,
},
"search.exclude": {
"data/**": true,
".git/**": true,
"out.docker/**": true,
"out/**": true,
"submodules/**": true,
},
"[c]": {
"editor.tabSize": 8,
"editor.insertSpaces": false
},
"files.associations": {
"rwsem.h": "c"
}
}
}