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
37925eaf
Commit
37925eaf
authored
Aug 20, 2003
by
Jukka Heinonen
Committed by
Alexandre Julliard
Aug 20, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove unnecessary __wine_call_from_16_regs call frame management code
from raw mode switch handler.
parent
5498cc51
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
97 deletions
+2
-97
dosexe.h
dlls/winedos/dosexe.h
+0
-3
int31.c
dlls/winedos/int31.c
+2
-19
relay.c
dlls/winedos/relay.c
+0
-75
No files found.
dlls/winedos/dosexe.h
View file @
37925eaf
...
...
@@ -28,7 +28,6 @@
#include "miscemu.h"
struct
_DOSEVENT
;
struct
_STACK16FRAME
;
/* amount of space reserved for relay stack */
#define DOSVM_RELAY_DATA_SIZE 4096
...
...
@@ -256,8 +255,6 @@ extern void DOSVM_SetRMHandler( BYTE, FARPROC16 );
/* relay.c */
void
DOSVM_RelayHandler
(
CONTEXT86
*
);
void
DOSVM_SaveCallFrame
(
CONTEXT86
*
,
struct
_STACK16FRAME
*
);
void
DOSVM_RestoreCallFrame
(
CONTEXT86
*
,
struct
_STACK16FRAME
*
);
void
DOSVM_BuildCallFrame
(
CONTEXT86
*
,
DOSRELAY
,
LPVOID
);
/* soundblaster.c */
...
...
dlls/winedos/int31.c
View file @
37925eaf
...
...
@@ -675,11 +675,11 @@ void WINAPI DPMI_FreeInternalRMCB( FARPROC16 proc )
/**********************************************************************
*
RawModeSwitch (WINEDOS.@)
*
DOSVM_RawModeSwitchHandler
*
* DPMI Raw Mode Switch handler
*/
void
WINAPI
DOSVM_RawModeSwitch
(
CONTEXT86
*
context
)
void
WINAPI
DOSVM_RawModeSwitch
Handler
(
CONTEXT86
*
context
)
{
CONTEXT86
rm_ctx
;
int
ret
;
...
...
@@ -768,23 +768,6 @@ void WINAPI DOSVM_FreeRMCB( CONTEXT86 *context )
/**********************************************************************
* DOSVM_RawModeSwitchHandler
*
* DPMI Raw Mode Switch handler.
* This routine does all the stack manipulation tricks needed
* to return from protected mode interrupt using modified
* code and stack pointers.
*/
void
WINAPI
DOSVM_RawModeSwitchHandler
(
CONTEXT86
*
context
)
{
STACK16FRAME
frame
;
DOSVM_SaveCallFrame
(
context
,
&
frame
);
DOSVM_RawModeSwitch
(
context
);
DOSVM_RestoreCallFrame
(
context
,
&
frame
);
}
/**********************************************************************
* DOSVM_CheckWrappers
*
* Check if this was really a wrapper call instead of an interrupt.
...
...
dlls/winedos/relay.c
View file @
37925eaf
...
...
@@ -172,81 +172,6 @@ void DOSVM_RelayHandler( CONTEXT86 *context )
/**********************************************************************
* DOSVM_SaveCallFrame
*
* Save current call frame. This routine must be called from DOSRELAY
* called using DOSVM_BuildCallFrame before the relay modifies stack
* pointer. This routine makes sure that the relay can return safely
* to application context and that no memory is leaked.
*
* Note: If DOSVM_BuildCallFrame was called using 32-bit CS or SS,
* old values of CS and SS will be lost. This does not matter
* since this routine is only used by Raw Mode Switch.
*/
void
DOSVM_SaveCallFrame
(
CONTEXT86
*
context
,
STACK16FRAME
*
frame
)
{
*
frame
=
*
CURRENT_STACK16
;
/*
* If context is using allocated stack, release it.
*/
if
(
context
->
SegSs
==
DOSVM_dpmi_segments
->
relay_data_sel
)
{
RELAY_Stack16
*
stack
=
RELAY_GetPointer
(
context
->
Esp
);
if
(
!
stack
->
inuse
||
stack
->
stack_bottom
!=
RELAY_MAGIC
||
stack
->
stack_top
!=
RELAY_MAGIC
)
ERR
(
"Stack corrupted!
\n
"
);
stack
->
inuse
=
0
;
}
}
/**********************************************************************
* DOSVM_RestoreCallFrame
*
* Restore saved call frame to currect stack. This routine must always
* be called after DOSVM_SaveCallFrame has been called and before returning
* from DOSRELAY.
*/
void
DOSVM_RestoreCallFrame
(
CONTEXT86
*
context
,
STACK16FRAME
*
frame
)
{
/*
* Allocate separate stack for relay call.
*/
RELAY_MakeShortContext
(
context
);
/*
* After this function returns to relay code, protected mode
* 16 bit stack will contain STACK16FRAME and single WORD
* (EFlags, see next comment).
*/
NtCurrentTeb
()
->
cur_stack
=
MAKESEGPTR
(
context
->
SegSs
,
context
->
Esp
-
sizeof
(
STACK16FRAME
)
-
sizeof
(
WORD
)
);
/*
* After relay code returns to glue function, protected
* mode 16 bit stack will contain interrupt return record:
* IP, CS and EFlags. Since EFlags is ignored, it won't
* need to be initialized.
*/
context
->
Esp
-=
3
*
sizeof
(
WORD
);
/*
* Restore stack frame so that relay code won't be confused.
* It should be noted that relay code overwrites IP and CS
* in STACK16FRAME with values taken from current CONTEXT86.
* These values are what is returned to glue function
* (see previous comment).
*/
*
CURRENT_STACK16
=
*
frame
;
}
/**********************************************************************
* DOSVM_BuildCallFrame
*
* Modifies the context so that return to context calls DOSRELAY and
...
...
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