X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f Message-ID: <014301c472f9$33d162c0$0d01a8c0@josepmariaxp> From: "turomas" To: Subject: PM hardware interrupts Date: Mon, 26 Jul 2004 12:13:13 +0200 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0140_01C47309.ECB4FA80" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2720.3000 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2739.300 X-MailScanner-Information: Please contact the ISP for more information X-MailScanner: Found to be clean Reply-To: djgpp AT delorie DOT com This is a multi-part message in MIME format. ------=_NextPart_000_0140_01C47309.ECB4FA80 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable First: The inline assembler is to store the coprocessor state and restor it = after interrupt ends. (If the interrupt ocurs when coprocessor is doing = any action - A floating comparation - and there are floating point = operations in the interrupt the coprocessor makes non interrupt = operation wrong). Second: It is normal ethernet cards, sound cards, etcs... uses Int10. Try to use = Int 9 or Int 5. If you want to use Int 10 go to Bios configuration = PNP/PCI Configuration and tell Bios that you uses NO PNP Operating = System. Then go to IRQ Resources and put Irq 10 to Legacy ISA. This = reserve IRQ10 to you because no PNP cards can uses this interrupt. Third: When a interrupt finishes you have to tell it to processor and to PIC. = Processor accepts new interrupts when receives enable() ("sti") or when = receives "iret" function. Don't put enable() in your interrupt code, = DPMI libraries do it for you and it can crash your code. PIC have to = receive an non specific EOI outport(0x20,0x20). I did have problems with chain in some interrupts. What hapens if old = ineterrupt enables CPU in the middle of the code?........ ------=_NextPart_000_0140_01C47309.ECB4FA80 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
First:
 
The inline assembler is to store the = coprocessor=20 state and restor it after interrupt ends. (If the interrupt ocurs when=20 coprocessor is doing any action - A floating comparation - and there are = floating point operations in the interrupt the coprocessor makes non = interrupt=20 operation wrong).
 
 
Second:
 
It is normal ethernet cards, sound = cards, etcs...=20 uses Int10. Try to use Int 9 or Int 5. If you want to use Int 10 go to = Bios=20 configuration PNP/PCI Configuration and tell Bios that you uses NO PNP = Operating=20 System. Then go to IRQ Resources and put Irq 10 to Legacy ISA. This = reserve=20 IRQ10  to you because no PNP cards can uses this = interrupt.
 
 
Third:
When a interrupt finishes you have to = tell it to=20 processor and to PIC. Processor accepts new interrupts when receives = enable()=20 ("sti") or when receives "iret" function.  Don't put enable() in = your=20 interrupt code, DPMI libraries  do it for you and it can crash your = code.=20 PIC have to receive an non specific EOI=20 outport(0x20,0x20).
 
 
I did have problems with chain in some = interrupts.=20 What hapens if old ineterrupt enables CPU in the middle of the=20 code?........
------=_NextPart_000_0140_01C47309.ECB4FA80--