Changes

47 bytes added ,  18:15, 16 November 2019
no edit summary
Line 14: Line 14:     
== OpenCodeFileSystem ==
 
== OpenCodeFileSystem ==
Takes an u64 [[NCM_services#ProgramId|ProgramId]] and a [[#ContentPath]]. Returns an [[#IFileSystem]].
+
Takes an [[NCM_services#ProgramId|ProgramId]] and a [[#ContentPath]]. Returns an [[#IFileSystem]].
    
== IsArchivedProgram ==
 
== IsArchivedProgram ==
Line 20: Line 20:     
== SetCurrentProcess ==
 
== SetCurrentProcess ==
Takes a PID descriptor.
+
Takes a ProcessId descriptor.
    
= fsp-pr =
 
= fsp-pr =
Line 39: Line 39:     
== RegisterProgram ==
 
== RegisterProgram ==
Takes a storageID, a pid, a [[NCM_services#ProgramId|ProgramId]], a 0x1C type-A buffer for the [[NPDM#FS_Access_Header| FS Access Header]], and a 0x2C type-A buffer for the [[NPDM#FS_Access_Control| FS Access Control]]
+
Takes a [[NCM_services#StorageId|StorageId]], an u64 ProcessId, a [[NCM_services#ProgramId|ProgramId]], a 0x1C type-A buffer for the [[NPDM#FS_Access_Header| FS Access Header]], and a 0x2C type-A buffer for the [[NPDM#FS_Access_Control| FS Access Control]]
    
Final FS permissions are stored as (ACI0_perms & ACID_perms). Will panic(svcBreak) when buffer sizes from ipc-rawdata are invalid.
 
Final FS permissions are stored as (ACI0_perms & ACID_perms). Will panic(svcBreak) when buffer sizes from ipc-rawdata are invalid.
Line 527: Line 527:     
== OpenFileSystem ==
 
== OpenFileSystem ==
Takes a type-0x19 input buffer (ContentPath) and a [[#FileSystemType]] as parameters. Returns an [[#IFileSystem]].
+
Takes a type-0x19 input [[#ContentPath]] and a [[#FileSystemType]] as parameters. Returns an [[#IFileSystem]].
    
[2.0.0+] This function was removed.
 
[2.0.0+] This function was removed.
Line 557: Line 557:     
== OpenBisFileSystem ==
 
== OpenBisFileSystem ==
Takes a type-0x19 input buffer string and a u32 [[Flash_Filesystem|Bis partitionID]]. Official user-process code sets instr[0] = 0 normally. Returns an [[#IFileSystem]].
+
Takes a type-0x19 input buffer string and a [[#BisPartitionId]]. Official user-process code sets instr[0] = 0 normally. Returns an [[#IFileSystem]].
    
Only partitionIDs for FAT partitions are usable with this, otherwise error 0x2EE202 is returned. Seems to be about the same as [[#OpenBisStorage]] except this mounts the partition filesystem instead of allowing direct access to the partition sectors.
 
Only partitionIDs for FAT partitions are usable with this, otherwise error 0x2EE202 is returned. Seems to be about the same as [[#OpenBisStorage]] except this mounts the partition filesystem instead of allowing direct access to the partition sectors.
Line 656: Line 656:     
== OpenDataStorageByDataId ==
 
== OpenDataStorageByDataId ==
Takes a [[NCM_services#StorageId|StorageID]] and a [[NCM_services#ProgramId|ProgramId]].
+
Takes a [[NCM_services#StorageId|StorageID]] and a [[NCM_services#DataId|DataId]].
    
Returns a [[IPC_Marshalling#Domain_message|domain object ID]] implementing the [[#IStorage]] interface for data archives.
 
Returns a [[IPC_Marshalling#Domain_message|domain object ID]] implementing the [[#IStorage]] interface for data archives.
Line 2,024: Line 2,024:  
| 0x0
 
| 0x0
 
| 0x8
 
| 0x8
| [[NCM_services#ProgramId|ProgramId]] (0 for SystemSaveData)</br>SaveData: 0 can be used for accessing the savedata associated with the current FS session [[NCM_services#ProgramId|ProgramId]], otherwise when set this is the [[NCM_services#ProgramId|ProgramId]] associated with the savedata to access.
+
| [[NCM_services#ApplicationId|ApplicationId]] (0 for SystemSaveData)</br>SaveData: 0 can be used for accessing the savedata associated with the current FS session [[NCM_services#ApplicationId|ApplicationId]], otherwise when set this is the [[NCM_services#ApplicationId|ApplicationId]] associated with the savedata to access.
 
|-
 
|-
 
| 0x8
 
| 0x8
Line 2,115: Line 2,115:     
= BcatSaveData =
 
= BcatSaveData =
This is accessed using the same commands for SaveData with the same input u8. The [[#SaveDataAttribute]] is the same as DeviceSaveData, except that the [[NCM_services#ProgramId|ProgramId]] field is set to <input ProgramId>. See above regarding [[#SaveDataCreationInfo]].
+
This is accessed using the same commands for SaveData with the same input u8. The [[#SaveDataAttribute]] is the same as DeviceSaveData, except that the [[NCM_services#ApplicationId|ApplicationId]] field is set to <input ApplicationId>. See above regarding [[#SaveDataCreationInfo]].
    
The 0x10-byte struct passed to [[#CreateSaveDataFileSystem]] has the first 0x5-bytes set to all-zero.
 
The 0x10-byte struct passed to [[#CreateSaveDataFileSystem]] has the first 0x5-bytes set to all-zero.
Line 2,130: Line 2,130:  
| 0x0
 
| 0x0
 
| 0x8
 
| 0x8
| Unknown saveID
+
| SaveDataId
 
|-
 
|-
 
| 0x8
 
| 0x8
Line 2,146: Line 2,146:  
| 0x10
 
| 0x10
 
| 0x10
 
| 0x10
| userID
+
| UserId
 
|-
 
|-
 
| 0x20
 
| 0x20
 
| 0x8
 
| 0x8
| saveID, 0 for regular SaveData.
+
| SystemSaveDataId (0 for regular SaveData)
 
|-
 
|-
 
| 0x28
 
| 0x28
 
| 0x8
 
| 0x8
| Application [[NCM_services#ProgramId|ProgramId]], for regular SaveData.
+
| [[NCM_services#ApplicationId|ApplicationId]] (for regular SaveData)
 
|-
 
|-
 
| 0x30
 
| 0x30