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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190811092411.4474796c@archlinux>
Date:   Sun, 11 Aug 2019 09:24:11 +0100
From:   Jonathan Cameron <jic23@...nel.org>
To:     Jacopo Mondi <jacopo@...ndi.org>
Cc:     Jacopo Mondi <jacopo+renesas@...ndi.org>,
        Hartmut Knaack <knaack.h@....de>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Peter Meerwald-Stadler <pmeerw@...erw.net>,
        Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>,
        Stefan Agner <stefan@...er.ch>, linux-iio@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] iio: adc: max9611: Fix temperature reading in probe

On Tue, 6 Aug 2019 09:31:14 +0200
Jacopo Mondi <jacopo@...ndi.org> wrote:

> Hi Jonathan,
> 
> On Mon, Aug 05, 2019 at 06:12:44PM +0100, Jonathan Cameron wrote:
> > On Mon,  5 Aug 2019 17:55:15 +0200
> > Jacopo Mondi <jacopo+renesas@...ndi.org> wrote:
> >  
> > > The max9611 driver reads the die temperature at probe time to validate
> > > the communication channel. Use the actual read value to perform the test
> > > instead of the read function return value, which was mistakenly used so
> > > far.
> > >
> > > The temperature reading test was only successful because the 0 return
> > > value is in the range of supported temperatures.
> > >
> > > Fixes: 69780a3bbc0b ("iio: adc: Add Maxim max9611 ADC driver")
> > > Signed-off-by: Jacopo Mondi <jacopo+renesas@...ndi.org>  
> >
> > Applied to the fixes-togreg branch of iio.git and marked for
> > stable.  That'll be a bit fiddly given other changes around this
> > so we may need to do backports.
> >  
> 
> Indeed, I should have mentioned this patch depends on Joe's
> ae8cc91a7d85 ("iio: adc: max9611: Fix misuse of GENMASK macro")
> which is now in linux-next, otherwise it might atually trigger errors
> due to the wrong mask value.
> 
> I wonder if there's a way to keep track of these dependencies for the
> sake of backporting, or it's an operation that has to be carried out
> manually...
A note in the commit message is normally enough as all the stable
maintainers check that first.  In this particular case both patches
are marked for stable so will get picked up automatically in the right
order (hopefully!).

Thanks,

Jonathan

> 
> Thanks
>    j
> 
> >  
> > > ---
> > >  drivers/iio/adc/max9611.c | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/iio/adc/max9611.c b/drivers/iio/adc/max9611.c
> > > index 917223d5ff5b..e9f6b1da1b94 100644
> > > --- a/drivers/iio/adc/max9611.c
> > > +++ b/drivers/iio/adc/max9611.c
> > > @@ -480,7 +480,7 @@ static int max9611_init(struct max9611_dev *max9611)
> > >  	if (ret)
> > >  		return ret;
> > >
> > > -	regval = ret & MAX9611_TEMP_MASK;
> > > +	regval &= MAX9611_TEMP_MASK;
> > >
> > >  	if ((regval > MAX9611_TEMP_MAX_POS &&
> > >  	     regval < MAX9611_TEMP_MIN_NEG) ||
> > > --
> > > 2.22.0
> > >  
> >  

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ