[Mesa-dev] [PATCH mesa 2/9] anv: Add KHR_display extension to anv [v5]

Jason Ekstrand jason at jlekstrand.net
Thu Jun 14 20:19:20 UTC 2018


On Thu, Jun 14, 2018 at 11:42 AM, Keith Packard <keithp at keithp.com> wrote:

> Jason Ekstrand <jason at jlekstrand.net> writes:
>
> >> +   if (instance->enabled_extensions.KHR_display) {
> >> +      master_fd = open(path, O_RDWR | O_CLOEXEC);
> >>
> >
> > Is this supposed to be opening primary_path instead?
>
> Yes, and this section of code needs to occur before anv_init_wsi.
>
> I appear to have skipped testing this path on ANV and only tested it on
> RADV -- RADV has the code in the right order. Thanks for catching this;
> sorry I messed up and didn't test it.
>
> > This could just be
> >
> > if (anv_gem_get_param(master_fd, I915_PARAM_CHIPSET_ID) == 0) {
> >    close(master_fd);
> >    master_fd = -1;
> > }
> >
> > No need to type out all that IOCTL stuff.
>
> Thanks, that's lots shorter (RADV doesn't appear to have a similar helper).
>
> Here's an amendment to the proposed patch which fixes the bug and
> switches to the simpler detection method.
>

Looks good to me.  With that,

Reviewed-by: Jason Ekstrand <jason at jlekstrand.net>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20180614/f7969277/attachment.html>


More information about the mesa-dev mailing list