lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Mon, 16 Jul 2018 14:03:52 +0000
From:   Marcel Ziswiler <marcel.ziswiler@...adex.com>
To:     "daniel.thompson@...aro.org" <daniel.thompson@...aro.org>
CC:     "rpurdie@...ys.net" <rpurdie@...ys.net>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "dianders@...gle.com" <dianders@...gle.com>,
        "robh+dt@...nel.org" <robh+dt@...nel.org>,
        "jingoohan1@...il.com" <jingoohan1@...il.com>,
        "enric.balletbo@...labora.com" <enric.balletbo@...labora.com>,
        "linux-leds@...r.kernel.org" <linux-leds@...r.kernel.org>,
        "jacek.anaszewski@...il.com" <jacek.anaszewski@...il.com>,
        "devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
        "kernel@...labora.com" <kernel@...labora.com>,
        "briannorris@...gle.com" <briannorris@...gle.com>,
        "pavel@....cz" <pavel@....cz>,
        "lee.jones@...aro.org" <lee.jones@...aro.org>,
        "amstan@...gle.com" <amstan@...gle.com>,
        "groeck@...gle.com" <groeck@...gle.com>
Subject: Re: REGRESSION: [RESEND PATCH v3 1/4] backlight: pwm_bl: linear
 interpolation between brightness-levels

On Mon, 2018-07-16 at 14:51 +0100, Daniel Thompson wrote:
> On Mon, Jul 16, 2018 at 11:57:29AM +0000, Marcel Ziswiler wrote:
> > On Mon, 2018-07-16 at 10:42 +0100, Daniel Thompson wrote:
> > > > 
> > > > From dbb31d00c9f2873affedbceae917c9d7fce5f832 Mon Sep 17
> > > > 00:00:00
> > > > 2001
> > > > Message-Id:
> > > > <dbb31d00c9f2873affedbceae917c9d7fce5f832.1531664663.git.ma
> > > > rcel.ziswiler@...adex.com>
> > > > From: Daniel Thompson <daniel.thompson@...aro.org>
> > > > Date: Sun, 15 Jul 2018 08:49:05 +0100
> > > > Subject: [PATCH] backlight: pwm_bl: Fix uninitialized variable
> > > > 
> > > > Currently, if the DT does not define num-interpolated-steps
> > > > then
> > > > num_steps is undefined meaning the interpolation code will
> > > > deploy
> > > > randomly. Fix this.
> > > > 
> > > > Fixes: 573fe6d1c25c ("backlight: pwm_bl: Linear interpolation
> > > > between
> > > > brightness-levels")
> > > > Reported-by: Marcel Ziswiler <marcel.ziswiler@...adex.com>
> > > > Signed-off-by: Daniel Thompson <daniel.thompson@...aro.org>
> > > > Signed-off-by: Marcel Ziswiler <marcel.ziswiler@...adex.com>
> > > 
> > > Is it Tested-by: too? It would be good to confirm I was right
> > > about
> > > the
> > > cause of the problem.
> > 
> > Yes and I confirm you were right.
> 
> Thanks.
> 
> 
> > > >  drivers/video/backlight/pwm_bl.c | 18 ++++++++----------
> > > >  1 file changed, 8 insertions(+), 10 deletions(-)
> > > > 
> > > > diff --git a/drivers/video/backlight/pwm_bl.c
> > > > b/drivers/video/backlight/pwm_bl.c
> > > > index 9ee4c1b735b2..e884d589378d 100644
> > > > --- a/drivers/video/backlight/pwm_bl.c
> > > > +++ b/drivers/video/backlight/pwm_bl.c
> > > > @@ -250,7 +250,7 @@ static int pwm_backlight_parse_dt(struct
> > > > device
> > > > *dev,
> > > >  	struct device_node *node = dev->of_node;
> > > >  	unsigned int num_levels = 0;
> > > >  	unsigned int levels_count;
> > > > -	unsigned int num_steps;
> > > > +	unsigned int num_steps = 0;
> > > 
> > > This can go. If we check the return code them this variable is no
> > > longer
> > > used uninitialized [I'm OK to make the change though... since
> > > you've
> > > kept my name at the top ;-) ].
> > 
> > Yes, I confirm that this works for me. Are you gona send a proper
> > patch
> > out or should I do it?
> 
> I can send it out.
> 
> 
> Daniel.

Thank you.

Cheers

Marcel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ