[PATCH 1/4 V2] powerpc/85xx: Add support for 85xx cpu type detection

Zhang Haijun-B42677 B42677 at freescale.com
Thu Jul 11 19:02:10 EST 2013



Thanks.

Regards
Haijun.


> -----Original Message-----
> From: David Laight [mailto:David.Laight at ACULAB.COM]
> Sent: Thursday, July 11, 2013 4:44 PM
> To: Wood Scott-B07421; Zhang Haijun-B42677
> Cc: Zhao Chenhui-B35336; linux-mmc at vger.kernel.org; Wrobel Heinz-R39252;
> Fleming Andy-AFLEMING; Zhang Haijun-B42677; cbouatmailru at gmail.com;
> cjb at laptop.org; linuxppc-dev at lists.ozlabs.org; Xie Xiaobo-R63061
> Subject: RE: [PATCH 1/4 V2] powerpc/85xx: Add support for 85xx cpu type
> detection
> 
> > > +#define IS_SVR_REV(svr, maj, min) \
> > > +	((SVR_MAJ(svr) == (maj)) && (SVR_MIN(svr) == (min)))
> >
> > I don't think IS_SVR_REV is needed.  Callers can just do "if
> > (SVR_REV(svr) == 0x30)" or whatever, especially since we're relying on
> > them to do this for greater/less than comparisons.
> 
> Not only that, I'd guess that 'maj' and 'min' are likely to be constants
> - so you'd want to combine them and compare against 'svr'
> rather than have two conditionals.
[Haijun Wrote:] yes, e.g: 1.0, 1.1 or 2.0. 'Major revision field' + '.' + 'Minor revision field '
I had resent the patch(V2). I'm not so clear about what you want to express.^_^  
> 
> 	David
> 
> 
> 




More information about the Linuxppc-dev mailing list