sorear changed the topic of #riscv to: RISC-V instruction set architecture | https://riscv.org | Logs: https://libera.irclog.whitequark.org/riscv | Matrix: #riscv:catircservices.org
atka has quit [Quit: WeeChat 4.4.1]
jacklsw has joined #riscv
BootLayer has joined #riscv
dramforever[m] has joined #riscv
<dramforever[m]> i'm following this patch https://lore.kernel.org/linux-riscv/20240826-riscv_mmap-v1-0-cd8962afe47f@rivosinc.com and related stuff and i feel i'm kinda going insane
<dramforever[m]> is the linux man-pages at binding https://man7.org/linux/man-pages/man2/mmap.2.html ? if not, that's kinda weird... and if it is why don't we just implement the "nearby page boundary" behavior, plus something like limiting to sv39/sv48 by default like other architectures
<dramforever[m]> i meant, is the manpage at mmap(2) "binding" in the sense that it documents how mmap(2) should work
jacklsw has quit [Ping timeout: 246 seconds]
jacklsw has joined #riscv
<dramforever[m]> okay i kinda get the patches now... so this one https://lore.kernel.org/linux-riscv/20230809232218.849726-1-charlie@rivosinc.com/ made up some crazy scheme about limiting the address to the number of bits in hint, and then the patches linked earlier is going to revert this
<sorear> what's binding is "don't break userspace", the documentation is unfortunately secondary to that
<dramforever[m]> well, it did break userspace
<sorear> https://pubs.opengroup.org/onlinepubs/9699919799/functions/mmap.html is binding at the C level but not the syscall level and leaves pretty much everything hint-related impdef
n_crm has joined #riscv
<dramforever[m]> as mentioned somewhere in the bunch of threads, at least box64 broke because it expects the "use hint if possible" behavior without specifying MAP_FIXED
TMM has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
TMM has joined #riscv
YangyuChen[m] has joined #riscv
<YangyuChen[m]> <dramforever[m]> "is the linux man-pages at..." <- > why don't we just implement the "nearby page boundary" behavior, plus something like limiting to sv39/sv48 by default like other architectures
<YangyuChen[m]> Charlie did this before. However, that patch does not use addr+size to select the nearby page boundary but uses the address itself, which causes some problems.
ganboing has quit [Quit: Client closed]
<dramforever[m]> i still feel this scheme is kinda insane, like why can't we just do what x86 already did
<YangyuChen[m]> At that time, I suggested using SV48 by default and using size to select, and then Charlie came up with the idea to limit the upper bound based on the address and the size, which caused the problem we see now.
<dramforever[m]> > When a hint address is passed to mmap, the returned address will never use more bits than the hint address.
<dramforever[m]> did charlie just invent this out of nowhere ... ? i don't think this is how things work anywhere else
<dramforever[m]> hmmm "If another mapping already exists there, the kernel picks a new address that may or may not depend on the hint."
levitating has quit [Remote host closed the connection]
<dramforever[m]> so i don't think using hint+size as an upper bound makes much sense either but i guess it technically just "depends on the hint"
<dramforever[m]> so basically the question is still "why can't we just do what x86 did"
n_crm has quit [Changing host]
n_crm has joined #riscv
<YangyuChen[m]> On x86 and aarch64, the kernel also limits the address to 47 bits by default; if there is no space below 47 bits, we will also get an ENOMEM error. However, it does not break the userspace since we are not limiting the upper bound.
<dramforever[m]> yeah just do that
<dramforever[m]> there literally is precedence
ganboing has joined #riscv
kxxt[m] has joined #riscv
<kxxt[m]> Yes, we should get it right in one go, instead of fixing things after it reaches a kernel release and breaks userspace.
<YangyuChen[m]> I will try to resubmit this patch and rebase to master: https://lore.kernel.org/linux-riscv/tencent_B2D0435BC011135736262764B511994F4805@qq.com/
levitating has joined #riscv
zkrx has quit [Ping timeout: 255 seconds]
jacklsw has quit [Ping timeout: 265 seconds]
jacklsw has joined #riscv
levitating has quit [Ping timeout: 252 seconds]
BootLayer has quit [Quit: Leaving]
zjason`` has joined #riscv
danilogondolfo has quit [Read error: Connection reset by peer]
danilogondolfo has joined #riscv
zjason` has quit [Ping timeout: 276 seconds]
jobol has joined #riscv
Andre_Z has joined #riscv
Andre_Z has quit [Client Quit]
ZipCPU_ has joined #riscv
ZipCPU has quit [Ping timeout: 246 seconds]
ZipCPU_ is now known as ZipCPU
ldevulder has joined #riscv
ganboing has quit [Quit: Client closed]
stolen has joined #riscv
ganboing has joined #riscv
peeps[zen] has quit [Ping timeout: 248 seconds]
jacklsw has quit [Ping timeout: 246 seconds]
jfsimon1981 has quit [Read error: Connection reset by peer]
jfsimon1981_b has joined #riscv
heat has joined #riscv
ganboing has quit [Quit: Client closed]
jacklsw has joined #riscv
Andre_Z has joined #riscv
naoki has quit [Quit: naoki]
peepsalot has joined #riscv
damian101 has joined #riscv
craigo has quit [Quit: Leaving]
jacklsw has quit [Ping timeout: 264 seconds]
jacklsw has joined #riscv
prabhakalad has joined #riscv
prabhakalad has quit [Quit: Konversation terminated!]
stolen has quit [Quit: Connection closed for inactivity]
prabhakalad has joined #riscv
memset has quit [Remote host closed the connection]
memset has joined #riscv
jacklsw has quit [Ping timeout: 260 seconds]
X-Scale has joined #riscv
X-Scale has quit [Ping timeout: 256 seconds]
coldfeet has joined #riscv
Tenkawa has joined #riscv
memset has quit [Remote host closed the connection]
memset has joined #riscv
Andre_Z has quit [Ping timeout: 264 seconds]
coldfeet has quit [Quit: leaving]
levitating has joined #riscv
levitating has quit [Read error: Connection reset by peer]
Stat_headcrabed has joined #riscv
Andre_Z has joined #riscv
memset has quit [Remote host closed the connection]
memset has joined #riscv
vagrantc has joined #riscv
coldfeet has joined #riscv
BootLayer has joined #riscv
BootLayer has quit [Remote host closed the connection]
BootLayer has joined #riscv
lemoniter has joined #riscv
lemoniter has quit [Client Quit]
heat has quit [Remote host closed the connection]
heat has joined #riscv
memset has quit [Remote host closed the connection]
memset has joined #riscv
zkrx has joined #riscv
Stat_headcrabed has quit [Quit: Stat_headcrabed]
jfsimon1981_b has quit [Remote host closed the connection]
jfsimon1981_b has joined #riscv
Andre_Z has quit [Ping timeout: 276 seconds]
jfsimon1981_c has joined #riscv
jfsimon1981_b has quit [Read error: Connection reset by peer]
hightower3 has quit [Ping timeout: 272 seconds]
Stat_headcrabed has joined #riscv
Stat_headcrabed has quit [Client Quit]
danilogondolfo has quit [Quit: Leaving]
<conchuod> palmer: do you know if Clement is going to submit a new version of the SSE stuff this side of LPC?
frkazoid333 has quit [Ping timeout: 276 seconds]
<palmer> I think he will, we were talking this morning (he just got back from vacation)
<palmer> I was off yesterday and the weekend, so I'm a bit out of it
<conchuod> palmer: will he be at LPC?
<palmer> I think so
<palmer> I told everyone to go, I forget who did
psydroid2 has joined #riscv
hightower2 has joined #riscv
frkazoid333 has joined #riscv
frkzoid has joined #riscv
frkazoid333 has quit [Ping timeout: 246 seconds]
lagash has joined #riscv
BootLayer has quit [Quit: Leaving]
ars23 has joined #riscv
ars23 has quit [Changing host]
ars23 has joined #riscv
coldfeet has quit [Remote host closed the connection]
memset has quit [Remote host closed the connection]
memset has joined #riscv
ldevulder has quit [Remote host closed the connection]
___nick___ has joined #riscv
___nick___ has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
___nick___ has joined #riscv
___nick___ has quit [Ping timeout: 255 seconds]
jfsimon1981_c has quit [Remote host closed the connection]
X-Scale has joined #riscv
craigo has joined #riscv
X-Scale has quit [Ping timeout: 256 seconds]
jedesa has joined #riscv
jedesa has quit [Changing host]
jedesa has joined #riscv
jedesa has quit [Client Quit]
ars23 has quit [Quit: Leaving]
jedesa has joined #riscv
naoki has joined #riscv
r6fej_ has joined #riscv
r6fej_ has quit [Quit: Leaving]
r6fej has quit [Quit: Leaving]
jobol has quit [Quit: Leaving]
r6fej has joined #riscv
memset has quit [Remote host closed the connection]
memset has joined #riscv
psydroid2 has quit [Quit: KVIrc 5.0.0 Aria http://www.kvirc.net/]
levitating has joined #riscv
fuwei has quit [Remote host closed the connection]
fuwei has joined #riscv
Starfoxxes has quit [Ping timeout: 252 seconds]
vagrantc has quit [Quit: leaving]
<naoki> hmm... aongpio cannot be controlled on u-boot?
<naoki> ^jh7110
Starfoxxes has joined #riscv
DesRoin has quit [Ping timeout: 272 seconds]
DesRoin has joined #riscv
TMM has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
TMM has joined #riscv