PSPSDK 2024-12-24
Loading...
Searching...
No Matches
osal.c File Reference
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <pspkerror.h>
#include <pspthreadman.h>
#include <pspsdk.h>
#include <sys/pte_generic_osal.h>
Include dependency graph for osal.c:

Data Structures

struct  pspThreadData
 

Macros

#define MAX_PSP_UID   2048
 
#define DEFAULT_STACK_SIZE_BYTES   4096
 
#define PSP_MAX_TLS   32
 
#define PSP_DEBUG(x)
 
#define POLLING_DELAY_IN_us   100
 

Typedefs

typedef int pte_osThreadHandle
 
typedef int pte_osSemaphoreHandle
 
typedef int pte_osMutexHandle
 
typedef struct pspThreadData pspThreadData
 

Functions

pte_osResult pteTlsGlobalInit (int maxEntries)
 
voidpteTlsThreadInit (void)
 
pte_osResult __pteTlsAlloc (unsigned int *pKey)
 
voidpteTlsGetValue (void *pTlsThreadStruct, unsigned int index)
 
pte_osResult __pteTlsSetValue (void *pTlsThreadStruct, unsigned int index, void *value)
 
void__getTlsStructFromThread (SceUID thid)
 
pte_osResult pteTlsFree (unsigned int index)
 
void pteTlsThreadDestroy (void *pTlsThreadStruct)
 
void pteTlsGlobalDestroy (void)
 
pspThreadData__getThreadData (SceUID threadHandle)
 
int __pspStubThreadEntry (unsigned int argc, void *argv)
 

Variables

unsigned int __threadDataKey
 
void__globalTls
 

Macro Definition Documentation

◆ DEFAULT_STACK_SIZE_BYTES

#define DEFAULT_STACK_SIZE_BYTES   4096

◆ MAX_PSP_UID

#define MAX_PSP_UID   2048

◆ POLLING_DELAY_IN_us

#define POLLING_DELAY_IN_us   100

◆ PSP_DEBUG

#define PSP_DEBUG (   x)

◆ PSP_MAX_TLS

#define PSP_MAX_TLS   32

Typedef Documentation

◆ pspThreadData

◆ pte_osMutexHandle

◆ pte_osSemaphoreHandle

◆ pte_osThreadHandle

Function Documentation

◆ __getThreadData()

pspThreadData * __getThreadData ( SceUID  threadHandle)

◆ __getTlsStructFromThread()

void * __getTlsStructFromThread ( SceUID  thid)

◆ __pspStubThreadEntry()

int __pspStubThreadEntry ( unsigned int  argc,
void argv 
)
extern

◆ __pteTlsAlloc()

pte_osResult __pteTlsAlloc ( unsigned int pKey)

◆ __pteTlsSetValue()

pte_osResult __pteTlsSetValue ( void pTlsThreadStruct,
unsigned int  index,
void value 
)

◆ pteTlsFree()

pte_osResult pteTlsFree ( unsigned int  index)

◆ pteTlsGetValue()

void * pteTlsGetValue ( void pTlsThreadStruct,
unsigned int  index 
)

◆ pteTlsGlobalDestroy()

void pteTlsGlobalDestroy ( void  )

◆ pteTlsGlobalInit()

pte_osResult pteTlsGlobalInit ( int  maxEntries)

◆ pteTlsThreadDestroy()

void pteTlsThreadDestroy ( void pTlsThreadStruct)

◆ pteTlsThreadInit()

void * pteTlsThreadInit ( void  )

Variable Documentation

◆ __globalTls

void* __globalTls
extern

◆ __threadDataKey

unsigned int __threadDataKey
extern