Re: [PATCH] Fix wrong initializer for "locked" variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 25 Aug 2011 15:37:45 +0200
Thomas Jarosch <thomas.jarosch@xxxxxxxxxxxxx> wrote:

> Otherwise it just contains random memory.
> 
> Issue detected by cppcheck.
> 
> Signed-off-by: Thomas Jarosch <thomas.jarosch@xxxxxxxxxxxxx>
> ---
>  drivers/gpu/drm/i915/intel_display.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index ee1d701..f6da4e4 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -878,7 +878,7 @@ static void assert_panel_unlocked(struct drm_i915_private *dev_priv,
>  	int pp_reg, lvds_reg;
>  	u32 val;
>  	enum pipe panel_pipe = PIPE_A;
> -	bool locked = locked;
> +	bool locked = true;
>  
>  	if (HAS_PCH_SPLIT(dev_priv->dev)) {
>  		pp_reg = PCH_PP_CONTROL;

Hah yeah that's a good one, thanks for the fix.

Reviewed-by: Jesse Barnes <jbarnes@xxxxxxxxxxxxxxxx>

-- 
Jesse Barnes, Intel Open Source Technology Center
_______________________________________________
dri-devel mailing list
dri-devel@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/dri-devel


[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux