[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg-devel
Subject:    Re: [PATCH xserver 1/2] modesetting: Fix swapping of provider sink / source capabilities
From:       Emil Velikov <emil.l.velikov () gmail ! com>
Date:       2016-06-23 0:22:29
Message-ID: CACvgo53eLTv61G3bJ1O1DADFaj+JPECgcE_xxj=_5+U3XZRUdg () mail ! gmail ! com
[Download RAW message or body]

On 22 June 2016 at 22:02, Hans de Goede <hdegoede@redhat.com> wrote:
> Hi,
>
> On 22-06-16 21:19, Emil Velikov wrote:
>>
>> Hi Hans,
>>
>> On 16 June 2016 at 14:37, Hans de Goede <hdegoede@redhat.com> wrote:
>>>
>>> When a card has import capability it can be an offload _sink_, not
>>> a source and vice versa for export capability.
>>>
>>> This commit fixes the modesetting driver to properly set these
>>> capabilities, this went unnoticed sofar because most gpus have both
>>> import and export capability.
>>>
>> Looking at randr/rrprovider.c ProcRRGetProviderInfo() and the
>> randrproto I'm not sure that this patch is correct.
>>
>> "SourceOffload: This device can source offload buffers"
>
>
> You should read that as:
>
> "SourceOffload: This device can _be a_ source _of_ offload buffers",
> iows it can export buffers,
>
>> My understanding is that such device should have CAP_IMPORT since the
>> buffers will be sourced (imported) to the offload GPU to be processed.
>
>
> No such a device _is_ the offload gpu and can be a source of rendered
> buffers for the master to display.
>
> Also see the actual checks for the caps in randr/rrprovider.c
> ProcRRSetProviderOffloadSink() :
>
>     if (!(provider->capabilities & RR_Capability_SourceOffload))
>         return BadValue;
>
> Where provider is the gpu to which rendering is to be offloaded,
> so that one must be able to export images.
>
> And
>
>         if (!(sink_provider->capabilities & RR_Capability_SinkOffload))
>             return BadValue;
>
> Where sink_provider is the gpu which has the actual screen attached
> (aka the master) and is the one importing the images to display.
>
Ouch, I feel like such a noob. Thanks for the time and patience
bringing clarity to my delusion.

-Emil
_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic