[Intel-gfx] [PATCH 2/7] drm: delay vblank cleanup until after driver unload

Jesse Barnes jbarnes at virtuousgeek.org
Mon Mar 29 18:05:34 CEST 2010


On Mon, 29 Mar 2010 10:02:04 +1000
Dave Airlie <airlied at gmail.com> wrote:

> 2010/3/29 Kristian Høgsberg <krh at bitplanet.net>:
> > On Fri, Mar 26, 2010 at 7:07 PM, Jesse Barnes <jbarnes at virtuousgeek.org> wrote:
> >> Drivers may use vblank calls now (e.g. drm_vblank_off) in their unload
> >> paths, so don't clean up the vblank related structures until after
> >> driver unload.
> >
> > I haven't tested this specific patch on a recent DRM, but I made the
> > same patch a while ago, and it fixed module unload for me.  I sent it
> > to the list and it fell through the cracks, because "vblank is hard"
> > or something.
> >
> > Reviewed-by: Kristian Høgsberg <krh at bitplanet.net>
> 
> I didn't apply it because from what I can see non-kms drivers need
> to free the vbl stuff on lastclose not unload. I'm nearly sure I said
> that at the
> time to.
> 
> This patch seems to suffer from the same problem from what I can see.
> 
> And really someone should already have cleaned up the insanity that is vbl
> struct allocations, vblank might not be hard, but it sure has some ugly.

Arg, yeah I didn't consider non-kms drivers.  And we had a patch to
bunch all the vbl info into a single struct, but iirc it came along as
we were still adding fields so never got applied.

Anyway I'll fix up this patch and re-post.

-- 
Jesse Barnes, Intel Open Source Technology Center



More information about the Intel-gfx mailing list