View previous topic :: View next topic |
Author |
Message |
nenoro n00b
Joined: 07 Jan 2018 Posts: 55
|
Posted: Sat Mar 23, 2024 5:08 pm Post subject: compile the kernel but error due to mm/vmscan |
|
|
Hello
So i wanted to compile the kernel and it has been a while i'm stuck with the 6.6.8 because above this version i have an error i can't figure out or on internet.
Code: | mm/vmscan.c: In function ‘shrink_node’:
mm/vmscan.c:6053:9: error: implicit declaration of function ‘prepare_workingset_protection’ [-Werror=implicit-function-declaration]
6053 | prepare_workingset_protection(pgdat, sc);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mm/vmscan.c:6145:17: error: implicit declaration of function ‘invoke_oom’ [-Werror=implicit-function-declaration]
6145 | invoke_oom(sc);
| ^~~~~~~~~~
mm/vmscan.c: At top level:
mm/vmscan.c:201:12: warning: ‘workingset_protection_prev_totalram’ defined but not used [-Wunused-variable]
201 | static u64 workingset_protection_prev_totalram __read_mostly = 0;
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
mm/vmscan.c:200:12: warning: ‘sysctl_clean_min_ratio_kb’ defined but not used [-Wunused-variable]
200 | static u64 sysctl_clean_min_ratio_kb __read_mostly = 0;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
mm/vmscan.c:199:12: warning: ‘sysctl_clean_low_ratio_kb’ defined but not used [-Wunused-variable]
199 | static u64 sysctl_clean_low_ratio_kb __read_mostly = 0;
| ^~~~~~~~~~~~~~~~~~~~~~~~~
mm/vmscan.c:198:12: warning: ‘sysctl_anon_min_ratio_kb’ defined but not used [-Wunused-variable]
198 | static u64 sysctl_anon_min_ratio_kb __read_mostly = 0;
| ^~~~~~~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
make[3]: *** [scripts/Makefile.build:243: mm/vmscan.o] Error 1
make[2]: *** [scripts/Makefile.build:481: mm] Error 2
make[2]: *** Waiting for unfinished jobs....
|
That is the issue i'm trying to find where is it in the nconfig
CPU: R7 5700x
RAM: 32 GB
i hope you won't ask me to do emerge --info since it's a kernel situation not compile a package. |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21867
|
Posted: Sat Mar 23, 2024 5:26 pm Post subject: |
|
|
Please provide the output of head Makefile and a description of how you obtained the kernel source that fails. I checked v6.6.8, v6.6.9, v6.7, and v6.8.1; none of them have anything like that at mm/vmscan.c:6053. I even tried to git grep prepare_workingset and was not able to find a reference to it anywhere in the kernels I checked. |
|
Back to top |
|
|
nenoro n00b
Joined: 07 Jan 2018 Posts: 55
|
Posted: Sat Mar 23, 2024 6:44 pm Post subject: |
|
|
Hu wrote: | Please provide the output of head Makefile and a description of how you obtained the kernel source that fails. I checked v6.6.8, v6.6.9, v6.7, and v6.8.1; none of them have anything like that at mm/vmscan.c:6053. I even tried to git grep prepare_workingset and was not able to find a reference to it anywhere in the kernels I checked. |
V6.6.8 has no issue it's above i have this issue when i use xanmod.
For the makefile:
https://pastebin.com/T1HmNQ3W
Source or the kernel where i downloaded it:
https://gitlab.com/xanmod/linux/-/archive/6.8.1-xanmod1/linux-6.8.1-xanmod1.tar.gz
as for Zen kernel, no vmscan error, i should check with the people who are maintaining xanmod |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21867
|
Posted: Sat Mar 23, 2024 7:01 pm Post subject: |
|
|
As I said above, I checked v6.8.1 (Linus' release) and see no sign of the code that is failing for you. You said this also fails for the vanilla and gentoo kernels. How did you obtain the source for the broken versions of those?
Looking at the xanmod code, it is clear to me that this code is wrong. Whoever wrote the addition of prepare_workingset_protection clearly did it wrong. It is defined inside a preprocessor guarded block, but then unconditionally used. Either the preprocessor guard should not exclude the definition of this function, or the #else block should provide a stub definition, or the call to the function should itself be wrapped in a preprocessor guard. Without delving into how the xanmod sources were produced, I cannot comment on whether this is something that xanmod broke or if they copied someone else's broken work for use as a baseline. |
|
Back to top |
|
|
nenoro n00b
Joined: 07 Jan 2018 Posts: 55
|
Posted: Sun Mar 31, 2024 4:17 pm Post subject: |
|
|
So you suggest to not use xanmod kernel but another kernel who doesn't have this issue ? |
|
Back to top |
|
|
Hu Administrator
Joined: 06 Mar 2007 Posts: 21867
|
Posted: Sun Mar 31, 2024 4:31 pm Post subject: |
|
|
Your choices are:- Use a kernel which lacks the broken code.
- Enable the Kconfig symbol to define the missing function.
- Fix the code. (No, I cannot tell you the right fix here.)
- Report it as a bug to Xanmod, and hope they fix the code.
|
|
Back to top |
|
|
nenoro n00b
Joined: 07 Jan 2018 Posts: 55
|
Posted: Sun Mar 31, 2024 6:28 pm Post subject: |
|
|
noted
i use zen kernel, my first choice before |
|
Back to top |
|
|
|