notaz.gp2x.de
/
ginge.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix missing syms in ginge_dyn
[ginge.git]
/
loader
/
patches.c
diff --git
a/loader/patches.c
b/loader/patches.c
index
ada0043
..
d272b56
100644
(file)
--- a/
loader/patches.c
+++ b/
loader/patches.c
@@
-113,12
+113,12
@@
static const unsigned int sig_execve[] = {
};
#define sig_mask_execve sig_mask_all
};
#define sig_mask_execve sig_mask_all
-static const unsigned int sig_
execve2
[] = {
+static const unsigned int sig_
hw_execve
[] = {
0xef90000b, // svc 0x90000b
0xe3700a01, // cmn r0, #4096
0xe1a04000, // mov r4, r0
};
0xef90000b, // svc 0x90000b
0xe3700a01, // cmn r0, #4096
0xe1a04000, // mov r4, r0
};
-#define sig_mask_
execve2
sig_mask_all
+#define sig_mask_
hw_execve
sig_mask_all
static const unsigned int sig_chdir[] = {
0xef90000c, // svc 0x90000c
static const unsigned int sig_chdir[] = {
0xef90000c, // svc 0x90000c
@@
-130,6
+130,13
@@
static const unsigned int sig_mask_chdir[] = {
0xffffffff, 0xffffffff, 0xffffffff, 0xff000000
};
0xffffffff, 0xffffffff, 0xffffffff, 0xff000000
};
+static const unsigned int sig_readlink[] = {
+ 0xef900055, // svc 0x900055
+ 0xe3700a01, // cmn r0, #0x1000
+ 0x312fff1e, // bxcc lr
+};
+#define sig_mask_readlink sig_mask_all
+
/* special */
static const unsigned int sig_cache1[] = {
0xee073f5e, // mcr 15, 0, r3, cr7, cr14, 2
/* special */
static const unsigned int sig_cache1[] = {
0xee073f5e, // mcr 15, 0, r3, cr7, cr14, 2
@@
-165,6
+172,7
@@
asm( \
SVC_CMN_R0_MOV_R4_WRAPPER(hw_read, w_read_raw)
SVC_CMN_R0_MOV_R4_WRAPPER(hw_ioctl, w_ioctl_raw)
SVC_CMN_R0_MOV_R4_WRAPPER(hw_read, w_read_raw)
SVC_CMN_R0_MOV_R4_WRAPPER(hw_ioctl, w_ioctl_raw)
+SVC_CMN_R0_MOV_R4_WRAPPER(hw_execve, w_execve_raw)
#define PATCH_(p, f, t) { sig_##p, sig_mask_##p, ARRAY_SIZE(sig_##p), t, f, #p }
#define PATCH(f) PATCH_(f, w_##f, 0)
#define PATCH_(p, f, t) { sig_##p, sig_mask_##p, ARRAY_SIZE(sig_##p), t, f, #p }
#define PATCH(f) PATCH_(f, w_##f, 0)
@@
-188,8
+196,9
@@
static const struct {
PATCH (ioctl),
PATCH_(hw_ioctl, hw_ioctl, 1),
PATCH (sigaction),
PATCH (ioctl),
PATCH_(hw_ioctl, hw_ioctl, 1),
PATCH (sigaction),
-// PATCH_(execve, execve2, 0), // hangs
+ PATCH_(hw_execve, hw_execve, 1),
PATCH (chdir),
PATCH (chdir),
+ PATCH (readlink),
PATCH_(cache1, NULL, 2),
PATCH_(cache2, NULL, 2),
};
PATCH_(cache1, NULL, 2),
PATCH_(cache2, NULL, 2),
};