Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1228413 > unrolled thread

Re: [PATCH] backlight: lp855x: Make sure props struct is zeroed

Started byLee Jones <lee.jones@linaro.org>
First post2015-09-19 12:10 +0200
Last post2015-09-19 12:10 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH] backlight: lp855x: Make sure props struct is zeroed Lee Jones <lee.jones@linaro.org> - 2015-09-19 12:10 +0200

#1228413 — Re: [PATCH] backlight: lp855x: Make sure props struct is zeroed

FromLee Jones <lee.jones@linaro.org>
Date2015-09-19 12:10 +0200
SubjectRe: [PATCH] backlight: lp855x: Make sure props struct is zeroed
Message-ID<qanfH-6H6-7@gated-at.bofh.it>
On Thu, 27 Aug 2015, Bjorn Andersson wrote:

> From: Werner Johansson <werner.johansson@sonymobile.com>
> 
> The driver occasionally got stuck in suspend mode or other strange
> states as those parts of the props struct were never initialized.
> 
> Signed-off-by: Werner Johansson <werner.johansson@sonymobile.com>
> Signed-off-by: Bjorn Andersson <bjorn.andersson@sonymobile.com>
> ---
>  drivers/video/backlight/lp855x_bl.c | 1 +
>  1 file changed, 1 insertion(+)

Applied, thanks.

> diff --git a/drivers/video/backlight/lp855x_bl.c b/drivers/video/backlight/lp855x_bl.c
> index 88116b493f3b..0a7f88ce1ab0 100644
> --- a/drivers/video/backlight/lp855x_bl.c
> +++ b/drivers/video/backlight/lp855x_bl.c
> @@ -282,6 +282,7 @@ static int lp855x_backlight_register(struct lp855x *lp)
>  	struct lp855x_platform_data *pdata = lp->pdata;
>  	const char *name = pdata->name ? : DEFAULT_BL_NAME;
>  
> +	memset(&props, 0, sizeof(props));
>  	props.type = BACKLIGHT_PLATFORM;
>  	props.max_brightness = MAX_BRIGHTNESS;
>  

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web