Difference between revisions of "/dev/boot2"
< /dev
Jump to navigation
Jump to search
(I was wrong) |
m (wikifying) |
||
(25 intermediate revisions by 6 users not shown) | |||
Line 1: | Line 1: | ||
− | + | {{stub}} | |
+ | '''/dev/boot2''' can presumably be written to to install a new [[boot2]].{{check}} '''THIS HAS NOT BEEN VERIFIED, DO NOT RELY ON THIS TO INSTALL A CUSTOM BOOT2.''' | ||
− | + | This accepts the following commands: open, close, read, write, seek, ioctl, ioctlv | |
+ | |||
+ | IOCTL example: | ||
+ | |||
+ | 14 ioctl(0,4,12 return -101) | ||
+ | |||
+ | ioctlv 4,12,14 last only in IOS56+ | ||
+ | |||
+ | == /dev/boot2 IOS_Ioctl == | ||
+ | {| class="wikitable" | ||
+ | ! Number | ||
+ | ! In | ||
+ | ! Out | ||
+ | ! Description | ||
+ | |- | ||
+ | | 1 | ||
+ | | Nothing | ||
+ | | Nothing | ||
+ | | Possibly writes ECC data to the main copy of boot2? | ||
+ | |- | ||
+ | | 3 | ||
+ | | 4 bytes: boot2 size | ||
+ | | Nothing | ||
+ | | Seems to copy the main boot2 copy over to the backup copy. Generates ECC data a second time? | ||
+ | |} | ||
+ | |||
+ | == /dev/boot2 IOS_Ioctlv == | ||
+ | {| class="wikitable" style="margin: 1em auto 1em auto" | ||
+ | ! style="vertical-align: top;" |number | ||
+ | ! style="vertical-align: top;" |name | ||
+ | ! style="vertical-align: top;" |in count | ||
+ | ! style="vertical-align: top;" |out count | ||
+ | ! style="vertical-align: top;" |vec entry target | ||
+ | ! style="vertical-align: top;" |vec entry size [bytes] | ||
+ | ! style="vertical-align: top;" |libogc prototype | ||
+ | ! style="vertical-align: top;" |Description | ||
+ | |- | ||
+ | | style="vertical-align: top;" rowspan="3" |0xC | ||
+ | | style="vertical-align: top;" rowspan="3" |? | ||
+ | | style="vertical-align: top;" rowspan="3" |1 | ||
+ | | style="vertical-align: top;" rowspan="3" |2 | ||
+ | | style="vertical-align: top;" |? | ||
+ | | style="vertical-align: top;" |0x40 | ||
+ | | style="vertical-align: top;" rowspan="3" |No | ||
+ | | style="vertical-align: top;" rowspan="3" |? | ||
+ | |- | ||
+ | |? | ||
+ | |0x4 | ||
+ | |- | ||
+ | |? | ||
+ | |0x4 | ||
+ | |- | ||
+ | | style="vertical-align: top;" "rowspan="3" |0x4 | ||
+ | | style="vertical-align: top;" "rowspan="3" |? | ||
+ | | style="vertical-align: top;" |1/2 | ||
+ | | style="vertical-align: top;" |1/2 | ||
+ | | style="vertical-align: top;" "rowspan="3" |? | ||
+ | | style="vertical-align: top;" "rowspan="3" |0x40 | ||
+ | | style="vertical-align: top;" "rowspan="3" |No | ||
+ | | style="vertical-align: top;" "rowspan="3" |Can be used with 1 In and 1 Out or 2 In and 2 | ||
+ | |- | ||
+ | |? | ||
+ | |0x4 | ||
+ | |- | ||
+ | |? (only if you use 2 In/Out)(if this is 0 it is the same as use only 1 in and Out) | ||
+ | |0x4 | ||
+ | |- | ||
+ | |? (only if you use 2 In/Out) | ||
+ | |Different each time(0xD* 2.in) | ||
+ | |- | ||
+ | | style="vertical-align: top;" |0xE | ||
+ | | style="vertical-align: top;" |? | ||
+ | | style="vertical-align: top;" |minimal 1 | ||
+ | | style="vertical-align: top;" |0 | ||
+ | | style="vertical-align: top;" |? | ||
+ | | style="vertical-align: top;" |? | ||
+ | | style="vertical-align: top;" |No | ||
+ | | style="vertical-align: top;" |? | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | == /dev/boot2 error codes == | ||
+ | |||
+ | Note: POSIX is a standardized system that helps maintain compatibility between many different operating systems. So, each error code shown below has a given POSIX equivalent (not known yet). Other OS's many have different error code numbers, but if their POSIX equivalent is the same, they mean the same thing. | ||
+ | |||
+ | {| class="wikitable" | ||
+ | |- | ||
+ | ! Error code | ||
+ | ! POSIX equivalent | ||
+ | ! Notes | ||
+ | |- | ||
+ | | -101 | ||
+ | | ? | ||
+ | | This can refer to: Invalid Wrong IN or OUT size, wrong size for a part of the vector, vector alignment problems, non-existant ioctl, or wrong structure. | ||
+ | |- | ||
+ | |- | ||
+ | | -102 | ||
+ | | ? | ||
+ | | ? | ||
+ | |-|- | ||
+ | | -104 | ||
+ | | ? | ||
+ | | ? | ||
+ | |-|- | ||
+ | | -106 | ||
+ | | ? | ||
+ | | ? | ||
+ | |-|- | ||
+ | | -107 | ||
+ | | ? | ||
+ | | ? | ||
+ | |-|- | ||
+ | | -108 | ||
+ | | ? | ||
+ | | ? | ||
+ | |- | ||
+ | |- | ||
+ | |} | ||
+ | |||
+ | [[Category:Wii Filesystem]] |
Latest revision as of 16:07, 26 May 2022
This article is a stub. You can help WiiBrew by expanding it. |
/dev/boot2 can presumably be written to to install a new boot2.[check] THIS HAS NOT BEEN VERIFIED, DO NOT RELY ON THIS TO INSTALL A CUSTOM BOOT2.
This accepts the following commands: open, close, read, write, seek, ioctl, ioctlv
IOCTL example:
14 ioctl(0,4,12 return -101)
ioctlv 4,12,14 last only in IOS56+
/dev/boot2 IOS_Ioctl
Number | In | Out | Description |
---|---|---|---|
1 | Nothing | Nothing | Possibly writes ECC data to the main copy of boot2? |
3 | 4 bytes: boot2 size | Nothing | Seems to copy the main boot2 copy over to the backup copy. Generates ECC data a second time? |
/dev/boot2 IOS_Ioctlv
number | name | in count | out count | vec entry target | vec entry size [bytes] | libogc prototype | Description |
---|---|---|---|---|---|---|---|
0xC | ? | 1 | 2 | ? | 0x40 | No | ? |
? | 0x4 | ||||||
? | 0x4 | ||||||
0x4 | ? | 1/2 | 1/2 | ? | 0x40 | No | Can be used with 1 In and 1 Out or 2 In and 2 |
? | 0x4 | ||||||
? (only if you use 2 In/Out)(if this is 0 it is the same as use only 1 in and Out) | 0x4 | ||||||
? (only if you use 2 In/Out) | Different each time(0xD* 2.in) | ||||||
0xE | ? | minimal 1 | 0 | ? | ? | No | ? |
/dev/boot2 error codes
Note: POSIX is a standardized system that helps maintain compatibility between many different operating systems. So, each error code shown below has a given POSIX equivalent (not known yet). Other OS's many have different error code numbers, but if their POSIX equivalent is the same, they mean the same thing.
Error code | POSIX equivalent | Notes |
---|---|---|
-101 | ? | This can refer to: Invalid Wrong IN or OUT size, wrong size for a part of the vector, vector alignment problems, non-existant ioctl, or wrong structure. |
-102 | ? | ? |
-104 | ? | ? |
-106 | ? | ? |
-107 | ? | ? |
-108 | ? | ? |