Comments (7)
Call ksceKernelAllocMemBlock
with Settings VA to option.field_C
and ATTR_VBASE
to option.attr
#define ATTR_VBASE (1)
from vita-headers.
Also note that the kernel memory cannot be mapped to the user address because the process has its own address space.
Kern memory to User address `0x81010000`: Should failed
User memory to User address `0x81010000`: Should success
User memory to Kern address `0x01200000`: Should failed
Kern memory to Kern address `0x01200000`: Should success
from vita-headers.
Awesome, I'm investigating if I can mimic the available memory regions of the nintendo 3DS.
Because it doesn't expose dynamic addresses for heap, mappable memory, vram, mapped IO, etc.
#define OS_HEAP_AREA_BEGIN 0x08000000 ///< Start of the heap area in the virtual address space
#define OS_HEAP_AREA_END 0x0E000000 ///< End of the heap area in the virtual address space
#define OS_MAP_AREA_BEGIN 0x10000000 ///< Start of the mappable area in the virtual address space
#define OS_MAP_AREA_END 0x14000000 ///< End of the mappable area in the virtual address space
#define OS_OLD_FCRAM_VADDR 0x14000000 ///< Old pre-8.x linear FCRAM mapping virtual address
#define OS_OLD_FCRAM_SIZE 0x8000000 ///< Old pre-8.x linear FCRAM mapping size (128 MiB)
#define OS_QTMRAM_VADDR 0x1E800000 ///< New3DS QTM memory virtual address
#define OS_QTMRAM_SIZE 0x400000 ///< New3DS QTM memory size (4 MiB; last 128 KiB reserved by kernel)
#define OS_MMIO_VADDR 0x1EC00000 ///< Memory mapped IO range virtual address
#define OS_MMIO_SIZE 0x400000 ///< Memory mapped IO range size (4 MiB)
#define OS_VRAM_VADDR 0x1F000000 ///< VRAM virtual address
#define OS_VRAM_SIZE 0x600000 ///< VRAM size (6 MiB)
#define OS_DSPRAM_VADDR 0x1FF00000 ///< DSP memory virtual address
#define OS_DSPRAM_SIZE 0x80000 ///< DSP memory size (512 KiB)
#define OS_KERNELCFG_VADDR 0x1FF80000 ///< Kernel configuration page virtual address
#define OS_SHAREDCFG_VADDR 0x1FF81000 ///< Shared system configuration page virtual address
#define OS_FCRAM_VADDR 0x30000000 ///< Linear FCRAM mapping virtual address
#define OS_FCRAM_SIZE 0x10000000 ///< Linear FCRAM mapping size (256 MiB)
Edit: removed physical addresses because they don't matter
from vita-headers.
Thank you, I will keep researching about this topic further.
from vita-headers.
Call
ksceKernelAllocMemBlock
with Settings VA tooption.field_C
andATTR_VBASE
tooption.attr
#define ATTR_VBASE (1)
Hello, I can't find "Settings VA" to fill field_C.
my code:
SceKernelAllocMemBlockKernelOpt opt;
opt.size = sizeof(SceKernelAllocMemBlockKernelOpt);
opt.field_C = 0x0; // ???? missing value
opt.attr = romMH4U.textVAddr; // virtual address is 0x100000
SceUID txtHndl = ksceKernelAllocMemBlock("3ds_text",
SCE_KERNEL_MEMBLOCK_TYPE_KERNEL_RX, // should be kernel right?
romMH4U.textSz, opt);
Checked everything with "settings" in the documentation and I found nothing.
And another thing, why does the Alloc function asks for a name?
Thanks in advance.
from vita-headers.
SceKernelAllocMemBlockKernelOpt opt;
memset(&opt, 0, sizeof(opt));
opt.size = sizeof(opt);
opt.field_C = romMH4U.textVAddr;
opt.attr = ATTR_VBASE;
from vita-headers.
Thanks for the 'memset' note. I forgot to clear this thing in the first place; my c/c++ practical skill is a little rusted.
from vita-headers.
Related Issues (20)
- Need to separate headers for each library HOT 7
- SceAppMgr HOT 6
- Some function arguments are wrong
- _vshSblAimgrGetConsoleId doesn't appear in the search HOT 11
- Functions with the same nid exist HOT 7
- socket sceNetSend looks not working properly HOT 4
- Libraries of the module SceDriverUser are in wrong modules HOT 2
- definition_check couldn't check c++ mangled methods
- split the db.yml to muliple files
- Merge vdsuite NID database to the vitasdk HOT 9
- Possible error in sceAppMgrLaunchAppByUri HOT 6
- PS Vita Dev Wiki link on homepage dead HOT 3
- Add a function to open quick menu without triggering the button HOT 5
- build.py makes bunch of empty folders without db.yml
- [Question] Calling function from loaded module HOT 9
- No `sceGxtGetDataAddress` nids?
- Compatibility with projects that have their own prototype definitions such as taihen or something
- sceAvPlayerInit return negative value (0x81300020) HOT 9
- Stubname field added to YML databases without any documentation HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from vita-headers.