[Nouveau] [PATCH v2] nouveau: add coherent BO attribute

Emil Velikov emil.l.velikov at gmail.com
Tue May 26 13:46:07 PDT 2015


On 26/05/15 19:06, Martin Peres wrote:
> On 26/05/2015 16:23, Alexandre Courbot wrote:
>> On Sun, May 24, 2015 at 3:26 PM, Maarten Lankhorst
>> <maarten at mblankhorst.nl> wrote:
>>> Op 23-05-15 om 08:45 schreef Alexandre Courbot:
>>>> On Fri, May 22, 2015 at 3:23 AM, Martin Peres <martin.peres at free.fr>
>>>> wrote:
>>>>> On 21/05/2015 11:47, Ben Skeggs wrote:
>>>>>> On 21 May 2015 at 16:08, Alexandre Courbot <acourbot at nvidia.com>
>>>>>> wrote:
>>>>>>> Add a flag allowing Nouveau to specify that an object should be
>>>>>>> coherent
>>>>>>> at allocation time. This is required for some class of objects like
>>>>>>> fences which are randomly-accessed by both the CPU and GPU. This
>>>>>>> flag
>>>>>>> instructs the kernel driver to make sure the object remains coherent
>>>>>>> even on architectures for which coherency is not guaranteed by
>>>>>>> the bus.
>>>>>>>
>>>>>>> Signed-off-by: Alexandre Courbot <acourbot at nvidia.com>
>>>>>> Reviewed-by: Ben Skeggs <bskeggs at redhat.com>
>>>>> Pushed!
>>>> Thanks! Should we also bump the ABI version or something?
>>> If you mean changing libdrm_nouveau.so.2 to .so.3 no! If you mean
>>> having something that pkg-config can pick up that's done
>>> automatically on every drm release.
>> Sorry for not having been clear. I was talking about checking against
>> the driver version to ensure it supports all the features that libdrm
>> can throw at it. We increased the modules's version to 1.2.2 when
>> adding the coherent flag:
>>
>> drm/nouveau/nouveau_drm.h:
>>   * 1.2.2:
>>   *      - add NOUVEAU_GEM_DOMAIN_COHERENT flag
> 
> That will be the job of mesa to check the DRM version, I would guess.
Precisely. It's up-to the user of nouveau_bo_new() to check for it.

Search for drm_version in src/gallium/drivers/nouveau to see how we
already do it for similar changes.

-Emil


More information about the Nouveau mailing list