Skip to content

Commit 76f4352

Browse files
committed
Config&ShellCode: 8550: Add ShellCode for Ayaneo Pocket S.
- Push Turbo key (Gpio109, active low) to enter uefi, otherwise enter android.
1 parent 03a4e51 commit 76f4352

2 files changed

Lines changed: 15 additions & 0 deletions

File tree

Config/DualBoot.Sm8550.cfg

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
StackBase=0xC7CC0000
2+
StackSize=0x00400000

ShellCode/ShellCode.AYAPS.S

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
.include "DummyHead.S"
2+
3+
/* Shell Code for Ayaneo Pocket S */
4+
_ShellCodeStart:
5+
movz x4, #0xd000
6+
movk x4, #0x0f16, lsl #16 // Store 0xf16d000 to x4, which is io control of gpio109 on sm8550.
7+
str wzr, [x4], #4 // Set 0 in control reg, then x4 add 4
8+
ldr w5, [x4] // Get status value from address stored in x4 and store it to w5.
9+
and w5, w5, #1 // w5 & 1 and save value in w5.
10+
cbz w5, _UEFI // Compare w5 with 0, if w5 == 0 goto _UEFI, else execute next instruction(jmp Linux).
11+
12+
.include "CommonTail.S"
13+
/* Do not remove the last line */

0 commit comments

Comments
 (0)