lkml.org 
[lkml]   [2013]   [Jan]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] 3c574_cs: fix operator precedence between << and &
From
From: Nickolai Zeldovich <nickolai@csail.mit.edu>
Date: Thu, 17 Jan 2013 12:18:29 -0500

> The code to print the FIFO size in tc574_config computes it as:
>
> 8 << config & Ram_size
>
> which evaluates the '<<' first, but the actual intent is to evaluate the
> '&' first. Add parentheses to enforce desired evaluation order.
>
> Signed-off-by: Nickolai Zeldovich <nickolai@csail.mit.edu>

Applied.


\
 
 \ /
  Last update: 2013-01-17 21:44    [W:0.042 / U:0.844 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site