Date: Sun, 22 Nov 1998 14:36:05 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: Willy Lee cc: djgpp AT delorie DOT com Subject: Re: TSRs with DJGPP? In-Reply-To: <3657E72D.99420240@jps.net> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com On Sun, 22 Nov 1998, Willy Lee wrote: > I should explain that I'm trying to hook Int 0x15, function 0x4F, which > is supposed to be called by the Int 0x09 (keyboard interrupt) handler > from real-mode. Int 15h is a software interrupt, and these are NOT reflected to protected mode. You need to install a real-mode handler. > What's the best thing for me to do here? Looks like I need to set a > real-mode vector to point to a real-mode address for my handler. Do I > need to setup a real-mode callback? Or should I just make the handler > completely real-mode? See the FAQ for the instructions on how to install a real-mode handler. If something's unclear there, ask specific questions. In general, a callback should be enough, unless it isn't fast enough for your needs (since a callback involves a mode switch). > If I setup a real-mode callback, can I still chain to the old protected > mode vector using _go32_dpmi_chain_....? No, this function is for chaining to protected-mode interrupts only. There is no function in the library for chaining to real-mode interrupts, you will need either to modify the register structure passed to your real-mode handler, before it returns; or call the previous handler from your handler using the _go32_... functions that simulate far procedure calls (look them up in the library reference).