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, 6 Aug 2012 18:17:28 +0200
From:	Jean Delvare <khali@...ux-fr.org>
To:	Randy Dunlap <rdunlap@...otime.net>
Cc:	Stephen Rothwell <sfr@...b.auug.org.au>,
	linux-next@...r.kernel.org, LKML <linux-kernel@...r.kernel.org>,
	linux-i2c@...r.kernel.org
Subject: Re: [PATCH] i2c: fix i2c-i801.c printk format warning

Hi Randy,

On Mon, 06 Aug 2012 09:10:47 -0700, Randy Dunlap wrote:
> From: Randy Dunlap <rdunlap@...otime.net>
> 
> Fix printk format warning.  ARRAY_SIZE() uses sizeof(),
> which is size_t, so use %zu to print it.
> 
> drivers/i2c/busses/i2c-i801.c: In function 'i801_add_mux':
> drivers/i2c/busses/i2c-i801.c:1043:4: warning: format '%lu' expects type 'long unsigned int', but argument 3 has type 'unsigned int'
> 
> Signed-off-by: Randy Dunlap <rdunlap@...otime.net>
> Cc: Mark D. Studebaker <mdsxyz123@...oo.com>
> Cc: Jean Delvare <khali@...ux-fr.org>
> ---
>  drivers/i2c/busses/i2c-i801.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- linux-next-20120806.orig/drivers/i2c/busses/i2c-i801.c
> +++ linux-next-20120806/drivers/i2c/busses/i2c-i801.c
> @@ -1039,7 +1039,7 @@ static int __devinit i801_add_mux(struct
>  
>  	/* Find absolute GPIO pin numbers */
>  	if (ARRAY_SIZE(priv->mux_priv) < mux_config->n_gpios) {
> -		dev_err(dev, "i801_priv.mux_priv too small (%lu, need %d)\n",
> +		dev_err(dev, "i801_priv.mux_priv too small (%zu, need %d)\n",
>  			ARRAY_SIZE(priv->mux_priv), mux_config->n_gpios);
>  		return -ENODEV;
>  	}

Good catch once again, thanks a lot. As the offending patch is still
not upstream, I've folded your fix into it.

-- 
Jean Delvare
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ