Re: [PATCH 1/2] RISC-V: mm: Restrict address space for sv39,sv48,sv57

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 6/28/23 02:36, Palmer Dabbelt wrote:
On Tue, 27 Jun 2023 15:32:36 PDT (-0700), jrtc27@xxxxxxxxxx wrote:
On 27 Jun 2023, at 23:21, Charlie Jenkins <charlie@xxxxxxxxxxxx> wrote:

Make sv39 the default address space for mmap as some applications
currently depend on this assumption.

They are just plain wrong too. Sv48 was in even Priv v1.10 (the first
spec where satp was named as such and contained the mode, rather than
requiring M-mode’s help in configuring virtual memory), predating the
ratified v1.11 spec. A 39-bit address space is pathetic and has
implications for ASLR.

I strongly suggest applications be forced to support at least Sv48,
which is totally reasonable given the address space sizes used by other
architectures. Sv57 is more disruptive to some runtimes, though ideally
even that would be free for the kernel to use rather than committing to
not using it for the default uABI.

Go and OpenJDK both broke when we expanded the VA width.  I don't like it either, but if the change breaks userspace then it's a regression and we have to live with the bug.


Have we debugged this ? do we at least know why they break ? Just disabling Sv48/57 by default for everyone because some userspace apps break doesn't seem the correct approach, it seems more like a bug in userspace IMHO.



[Index of Archives]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]

  Powered by Linux