How to report and verify that a kernel bug was solved.
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to report and verify that a kernel bug was solved.
While building a driver for Fedora 11, kernel 2.6.30.5-43.fc11.i686.PAE, I encounter the following error,
[include/linux/mm_inline.h:31: error: implicit declaration of function ‘mem_cgroup_add_lru_list’
include/linux/mm_inline.h: In function ‘del_page_from_lru_list’:
include/linux/mm_inline.h:39: error: implicit declaration of function ‘mem_cgroup_del_lru_list’]
I think that this is a bug in the kernel. My questions are how and where to report the bug and how to verify that the bug has been solved in a recent version?
While building a driver for Fedora 11, kernel 2.6.30.5-43.fc11.i686.PAE, I encounter the following error,
Code:
include/linux/mm_inline.h:31: error: implicit declaration of function ‘mem_cgroup_add_lru_list’
include/linux/mm_inline.h: In function ‘del_page_from_lru_list’:
include/linux/mm_inline.h:39: error: implicit declaration of function ‘mem_cgroup_del_lru_list’
I think that this is a bug in the kernel.
You are building a driver that's not part of the kernel, so, what's your base to state that the bug is in the kernel?
In any case, it seems to me that you just don't have the needed headers or kernel sources in place. Gcc can't find them, so it can't find the prototype for mem_cgroup_add_lru_list(), and hence it *thinks* that you are trying to declarate is implicitly. The real problem is most likely that the declaration can't be found because you are missing the source files.
I know nothing about fedora, but you will usually need to install a package that's similar to 2.6.30.5-43.fc11.i686.PAE but with the word "headers" or "src" in the middle of that, those will contain the headers and sources for this kernel that you are using, and that are needed to compile drivers for this kernel. Additional steps might be needed depending on the driver itself.
It seems that mem_inline should have included memcontrol.h which is not the case?
It entirely depends on *where* is this driver looking for the kernel sources/headers. The make or configure output and the config.log should offer you some hints on this. Usually (and don't take this as a rule), programs will use either /lib/modules/`uname -r`/build OR /usr/src/linux to determine the correct source tree to use. Both of them should be symlinks pointing to your kernel sources.
make -C /lib/modules/2.6.30.5-43.fc11.i686.PAE/build
make[4]: Entering directory `/usr/src/kernels/2.6.30.5-43.fc11.i686.PAE'
However, if I go and do a grep in lib/modules/2.6.30.5-43.fc11.i686.PAE/build, I get the same three hits. Is not it clear that mem_inline.h is not including the header file with the correct definition of the function?
I can paste both the header files on pastebin.ca. I have never used it. So what is the procedure? How would you pick that up from there. Do you need some info, or a tag from me.
When you paste something in a pastebin, it gives you an url as response, you need to copy it and paste it here. It's useful to exchange big log files, kernel configs, source files, the output of commands, and things like that. A lot of people us it for collaborative debugging, which is kind of the case here.
It might not be possible for me to send you the drivers. I am under a contract. Is there any way, you could help me debug the issue without compiling the driver yourself?
Oh, sorry, I thought they were publicly available.
Well, I suggest you to try this on the sources of that driver:
Code:
grep -r 'mm_inline.h'
Try to locate from where is that header included, and make sure that memcontrol.h is included before mm_inline.sh. You will probably find something like this:
That's all the help I can give though, note that even if I have the sources, I am not really a kernel hacker and don't know much about the internals. I know and understand C, but never wondered to deep inside the linux kernel. In any case, even if there's any other problem, now your driver should not complain about the implicit declaration of that function, because it's declared in memcontrol.h, but the fact that it's an extern function can have many implications.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.