www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/03/16/13:19:02

From: Shawn Hargreaves <Shawn AT talula DOT demon DOT co DOT uk>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: DJGPP gurus: interrupts wrappers are reentrant ?
Date: Sun, 16 Mar 1997 12:08:48 +0000
Organization: None
Distribution: world
Message-ID: <WgzGfHAQL+KzEwl8@talula.demon.co.uk>
References: <332BADAD DOT 63C7A87E AT lmn DOT pub DOT ro>
NNTP-Posting-Host: talula.demon.co.uk
MIME-Version: 1.0
Lines: 16
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Laurentiu Badea writes:
>My interrupt handler is designed to be "reentrant" (if another
>interrupt arrives while the current one is still served, then
>my handler just counts it), as in the attached simple program.
>Then why it hangs or keeps reporting 0 "lost irqs", at best ?

The interrupt wrappers produced by _go32_dpmi_allocate_iret_wrapper are
indeed not reentrant, because they only allocate a single stack for the
handler to use. To make this work you need to write your own asm wrapper
routine: look at the files irq.c and irqwrap.s from Allegro for an
example of how to do this...


--
Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - http://www.talula.demon.co.uk/
Beauty is a French phonetic corruption of a short cloth neck ornament.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019