🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.msdos.programmer
Article #5391

Re: using int's in C

#5391
From: Jim Bittman
Date: Sat, 23 Mar 1991 02:12
19 lines
1321 bytes
I learned something quite interesting from Microsoft Tech Support today.
It turns out that "outport(PORTID,PORTVALUE)" is not a "nice" function.
They said it must access the BIOS or DOS or something which makes it
non re-entrant (i.e. unavailable for interrupt routines).
Excuse me?  Shouldn't this just translate to:
  mov dx,PORTID
  mov ax,PORTVALUE
  out dx,ax

Not to mention the fact that for a hardware interrupt, an outport(20,20)
needs to be executed to "EOI" the 8259.  Anyway, this was their excuse
for the fact that hardware ints don't seem to work properly.  I'm sorry
that I haven't verified this yet, but I do know that a very simple
program works just fine with Borland, but dies miserably with Microsoft.

I hope this saves someone else the many, many, many, frustrating hours
I have spent dealing with this problem.

Jim Bittman, jmbj@grebyn.com
Technical Details
Message-ID: <1991Mar23.021231.21131@grebyn.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!att!princeton!njin!uupsi!grebyn!jmbj
References: <hart.669469853@blackjack>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!att!princeton!njin!uupsi!grebyn!jmbj
From: jmbj@grebyn.com (Jim Bittman)
Newsgroups: comp.os.msdos.programmer
Subject: Re: using int's in C
Message-ID: <1991Mar23.021231.21131@grebyn.com>
Date: 23 Mar 91 02:12:31 GMT
References: <hart.669469853@blackjack>
Organization: Grebyn Timesharing
Lines: 19