delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2006/02/03/18:31:26

X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f
From: "Rod Pemberton" <dont_have AT bitbucket DOT cmm>
Newsgroups: comp.os.msdos.djgpp
References: <43E12016 DOT 2070308 AT mainstreetsoftworks DOT com> <7t88b3-d2q DOT ln1 AT news DOT infowest DOT com> <43E1863D DOT 8080308 AT mainstreetsoftworks DOT com> <fgt8b3-c4u DOT ln1 AT news DOT infowest DOT com> <43E216B4 DOT 70509 AT mainstreetsoftworks DOT com> <43E243F8 DOT 7060401 AT mainstreetsoftworks DOT com> <1o8ab3-2i71 DOT ln1 AT news DOT infowest DOT com> <k2qab3-d7b1 DOT ln1 AT news DOT infowest DOT com> <43E2C6DA DOT 4080700 AT mainstreetsoftworks DOT com> <4mcbb3-q1f1 DOT ln1 AT news DOT infowest DOT com> <43E3884C DOT 8050308 AT mainstreetsoftworks DOT com>
Subject: Re: TSR issues (with code)
Lines: 38
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1437
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1441
X-IWN-Posted-By: [68.60.59.250] Fri Feb 3 16:04:32 2006
Message-ID: <054db3-s3r1.ln1@news.infowest.com>
X-Complaints-To: abuse AT eli DOT net
X-Trace: 52616e646f6d49564b835516cab6b1f728cd0aaad111e06a2859ca5fe614c2a3fdb4d17c804a296421caf04f2ab9f82137f3d0e3749e8f9d7be90f25236305362eecd21a8a98f66cf3d788fbbaea448683778b3ea77e4345c2d05b6830402f94620e44d3b62ec4c54972c32ac1c0292fc2ff9609e3e2d68eac200aa4be57da81bdcc24f4a46086894c88709de2ec629a
X-Abuse-Info: Please be sure to forward ALL headers so that we may process your complaint properly.
NNTP-Posting-Date: Fri, 03 Feb 2006 23:19:50 UTC
Date: Fri, 03 Feb 2006 23:27:11 GMT
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

"Brad House" <brad AT mainstreetsoftworks DOT com> wrote in message
news:43E3884C DOT 8050308 AT mainstreetsoftworks DOT com...
> Ok, doing realmode reflection doesn't look like it's too bad then...
> And you suggest using _go32 function instead of __dpmi functions,
> so to chain the interrupt vector, how would that work, it seems as
> though there is no _chain_ routine, would I simply call the old
> dos realmode int's  pm_offset assuming the _go32_dpmi wrappers
> made such a routine for me?

Inside the new interrupt, you'll probably need to call
_go32_dpmi_simulate_fcall_iret() to chain.
IIRC, there are some other regs that can be used for a stack etc.

r->x.cs=old_dosidle_int.rm_segment;
r->x.ip=old_dosidle_int.rm_offset;
 _go32_dpmi_simulate_fcall_iret(&r);

> This is how I think it _should_
> look:
<snip>

That look very good to me.

This is probably fine due to implicit casting.
> new_dosidle_int.pm_offset = my_dosidle_handler;

Just in case, I have code similar to this:
new_dosidle_int.pm_offset = (unsigned long)&my_dosidle_handler;

I'll check what you wrote against some code of mine and see if I can get it
to work without a bunch of locking/nearptr stuff...


Rod Pemberton



- Raw text -


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