[Cbe-oss-dev] [PATCH] spufs: fix restore_decr_wrapped()

Jeremy Kerr jk at ozlabs.org
Tue Aug 28 12:37:52 EST 2007


Christoph,

> This should be:
>
> 	if (csa->spu_chnlcnt_RW[0] == 0 &&
> 	    (csa->spu_chnldata_RW[1] & 0x20) &&
> 	    !(csa->spu_chnldata_RW[0] & 0x20))
> 		csa->spu_chnlcnt_RW[0] = 1;

Hm, I disagree - the 4-space indent makes it difficult to quickly see 
where the body of the if statement begins, especially since (in this 
case) the body looks a lot like the condition.

And from CodingStyle:

 Statements longer than 80 columns will be broken into sensible chunks.
 Descendants are always substantially shorter than the parent and are 
 placed substantially to the right.

I think mine is more 'substantially to the right' than yours :D

However, religious wars over whitespace are best avoided, and if you can 
convince me that the half-indent is better, I'll do it that way :)

Cheers,


Jeremy



More information about the cbe-oss-dev mailing list