Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
506fb710
Commit
506fb710
authored
May 13, 1999
by
Andreas Mohr
Committed by
Alexandre Julliard
May 13, 1999
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implemented InsertInASPIChain and fixed minor things.
parent
41d38ee8
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
54 additions
and
19 deletions
+54
-19
winaspi16.c
dlls/winaspi/winaspi16.c
+51
-16
winaspi.spec
if1632/winaspi.spec
+1
-1
aspi.h
include/aspi.h
+2
-2
No files found.
dlls/winaspi/winaspi16.c
View file @
506fb710
...
@@ -27,6 +27,10 @@ DEFAULT_DEBUG_CHANNEL(aspi)
...
@@ -27,6 +27,10 @@ DEFAULT_DEBUG_CHANNEL(aspi)
*/
*/
#ifdef linux
#ifdef linux
static
FARPROC16
ASPIChainFunc
=
NULL
;
static
WORD
HA_Count
=
1
;
/* host adapter count; FIXME: detect it */
static
int
static
int
ASPI_OpenDevice16
(
SRB_ExecSCSICmd16
*
prb
)
ASPI_OpenDevice16
(
SRB_ExecSCSICmd16
*
prb
)
{
{
...
@@ -383,13 +387,10 @@ WORD WINAPI GetASPISupportInfo16()
...
@@ -383,13 +387,10 @@ WORD WINAPI GetASPISupportInfo16()
{
{
#ifdef linux
#ifdef linux
TRACE
(
aspi
,
"GETASPISupportInfo16
\n
"
);
TRACE
(
aspi
,
"GETASPISupportInfo16
\n
"
);
/* high byte SS_COMP - low byte number of host adapters.
/* high byte SS_COMP - low byte number of host adapters */
* FIXME!!! The number of host adapters is incorrect.
return
((
SS_COMP
<<
8
)
|
HA_Count
);
* I'm not sure how to determine this under linux etc.
*/
return
((
SS_COMP
<<
8
)
|
1
);
#else
#else
return
((
SS_
COMP
<<
8
)
|
0
);
return
((
SS_
NO_ASPI
<<
8
)
|
0
);
#endif
#endif
}
}
...
@@ -407,6 +408,16 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
...
@@ -407,6 +408,16 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
break
;
break
;
case
ASPI_WIN16
:
case
ASPI_WIN16
:
lpSRB
=
PTR_SEG_TO_LIN
(
ptrSRB
);
lpSRB
=
PTR_SEG_TO_LIN
(
ptrSRB
);
if
(
ASPIChainFunc
)
{
/* This is not the post proc, it's the chain proc this time */
DWORD
ret
=
Callbacks
->
CallASPIPostProc
(
ASPIChainFunc
,
ptrSRB
);
if
(
ret
)
{
lpSRB
->
inquiry
.
SRB_Status
=
SS_INVALID_SRB
;
return
ret
;
}
}
break
;
break
;
}
}
...
@@ -417,7 +428,7 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
...
@@ -417,7 +428,7 @@ DWORD ASPI_SendASPICommand(DWORD ptrSRB, UINT16 mode)
TRACE
(
aspi
,
"Extended request detected (Adaptec's ASPIxDOS).
\n
We don't support it at the moment.
\n
"
);
TRACE
(
aspi
,
"Extended request detected (Adaptec's ASPIxDOS).
\n
We don't support it at the moment.
\n
"
);
}
}
lpSRB
->
inquiry
.
SRB_ExtBufferSize
=
0x2000
;
/* bogus value */
lpSRB
->
inquiry
.
SRB_ExtBufferSize
=
0x2000
;
/* bogus value */
lpSRB
->
inquiry
.
HA_Count
=
1
;
/* not always */
lpSRB
->
inquiry
.
HA_Count
=
HA_Count
;
lpSRB
->
inquiry
.
HA_SCSI_ID
=
7
;
/* not always ID 7 */
lpSRB
->
inquiry
.
HA_SCSI_ID
=
7
;
/* not always ID 7 */
strcat
(
lpSRB
->
inquiry
.
HA_ManagerId
,
"Wine ASPI16"
);
/* max 15 chars */
strcat
(
lpSRB
->
inquiry
.
HA_ManagerId
,
"Wine ASPI16"
);
/* max 15 chars */
strcat
(
lpSRB
->
inquiry
.
HA_Identifier
,
"Wine host"
);
/* FIXME: return host
strcat
(
lpSRB
->
inquiry
.
HA_Identifier
,
"Wine host"
);
/* FIXME: return host
...
@@ -436,12 +447,10 @@ adapter name */
...
@@ -436,12 +447,10 @@ adapter name */
FIXME
(
aspi
,
"Not implemented SC_RESET_DEV
\n
"
);
FIXME
(
aspi
,
"Not implemented SC_RESET_DEV
\n
"
);
break
;
break
;
default:
default:
WARN
(
aspi
,
"Unknown command %d
\n
"
,
lpSRB
->
common
.
SRB_Cmd
);
FIXME
(
aspi
,
"Unknown command %d
\n
"
,
lpSRB
->
common
.
SRB_Cmd
);
}
}
return
SS_INVALID_SRB
;
#else
return
SS_INVALID_SRB
;
#endif
#endif
return
SS_INVALID_SRB
;
}
}
...
@@ -459,15 +468,43 @@ WORD WINAPI SendASPICommand16(SEGPTR segptr_srb)
...
@@ -459,15 +468,43 @@ WORD WINAPI SendASPICommand16(SEGPTR segptr_srb)
/***********************************************************************
/***********************************************************************
* InsertInASPIChain16 (WINASPI.3)
*/
WORD
WINAPI
InsertInASPIChain16
(
BOOL16
remove
,
FARPROC16
pASPIChainFunc
)
{
#ifdef linux
if
(
remove
==
TRUE
)
/* Remove */
{
if
(
ASPIChainFunc
==
pASPIChainFunc
)
{
ASPIChainFunc
=
NULL
;
return
SS_COMP
;
}
}
else
if
(
remove
==
FALSE
)
/* Insert */
{
if
(
ASPIChainFunc
==
NULL
)
{
ASPIChainFunc
=
pASPIChainFunc
;
return
SS_COMP
;
}
}
#endif
return
SS_ERR
;
}
/***********************************************************************
* GetASPIDLLVersion16 (WINASPI.4)
* GetASPIDLLVersion16 (WINASPI.4)
*/
*/
DWORD
WINAPI
GetASPIDLLVersion16
()
DWORD
WINAPI
GetASPIDLLVersion16
()
{
{
#ifdef linux
#ifdef linux
return
(
DWORD
)
2
;
return
2
;
#else
#else
return
(
DWORD
)
0
;
return
0
;
#endif
#endif
}
}
...
@@ -498,8 +535,6 @@ void ASPI_DOS_HandleInt(CONTEXT *context)
...
@@ -498,8 +535,6 @@ void ASPI_DOS_HandleInt(CONTEXT *context)
AX_reg
(
context
)
=
CX_reg
(
context
);
AX_reg
(
context
)
=
CX_reg
(
context
);
}
}
else
else
SET_CFLAG
(
context
);
#else
SET_CFLAG
(
context
);
#endif
#endif
SET_CFLAG
(
context
);
}
}
if1632/winaspi.spec
View file @
506fb710
...
@@ -3,6 +3,6 @@ type win16
...
@@ -3,6 +3,6 @@ type win16
1 pascal16 GetASPISupportInfo() GetASPISupportInfo16
1 pascal16 GetASPISupportInfo() GetASPISupportInfo16
2 pascal16 SendASPICommand(segptr) SendASPICommand16
2 pascal16 SendASPICommand(segptr) SendASPICommand16
3
stub INSERTINASPICHAIN
3
pascal16 InsertInASPIChain(word segptr) InsertInASPIChain16
4 pascal GETASPIDLLVERSION() GetASPIDLLVersion16
4 pascal GETASPIDLLVERSION() GetASPIDLLVersion16
5 stub ___EXPORTEDSTUB
5 stub ___EXPORTEDSTUB
include/aspi.h
View file @
506fb710
...
@@ -9,12 +9,12 @@
...
@@ -9,12 +9,12 @@
#define SS_COMP 0x01
#define SS_COMP 0x01
#define SS_ABORTED 0x02
#define SS_ABORTED 0x02
#define SS_ERR 0x04
#define SS_ERR 0x04
#define SS_INVALID_HA 0x81
#define SS_INVALID_SRB 0xe0
#define SS_OLD_MANAGE 0xe1
#define SS_OLD_MANAGE 0xe1
#define SS_ILLEGAL_MODE 0xe2
#define SS_ILLEGAL_MODE 0xe2
#define SS_NO_ASPI 0xe3
#define SS_NO_ASPI 0xe3
#define SS_FAILED_INIT 0xe4
#define SS_FAILED_INIT 0xe4
#define SS_INVALID_HA 0x81
#define SS_INVALID_SRB 0xe0
#define SS_ASPI_IS_BUSY 0xe5
#define SS_ASPI_IS_BUSY 0xe5
#define SS_BUFFER_TO_BIG 0xe6
#define SS_BUFFER_TO_BIG 0xe6
...
...
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