switchbrew / libnx

Library for Switch Homebrew
https://switchbrew.github.io/libnx/
ISC License
1.26k stars 167 forks source link

nv: Allow access to nvdrv:t #633

Closed averne closed 10 months ago

averne commented 10 months ago

Applications wishing to access NVJPG need to initialize nvdrv:a, as nvdrv does not have permission for this channel. However, it appears that this service only allows a limited amount of memory to be mapped using /dev/nvhost-as-gpu (around 430MiB in my testing). As a workaround, this PR restores the possibility to access nvdrv:t, which was removed in efacee69564850e5772308938e58129a9244d44c.

NB: it would be nicer to explicitely choose which type of service to initialize, like what is done in vi, but I didn't want to break backwards compatibility.

averne commented 10 months ago

Thanks for the patch