Re: Modules vs. Resident Kernel

From: Manfred Spraul (manfred@colorfullife.com)
Date: Tue Jul 11 2000 - 16:23:52 EST


"Boerner, Brian" wrote:
>
> Howdy Folks
>
> I'm working on a hw raid driver for some of the Dell and HP raid
> controllers. I'm running into a problem on the 2.2.16-3
> kernel when my driver is built as part of the resident kernel on an SMP
> system.
>
Which compiler & binutils do you use?

>
> For people who are interested, I've included the acquire and release
> spinlock routines. Just to make sure
> I'm not doing something stupid here that just hasn't been picked up before.
>

spin_lock_irqsave() stores the previous interrupt enabled flag _before_
it spins, thus you must at least replace cpu_flag with a per-cpu array.
And note that this won't work on sparc, afaik the sparc cpu stores a
combination of the stack pointer and the interrupt flag in cpu_flag -->
crash during spin_unlock_irqrestore().

--
	Manfred

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Jul 15 2000 - 21:00:13 EST