Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
d41581db
Commit
d41581db
authored
Nov 15, 2002
by
Jukka Heinonen
Committed by
Alexandre Julliard
Nov 15, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DeviceIoControl now calls winedos interrupt handlers.
Fixed RawModeSwitch.
parent
c702ae8a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
42 additions
and
11 deletions
+42
-11
interrupts.c
dlls/winedos/interrupts.c
+13
-0
winedos.spec
dlls/winedos/winedos.spec
+1
-0
callback.h
include/callback.h
+1
-0
dpmi.c
msdos/dpmi.c
+1
-0
device.c
win32/device.c
+26
-11
No files found.
dlls/winedos/interrupts.c
View file @
d41581db
...
...
@@ -103,6 +103,8 @@ void WINAPI DOSVM_EmulateInterruptPM( CONTEXT86 *context, BYTE intnum )
if
(
context
->
SegCs
==
DOSVM_dpmi_segments
->
int48_sel
)
islong
=
FALSE
;
else
if
(
context
->
SegCs
==
DOSVM_dpmi_segments
->
dpmi_sel
)
islong
=
FALSE
;
else
if
(
DOSVM_IsDos32
())
islong
=
TRUE
;
else
if
(
IS_SELECTOR_32BIT
(
context
->
SegCs
))
{
...
...
@@ -256,3 +258,14 @@ INTPROC DOSVM_GetBuiltinHandler( BYTE intnum )
WARN
(
"int%x not implemented, returning dummy handler
\n
"
,
intnum
);
return
DOSVM_DefaultHandler
;
}
/**********************************************************************
* DOSVM_CallBuiltinHandler
*
* Execute Wine interrupt handler procedure.
*/
void
WINAPI
DOSVM_CallBuiltinHandler
(
CONTEXT86
*
context
,
BYTE
intnum
)
{
INTPROC
proc
=
DOSVM_GetBuiltinHandler
(
intnum
);
proc
(
context
);
}
dlls/winedos/winedos.spec
View file @
d41581db
@ stdcall LoadDosExe(str long) MZ_LoadImage
@ stdcall EmulateInterruptPM(ptr long) DOSVM_EmulateInterruptPM
@ stdcall CallBuiltinHandler(ptr long) DOSVM_CallBuiltinHandler
# DPMI functions
@ stdcall CallRMInt(ptr) DOSVM_CallRMInt
...
...
include/callback.h
View file @
d41581db
...
...
@@ -27,6 +27,7 @@
typedef
struct
{
void
(
WINAPI
*
LoadDosExe
)(
LPCSTR
filename
,
HANDLE
hFile
);
void
(
WINAPI
*
EmulateInterruptPM
)(
CONTEXT86
*
context
,
BYTE
intnum
);
void
(
WINAPI
*
CallBuiltinHandler
)(
CONTEXT86
*
context
,
BYTE
intnum
);
/* DPMI functions */
void
(
WINAPI
*
CallRMInt
)(
CONTEXT86
*
context
);
...
...
msdos/dpmi.c
View file @
d41581db
...
...
@@ -75,6 +75,7 @@ BOOL DPMI_LoadDosSystem(void)
GET_ADDR
(
outport
);
GET_ADDR
(
ASPIHandler
);
GET_ADDR
(
EmulateInterruptPM
);
GET_ADDR
(
CallBuiltinHandler
);
#undef GET_ADDR
return
TRUE
;
}
...
...
win32/device.c
View file @
d41581db
...
...
@@ -44,6 +44,7 @@
#include "stackframe.h"
#include "wine/server.h"
#include "wine/debug.h"
#include "callback.h"
/* int 13 stuff */
#ifdef HAVE_SYS_IOCTL_H
...
...
@@ -1573,9 +1574,13 @@ static BOOL DeviceIo_IFSMgr(DWORD dwIoControlCode, LPVOID lpvInBuffer, DWORD cbI
if
(
dwIoControlCode
==
IFS_IOCTL_21
)
{
DOS3Call
(
&
cxt
);
/* Call int 21h */
}
else
{
INT_Int2fHandler
(
&
cxt
);
/* Call int 2Fh */
if
(
Dosvm
.
CallBuiltinHandler
||
DPMI_LoadDosSystem
())
Dosvm
.
CallBuiltinHandler
(
&
cxt
,
0x21
);
}
else
{
if
(
Dosvm
.
CallBuiltinHandler
||
DPMI_LoadDosSystem
())
Dosvm
.
CallBuiltinHandler
(
&
cxt
,
0x2f
);
}
CONTEXT_2_win32apieq
(
&
cxt
,
pOut
);
...
...
@@ -1640,7 +1645,8 @@ static DWORD VxDCall_VWin32( DWORD service, CONTEXT86 *context )
SET_AX
(
context
,
callnum
);
SET_CX
(
context
,
parm
);
INT_Int31Handler
(
context
);
if
(
Dosvm
.
CallBuiltinHandler
||
DPMI_LoadDosSystem
())
Dosvm
.
CallBuiltinHandler
(
context
,
0x31
);
return
LOWORD
(
context
->
Eax
);
}
...
...
@@ -1983,6 +1989,7 @@ static BOOL DeviceIo_VWin32(DWORD dwIoControlCode,
CONTEXT86
cxt
;
DIOC_REGISTERS
*
pIn
=
(
DIOC_REGISTERS
*
)
lpvInBuffer
;
DIOC_REGISTERS
*
pOut
=
(
DIOC_REGISTERS
*
)
lpvOutBuffer
;
BYTE
intnum
=
0
;
TRACE
(
"Control '%s': "
"eax=0x%08lx, ebx=0x%08lx, ecx=0x%08lx, "
...
...
@@ -1998,17 +2005,25 @@ static BOOL DeviceIo_VWin32(DWORD dwIoControlCode,
switch
(
dwIoControlCode
)
{
case
VWIN32_DIOC_DOS_IOCTL
:
DOS3Call
(
&
cxt
);
break
;
/* Call int 21h */
case
VWIN32_DIOC_DOS_INT13
:
INT_Int13Handler
(
&
cxt
);
break
;
case
VWIN32_DIOC_DOS_IOCTL
:
/* Call int 21h */
case
0x10
:
/* Int 0x21 call, call it VWIN_DIOC_INT21 ? */
DOS3Call
(
&
cxt
);
break
;
case
VWIN32_DIOC_DOS_INT25
:
INT_Int25Handler
(
&
cxt
);
break
;
case
VWIN32_DIOC_DOS_INT26
:
INT_Int26Handler
(
&
cxt
);
break
;
case
VWIN32_DIOC_DOS_DRIVEINFO
:
/* Call int 21h 730x */
intnum
=
0x21
;
break
;
case
VWIN32_DIOC_DOS_INT25
:
intnum
=
0x25
;
break
;
case
VWIN32_DIOC_DOS_INT26
:
intnum
=
0x26
;
break
;
case
0x29
:
/* Int 0x31 call, call it VWIN_DIOC_INT31 ? */
INT_Int31Handler
(
&
cxt
);
break
;
case
VWIN32_DIOC_DOS_DRIVEINFO
:
DOS3Call
(
&
cxt
);
break
;
/* Call int 21h 730x */
intnum
=
0x31
;
break
;
}
if
(
Dosvm
.
CallBuiltinHandler
||
DPMI_LoadDosSystem
())
Dosvm
.
CallBuiltinHandler
(
&
cxt
,
intnum
);
CONTEXT_2_DIOCRegs
(
&
cxt
,
pOut
);
}
break
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment