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:	Wed, 8 Apr 2009 10:15:22 +0200
From:	Wolfram Sang <w.sang@...gutronix.de>
To:	Jean Delvare <khali@...ux-fr.org>
Cc:	Geert Uytterhoeven <geert@...ux-m68k.org>,
	LKML <linux-kernel@...r.kernel.org>,
	Linux I2C <linux-i2c@...r.kernel.org>
Subject: Re: [GIT PULL] i2c updates for 2.6.30

On Wed, Apr 08, 2009 at 10:13:03AM +0200, Jean Delvare wrote:
> Hi Geert,
> 
> On Tue, 7 Apr 2009 22:20:29 +0200, Geert Uytterhoeven wrote:
> > On Sat, Mar 28, 2009 at 22:39, Jean Delvare <khali@...ux-fr.org> wrote:
> > > Please pull the i2c subsystem updates for Linux 2.6.30 from:
> > 
> > > Wolfram Sang (4):
> > >      i2c-algo-pca: Rework waiting for a free bus
> > 
> > This one introduced:
> > 
> > drivers/i2c/algos/i2c-algo-pca.c:197: warning: 'state' is used
> > uninitialized in this function
> > 
> > Probably
> > 
> >         while (pca_status(adap) != 0xf8) {
> > 
> > should become
> > 
> >         while ((state = pca_status(adap)) != 0xf8) {
> > 
> > again.
> 
> You're perfectly right, I must have missed it because I didn't build
> any kernel with CONFIG_I2C_DEBUG_ALGO=y for a long time. Here's the fix
> I will push to Linus soon:
> 
> From: Jean Delvare <khali@...ux-fr.org>
> Subject: i2c-algo-pca: Fix use of uninitialized variable in debug message
> 
> A recent change broke debugging of pca_xfer(), fix it.
> 
> Reported-by: Geert Uytterhoeven <geert@...ux-m68k.org>
> Signed-off-by: Jean Delvare <khali@...ux-fr.org>
> Cc: Wolfram Sang <w.sang@...gutronix.de>

Heh, I was too slow :)

Acked-by: Wolfram Sang <w.sang@...gutronix.de>

> ---
>  drivers/i2c/algos/i2c-algo-pca.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- linux-2.6.30-rc1.orig/drivers/i2c/algos/i2c-algo-pca.c	2009-04-08 08:52:48.000000000 +0200
> +++ linux-2.6.30-rc1/drivers/i2c/algos/i2c-algo-pca.c	2009-04-08 10:06:36.000000000 +0200
> @@ -190,7 +190,7 @@ static int pca_xfer(struct i2c_adapter *
>  	int completed = 1;
>  	unsigned long timeout = jiffies + i2c_adap->timeout;
>  
> -	while (pca_status(adap) != 0xf8) {
> +	while ((state = pca_status(adap)) != 0xf8) {
>  		if (time_before(jiffies, timeout)) {
>  			msleep(10);
>  		} else {
> 
> 
> -- 
> Jean Delvare
> --
> To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

-- 
Pengutronix e.K.                           | Wolfram Sang                |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

Download attachment "signature.asc" of type "application/pgp-signature" (198 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ