Comments (3)
Hi! Which architecture are you asking about in this case? I'm guessing this is riscv64, since from what I can remember that's the only one that generally defaults to Sv39.
In the case of a Sv48 arch, the code has the logic to deal with it, it just has to be compile time set to a Sv48. See https://github.com/littlekernel/lk/blob/master/arch/riscv/rules.mk#L50
from lk.
Hi @travisg thanks for the info.
Sorry I forgot to mention the architecture.
Hi @travisg.
can you help me with another query regarding arm64.
In arm64, does it supports VA>39 bits?
Also as you can see here:
[https://github.com/littlekernel/lk/blob/master/arch/arm64/rules.mk#L62C1-L62C20]
I was just wondering the USER_ASPACE_BASE will vary according to the user, right? If the user changes it, Will the USER_ASPACE_SIZE will still be the same? I understand the USER APSACE SIZE can go till max 0XFFFFFFFFFFFF.
From what I could understand from code the sum of USER_ASPACE_BASE + USER_ASPACE_SIZE should be 0xFFFFFF000000. is this the correct understanding or I'm missing something?
from lk.
ARM64 indeed supports more than 39 bits. In the default configuration each half of the total address space is 48 bits long, so what those constants are marking is:
user aspace 0x100.0000 - 0x0000.ffff.ffff.ffff
kernel aspace 0xffff.0000.0000.0000 .... 0xffff.ffff.ffff.ffff
The reason for user aspace not being based at 0 is to keep 0 unmapped, so that null pointers are trapped. Actual hardware supports down to 0.
Of course, the full 64bit address space is not supported on ARM64 (or most architectures for that matter), so there's a gap of unusable hardware space between 0x0000.ffff.ffff.ffff - 0xffff.0000.0000.0000.
from lk.
Related Issues (20)
- [Feature] Dual boot support HOT 4
- [libc][printf] limited number of characters support
- arch_in_int_handler not working on multicore ARCH HOT 1
- riscv sifive_u qemu port doesn't seem to have working timers/interrupts
- printf("%zd") of ssize_t variables results in a warning
- Exception occurs when SVE instructions used on aarch64
- [lib][console] unused with_history parameter when creating a new console
- Adding the `-mgeneral-regs-only` flag breaks variadic functions
- Aarch64 ILP32 LK HOT 1
- Saving FPU registers during IRQ Handler HOT 1
- Evaluate Profile-Guided Optimization (PGO) HOT 2
- Assessment of the difficulty in porting CPU architecture for lk HOT 1
- ........................... 5776-9529-3040
- [virtio/fs] Support for virtual 9p devices HOT 3
- qemu-system-riscv64 cannot start up HOT 1
- Upstreaming msm8916 SoC support HOT 3
- Cortex A8 target generating SIMD code in timer_tick interrupt handler HOT 5
- buffer-underflow on _vsnprintf when len=0
- compiling VisionFive2 failed HOT 2
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 lk.