mirror of
https://github.com/GaryOderNichts/recovery_menu.git
synced 2025-06-19 03:05:32 -04:00
23 lines
556 B
C
23 lines
556 B
C
#include "imports.h"
|
|
#include "menu.h"
|
|
|
|
static int threadStarted = 0;
|
|
static uint8_t threadStack[0x1000] __attribute__((aligned(0x20)));
|
|
|
|
int MCP_ioctl100_patch(void* msg)
|
|
{
|
|
printf("MCP_ioctl100_patch %p\n", msg);
|
|
|
|
// start the menu thread
|
|
if (!threadStarted) {
|
|
int tid = IOS_CreateThread(menuThread, NULL, threadStack + sizeof(threadStack), sizeof(threadStack), IOS_GetThreadPriority(0), IOS_THREAD_FLAGS_DETACHED);
|
|
if (tid > 0) {
|
|
IOS_StartThread(tid);
|
|
}
|
|
|
|
threadStarted = 1;
|
|
}
|
|
|
|
return 29;
|
|
}
|