Commits (6)
  • Robert Sprowson's avatar
    Clean up pass · 88da2be2
    Robert Sprowson authored
    * Use Command macro to make the command name table
    * Rename Origin to Module_BaseAddr (for Command macro)
    * Split messages into CmdHelp+Messages files
    * Use international_help switch passed in from makefile to decide which to build; remove "NewOS" and "CurrentOS" equivalents
    * Use Hdr:OsBytes to name OS_Byte value in R0
    * Remove some unused headers
    * {TRUE} and {FALSE} from ObjAsm
    Not tagged.
    88da2be2
  • Robert Sprowson's avatar
    Minor fixes · 1a583229
    Robert Sprowson authored
    Interface.s: Use error &1E6 for Bad SWI.
    Commands.s: Fix top-bit-set address bug where commands issued above 2G would be interpreted as a *Configure syntax request. Sort out confusion about internationalising configure commands - the 'FS' of the status report shouldn't be looked up since that would mean the *Configure command changed for each language.
    Random.s: Fix for several ARMv7 alignment faults using LDR to read a byte variable FCB_Status from a non word aligned offset.
    Tested on a high vectors ARMv7 with strict alignment checking enabled, copying files back and forth and generally browsing a server through NetI 6.26 to !Server 1.33 via Ethernet physical link.
    
    Version 5.97. Tagged as 'NetFS-5_97'
    1a583229
  • Robert Sprowson's avatar
    Fix for returning whole monitor name · 3c84863f
    Robert Sprowson authored
    When *OPT1,2 is enabled NetFS would either return the whole name including path or the leaf followed by garbage.
    OsFile.s: terminate the name properly with a null, loop back to find only the leaf as FileSwitch expects for the monitor name
    Memory.s: Never overlap the name buffer, delete that as a possibility
    Random.s: Spelling mistake found (copied from OsFile.s)
    
    Version 5.97. Not tagged
    3c84863f
  • Robert Sprowson's avatar
    Add support for RAM variant · 34a080a1
    Robert Sprowson authored
    Usual boiler plate code to register with ResourceFS. Tested briefly on Titanium.
    
    Version 5.98. Tagged as 'NetFS-5_98'
    34a080a1
  • Robert Sprowson's avatar
    Audit of signed pointer compares · e51f74b1
    Robert Sprowson authored
    Fairly thorough combing of things holding addresses with condition codes LT GE LE GT.
    The compare in Configure.s was missed when the exact same bug was fixed in revision 4.3 of this file.
    Given a reasonable test with FilerAction browsing around a standard disc image exported as an FS via Level 4.
    
    Version 5.99. Tagged as 'NetFS-5_99'
    e51f74b1
  • Robert Sprowson's avatar
    Build fix · 74051a92
    Robert Sprowson authored
    When CMDHELP=None some parts of NetFS assumed MessageTrans was unavailable, even though UseMsgTrans={TRUE}.
    Added a couple of missing ALIGN directives for standalone case.
    
    Version 6.00. Tagged as 'NetFS-6_00'
    74051a92
TTL ==> &.Arthur.NetFS.NewOS
GBLL OldOs
OldOs SETL {FALSE}
GBLL UseMsgTrans
UseMsgTrans SETL {TRUE}
GBLL Files32Bit
Files32Bit SETL {FALSE}
GBLL Files24Bit
Files24Bit SETL {TRUE}
GBLS OsString
OsString SETS ""
GBLL TokeniseHelp
TokeniseHelp SETL {TRUE}
LNK s.Module
SUBT Strings for Help messages. => &.Arthur.NetFS.HelpTexts
[ TokeniseHelp
[ international_help
HelpForStarNet
Net_Help
DCB "HNFSNET", 0
SyntaxOfStarNet
Net_Syntax
DCB "SNFSNET", 0
HelpForStarAddFS
AddFS_Help
DCB "HNFSAFS", 0
SyntaxOfStarAddFS
AddFS_Syntax
DCB "SNFSAFS", 0
HelpForStarFree
Free_Help
DCB "HNFSFRE", 0
SyntaxOfStarFree
Free_Syntax
DCB "SNFSFRE", 0
HelpForStarFS
FS_Help
DCB "HNFSFS", 0
SyntaxOfStarFS
FS_Syntax
DCB "SNFSFS", 0
HelpForStarMount
Mount_Help
DCB "HNFSMNT", 0
SyntaxOfStarMount
Mount_Syntax
DCB "SNFSMNT", 0
HelpForStarSDisc
SDisc_Help
DCB "HNFSSDS", 0
SyntaxOfStarSDisc
SDisc_Syntax
DCB "SNFSSDS", 0
HelpForStarListFS
ListFS_Help
DCB "HNFSLFS", 0
SyntaxOfStarListFS
ListFS_Syntax
DCB "SNFSLFS", 0
HelpForStarBye
Bye_Help
DCB "HNFSBYE", 0
SyntaxOfStarBye
Bye_Syntax
DCB "SNFSBYE", 0
HelpForStarLogon
Logon_Help
DCB "HNFSLON", 0
SyntaxOfStarLogon
Logon_Syntax
DCB "SNFSLON", 0
HelpForStarPass
Pass_Help
DCB "HNFSPAS", 0
SyntaxOfStarPass
Pass_Syntax
DCB "SNFSPAS", 0
HelpForConfigureFS
ConfigureFS_Help
DCB "HNFSCFS", 0
SyntaxOfConfigureFS
ConfigureFS_Syntax
DCB "SNFSCFS", 0
SyntaxOnlyOfConfigureFS
DCB "FS <station number>|<file server name>", 0
HelpForConfigureLib
ConfigureLib_Help
DCB "HNFSCLB", 0
SyntaxOfConfigureLib
ConfigureLib_Syntax
DCB "SNFSCLB", 0
SyntaxOnlyOfConfigureLib
DCB "Lib <0|1>"
DCB 0
| ; TokeniseHelp
| ; international_help
HelpForStarNet
Net_Help
= "*"
= TokenEscapeChar,Token0
= " selects the network as the current filing system.", 13
SyntaxOfStarNet
Net_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= 0
HelpForStarAddFS
AddFS_Help
= "*"
= TokenEscapeChar,Token0
= " adds the given file server and disc name to those"
= " NetFS currently knows about. If only the station"
= " number is given then that station will be removed"
= " from the list of known file servers.", 13
SyntaxOfStarAddFS
AddFS_Syntax
DCB "Syntax: *AddFS"
DCB " <station number> [<disc number> [:]<disc name>]", 0
HelpForStarFree
Free_Help
= "*"
= TokenEscapeChar,Token0
= " displays your current remaining"
......@@ -96,12 +91,12 @@ HelpForStarFree
= " total free space for the disc(s)."
= " If an argument is given the free"
= " space for that user name will be printed out.", 13
SyntaxOfStarFree
Free_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [:<file server>] [<user name>]", 0
HelpForStarFS
FS_Help
= "*"
= TokenEscapeChar,Token0
= " changes your currently selected file server, restoring any"
......@@ -109,105 +104,100 @@ HelpForStarFS
= " file server name and/or number are printed out, this is"
= " followed by the names and numbers of any other logged on"
= " file servers.", 13
SyntaxOfStarFS
FS_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [[:]<file server>]", 0
HelpForStarMount
Mount_Help
= "*"
= TokenEscapeChar,Token0
= " reselects your user root as well as your"
= " currently selected directory and library.", 13
SyntaxOfStarMount
Mount_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [:]<disc name>", 0
HelpForStarSDisc
SDisc_Help
= "*"
= TokenEscapeChar,Token0
= " is synonymous with *Mount.", 13
SyntaxOfStarSDisc
SDisc_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [:]<disc name>", 0
HelpForStarListFS
ListFS_Help
= "*"
= TokenEscapeChar,Token0
= " shows those file servers that the NetFS currently knows"
= " about. If the optional argument is supplied then"
= " the list will be refreshed before it is displayed.", 13
SyntaxOfStarListFS
ListFS_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [-force]", 0
HelpForStarBye
Bye_Help
= "*"
= TokenEscapeChar,Token0
= " terminates your use of the current (or given)"
= " file server. Closing all open files and directories.", 13
SyntaxOfStarBye
Bye_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= " [[:]<file server>]", 0
HelpForStarLogon
Logon_Help
= "*"
= TokenEscapeChar,Token0
= " initialises the current (or given) file server for your use."
= " Your user name and password are checked by the file"
= " server against the password file.", 13
SyntaxOfStarLogon
DCB "Syntax: *Logon"
DCB " [[:]<station number>|:<File server name>] <user name> "
DCB "[[:<CR>]<Password>]", 0
Logon_Syntax
= "Syntax: *Logon"
= " [[:]<station number>|:<File server name>] <user name> "
= "[[:<CR>]<Password>]", 0
HelpForStarPass
Pass_Help
= "*"
= TokenEscapeChar,Token0
= " changes your password on the file server.", 13
SyntaxOfStarPass
Pass_Syntax
= "Syntax: *Pass [<Old password> [<New password>]]", 0
HelpForConfigureFS
ConfigureFS_Help
= "*Configure FS sets the default number or name for the file server. "
= "This name will be used when the first *Logon command is issued if it "
= "does not explicitly quote either a name or a number.", 13
SyntaxOfConfigureFS
= "Syntax: *Configure "
SyntaxOnlyOfConfigureFS
DCB "FS <station number>|<file server name>", 0
ConfigureFS_Syntax
= "Syntax: *Configure FS <station number>|<file server name>", 0
HelpForConfigureLib
ConfigureLib_Help
= "*Configure Lib 0 will mean that logon will select the "
= "default library, if it exists. *Configure Lib 1 means "
= "that the library 'ArthurLib' "
= "will be selected at logon.", 13
SyntaxOfConfigureLib
= "Syntax: *Configure "
SyntaxOnlyOfConfigureLib
DCB "Lib <0|1>"
DCB 0
] ; TokeniseHelp
ConfigureLib_Syntax
= "Syntax: *Configure Lib <0|1>", 0
] ; international_help
[ :LNOT: ReleaseVersion
HelpForStarFCBs
NetFS_FCBs_Help
= "*"
= TokenEscapeChar,Token0
= " shows the internal details of every open object.", 13
SyntaxOfStarFCBs
NetFS_FCBs_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= 0
HelpForStarContexts
NetFS_Contexts_Help
= "*"
= TokenEscapeChar,Token0
= " shows the internal details of every valid context.", 13
SyntaxOfStarContexts
NetFS_Contexts_Syntax
= "Syntax: *"
= TokenEscapeChar,Token0
= 0
......
......@@ -14,20 +14,9 @@
#
# Makefile for NetFS
#
# ************************************
# *** C h a n g e L i s t ***
# ************************************
# Date Name Description
# ---- ---- -----------
# 20-Dec-2002 KJB Created.
#
# AMcC {28-Apr-94}: Source should be set to CurrentOS - it's set to NewOS
# for comparison with RISC OS 3.50 only.
#
COMPONENT = NetFS
ROM_SOURCE = CurrentOS
COMPONENT = NetFS
ROM_SOURCE = Module.s
TOKHELPSRC = ${TOKENSOURCE}
HELPSRC = HelpTexts
......
| Copyright 2016 Castle Technology Ltd
|
| Licensed under the Apache License, Version 2.0 (the "License");
| you may not use this file except in compliance with the License.
| You may obtain a copy of the License at
|
| http://www.apache.org/licenses/LICENSE-2.0
|
| Unless required by applicable law or agreed to in writing, software
| distributed under the License is distributed on an "AS IS" BASIS,
| WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
| See the License for the specific language governing permissions and
| limitations under the License.
|
Dir <Obey$Dir>
amu_machine standalone
TTL ==> &.Arthur.NetFS.NewOS
GBLL OldOs
OldOs SETL {FALSE}
GBLL UseMsgTrans
UseMsgTrans SETL {TRUE}
GBLL Files32Bit
Files32Bit SETL {FALSE}
GBLL Files24Bit
Files24Bit SETL {TRUE}
GBLS OsString
OsString SETS " (3.00)"
GBLL TokeniseHelp
TokeniseHelp SETL {FALSE}
LNK s.Module
No preview for this file type
......@@ -11,13 +11,13 @@
GBLS Module_HelpVersion
GBLS Module_ComponentName
GBLS Module_ComponentPath
Module_MajorVersion SETS "5.96"
Module_Version SETA 596
Module_MajorVersion SETS "6.00"
Module_Version SETA 600
Module_MinorVersion SETS ""
Module_Date SETS "20 Feb 2012"
Module_ApplicationDate SETS "20-Feb-12"
Module_Date SETS "23 Oct 2016"
Module_ApplicationDate SETS "23-Oct-16"
Module_ComponentName SETS "NetFS"
Module_ComponentPath SETS "castle/RiscOS/Sources/FileSys/NetFS/NetFS"
Module_FullVersion SETS "5.96"
Module_HelpVersion SETS "5.96 (20 Feb 2012)"
Module_FullVersion SETS "6.00"
Module_HelpVersion SETS "6.00 (23 Oct 2016)"
END
/* (5.96)
/* (6.00)
*
* This file is automatically maintained by srccommit, do not edit manually.
* Last processed by srccommit version: 1.1.
*
*/
#define Module_MajorVersion_CMHG 5.96
#define Module_MajorVersion_CMHG 6.00
#define Module_MinorVersion_CMHG
#define Module_Date_CMHG 20 Feb 2012
#define Module_Date_CMHG 23 Oct 2016
#define Module_MajorVersion "5.96"
#define Module_Version 596
#define Module_MajorVersion "6.00"
#define Module_Version 600
#define Module_MinorVersion ""
#define Module_Date "20 Feb 2012"
#define Module_Date "23 Oct 2016"
#define Module_ApplicationDate "20-Feb-12"
#define Module_ApplicationDate "23-Oct-16"
#define Module_ComponentName "NetFS"
#define Module_ComponentPath "castle/RiscOS/Sources/FileSys/NetFS/NetFS"
#define Module_FullVersion "5.96"
#define Module_HelpVersion "5.96 (20 Feb 2012)"
#define Module_LibraryVersionInfo "5:96"
#define Module_FullVersion "6.00"
#define Module_HelpVersion "6.00 (23 Oct 2016)"
#define Module_LibraryVersionInfo "6:0"
......@@ -18,7 +18,7 @@
; *** Utils grade commands ***
; ******************************
DoStarNet ROUT
Net_Code ROUT
MOV r6, lr
MOV r0, #FSControl_SelectFS
ADRL r1, FilingSystemName
......@@ -43,7 +43,7 @@ DoStarDir ROUT
LDRB r0, [ r1 ]
CMP r0, #" "
BLT StarDirByItself
[ True
[ {TRUE}
LDR r2, =&20726944 ; "Dir "
|
LD r0, FSOpHandleFlags
......@@ -437,7 +437,7 @@ BootCommand
; *** Preserve R7-R11, R13 (sp) ***
; ***************************************
DoStarAddFS ROUT
AddFS_Code ROUT
; R0 points to the argument(s)
; R1 is the number of arguments
; HelpForStarAddFS
......@@ -557,16 +557,14 @@ ErrorFileServerNameTooLong
TextOfSixteen
DCB "16", 0
ALIGN
|
Err BadName
Err FileServerNameTooLong
ALIGN
]
[ TokeniseHelp
ErrorAddFSSyntax
DCD ErrorNumber_Syntax
DCB "SNFSAFS", 0
ALIGN
|
Err BadName
Err FileServerNameTooLong
ALIGN
]
RemoveGivenFS
......@@ -607,7 +605,7 @@ AddFSFullStationRequired
B ErrorExitStarAddFS
MakeAddFSSyntaxError
[ TokeniseHelp
[ UseMsgTrans
ADR r0, ErrorAddFSSyntax
ADRL r4, AddFSCommandName
BL MessageTransErrorLookup2
......@@ -620,7 +618,7 @@ ErrorExitStarAddFS
ExitStarAddFS
Pull "r7-r8, pc"
DoStarFree ROUT
Free_Code ROUT
; R0 points to the argument(s)
; R1 is the number of arguments
LDR wp, [ r12 ]
......@@ -918,8 +916,8 @@ FormatCountLoop
BEQ FormatCountDone
ADD r1, r1, r2
CMP r1, r4 ; Would this group put us beyond the string?
ADDLT r8, r8, r7 ; Add the separator length to the string
BLT FormatCountLoop
ADDCC r8, r8, r7 ; Add the separator length to the string
BCC FormatCountLoop
FormatCountDone
ADD r14, sp, #FormatFrameSize ; Entry R1
LDMIA r14, { r1, r2 }
......@@ -966,7 +964,7 @@ ExitConvertFormatted
Pull "r0, r1, r2, r4-r9, pc"
]
DoStarFS ROUT
FS_Code ROUT
; R0 => Pointer to the argument(s)
; R1 => Count of the number of arguments
LDR wp, [ r12 ]
......@@ -1111,7 +1109,8 @@ FSListPrintRegardless
LTORG
DoStarMount ROUT
Mount_Code ROUT
SDisc_Code
Push "lr"
; R0 => Pointer to the argument(s)
; R1 => Count of the number of arguments
......@@ -1138,7 +1137,7 @@ DoStarMount ROUT
LTORG
DoStarBye ROUT
Bye_Code ROUT
LDR wp, [ r12 ]
TEQ r1, #0 ; Did we get an argument ??
LDREQ r0, Current ; No, so use the current FS
......@@ -1322,7 +1321,7 @@ ExitFromPurge
LTORG
DoStarListFS ROUT
ListFS_Code ROUT
MOV r6, lr
LDR wp, [ r12 ]
TEQ r1, #0 ; Check for an argument
......@@ -1422,7 +1421,7 @@ ExitFillCacheLoop
SETV
B FillCacheFails
DoStarPass ROUT
Pass_Code ROUT
; R0 => Pointer to the argument(s)
; R1 => Count of the number of arguments
LDR wp, [ r12 ]
......@@ -1493,7 +1492,7 @@ AddNullPassword
; *************************
; *** Do Star Logon ***
; *************************
DoStarLogon ROUT
Logon_Code ROUT
; R0 => Pointer to the argument(s)
; R1 => Count of the number of arguments
Push "lr"
......@@ -1554,7 +1553,7 @@ FindPassword
B LogonInputOrganised
MakeLogonSyntaxError
[ TokeniseHelp
[ UseMsgTrans
ADR r0, ErrorLogonSyntax
ADRL r4, LogonCommandName
BL MessageTransErrorLookup2
......@@ -1566,21 +1565,17 @@ AbortStarLogon
SETV
B ExitFromStarLogon
[ TokeniseHelp
[ UseMsgTrans
ErrorLogonSyntax
DCD ErrorNumber_Syntax
DCB "SNFSLON", 0
ALIGN
|
MakeSyntaxError
; R0 => Pointer to the relevant syntax meaasge
; R0 => Pointer to the relevant syntax message
; R0 <= Pointer to an error block
Push "r1, lr"
[ UseMsgTrans
ADR r1, TemporaryBuffer
|
ADR r1, ErrorBuffer
]
LDR r14, =ErrorNumber_Syntax
STR r14, [ r1 ], #4
SyntaxErrorLoop
......@@ -1588,12 +1583,7 @@ SyntaxErrorLoop
STRB r14, [ r1 ], #1
TEQ r14, #0
BNE SyntaxErrorLoop
[ UseMsgTrans
ADR r0, TemporaryBuffer
SWI XMessageTrans_CopyError
|
ADR r0, ErrorBuffer
]
Pull "r1, pc"
]
......@@ -1775,7 +1765,7 @@ UserIdCopyLoop
[ Files32Bit :LAND: Files24Bit
MOV r0, #FileServer_ReadObjectInfo
ADR r1, CommandBuffer
[ True
[ {TRUE}
LDR r14, =&0D2424BC ; Sus 32 bit capability
STR r14, [ r1, #0 ]
MOV r2, #4
......@@ -1824,6 +1814,10 @@ NeedToUpdateFSList
MaintenanceModeFS
MOV r1, #&00FFFFFF ; Three handles of -1, and an option of zero
ASSERT (Context_RootDirectory :MOD: 4) = 0
ASSERT Context_Directory = Context_RootDirectory + 1
ASSERT Context_Library = Context_RootDirectory + 2
ASSERT Context_BootOption = Context_RootDirectory + 3
STR r1, [ r4, #Context_RootDirectory ]
MOV r1, #"!"
STRB r1, [ r4, #Context_DiscName ]
......@@ -1869,7 +1863,7 @@ NoNeedForSDisc ; Enters here with V cle
AND r0, r0, #2_11
ADRL r1, BootUpNOP
LDR r0, [ r1, r0, LSL #2 ]
ADRL r1, Origin
ADRL r1, Module_BaseAddr
ADD r0, r1, r0
SWI XOS_CLI
ExitFromStarLogon
......@@ -1877,10 +1871,10 @@ ExitFromStarLogon
Pull pc
BootUpNOP ; Things to do at boot time
DCD BootUpNOPString - Origin
DCD BootUpLoadString - Origin
DCD BootUpRunString - Origin
DCD BootUpExecString - Origin
DCD BootUpNOPString - Module_BaseAddr
DCD BootUpLoadString - Module_BaseAddr
DCD BootUpRunString - Module_BaseAddr
DCD BootUpExecString - Module_BaseAddr
; 16-Jan-92 Bruce Cockburn
; -------------------------
......@@ -2073,7 +2067,7 @@ IsItANumber ROUT
SelectLibrary ROUT ; May trash R0-R6
; Called after a *Logon or a *Mount
Push lr
MOV r0, #ReadCMOS
MOV r0, #OsByte_ReadCMOS
MOV r1, #NetFilerCMOS
SWI XOS_Byte
BVS ExitSelectLibrary
......@@ -2151,7 +2145,7 @@ SelectLibrary ROUT ; May trash R0-R6
; get a string for it it returns % and works as it
; always did.
Push lr
MOV r0, #ReadCMOS
MOV r0, #OsByte_ReadCMOS
MOV r1, #NetFilerCMOS
SWI XOS_Byte
BVS ExitSelectLibrary
......@@ -2684,6 +2678,9 @@ UpdateCacheCopyLoop
; (fs and drive) is already here, and if it is to remove it
PHPSEI r8 ; ** Interrupts OFF **
ADR r1, NameCache - Cache_Link
ASSERT (Cache_Station :MOD: 4) = 0
ASSERT Cache_Network = Cache_Station + 1
ASSERT Cache_Drive = Cache_Station + 2
LDR r14, [ r7, #Cache_Station ] ; Picks up station, net, and drive
BIC r14, r14, #&FF000000
UpdateCacheSearchLoop
......@@ -2696,8 +2693,8 @@ UpdateCacheSearchLoop
MOVNE r1, r0
BNE UpdateCacheSearchLoop
; Remove the record pointed to by R0
[ False ; Debug
MOV r14, #&108
[ {FALSE} ; Debug
MOV r14, #IRQsema
LDR r14, [ r14 ]
TEQ r14, #0
BNE %56
......@@ -2720,10 +2717,10 @@ UpdateCacheFindLoop
BL CompareDiscs
MOVLT r1, r0
BLT UpdateCacheFindLoop
[ False ; Debug
[ {FALSE} ; Debug
BL %54
]
[ True ; Put the same name in once, highest number wins
[ {TRUE} ; Put the same name in once, highest number wins
BEQ ChooseDisc
InsertDisc
; R1 points to the record before, R0 points to the record after
......@@ -2734,10 +2731,10 @@ RestoreAndExitUpdateCache
ExitUpdateCache
Pull "pc"
[ False ; Debug
[ {FALSE} ; Debug
54
EntryS
MOV r14, #&108
MOV r14, #IRQsema
LDR r14, [ r14 ]
TEQ r14, #0
BNE %57
......@@ -2748,8 +2745,8 @@ ExitUpdateCache
]
ChooseDisc
[ False ; Debug
MOV r14, #&108
[ {FALSE} ; Debug
MOV r14, #IRQsema
LDR r14, [ r14 ]
TEQ r14, #0
BNE %58
......@@ -2771,7 +2768,7 @@ ChooseDisc
SWI XOS_Module ; No way to deal with error so ignore
B RestoreAndExitUpdateCache
|
[ False ; Put the same name in twice (in numerical order)
[ {FALSE} ; Debug
BNE InsertDisc ; If the names are equal then more tests
LDRB r2, [ r0, #Cache_Network ] ; If the network number of the record
LDRB r3, [ r7, #Cache_Network ] ; already in the list is greater than the
......@@ -2971,7 +2968,7 @@ FileServerCommand ROUT
[ Debug
DSTRING r0, "Service unknown command "
]
MOV r0, #0
MOV r0, #OSArgs_ReadPTR
MOV r1, #0
SWI XOS_Args ; See if we are the current filing system
BVS %10
......@@ -3113,7 +3110,7 @@ ServiceNetFS ; Preserves all
LTORG
[ :LNOT: ReleaseVersion
DoStarFCBs
NetFS_FCBs_Code
Push lr
LDR wp, [ r12 ]
LDR r10, FCBs
......@@ -3275,7 +3272,7 @@ FCB_Nibble
SWI XOS_WriteC
EXIT
DoStarContexts
NetFS_Contexts_Code
Push lr
LDR wp, [ r12 ]
SWI XOS_WriteS
......
......@@ -18,14 +18,14 @@
; *** Configuration and Status ***
; ************************************
ConfigureFS ROUT
ConfigureFS_Code ROUT
Push "r0-r4, lr"
LDR wp, [ r12 ]
CMP r0, #1
BGT DoConfigureFS ; Configure
BHI DoConfigureFS ; Configure
BEQ StatusOfFS ; Print status
PrintSyntaxOfConfigureFS
[ TokeniseHelp
[ UseMsgTrans
ADR r1, Token_FSSyntaxOnly
PrintToken
LD r0, MessageBlockAddress
......@@ -63,34 +63,19 @@ Token_FSSyntaxOnly
SWI XOS_Write0
SWIVC XOS_NewLine
B ExitConfigure
SyntaxOnlyOfConfigureFS
DCB "FS <station number>|<file server name>", 0
ALIGN
]
StatusOfFS ; Print the status
[ UseMsgTrans
BL TextualiseConfiguration
ADREQ r1, Token_FSName
ADRNE r1, Token_FSNumber
ADR r2, TemporaryBuffer
MOV r3, #?TemporaryBuffer
ADR r4, LogonDisc
BLVC MessageTransGSLookup1
MOVVC r0, r2 ; The passed buffer
MOV r1, r3 ; Length of the resultant string
SWIVC XOS_WriteN
B ExitConfigure
Token_FSName
DCB "FSName", 0
Token_FSNumber
DCB "FSNumb", 0
ALIGN
| ; UseMsgTrans
BL TextualiseConfiguration
BVS ExitConfigure
MOVEQ r4, #"'" ; Configuration is a name
MOVNE r4, #0
SWI XOS_WriteS
DCB "File server ", 0
DCB "FS ", 0
ALIGN
BVS ExitConfigure
MOVS r0, r4
......@@ -102,7 +87,6 @@ Token_FSNumber
SWINE XOS_WriteC
SWIVC XOS_NewLine
B ExitConfigure
] ; UseMsgTrans
DoConfigureFS
LDRB r1, [ r0 ]
......@@ -230,13 +214,13 @@ ExitTextualiseConfiguration
STRVS r0, [ sp, #0 ]
Pull "r0-r3, pc"
ConfigureLib ROUT
ConfigureLib_Code ROUT
Push "r0-r4, lr"
LDR wp, [ r12 ]
CMP r0, #1
BGT DoConfigureLib ; Configure
BHI DoConfigureLib ; Configure
BEQ StatusOfLib ; Print status
[ TokeniseHelp
[ UseMsgTrans
ADR r1, Token_LibSyntaxOnly
B PrintToken
......@@ -248,27 +232,24 @@ Token_LibSyntaxOnly
SWI XOS_Write0
SWIVC XOS_NewLine
B ExitConfigure
SyntaxOnlyOfConfigureLib
DCB "Lib <0|1>"
DCB 0
ALIGN
]
StatusOfLib
[ UseMsgTrans
ADR r1, Token_Libry
ADR r2, TemporaryBuffer
MOV r3, #?TemporaryBuffer
BL MessageTransGSLookup0
BVS ExitConfigure
ADD r4, r2, r3 ; Compute the address of the terminator
| ; UseMsgTrans
ADR r1, TemporaryBuffer
MOV r3, #20
BL AddString
DCB "Library ", 0
DCB "Lib ", 0
ALIGN
MOV r4, r1
] ; UseMsgTrans
MOV r1, #NetFilerCMOS
BL MyReadCMOS
BVS ExitConfigure
MOV r1, r4
TST r2, #BitOne
BEQ %20 ; Default
......@@ -278,11 +259,12 @@ StatusOfLib
BVS ExitConfigure
B %30
20
[ UseMsgTrans
Token_Def
DCB "Def", 0
ALIGN
20
MOV r2, r1
MOV r0, #"'"
STRB r0, [ r2 ], #1
ADR r1, Token_Def
ADR r3, TemporaryBuffer + ?TemporaryBuffer
SUB r3, r3, r2
......@@ -290,9 +272,10 @@ StatusOfLib
BVS ExitConfigure
ADD r1, r2, r3 ; Compute the address of the terminator
BL AddString
DCB "'", 10, 13, 0
DCB 10, 13, 0
ALIGN
| ; UseMsgTrans
20
BL AddString
DCB "'<Default>'", 10, 13, 0
ALIGN
......@@ -303,14 +286,6 @@ StatusOfLib
SWI XOS_Write0
B ExitConfigure
[ UseMsgTrans
Token_Libry
DCB "Libry", 0
Token_Def
DCB "Def", 0
ALIGN
] ; UseMsgTrans
DoConfigureLib
MOV r1, r0 ; Pointer to argument
MOV r0, #10
......
......@@ -15,175 +15,56 @@
SUBT ==> &.Arthur.NetFS.FileSystem
FSInfoBlock
DCD FilingSystemName - Origin
DCD FilingSystemName - Module_BaseAddr
DCD -1 ; StartUpBanner is code
DCD Open - Origin
DCD GetBuffer - Origin
DCD PutBuffer - Origin
DCD Args - Origin
DCD Close - Origin
DCD File - Origin
DCD Open - Module_BaseAddr
DCD GetBuffer - Module_BaseAddr
DCD PutBuffer - Module_BaseAddr
DCD Args - Module_BaseAddr
DCD Close - Module_BaseAddr
DCD File - Module_BaseAddr
[ OldOs
DCD fsinfo_special+fsinfo_fsfilereadinfonolen+fsinfo_fileinfo+fsnumber_net+(5:SHL:fsinfo_nfiles_shift)
| ; OldOs
DCD fsinfo_special+fsinfo_fsfilereadinfonolen+fsinfo_fileinfo+fsinfo_multifsextensions+fsinfo_handlesurdetc+fsinfo_giveaccessstring+fsinfo_extrainfo+fsnumber_net+(5:SHL:fsinfo_nfiles_shift)
]
DCD Funct - Origin
DCD PutBytes - Origin
DCD Funct - Module_BaseAddr
DCD PutBytes - Module_BaseAddr
[ :LNOT: OldOs
DCD fsextra_dirinformation+fsextra_FSDoesCat+fsextra_FSDoesEx
]
FilingSystemName
UtilsCommands
DCB "Net", 0
ALIGN
DCD DoStarNet - Origin
[ TokeniseHelp
InfoWord 0, 0, International_Help
[ international_help
NetFS_InterHelp * International_Help
|
InfoWord 0, 0
NetFS_InterHelp * 0
]
DCD SyntaxOfStarNet - Origin
DCD HelpForStarNet - Origin
[ :LNOT: ReleaseVersion
DCB "NetFS_FCBs", 0
ALIGN
DCD DoStarFCBs - Origin
InfoWord 0, 0
DCD SyntaxOfStarFCBs - Origin
DCD HelpForStarFCBs - Origin
DCB "NetFS_Contexts", 0
ALIGN
DCD DoStarContexts - Origin
InfoWord 0, 0
DCD SyntaxOfStarContexts - Origin
DCD HelpForStarContexts - Origin
]
; FilingSystemCommands
AddFSCommandName
DCB "AddFS", 0
ALIGN
DCD DoStarAddFS - Origin
[ TokeniseHelp
InfoWord 3, 1, FS_Command_Flag:OR:International_Help
|
InfoWord 3, 1, FS_Command_Flag
]
DCD SyntaxOfStarAddFS - Origin
DCD HelpForStarAddFS - Origin
DCB "Bye", 0
ALIGN
DCD DoStarBye - Origin
[ TokeniseHelp
InfoWord 1, 0, FS_Command_Flag:OR:International_Help
|
InfoWord 1, 0, FS_Command_Flag
]
DCD SyntaxOfStarBye - Origin
DCD HelpForStarBye - Origin
DCB "Free", 0
ALIGN
DCD DoStarFree - Origin
[ TokeniseHelp
InfoWord 2, 0, FS_Command_Flag:OR:International_Help
|
InfoWord 2, 0, FS_Command_Flag
]
DCD SyntaxOfStarFree - Origin
DCD HelpForStarFree - Origin
DCB "FS", 0
ALIGN
DCD DoStarFS - Origin
[ TokeniseHelp
InfoWord 1, 0, FS_Command_Flag:OR:International_Help
|
InfoWord 1, 0, FS_Command_Flag
]
DCD SyntaxOfStarFS - Origin
DCD HelpForStarFS - Origin
FilingSystemName
UtilsCommands
Command "Net", 0, 0, NetFS_InterHelp
DCB "ListFS", 0
ALIGN
DCD DoStarListFS - Origin
[ TokeniseHelp
InfoWord 1, 0, FS_Command_Flag:OR:International_Help
|
InfoWord 1, 0, FS_Command_Flag
[ :LNOT: ReleaseVersion
Command "NetFS_FCBs", 0, 0, 0
Command "NetFS_Contexts", 0, 0, 0
]
DCD SyntaxOfStarListFS - Origin
DCD HelpForStarListFS - Origin
; FilingSystemCommands
AddFSCommandName
Command "AddFS", 3, 1, NetFS_InterHelp :OR: FS_Command_Flag
Command "Bye", 1, 0, NetFS_InterHelp :OR: FS_Command_Flag
Command "Free", 2, 0, NetFS_InterHelp :OR: FS_Command_Flag
Command "FS", 1, 0, NetFS_InterHelp :OR: FS_Command_Flag
Command "ListFS", 1, 0, NetFS_InterHelp :OR: FS_Command_Flag
LogonCommandName
DCB "Logon", 0
ALIGN
DCD DoStarLogon - Origin
[ TokeniseHelp
InfoWord 3, 1, FS_Command_Flag:OR:International_Help
|
InfoWord 3, 1, FS_Command_Flag
]
DCD SyntaxOfStarLogon - Origin
DCD HelpForStarLogon - Origin
DCB "Mount", 0
ALIGN
DCD DoStarMount - Origin
[ TokeniseHelp
InfoWord 1, 1, FS_Command_Flag:OR:International_Help
|
InfoWord 1, 1, FS_Command_Flag
]
DCD SyntaxOfStarMount - Origin
DCD HelpForStarMount - Origin
DCB "Pass", 0
ALIGN
DCD DoStarPass - Origin
[ TokeniseHelp
InfoWord 2, 0, FS_Command_Flag:OR:International_Help
|
InfoWord 2, 0, FS_Command_Flag
]
DCD SyntaxOfStarPass - Origin
DCD HelpForStarPass - Origin
DCB "SDisc", 0
ALIGN
DCD DoStarMount - Origin
[ TokeniseHelp
InfoWord 1, 1, FS_Command_Flag:OR:International_Help
|
InfoWord 1, 1, FS_Command_Flag
]
DCD SyntaxOfStarSDisc - Origin
DCD HelpForStarSDisc - Origin
Command "Logon", 3, 1, NetFS_InterHelp :OR: FS_Command_Flag
Command "Mount", 1, 1, NetFS_InterHelp :OR: FS_Command_Flag
Command "Pass", 2, 0, NetFS_InterHelp :OR: FS_Command_Flag
Command "SDisc", 1, 1, NetFS_InterHelp :OR: FS_Command_Flag
; Configuration and Status commands
DCB "FS", 0
ALIGN
DCD ConfigureFS - Origin
[ TokeniseHelp
InfoWord 1, 1, Status_Keyword_Flag:OR:International_Help
|
InfoWord 1, 1, Status_Keyword_Flag
]
DCD SyntaxOfConfigureFS - Origin
DCD HelpForConfigureFS - Origin
DCB "Lib", 0
ALIGN
DCD ConfigureLib - Origin
[ TokeniseHelp
InfoWord 1, 1, Status_Keyword_Flag:OR:International_Help
|
InfoWord 1, 1, Status_Keyword_Flag
]
DCD SyntaxOfConfigureLib - Origin
DCD HelpForConfigureLib - Origin
Command "FS", 1, 1, NetFS_InterHelp :OR: Status_Keyword_Flag, ConfigureFS
Command "Lib", 1, 1, NetFS_InterHelp :OR: Status_Keyword_Flag, ConfigureLib
DCD 0 ; Terminate table
......@@ -328,7 +209,7 @@ FindNamedContext ROUT
[ Debug
DSTRING r1, "Find a context named "
]
[ False
[ {FALSE} ; Debug
LDRB r14, [ r1, #0 ]
TEQ r14, #"*" ; Is this a wild one?
LDREQ r0, Current
......@@ -761,9 +642,9 @@ CopyPathIn
DSTRING r3, "Path name translates to "
DREG r2, "Resultant command length is &"
]
[ False ; No path splitting yet
[ {FALSE} ; Debug
CMP r2, #FSCommandMax ; Is the result too large?
Pull "r3, r4, pc", LE ; No, so return
Pull "r3, r4, pc", LS ; No, so return
[ Debug
DLINE "Which is too long!"
]
......
......@@ -1093,7 +1093,7 @@ CanonicaliseSpecialAndDisc
; e.g. Net#<userid>@<disc>: or Net#<userid>::<disc>
;
[ Debug
[ True
[ {TRUE}
Push "r0, lr"
SWI XOS_WriteS
DCB "Canonicalise ""Net", 0
......
......@@ -52,7 +52,7 @@ JumpTable
EndOfJumpTable
SWIOutOfRange
ADR r0, ErrorOutOfRange
ADR r0, ErrorNoSuchSWI
[ UseMsgTrans
B MakeErrorWithModuleName
|
......@@ -60,12 +60,12 @@ SWIOutOfRange
] ; UseMsgTrans
[ UseMsgTrans
ErrorOutOfRange
DCD ErrorNumber_OutOfRange
ErrorNoSuchSWI
DCD ErrorNumber_NoSuchSWI
DCB "BadSWI", 0
ALIGN
|
Err OutOfRange
Err NoSuchSWI
ALIGN
] ; UseMsgTrans
......@@ -317,7 +317,7 @@ DoFSOpRegsSaved
BEQ FunctionIsPutBytes
|
CMP r0, #12
ADDLT pc, pc, r0, LSL #2
ADDCC pc, pc, r0, LSL #2
B SimpleCase
B SimpleCase ; CLI
......@@ -485,7 +485,7 @@ ConvertFSErrorLoop ; Copy the error string
InterpretCommandCode ; In R1
LDR r14, Temporary
CMP r1, #MaximumCommandCode
ADDLE pc, pc, r1, LSL #2
ADDLS pc, pc, r1, LSL #2
B ReturnUserData
CommandCodeTable ; Command code dispatch table
B ReturnUserData ; 0, NoActionRequired
......
......@@ -126,13 +126,8 @@ SmallBufferSize * 256 ; Bytes
Word
Byte LogonName, SmallBufferSize
[ True
Byte TextBuffer, SmallBufferSize
Byte ReportName, SmallBufferSize
|
Overlap LogonName, TextBuffer ; Used for small text processing
Overlap LogonName, ReportName ; Holds the name returned from OSFile
]
Byte TextBuffer, SmallBufferSize ; Used for small text processing
Byte ReportName, SmallBufferSize ; Holds the name returned from OSFile
Byte Password, SmallBufferSize * 2
Overlap Password, BigTextBuffer
......
......@@ -17,8 +17,6 @@
GET Hdr:ListOpts
GET Hdr:Macros
GET Hdr:System
GET Hdr:Machine.<Machine>
GET Hdr:CPU.Arch
GET Hdr:Proc
GET Hdr:CMOS
GET Hdr:ModHand
......@@ -29,6 +27,7 @@
GET Hdr:HighFSI
GET Hdr:LowFSI
GET Hdr:Econet
GET Hdr:OsBytes
GET Hdr:NewErrors
GET Hdr:VduExt
GET Hdr:Tokens
......@@ -36,25 +35,35 @@
GET Hdr:Territory
GET Hdr:Symbols
GET Hdr:Portable
GET VersionASM
GBLL ReleaseVersion
ReleaseVersion SETL True
GET Hdr:ResourceFS
GET VersionASM
SUBT Module header ==> &.Arthur.NetFS.Module
MySWIChunkBase * Module_SWISystemBase + NetFSSWI * Module_SWIChunkSize
ASSERT MySWIChunkBase = NetFS_ReadFSNumber
ASSERT Files24Bit :LOR: Files32Bit ; Must be ome or other or both
GBLS NewLibName
GBLL OldOs
OldOs SETL {FALSE}
GBLL UseMsgTrans
UseMsgTrans SETL {TRUE}
GBLL Files32Bit
Files32Bit SETL {FALSE}
GBLL Files24Bit
Files24Bit SETL {TRUE}
GBLL ReleaseVersion
ReleaseVersion SETL {TRUE}
GBLS NewLibName
NewLibName SETS "ArthurLib"
GBLL Debug
Debug SETL (:LNOT: ReleaseVersion) :LAND: False
TokeniseHelp SETL TokeniseHelp :LAND: (:LNOT: (International_Help = 0))
GBLL Debug
Debug SETL (:LNOT: ReleaseVersion) :LAND: {FALSE}
[ :LNOT: :DEF: standalone
GBLL standalone
standalone SETL {FALSE} ; Build-in Messages file and i/f to ResourceFS
]
[ :LNOT: :DEF: international_help
GBLL international_help
international_help SETL {TRUE} ; Default to RISC OS 3.60+ internationalisation
]
ASSERT Files24Bit :LOR: Files32Bit ; Must be one or other or both
NumberOfDiscs * 4 ; Number of discs requested by the broadcast
WriteOnlySize * &400 ; Buffer size used at run time
......@@ -68,24 +77,24 @@ UserIdSize * 21 ; "TenChars**.TenChars**
AREA |NetFS$$Code|,CODE,READONLY,PIC
Origin
Module_BaseAddr
DCD 0 ; StartAsFS
DCD InitModule - Origin ; Initialisation
DCD KillModule - Origin ; Finalisation
DCD Service - Origin
DCD ModuleTitle - Origin
DCD HelpString - Origin
DCD UtilsCommands - Origin ; Command Table
DCD MySWIChunkBase
DCD SWIEntry - Origin
DCD SWINameTable - Origin
DCD InitModule - Module_BaseAddr ; Initialisation
DCD KillModule - Module_BaseAddr ; Finalisation
DCD Service - Module_BaseAddr
DCD ModuleTitle - Module_BaseAddr
DCD HelpString - Module_BaseAddr
DCD UtilsCommands - Module_BaseAddr ; Command Table
DCD NetFSSWI_Base
DCD SWIEntry - Module_BaseAddr
DCD SWINameTable - Module_BaseAddr
DCD 0
[ TokeniseHelp
DCD MessageFileName - Origin
[ international_help
DCD MessageFileName - Module_BaseAddr
|
DCD 0
]
DCD ModuleFlags - Origin
DCD ModuleFlags - Module_BaseAddr
GET Memory.s
......@@ -192,6 +201,14 @@ ErrorNoEco
ReInitialisation
StoreClaimed
[ UseMsgTrans
[ standalone
ADRL r0, ResourceFilesList
SWI XResourceFS_RegisterFiles
BVS ExitInitialisation
]
]
ASSERT ((EndOfInitialisationData - InitialisationData):AND:3)=0
MOV r3, #EndOfInitialisationData - InitialisationData - 4
ADR r2, InitialisationData
......@@ -202,8 +219,8 @@ StoreClaimed
BPL %10
MOV r0, #FSControl_AddFS
ADR r1, Origin
LDR r2, =FSInfoBlock - Origin
ADR r1, Module_BaseAddr
LDR r2, =FSInfoBlock - Module_BaseAddr
MOV r3, r4 ; The address of my private word
SWI XOS_FSControl
[ :LNOT: OldOs
......@@ -223,7 +240,7 @@ ClaimEvent
ADRL r1, Event
MOV r2, wp
SWI XOS_Claim ; Start up the cache task
MOVVC r0, #14 ; Enable events
MOVVC r0, #OsByte_EnableEvent
MOVVC r1, #Event_Econet_Rx
SWIVC XOS_Byte
MOVVC r1, #Service_NetFS
......@@ -234,25 +251,36 @@ ExitInitialisation
ServiceTable
DCD 0
DCD ServiceMain - Origin
DCD Service_UKCommand ; Don't forget - ascending order required
DCD ServiceMain - Module_BaseAddr
ASSERT Service_Reset > Service_UKCommand
ASSERT Service_FSRedeclare > Service_Reset
ASSERT Service_EconetDying > Service_FSRedeclare
ASSERT Service_ResourceFSStarting > Service_EconetDying
ASSERT Service_TerritoryStarted > Service_ResourceFSStarting
ASSERT Service_Portable > Service_TerritoryStarted
DCD Service_UKCommand
DCD Service_Reset
DCD Service_FSRedeclare
DCD Service_EconetDying
[ standalone
DCD Service_ResourceFSStarting
]
[ :LNOT: OldOs
DCD Service_TerritoryStarted
DCD Service_Portable
]
DCD 0
DCD ServiceTable - Origin
DCD ServiceTable - Module_BaseAddr
Service ROUT
MOV r0, r0
TEQ r1, #Service_FSRedeclare
TEQNE r1, #Service_UKCommand
TEQNE r1, #Service_EconetDying
TEQNE r1, #Service_Reset
[ standalone
TEQNE r1, #Service_ResourceFSStarting
]
[ :LNOT: OldOs
TEQNE r1, #Service_Portable
TEQNE r1, #Service_TerritoryStarted
......@@ -266,6 +294,10 @@ ServiceMain
BEQ FileServerCommand
TEQ r1, #Service_EconetDying
BEQ FlushNameCache
[ standalone
TEQ r1, #Service_ResourceFSStarting
BEQ ReRegisterResourceFiles
]
[ :LNOT: OldOs
TEQ r1, #Service_Portable
BEQ Portable
......@@ -276,7 +308,7 @@ ServiceMain
; MOVNE pc, lr
; Now check reset was NOT hard
Push "r0-r4, lr"
MOV r0, #253
MOV r0, #OsByte_RW_LastResetType
MOV r1, #0
MOV r2, #255
SWI XOS_Byte ; Read last reset type, only do reset when it was soft
......@@ -301,11 +333,20 @@ TerritoryStarted
Pull "r0, pc"
]
[ standalone
ReRegisterResourceFiles
Push "r0, lr"
ADRL r0, ResourceFilesList
MOV lr, pc ; Make a return link
MOV pc, r2 ; Enter ResourceFS
Pull "r0, pc"
]
RedeclareFilingSystem ; to FileSwitch
Push "r0-r3, lr"
MOV r0, #FSControl_AddFS
ADRL r1, Origin
LDR r2, =FSInfoBlock - Origin
ADRL r1, Module_BaseAddr
LDR r2, =FSInfoBlock - Module_BaseAddr
MOV r3, r12 ; The address of my private word
SWI XOS_FSControl
Pull "r0-r3, pc"
......@@ -316,7 +357,7 @@ KillModule ROUT ; Totally ignore all err
LDR wp, [ r12 ]
BL FlushNameCache
BL FlushAnotherTxList
MOV r0, #13 ; Disable events
MOV r0, #OsByte_DisableEvent
MOV r1, #Event_Econet_Rx
SWI XOS_Byte
MOV r0, #EventV
......@@ -345,19 +386,23 @@ FlushContextsFinish
ST r1, MessageBlockAddress ; Mark it as closed
TEQ r0, #0
SWINE XMessageTrans_CloseFile ; Close it if it was open
[ standalone
ADRL r0, ResourceFilesList
SWI XResourceFS_DeregisterFiles
]
] ; UseMsgTrans
CLRV ; Note that this can't fail
Pull "r0-r2, pc"
MyReadCMOS
Push "r1, lr"
MOV r0, #ReadCMOS
MOV r0, #OsByte_ReadCMOS
SWI XOS_Byte
Pull "r1, pc"
MyWriteCMOS
Push "r1, lr"
MOV r0, #WriteCMOS
MOV r0, #OsByte_WriteCMOS
SWI XOS_Byte
Pull "r1, pc"
......@@ -444,7 +489,7 @@ DoGSLookup
MyClaimRMA
Push "r0, lr"
[ False ; Debug
[ {FALSE} ; Debug
DREG r3, "Claiming &", cc
]
MOV r0, #ModHandReason_Claim
......@@ -452,14 +497,14 @@ MyClaimRMA
MyFreeRMA
Push "r0, lr"
[ False ; Debug
[ {FALSE} ; Debug
LDR r0, [ r2, #-4 ]
DREG r0, "Freeing &", cc
]
MOV r0, #ModHandReason_Free
CallOSModule
SWI XOS_Module
[ False ; Debug
[ {FALSE} ; Debug
DREG r2, " bytes at &"
]
STRVS r0, [ sp, #0 ]
......@@ -489,8 +534,14 @@ ConvertStatusToError
GET Catalog.s
GET TokHelpSrc.s
[ Debug
[ standalone
ResourceFilesList
ResourceFile $MergedMsgs, Resources.NetFS.Messages
DCD 0
]
[ Debug
InsertDebugRoutines
]
]
END
......@@ -53,7 +53,7 @@ File ROUT
TEQ r0, #&FF
BEQ OsFileLoad
CMP r0, #OsFileMax
ADDLE pc, pc, r0, LSL #2
ADDLS pc, pc, r0, LSL #2
B FileGoodExit
OsFileJumpTable
B OsFileSave ; 0
......@@ -155,8 +155,9 @@ OsFileLoad ROUT ; 255
30
LDRB r3, [ r1, r0 ]
INC r0
STRB r3, [ r2 ], #1
CMP r3, #" "
MOVLE r3, #0
STRB r3, [ r2 ], #1
BGT %30
LDRB r0, [ r8, #12 ] ; Flag byte for load address
......@@ -240,15 +241,8 @@ FileBadExit ; Not always assured of
OsFileSave ROUT ; 0
OsFileCreate ; 7
[ Debug :LAND: False
CMP r5, #&00001000
MOVGT r5, r5, LSL #10
BLE %52
DREG r5, "Size changed to &"
52
]
SUB r5, r5, r4 ; Calculate the length
CMP r5, #&01000000 ; Does this excede the 24 bit limit?
CMP r5, #&01000000 ; Does this exceed the 24 bit limit?
BHS ExitSaveTooBig
Push "r0, r1"
TEQ r0, #fsfile_Create ; Create ?
......@@ -279,19 +273,19 @@ OsFileCreate ; 7
BVS SaveBadExit
LDRB r0, [ r8, #0 ] ; The original R0 determines Save or Create
TEQ r0, #fsfile_Create ; Create ??
MOV r0, #FileServer_SaveFile
MOVNE r0, #FileServer_SaveFile
MOVEQ r0, #FileServer_CreateFile
BL DoFSOp
BVS SaveBadExit
ADRL r4, ReportName
TEQ r0, #0 ; Test if the name was sent back or not
STREQB r0, [ r4, #0 ] ; No it wasn't
BEQ %30 ; So skip the copying
BEQ %30 ; No it wasn't, so skip the copying
20
LDRB r2, [ r1, r0 ]
STRB r2, [ r4 ], #1
INC r0
CMP r2, #" "
MOVLE r2, #0
STRB r2, [ r4 ], #1
BGT %20
30
LDRB r2, [ r8, #0 ] ; The original R0 determines Save or Create
......@@ -313,8 +307,8 @@ SaveNextBlock
BL DoUpCall
BVS FileBadExit
CMP r11, r9 ; Is there more remaining data than a buffer full??
MOVGT r5, r9
MOVLE r5, r11
MOVHI r5, r9
MOVLS r5, r11
SUB r11, r11, r5 ; Length for next time
MOV r4, r10
ADD r10, r10, r5 ; Calculate next start address
......@@ -678,9 +672,9 @@ DoLoadByGBPB ROUT ; Returns if unable, goes bang by itself if needed
; R3 <= File's extent
; R6 <= File's attributes (FS format for internal use)
; R7 <= filename as seen by the file server (entry R1)
MOVS r11, r1 ; Keep handle, set Z if zero, clears N since it's an address
MOVS r11, r1 ; Keep handle, set Z if zero
MOV r1, r7 ; Get the supplied value of R1
Pull pc, LE