Subject: Re: power hook and spl level
To: Artur Grabowski <>
From: Lennart Augustsson <>
List: tech-kern
Date: 09/06/2000 11:13:47
Artur Grabowski wrote:

> Yes, that was the problem, but it's probably more complicated than that.
> (the soultion was wrong because it was only splimp, should have been splhigh).
> In this particular case the powerhook reenabled interrupts on the wavelan
> before the cardbus interrupt forwarding code has been reenabled. The only
> problem was that the interrupt wasn't acked. But in the future if a pcmcia
> device is reenabled by a powerhook before the cardbus code is reenabled,
> worse things might happen, so I would suggest some mechanism to defer
> powerhooks or put priorities in them (so that the bus is reenabled before the
> devices on that bus).

The order the power hooks are run in NetBSD should avoid this problem.
When powering down they are run in reverse installation order and when
powering up they are run in installation order.
Since the cardbus bridge must be discovered before a device attached to
it is discovered this will give you the right order.

    -- Lennart