[Mesa-dev] [Bug 86837] kodi segfault since auxiliary/vl: rework the build of the VL code

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Fri Dec 19 04:58:54 PST 2014


https://bugs.freedesktop.org/show_bug.cgi?id=86837

--- Comment #5 from Emil Velikov <emil.l.velikov at gmail.com> ---
(In reply to Christian König from comment #3)
> Most likely we end up with the implementation with the dummy symbols loaded
> first (e.g. kodi loads OGL first the VDPAU). This results in a couple of
> problems when VDPAu tries to query the video capabilities from the screen.
> 
> Would it be possible to define the dummy symbols as weak and pointing to
> zero instead? That might allow overwriting them after loading VDPAU.
>
There are two catches with using weak symbols:

1. Both modules must be opened with RTLD_GLOBAL (presently holds true).
2. The VDPAU must be opened/used prior to GL. Otherwise we end up with one of
two issues:
 A: DRI module doesn't define the functions -> segfault, as we call function @0
 B: DRI module defines stubs -> the stubs end up used, rather than the ones in
VDPAU module.

So based (and the note below) on those I'll revert the previous approach and
shove everything but vl_winsys_dri.c back into the DRI modules :'(

On a closer look it seems that we have a _very_ nasty ABI between the DRI and
VDPAU modules, which lacks any checks and can explode at any moment.

Would be interesting to see if the nvidia driver uses similar approach or
copies the objects back and forth between the two contexts, keeping them in
sync. An interesting TODO for rainy days :)

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20141219/3adef699/attachment.html>


More information about the mesa-dev mailing list