Hi Adrian,
Thanks for the patch! Some comments inline.

On 22 March 2017 at 13:40, Adrian Pielech <adrian.piel...@intel.com> wrote:
> +struct list_head window_list = {NULL, NULL};
> +
> +/* Checks if a EGLWindow already have a created surface */
> +static inline bool
> +is_window_associated_with_surface(EGLNativeWindowType window)
> +{
> +   list_for_each_entry(struct window_list_item, item, &window_list, link) {
> +      if (item->native_window = window) {

This must be changed to == rather than =. Right now it will always
return a false positive.

> +         return true;
> +      }
> +   }
> +
> +   return false;
> +}

I also can't see any locking associated with these (mutex/spinlock),
so this would in fact fail when multiple threads are
creating/destroying surfaces/displays simultaneously. Can you please
add some locking so that concurrent access succeeds?

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

Reply via email to