Filesystem services: Difference between revisions
Moosehunter (talk | contribs) |
No edit summary |
||
Line 527: | Line 527: | ||
== OpenFileSystem == | == OpenFileSystem == | ||
Takes a type-0x19 input [[#ContentPath]] and a [[# | Takes a type-0x19 input [[#ContentPath]] and a [[#FileSystemProxyType]] as parameters. Returns an [[#IFileSystem]]. | ||
[2.0.0+] This function was removed. | [2.0.0+] This function was removed. | ||
Line 535: | Line 535: | ||
== OpenFileSystemWithPatch == | == OpenFileSystemWithPatch == | ||
Takes an input [[# | Takes an input [[#FileSystemProxyType]] and an u64 title-id. Returns an [[#IFileSystem]]. | ||
Web-applet loads the [[# | Web-applet loads the [[#FileSystemProxyType]] (which must be '''Manual''') from u32_table[inparam]. | ||
Note: web-applet strings refer to both this cmd and [[#OpenFileSystemWithId]] as "MountContent", but official nn_sf_sync symbols use "OpenXX" names. | Note: web-applet strings refer to both this cmd and [[#OpenFileSystemWithId]] as "MountContent", but official nn_sf_sync symbols use "OpenXX" names. | ||
== OpenFileSystemWithId == | == OpenFileSystemWithId == | ||
Takes a type-0x19 input buffer, an [[# | Takes a type-0x19 input buffer, an [[#FileSystemProxyType]] and an u64 title-id. Returns an [[#IFileSystem]]. | ||
The [[#IFileSystem]] must be ''' | The [[#IFileSystem]] must be '''Meta''' if the NCA type is 0. | ||
The input buffer is the output string path from [[NS_Services#GetApplicationContentPath|GetApplicationContentPath]]. | The input buffer is the output string path from [[NS_Services#GetApplicationContentPath|GetApplicationContentPath]]. | ||
Line 550: | Line 550: | ||
May return errors when attempting to access NCA-paths for an update-title with a gamecard, when the gamecard isn't inserted. May return error 0x7D402 in some cases with update-titles. Non-val2 in32 values with NCA-type1 are unusable, even for normal titles. | May return errors when attempting to access NCA-paths for an update-title with a gamecard, when the gamecard isn't inserted. May return error 0x7D402 in some cases with update-titles. Non-val2 in32 values with NCA-type1 are unusable, even for normal titles. | ||
The official "MountApplicationPackage" func uses this with in64=0 and [[# | The official "MountApplicationPackage" func uses this with in64=0 and [[#FileSystemProxyType]] '''Package'''. | ||
After the [[# | After the [[#FileSystemProxyType]] specific permissions are checked, it then gets the func retval for permissions-type 0x25 and func0. | ||
When [[# | When [[#FileSystemProxyType]] is '''Meta''', it uses in64=0xffffffffffffffff internally, otherwise it checks if in64 is set to 0xffffffffffffffff then throws an error if so. When the in64 used internally is not 0xffffffffffffffff, it's compared with the NCA [[NCM_services#ProgramId|ProgramId]], then an error is thrown on mismatch. | ||
== OpenBisFileSystem == | == OpenBisFileSystem == | ||
Line 1,497: | Line 1,497: | ||
No input/output. | No input/output. | ||
= | = FileSystemProxyType = | ||
This is "nn::fs::FileSystemProxyType". | |||
{| class="wikitable" border="1" | {| class="wikitable" border="1" | ||
|- | |- | ||
Line 1,504: | Line 1,506: | ||
| 0 || Code | | 0 || Code | ||
|- | |- | ||
| 1 || | | 1 || Rom | ||
|- | |- | ||
| 2 || Logo | | 2 || Logo | ||
|- | |- | ||
| 3 || | | 3 || Control | ||
|- | |- | ||
| 4 || | | 4 || Manual | ||
|- | |- | ||
| 5 || | | 5 || Meta | ||
|- | |- | ||
| 6 || | | 6 || Data | ||
|- | |- | ||
| 7 || | | 7 || Package | ||
|- | |- | ||
| 8 || [4.0.0+] RegisteredUpdate | | 8 || [4.0.0+] RegisteredUpdate |