From: massarin AT alpha3 DOT cram DOT enel DOT it Newsgroups: comp.os.msdos.djgpp Subject: Assembler and C again. HELP !!! Date: 16 Feb 1998 15:04:27 GMT Organization: ENEL Ricerca PEA Lines: 35 Distribution: inet Message-ID: <6c9khr$asf1@willy.cra.enel.it> Reply-To: massarin AT alpha3 DOT cram DOT enel DOT it NNTP-Posting-Host: alpha3.cram.enel.it To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk This is my code. Please help me !!!!!. /****** CODE ******/ struct drv_struct *_pointer_4_driver; unsigned int driver_address; short gbl_sel; /* load driver address */ /* it's a DOS driver in DOS memory */ r.x.ax = some; r.x.bx = some; __dpmi_int(value,&r); driver_address = (r.x.es << 4) + r.x.di; /* that's ok */ /* call driver. HOW ????? */ gbl_sel = _dos_ds; asm volatile ("pushl %es movw _gbl_sel,%es movl __pointer_4_driver,%esi lcall _driver_address popl %es" ); /****** END CODE ******/ How I call the driver (loaded from DOS) passing it a pointer,to a struct on which it works, with registers es:di ???. I'm very confused. Thank all.