Re: Recent development patches

Mikael Pettersson <[email protected]>
Newsgroups gmane.linux.swsusp.devel
Message-ID <[email protected]>
Milan Oravec writes:
 > Hi Mikael, patches applied cleanly, but compilation ends witch error:
 > 
 >    CC      kernel/power/tuxonice_userui.o
 >    CC [M]  arch/x86/kvm/../../../virt/kvm/assigned-dev.o
 > kernel/power/tuxonice_userui.c:598: error: ‘THIS_MODULE’ undeclared here 
 > (not in a function)
 > make[2]: *** [kernel/power/tuxonice_userui.o] Error 1
 > make[1]: *** [kernel/power] Error 2
 > make: *** [kernel] Error 2
 > 
 > I'm using tuxoniceui_text in kernel config.

This is caused by Linux header file changes between the 3.1 and 3.2-rc
kernels.  I had fixed it for many of the other tuxonice_*.c files, but
missed this one since I don't enable the UI bits myself.

Fixed by the patch below.

/Mikael

--- linux-3.2-rc4/kernel/power/tuxonice_userui.c.~1~	2011-12-06 10:05:20.000000000 +0100
+++ linux-3.2-rc4/kernel/power/tuxonice_userui.c	2011-12-06 15:19:44.000000000 +0100
@@ -33,6 +33,7 @@
 #include <linux/security.h>
 #include <linux/syscalls.h>
 #include <linux/vt.h>
+#include <linux/module.h>
 
 #include "tuxonice_sysfs.h"
 #include "tuxonice_modules.h"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.