mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-12-03 03:03:50 +01:00
Fake netconf dialog, etc
This commit is contained in:
1 parent
aca35fc96c
commit
3e207a1490
6 files changed
+63
-10
No files matched your search
@@ -94,6 +94,11 @@ bool ElfReader::LoadInto(u32 loadAddress)
|
||||
else
|
||||
vaddr = userMemory.Alloc(totalSize, false, "ELF");
|
||||
|
||||
if (vaddr == -1) {
|
||||
ERROR_LOG(LOADER, "Failed to allocate memory for ELF!");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (bRelocate) {
|
||||
DEBUG_LOG(LOADER,"Relocatable module");
|
||||
entryPoint += vaddr;
|
||||
|
||||
+1
-2
@@ -30,7 +30,6 @@ struct HLEFunction
|
||||
u32 ID;
|
||||
HLEFunc func;
|
||||
const char *name;
|
||||
int minVersion; // for example: 150 for 1.5, 271 for 2.71, etc. If 0, counts as 150.
|
||||
};
|
||||
|
||||
struct HLEModule
|
||||
@@ -42,7 +41,7 @@ struct HLEModule
|
||||
|
||||
struct Syscall
|
||||
{
|
||||
char moduleName[32];
|
||||
char moduleName[32];
|
||||
u32 symAddr;
|
||||
u32 nid;
|
||||
};
|
||||
|
||||
@@ -150,13 +150,13 @@ void sceKernelRegisterDefaultExceptionHandler()
|
||||
void sceKernelSetGPO()
|
||||
{
|
||||
// Sets debug LEDs.
|
||||
INFO_LOG(HLE,"sceKernelSetGPO(%02x)", PARAM(0));
|
||||
DEBUG_LOG(HLE,"sceKernelSetGPO(%02x)", PARAM(0));
|
||||
}
|
||||
|
||||
void sceKernelGetGPI()
|
||||
{
|
||||
// Always returns 0 on production systems.
|
||||
INFO_LOG(HLE,"0=sceKernelGetGPI()");
|
||||
DEBUG_LOG(HLE,"0=sceKernelGetGPI()");
|
||||
RETURN(0);
|
||||
}
|
||||
|
||||
@@ -318,13 +318,13 @@ const HLEFunction ThreadManForUser[] =
|
||||
{0x17c1684e,sceKernelReferThreadStatus,"sceKernelReferThreadStatus"},
|
||||
{0x2C34E053,0,"sceKernelReleaseWaitThread"},
|
||||
{0x75156e8f,sceKernelResumeThread,"sceKernelResumeThread"},
|
||||
{0x27e22ec2,0,"sceKernelResumeDispatchThread"},
|
||||
{0x3ad58b8c,&WrapU_V<sceKernelSuspendDispatchThread>,"sceKernelSuspendDispatchThread"},
|
||||
{0x27e22ec2,&WrapU_U<sceKernelResumeDispatchThread>,"sceKernelResumeDispatchThread"},
|
||||
{0x912354a7,sceKernelRotateThreadReadyQueue,"sceKernelRotateThreadReadyQueue"},
|
||||
{0x9ACE131E,sceKernelSleepThread,"sceKernelSleepThread"},
|
||||
{0x82826f70,sceKernelSleepThreadCB,"sceKernelSleepThreadCB"},
|
||||
{0xF475845D,&WrapU_V<sceKernelStartThread>,"sceKernelStartThread"},
|
||||
{0x9944f31f,sceKernelSuspendThread,"sceKernelSuspendThread"},
|
||||
{0x3ad58b8c,0,"sceKernelSuspendDispatchThread"},
|
||||
{0x616403ba,0,"sceKernelTerminateThread"},
|
||||
{0x383f7bcc,sceKernelTerminateDeleteThread,"sceKernelTerminateDeleteThread"},
|
||||
{0x840E8133,sceKernelWaitThreadEndCB,"sceKernelWaitThreadEndCB"},
|
||||
|
||||
@@ -257,6 +257,9 @@ SceUID threadIdleID[2];
|
||||
|
||||
int eventScheduledWakeup;
|
||||
|
||||
bool dispatchSuspended = false;
|
||||
|
||||
|
||||
// This seems nasty
|
||||
SceUID curModule;
|
||||
|
||||
@@ -286,6 +289,8 @@ void __KernelThreadingInit()
|
||||
{
|
||||
u32 blockSize = 4 * 4 + 4 * 2 * 3; // One 16-byte thread plus 3 8-byte "hacks"
|
||||
|
||||
dispatchSuspended = false;
|
||||
|
||||
idleThreadHackAddr = kernelMemory.Alloc(blockSize, false, "threadrethack");
|
||||
// Make sure it got allocated where we expect it... at the very start of kernel RAM
|
||||
//CHECK_EQ(idleThreadHackAddr & 0x3FFFFFFF, 0x08000000);
|
||||
@@ -928,6 +933,21 @@ void sceKernelExitDeleteThread()
|
||||
}
|
||||
}
|
||||
|
||||
u32 sceKernelSuspendDispatchThread()
|
||||
{
|
||||
u32 oldDispatchSuspended = dispatchSuspended;
|
||||
dispatchSuspended = true;
|
||||
DEBUG_LOG(HLE,"%i=sceKernelSuspendDispatchThread()", oldDispatchSuspended);
|
||||
return oldDispatchSuspended;
|
||||
}
|
||||
|
||||
u32 sceKernelResumeDispatchThread(u32 suspended)
|
||||
{
|
||||
u32 oldDispatchSuspended = dispatchSuspended;
|
||||
dispatchSuspended = suspended;
|
||||
DEBUG_LOG(HLE,"%i=sceKernelResumeDispatchThread(%i)",oldDispatchSuspended, suspended);
|
||||
return oldDispatchSuspended;
|
||||
}
|
||||
|
||||
void sceKernelRotateThreadReadyQueue()
|
||||
{
|
||||
|
||||
@@ -36,6 +36,8 @@ void _sceKernelExitThread();
|
||||
void sceKernelGetThreadId();
|
||||
void sceKernelGetThreadCurrentPriority();
|
||||
u32 sceKernelStartThread();
|
||||
u32 sceKernelSuspendDispatchThread();
|
||||
u32 sceKernelResumeDispatchThread(u32 suspended);
|
||||
void sceKernelWaitThreadEnd();
|
||||
void sceKernelReferThreadStatus();
|
||||
void sceKernelChangeCurrentThreadAttr();
|
||||
|
||||
+31
-4
@@ -350,6 +350,33 @@ void sceUtilityOskGetStatus()
|
||||
}
|
||||
|
||||
|
||||
void sceUtilityNetconfInitStart()
|
||||
{
|
||||
DEBUG_LOG(HLE,"FAKE sceUtilityNetconfInitStart(%i)", PARAM(0));
|
||||
__UtilityInitStart();
|
||||
}
|
||||
|
||||
void sceUtilityNetconfShutdownStart()
|
||||
{
|
||||
DEBUG_LOG(HLE,"FAKE sceUtilityNetconfShutdownStart(%i)", PARAM(0));
|
||||
__UtilityShutdownStart();
|
||||
RETURN(0);
|
||||
}
|
||||
|
||||
void sceUtilityNetconfUpdate()
|
||||
{
|
||||
DEBUG_LOG(HLE,"FAKE sceUtilityNetconfUpdate(%i)", PARAM(0));
|
||||
__UtilityUpdate();
|
||||
RETURN(0);
|
||||
}
|
||||
|
||||
void sceUtilityNetconfGetStatus()
|
||||
{
|
||||
DEBUG_LOG(HLE,"sceUtilityNetconfGetStatus()");
|
||||
RETURN(__UtilityGetStatus());
|
||||
}
|
||||
|
||||
|
||||
void sceUtilityGetSystemParamString()
|
||||
{
|
||||
int id = PARAM(0);
|
||||
@@ -388,10 +415,10 @@ u32 sceUtilityLoadNetModule(u32 module)
|
||||
const HLEFunction sceUtility[] =
|
||||
{
|
||||
{0x1579a159, &WrapU_U<sceUtilityLoadNetModule>, "sceUtilityLoadNetModule"},
|
||||
{0xf88155f6, 0, "sceUtilityNetconfShutdownStart"},
|
||||
{0x4db1e739, 0, "sceUtilityNetconfInitStart"},
|
||||
{0x91e70e35, 0, "sceUtilityNetconfUpdate"},
|
||||
{0x6332aa39, 0, "sceUtilityNetconfGetStatus"},
|
||||
{0xf88155f6, sceUtilityNetconfShutdownStart, "sceUtilityNetconfShutdownStart"},
|
||||
{0x4db1e739, sceUtilityNetconfInitStart, "sceUtilityNetconfInitStart"},
|
||||
{0x91e70e35, sceUtilityNetconfUpdate, "sceUtilityNetconfUpdate"},
|
||||
{0x6332aa39, sceUtilityNetconfGetStatus, "sceUtilityNetconfGetStatus"},
|
||||
|
||||
{0x67af3428, sceUtilityMsgDialogShutdownStart, "sceUtilityMsgDialogShutdownStart"},
|
||||
{0x2ad8e239, sceUtilityMsgDialogInitStart, "sceUtilityMsgDialogInitStart"},
|
||||
|
||||
Reference in new issue
Block a user