[Intel-gfx] [PATCH v3 1/2] drm/i915: Tear down fbdev if initialization fails

Chris Wilson chris at chris-wilson.co.uk
Thu Nov 19 13:46:34 PST 2015


On Thu, Nov 19, 2015 at 04:58:44PM +0100, Daniel Vetter wrote:
> On Wed, Nov 18, 2015 at 04:29:51PM +0100, Lukas Wunner wrote:
> > @@ -727,7 +730,8 @@ void intel_fbdev_fini(struct drm_device *dev)
> >  
> >  	flush_work(&dev_priv->fbdev_suspend_work);
> >  
> > -	async_synchronize_full();
> > +	if (!current_is_async())
> > +		async_synchronize_full();
> 
> I think this is a bit too fragile, and the core depency will make merging
> tricky. Can't we just push the async_synchronize_full into module unload
> for now?

(intel_fbdev_fini() is already module unload, right? Do you mean just
move the async handling into i915_driver_unload() so that we have a
single spot for all future potential users of the async framework?)

And optimising module unload to avoid one potential grace period when we
already have a bunch of grace period waits seems overkill.

The alternative to using async_synchronize_full() would be to use an
async-domain.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre


More information about the Intel-gfx mailing list