[APPLIED] Re: [PATCH 1/1] [Maverick] UBUNTU: SAUCE: fbcon -- fix OOPs triggered by race prevention fixes

Leann Ogasawara leann.ogasawara at canonical.com
Fri Sep 10 17:48:05 UTC 2010


Applied to Maverick linux master.

Thanks,
Leann

On Fri, 2010-09-10 at 17:26 +0100, Andy Whitcroft wrote:
> BugLink: http://bugs.launchpad.net/bugs/614008
> 
> The fix below added reference counting to framebuffer opens, it
> inadvertantly does not handle the totally missing framebuffer case:
> 
>     UBUNTU: SAUCE: fbcon -- fix race between open and removal of framebuffers
> 
> lshw tickles this searching for framebuffers leading to an OOPs and boot
> hangs for some machines.
> 
> Initial-fix-by: Dave Gilbert
> Signed-off-by: Andy Whitcroft <apw at canonical.com>
> ---
>  drivers/video/fbmem.c |    3 ++-
>  1 files changed, 2 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/video/fbmem.c b/drivers/video/fbmem.c
> index 02eb135..0088013 100644
> --- a/drivers/video/fbmem.c
> +++ b/drivers/video/fbmem.c
> @@ -1407,7 +1407,8 @@ __releases(&registered_lock)
>  
>  	spin_lock(&registered_lock);
>  	fb_info = registered_fb[idx];
> -	fb_info->ref_count++;
> +	if (fb_info)
> +		fb_info->ref_count++;
>  	spin_unlock(&registered_lock);
>  
>  	return fb_info;
> -- 
> 1.7.0.4
> 
> 






More information about the kernel-team mailing list