Direct access to GPU memory from within sandbox
Alexander Larsson
alexl at redhat.com
Tue Oct 1 07:06:11 UTC 2019
On Mon, Sep 30, 2019 at 7:46 PM Winnie Poon <winniepoon_home at hotmail.com>
wrote:
> thanks for your reply Michael. I've also read discussion about installing
> Nvidia driver inside flatpak. Is this another way to access the GPU memory
> without punching hole?
>
It actually depends a bit on the exact driver and how the app accesses it.
For instance, with some DRI3 drivers the X server hands the application a
file descriptor with the GPU device that the GL driver can directly use, in
other drivers the GL driver has to open the device itself. We really only
need the hole in the later case, but, to ensure it works on all drivers its
best to always punch the hole if you expect the app to have GPU access.
As for allowing it without punching a hole, I don't even know what that
means. "punch a hole" is slang for "allow access to", how would you allow
access to something without allowing access to it?
Of course, having device access doesn't mean you can arbitrarily access the
GPU memory however you please, its protected against other processes via
the kernel device driver interface.
--
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
Alexander Larsson Red Hat, Inc
alexl at redhat.com alexander.larsson at gmail.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/flatpak/attachments/20191001/9aecb2ff/attachment-0001.html>
More information about the Flatpak
mailing list