TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Dann Lunsford
from: Rinat Sadretdinow
date: 1994-08-26 04:29:52
subject: Re: ASM in OS/2

Yo there Dann!

Friday August 19 1994, Dann Lunsford writes to All:

 DL> People, I am having a problem getting a VERY small assenbler program
 DL> running under OS/2, and I can't for the life of me figure out why.  Here's
 DL> the code as of latest incarnation (BTW, the purpose is to reprogram the
 DL> DMA control timing in the SYMPHONY chipset, so my PAS-16 will work.  Yes,
 DL> I know I could do this from DOS, but it's become an obsession... laughter>).  Using MASM 6.0a.  All I get is an access violation before the
 DL> program even starts, so I must be doing something VERY wrong.

You use OUT instructions but they allowed only if executed within segment that
has IOPL privelege. Try to move your procedure in another segment, for
example CODE_IOPL and include in your .DEF file description of this
segment:

SEGMENTS
  CODE_IOPL  IOPL

Then call it from your program main segment. Everything should be Ok.

If you don't like to create an extra segment you may use DosPortAccess API
call to enable access to certain port(s).

                Catch ya later!

--- Link386.Exe


* Origin: --== THuNDeR BiRD MaiL $TaTioN ==-- (2:5020/214.14)
SEEN-BY: 12/2442 54/54 620/243 624/50 632/348 640/820 690/660 711/409 410 413
SEEN-BY: 711/430 807 808 809 934 712/353 623 713/888 800/1
@PATH: 5020/214 5026/3 51/2 281/550 283/512 280/801 24/24
@PATH: 396/1 3615/50 229/2 12/2442 711/409 54/54 711/808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.