Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Linux: Kernel
PREEMPT_ACTIVE too low error with all asm-generic headers for some arches
 

Index | Next | Previous | View Flat


vapier.adi at gmail

Jun 23, 2009, 3:08 PM


Views: 165
Permalink
PREEMPT_ACTIVE too low error with all asm-generic headers for some arches

after pulling the latest mainline code, Blackfin started hitting a
build failure like so:
CC arch/blackfin/kernel/asm-offsets.s
In file included from include/linux/interrupt.h:12,
from include/linux/kernel_stat.h:8,
from arch/blackfin/kernel/asm-offsets.c:32:
include/linux/hardirq.h:66:2: error: #error PREEMPT_ACTIVE is too low!
make[1]: *** [arch/blackfin/kernel/asm-offsets.s] Error 1

this is because we've converted to asm-generic for most of our headers
(including hardirq.h). originally we were defining HARDIRQ_BITS
ourselves to 8, but then we dropped that in favor of the
asm-generic/hardirq.h which setup a default of 8. but then they
dropped it in favor of the linux/hardirq.h default handling ... but it
sets it to MAX_HARDIRQ_BITS by default which is 10. which pushes
Blackfin over the edge and into this build error.

if we look at linux/hardirq.h, it makes this claim:
* - bit 28 is the PREEMPT_ACTIVE flag
if that's true, then why are we letting any arch set this define ? a
quick survey shows that half the arches (11) are using 0x10000000 (bit
28) while the other half (10) are using 0x4000000 (bit 26). and then
there is the ia64 oddity which uses bit 30. the exact value here
shouldnt really matter across arches though should it ?

how about adding this to linux/thread_info.h:
#ifndef PREEMPT_ACTIVE
# ifndef PREEMPT_ACTIVE_BIT
# define PREEMPT_ACTIVE_BIT 28
# endif
# define PREEMPT_ACTIVE (1 << PREEMPT_ACTIVE_BIT)
#endif
-mike
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo[at]vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Subject User Time
PREEMPT_ACTIVE too low error with all asm-generic headers for some arches vapier.adi at gmail Jun 23, 2009, 3:08 PM
    Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches mingo at elte Jun 24, 2009, 6:13 AM
        Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches vapier.adi at gmail Jun 24, 2009, 6:22 AM
        Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches arnd at arndb Jun 24, 2009, 7:02 AM
            Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches vapier.adi at gmail Jun 24, 2009, 8:02 AM
    Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches mingo at elte Jun 24, 2009, 8:13 AM
    Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches vapier.adi at gmail Jun 24, 2009, 3:21 PM
    Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches vapier.adi at gmail Jul 4, 2009, 3:43 PM
    Re: PREEMPT_ACTIVE too low error with all asm-generic headers for some arches rgetz at blackfin Jul 7, 2009, 5:41 AM

  Index | Next | Previous | View Flat
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.