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: <4FC7DA93.1080905@pengutronix.de>
Date:	Thu, 31 May 2012 22:54:43 +0200
From:	Marc Kleine-Budde <mkl@...gutronix.de>
To:	Joe Perches <joe@...ches.com>
CC:	linux-kernel@...r.kernel.org,
	Wolfgang Grandegger <wg@...ndegger.com>,
	linux-can@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH 2/4] can: cc770: Fix likely misuse of | for &

On 05/30/2012 10:25 PM, Joe Perches wrote:
> Using | with a constant is always true.
> Likely this should have be &.
> 
> Signed-off-by: Joe Perches <joe@...ches.com>

Sounds reasonable. And there are no in tree users of the platform driver
that this fix could break.

commited to linux-can,
Marc

> ---
>  drivers/net/can/cc770/cc770_platform.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/net/can/cc770/cc770_platform.c b/drivers/net/can/cc770/cc770_platform.c
> index 53115ee..688371c 100644
> --- a/drivers/net/can/cc770/cc770_platform.c
> +++ b/drivers/net/can/cc770/cc770_platform.c
> @@ -154,7 +154,7 @@ static int __devinit cc770_get_platform_data(struct platform_device *pdev,
>  	struct cc770_platform_data *pdata = pdev->dev.platform_data;
>  
>  	priv->can.clock.freq = pdata->osc_freq;
> -	if (priv->cpu_interface | CPUIF_DSC)
> +	if (priv->cpu_interface & CPUIF_DSC)
>  		priv->can.clock.freq /= 2;
>  	priv->clkout = pdata->cor;
>  	priv->bus_config = pdata->bcr;


-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |


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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ