Page 1 of 1

Compile error with grsecurity-2.2.0-2.6.32.22-201009212029

PostPosted: Wed Sep 22, 2010 2:04 pm
by jdoe
I'm seeing this while trying to compile the current patch:

Code: Select all
In file included from /usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic.h:4,
                 from /usr/src/linux-2.6.32.22/arch/x86/include/asm/thread_info.h:24,
                 from include/linux/thread_info.h:56,
                 from include/linux/preempt.h:9,
                 from include/linux/spinlock.h:50,
                 from include/linux/seqlock.h:29,
                 from include/linux/time.h:8,
                 from include/linux/stat.h:60,
                 from init/noinitramfs.c:21:
/usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic_64.h: In function ‘atomic_inc_return_unchecked’:
/usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic_64.h:375: warning: passing argument 2 of ‘atomic_add_return’ from incompatible pointer type


... it may be a general thing for all of the functions in that header, there's at least this as well:

Code: Select all
In file included from /usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic.h:4,
                 from include/linux/crypto.h:20,
                 from arch/x86/kernel/asm-offsets_64.c:8,
                 from arch/x86/kernel/asm-offsets.c:4:
/usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic_64.h: In function ‘atomic_inc_return_unchecked’:
/usr/src/linux-2.6.32.22/arch/x86/include/asm/atomic_64.h:375: warning: passing argument 2 of ‘atomic_add_return’ from incompatible pointer type

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Wed Sep 22, 2010 6:55 pm
by spender
I've uploaded a new patch that fixes this and also reverts a Xen patch in the latest stable kernels (not in grsec) that was causing some Xen domUs to fail to boot.

-Brad

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 2:11 pm
by jdoe
Thanks, compiles fine now... although netstat is giving an odd error

Code: Select all
warning, got bogus unix line.
warning, got bogus unix line.
warning, got bogus unix line.
warning, got bogus unix line.


... etc.

I'm not sure if it's grsec or something else. This is a much-delayed upgrade from 2.6.32.7, but it wasn't happening there (and the kernel config is the same.)

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 2:45 pm
by spender
Could you mail me the contents of your /proc/net/unix file, or just the first line of it?

-Brad

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 6:37 pm
by jdoe
The entire Num column is (null), ie

Code: Select all
(null): 00000002 00000000 00010000 0001 01  4950 private/proxymap

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 7:20 pm
by spender
Ok, that's some mainline kernel stupidity that they replaced the output of %p with something that can't be parsed as a %p in userland. Will fix it in the next patch.

-Brad

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 7:32 pm
by jdoe
Awesome, thanks to both of you for your efforts.

Re: Compile error with grsecurity-2.2.0-2.6.32.22-2010092120

PostPosted: Thu Sep 23, 2010 8:03 pm
by spender
I've uploaded new patches that should resolve this issue. Thanks for the report.

-Brad