OpenOrbis / musl

A PS4 port of musl for the OpenOrbis PS4 Toolchain.
Other
34 stars 9 forks source link

[possible enhancement] Use libkernel wrappers instead of issuing syscalls directly #6

Closed sleirsgoevy closed 4 years ago

sleirsgoevy commented 4 years ago

This is not a bugreport, just a possible enhancement.

Arguments:

  1. Issuing syscalls directly requires a patched kernel. If some other way of running homebrew (e.g. a code execution vulnerability in a JIT-enabled system app) approaches, OpenOrbis toolchain would be of no use.
  2. It seems that libkernel explicitly omits some syscall wrappers. Sony can expect that replacing one of those with another custom syscall won't break existing code.
  3. Little can be done without loading system libraries, and those depend on libkernel anyway.
  4. libkernel wrappers are supposed to be C functions, so using them could allow to avoid low-level ABI incompatibilities.