Skip to contentSkip to conversation

2.6.31.1 BUG #include <asm/bitsperlong.h>

DISCUSSION Bernard Pidoux 3 participants 3 messages Sep 27, 2009

lore
Share & tools
lore
#0 lore raw

The problem is that when I compile an application that never caused any problem before I get an error due to incorrect reference to <asm/bitsperlong>

This was due to int-ll64.h including <asm/bitsperlong.h> which does not exists.

Is the correct solution to replace symbolic link ?

/usr/src/linux/include/asm->asm-x86

by

/usr/src/linux/include/asm->asm-generic

Bernard Pidoux

Quoted 7 lines · Bernard Pidoux

In kernel 2.6.31.1 the following files in

/usr/src/linux-2.6.31.1/include/asm-generic/

include <asm/bitsperlong.h>

while they should #include <asm-generic/bitsperlong.h>

It would be wrong to include the generic version
directly.
We need access to the arch specifics definitions
before we include the generic version.

See how different architectures does various things in their: arch/$(ARCH)/include/asm/bitsperlong.h

Sam

#1 lore raw
Quoted 3 lines · On Sun, 27 Sep 2009 13:16:41 +0200 Bernard Pidoux <[email protected]>…

The problem is that when I compile an application that never caused any problem before I get an error due to incorrect reference to <asm/bitsperlong>

is this a userspace application? or some kernel module?

Signature · 3 lines
Arjan van de Ven 	Intel Open Source Technology Centre
For development, discussion and tips for power savings, 
visit http://www.lesswatts.org
#2 lore raw
In reply to Bernard Pidoux
Quoted 6 lines · Bernard Pidoux

The problem is that when I compile an application that never caused any problem before I get an error due to incorrect reference to <asm/bitsperlong>

This was due to int-ll64.h including <asm/bitsperlong.h> which does not exists.

Quoted 7 lines

Is the correct solution to replace symbolic link ?

/usr/src/linux/include/asm->asm-x86

by

/usr/src/linux/include/asm->asm-generic

The correct fix is to include the missing bitsperlong in the asm-x86 directory.
In other words your kernel headers are broken.

Looking at latest kernel we do export bitsperlong.h. So see if you can find a fix for your broken kernel headers.

Sam