Hi, Emil,

On 08/29/2018 07:13 PM, Emil Velikov wrote:
From: Emil Velikov <emil.veli...@collabora.com>

Currently pipe_loader_drm_probe_fd takes ownership of the fd given.
To match that, pipe_loader_release closes it.

Yet we have many instances which do not want the change of ownership,
and thus duplicate the fd before passing it to the pipe-loader.

Move the dup() within pipe-loader, explicitly document that and document
all the cases through the codebase.

A trivial git grep -2 pipe_loader_release makes things as obvious as it
gets ;-)

Cc: Leo Liu <leo....@amd.com>
Cc: Thomas Hellstrom <thellst...@vmware.com>
Cc: Axel Davy <davyax...@gmail.com>
Cc: Patrick Rudolph <s...@das-labor.org>
Signed-off-by: Emil Velikov <emil.veli...@collabora.com>
---
I'm 99% sure that the VAAPI/XA notes are correct, but I left it as CHECK
since it's been a while since I useed those ;-)

Leo, Thomas, can you please confirm the respective CHECK notes?


Yes, The user of the xa API maintains ownership of the drm fd passed to XA.

For the xa part:
Reviewed-by: Thomas Hellstrom <thellst...@vmware.com>


Thanks,
Thomas

_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to