BenHur
Joined: 20 Oct 2007 Posts: 30
|
Posted: Tue Dec 22, 2009 6:45 am Post subject: access user mode memory from kernel mode |
|
|
Hi,
I'm using the htmlviewer (from the pspsdk sample dir) and hook some sceIO-functions to intercept file-queries to serve websites to it (the goal is a simple offline wiki-reader). However, I seem to have problems in the kernel module with allocating memory from the user mode memory block (kernel memory isn't enough):
| Code: | int memid = sceKernelAllocPartitionMemory(2, "mybuffer", 0, size, NULL);
char* ptr = sceKernelGetBlockHeadAddr(memid); | returns a valid address, but after using the memory the htmlviewer hangs while shuting down. Could this be related to an improper memory allocation? How is it done properly? (FYI: htmlviewer uses sceKernelCreateVpl and sceKernelAllocateVpl to allocate memory).
Any thoughts?
Cheers, BenHur |
|