upload src
This commit is contained in:
commit
fd842c1ecb
|
@ -0,0 +1,55 @@
|
|||
# ---> C
|
||||
# Prerequisites
|
||||
*.d
|
||||
|
||||
# Object files
|
||||
*.o
|
||||
*.ko
|
||||
*.obj
|
||||
*.elf
|
||||
|
||||
# Linker output
|
||||
*.ilk
|
||||
*.map
|
||||
*.exp
|
||||
|
||||
# Precompiled Headers
|
||||
*.gch
|
||||
*.pch
|
||||
|
||||
# Libraries
|
||||
*.lib
|
||||
*.a
|
||||
*.la
|
||||
*.lo
|
||||
|
||||
# Shared objects (inc. Windows DLLs)
|
||||
*.dll
|
||||
*.so
|
||||
*.so.*
|
||||
*.dylib
|
||||
|
||||
# Executables
|
||||
*.exe
|
||||
*.out
|
||||
*.app
|
||||
*.i*86
|
||||
*.x86_64
|
||||
*.hex
|
||||
|
||||
# Debug files
|
||||
*.dSYM/
|
||||
*.su
|
||||
*.idb
|
||||
*.pdb
|
||||
|
||||
# Kernel Module Compile Results
|
||||
*.mod*
|
||||
*.cmd
|
||||
.tmp_versions/
|
||||
modules.order
|
||||
Module.symvers
|
||||
Mkfile.old
|
||||
dkms.conf
|
||||
|
||||
build/*
|
|
@ -0,0 +1,34 @@
|
|||
cmake_minimum_required(VERSION 2.8)
|
||||
|
||||
if(NOT DEFINED CMAKE_TOOLCHAIN_FILE)
|
||||
if(DEFINED ENV{VITASDK})
|
||||
set(CMAKE_TOOLCHAIN_FILE "$ENV{VITASDK}/share/vita.toolchain.cmake" CACHE PATH "toolchain file")
|
||||
else()
|
||||
message(FATAL_ERROR "Please define VITASDK to point to your SDK path!")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
project(PythonWhiteFin)
|
||||
include("${VITASDK}/share/vita.cmake" REQUIRED)
|
||||
|
||||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wl,-q -Wall -O3 -nostdlib")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fno-rtti -fno-exceptions")
|
||||
|
||||
add_executable(PythonWhiteFin
|
||||
packetlog.c
|
||||
)
|
||||
|
||||
target_link_libraries(PythonWhiteFin
|
||||
taihenForKernel_stub
|
||||
SceIofilemgrForDriver_stub
|
||||
SceSdifForDriver_stub
|
||||
SceNpDrmForDriver_stub
|
||||
SceRtcForDriver_stub
|
||||
SceRegMgrForDriver_stub
|
||||
SceSblSsMgrForDriver_stub
|
||||
SceSysclibForDriver_stub
|
||||
SceDebugForDriver_stub
|
||||
SceThreadmgrForDriver_stub
|
||||
)
|
||||
|
||||
vita_create_self(PythonWhiteFin.skprx PythonWhiteFin CONFIG exports.yml UNSAFE)
|
|
@ -0,0 +1,9 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2024 Li
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
@ -0,0 +1,3 @@
|
|||
# PythonWhiteFin
|
||||
|
||||
revert cobra blackfin patches added in 3.60
|
|
@ -0,0 +1,8 @@
|
|||
packetlog:
|
||||
attributes: 0
|
||||
version:
|
||||
major: 1
|
||||
minor: 1
|
||||
main:
|
||||
start: module_start
|
||||
stop: module_stop
|
|
@ -0,0 +1,34 @@
|
|||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
#include <vitasdkkern.h>
|
||||
#include <taihen.h>
|
||||
|
||||
static int kernelGetSysTime = -1;
|
||||
static tai_hook_ref_t kernelGetSysTimeRef;
|
||||
|
||||
uint64_t sceKernelGetSystemTimeWide_Patched(){
|
||||
return 0;
|
||||
}
|
||||
|
||||
void _start() __attribute__ ((weak, alias ("module_start")));
|
||||
int module_start(SceSize argc, const void *args)
|
||||
{
|
||||
|
||||
// undo cobra blackfin patch
|
||||
kernelGetSysTime = taiHookFunctionImportForKernel(KERNEL_PID,
|
||||
&kernelGetSysTimeRef,
|
||||
"SceSblGcAuthMgr",
|
||||
0xE2C40624, // SceThreadmgrForDriver
|
||||
0xF4EE4FA9, // sceKernelGetSystemTimeWide
|
||||
sceKernelGetSystemTimeWide_Patched);
|
||||
ksceKernelPrintf("[started] %x %x\n", kernelGetSysTime, kernelGetSysTimeRef);
|
||||
|
||||
return SCE_KERNEL_START_SUCCESS;
|
||||
}
|
||||
|
||||
int module_stop(SceSize argc, const void *args)
|
||||
{
|
||||
if (kernelGetSysTime >= 0) taiHookReleaseForKernel(kernelGetSysTime, kernelGetSysTimeRef);
|
||||
|
||||
return SCE_KERNEL_STOP_SUCCESS;
|
||||
}
|
Loading…
Reference in New Issue