Message-ID: <3E51709E.DE111E40@worldnet.att.net> From: Paul Cousoulis X-Mailer: Mozilla 4.78 [en] (Win95; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.os.msdos.djgpp Subject: Passing pointers to dpmi_int Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 16 Date: Mon, 17 Feb 2003 23:34:53 GMT NNTP-Posting-Host: 12.81.74.246 X-Complaints-To: abuse AT worldnet DOT att DOT net X-Trace: bgtnsc04-news.ops.worldnet.att.net 1045524893 12.81.74.246 (Mon, 17 Feb 2003 23:34:53 GMT) NNTP-Posting-Date: Mon, 17 Feb 2003 23:34:53 GMT Organization: AT&T Worldnet To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com I'm trying to implement the Virtual DMA Service. In order to lock DMA memory I need to pass the address of a structure to int 4b in es:di. The physical address should be returned in dds_local, but I keep getting zero even though the function seems to otherwise return successfully. The code I'm using is: > > dr.x.dx = 0; > dr.x.ax = 0x8103; > temp = (int)(&dds_local); > dr.x.es = (unsigned short)(temp>>16); > dr.x.di = (unsigned short)(temp & 0xffff); > if(__dpmi_int(0x4b,&dr)) printf("error\n"); > Thanks Paul