Commit 76f47491 authored by Jeffrey Lee's avatar Jeffrey Lee
Browse files

Don't issue INQUIRY with only 5 bytes of response data

Detail:
  s/ScsiFs05 - Change ScanDrives2 to request 36 bytes of INQUIRY response data instead of just 5.
  This fixes an issue where some dodgy devices weren't responding to the inquiry command at all. Also CheckDriveAllowed will cause the module to ignore any drive that isn't capable of returning 36 bytes of inquiry data, so this change shouldn't cause previously working drives to suddenly stop working.
Admin:
  Tested in softload form on Iyonix.
  TS-H552 DVD-RW no longer causes hang/softlock when connected.


Version 1.23. Tagged as 'SCSIFS-1_23'
parent 4db081c1
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "1.22"
Module_Version SETA 122
Module_MajorVersion SETS "1.23"
Module_Version SETA 123
Module_MinorVersion SETS ""
Module_Date SETS "14 Oct 2011"
Module_ApplicationDate SETS "14-Oct-11"
Module_Date SETS "27 Nov 2011"
Module_ApplicationDate SETS "27-Nov-11"
Module_ComponentName SETS "SCSIFS"
Module_ComponentPath SETS "castle/RiscOS/Sources/FileSys/SCSIFS/SCSIFS"
Module_FullVersion SETS "1.22"
Module_HelpVersion SETS "1.22 (14 Oct 2011)"
Module_FullVersion SETS "1.23"
Module_HelpVersion SETS "1.23 (27 Nov 2011)"
END
/* (1.22)
/* (1.23)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 1.22
#define Module_MajorVersion_CMHG 1.23
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 14 Oct 2011
#define Module_Date_CMHG 27 Nov 2011
#define Module_MajorVersion "1.22"
#define Module_Version 122
#define Module_MajorVersion "1.23"
#define Module_Version 123
#define Module_MinorVersion ""
#define Module_Date "14 Oct 2011"
#define Module_Date "27 Nov 2011"
#define Module_ApplicationDate "14-Oct-11"
#define Module_ApplicationDate "27-Nov-11"
#define Module_ComponentName "SCSIFS"
#define Module_ComponentPath "castle/RiscOS/Sources/FileSys/SCSIFS/SCSIFS"
#define Module_FullVersion "1.22"
#define Module_HelpVersion "1.22 (14 Oct 2011)"
#define Module_LibraryVersionInfo "1:22"
#define Module_FullVersion "1.23"
#define Module_HelpVersion "1.23 (27 Nov 2011)"
#define Module_LibraryVersionInfo "1:23"
......@@ -473,7 +473,7 @@ MapDevToDrv ROUT
; Drive -> Device mappings filled in
ScanDrives2
Push "R0-R2,R5-R8,LR"
SUB StkPtr, StkPtr, #16
SUB StkPtr, StkPtr, #36
[ Debug7
wrhex R0
wrhex R2
......@@ -489,8 +489,8 @@ ScanLoop
TEQEQ R4, R6
BEQ ScanFinished
LDR LR, [StkPtr, #16+0*4] ; check we fall within the mask
LDR R8, [StkPtr, #16+2*4]
LDR LR, [StkPtr, #36+0*4] ; check we fall within the mask
LDR R8, [StkPtr, #36+2*4]
AND R8, R1, R8
TEQ R8, LR
BNE ScanNext
......@@ -515,7 +515,7 @@ ScanLoop
MOV R1, #6
ADR R2, CDB_Inquiry
ADD R3, StkPtr, #6*4
MOV R4, #5
MOV R4, #36
MOV R5, #100
MOV R8, R12
SWI XSCSI_Op
......@@ -588,7 +588,7 @@ ScanNextDev
MOV R3, R5
MOV R4, R6
ScanFinished
ADD StkPtr, StkPtr, #16
ADD StkPtr, StkPtr, #36
[ Debug7
wrhex R3
wrhex R4
......@@ -608,7 +608,7 @@ CDB_Inquiry
DCB 0
DCB 0
DCB 0
DCB 5
DCB 36
DCB 0
ALIGN
]
......@@ -617,15 +617,6 @@ CDB_Inquiry
[ {TRUE}
CDB_Inquiryfull
DCB &12 ; INQUIRY
DCB 0
DCB 0
DCB 0
DCB 36
DCB 0
ALIGN
; check if this drive is 'disabled'. A drive is 'disabled' if its
; inquiry string from offset 8 to offset 31 inclusive matches one
......@@ -641,7 +632,7 @@ CheckDriveAllowed ROUT
]
ORR R0, R1, #CTL_TXREAD
MOV R1, #6
ADR R2, CDB_Inquiryfull
ADR R2, CDB_Inquiry
SUB StkPtr, StkPtr, #36 + 44
MOV R3, StkPtr
MOV R4, #36
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment