Date: Tue, 5 May 1998 10:48:07 -0600 From: Nate Williams <nate@mt.sri.com> To: Matthias.Apitz@SOFTCON.de (Matthias Apitz) Cc: nate@mt.sri.com (Nate Williams), mobile@FreeBSD.ORG Subject: Re: PCMCIA support for AVM Fritz!Card (ISDN) Message-ID: <199805051648.KAA00805@mt.sri.com> In-Reply-To: <9805051823.AA04883@kant.SOFTCON.de> References: <9805051823.AA04883@kant.SOFTCON.de>
next in thread | previous in thread | raw e-mail | index | archive | help
> To catch the first interrupt of the card I had to move the
> call to splx(s) a little bit down in allocate_driver() in
> pccard/pccard.c:
>
> allocate_driver(struct slot *slt, struct dev_desc *desc)
> {
> ...
> err = drv->enable(devi);
> /* splx(s); ap: old location */
> /*
> * If the enable functions returns no error, then the
> * device has been successfully installed. If so, then
> * attach it to the slot, otherwise free it and return
> * the error.
> */
> if (err)
> remove_device(devi);
> else
> devi->running = 1;
> splx(s); /* ap: moved down to catch all IRQs */
> return(err);
> }
>
> Without this move the result is an "unfielded interrupt" for the
> PCCARD irq in slot_irq_handler() because the devi->running isn't
> set to 1. The card will not generate new interrupts because
> the old one isn't handled.
This is indeed a bug in FreeBSD. Interrupts should be disabled until
after devi->running is set. However, this code has changed in
FreeBSD-stable and -current. Can you see if the bug exists in newer
sources?
Nate
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-mobile" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199805051648.KAA00805>
