[PATCH 2/3] drm/i915: Fix fbdev unload sequence

Chris Wilson chris at chris-wilson.co.uk
Fri Jul 14 19:32:18 UTC 2017


Quoting Daniel Vetter (2017-07-14 20:14:38)
Second nit:

> +void intel_fbdev_fini(struct drm_i915_private *dev_priv)
> +{
> +       struct intel_fbdev *ifbdev = dev_priv->fbdev;
> +
> +       if (!ifbdev)
> +               return;
> +
>         intel_fbdev_destroy(ifbdev);
>         dev_priv->fbdev = NULL;

Maybe
	struct intel_fbdev *ifbdev;

	ifbdev = fetch_and_zero(&dev_priv->fbdev);
	if (!fbdev)
		return;

	intel_fbdev_destroy(ifbdev);
-Chris


More information about the dri-devel mailing list