[U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Sanjeev Premi
This patch does following changes: * Change the type (u8 - int) for omap3_evm_version. * Introduce an 'undefined' board revision for init value. * Use of #define instead of magic numbers Signed-off-by: Sanjeev Premi pr...@ti.com --- board/ti/evm/evm.c | 39

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Wolfgang Denk
Dear Sanjeev Premi, In message 1291288812-12653-1-git-send-email-pr...@ti.com you wrote: This patch does following changes: * Change the type (u8 - int) for omap3_evm_version. * Introduce an 'undefined' board revision for init value. * Use of #define instead of magic numbers

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Albert ARIBAUD
Le 02/12/2010 12:37, Wolfgang Denk a écrit : Dear Sanjeev Premi, In message1291288812-12653-1-git-send-email-pr...@ti.com you wrote: This patch does following changes: * Change the type (u8 - int) for omap3_evm_version. * Introduce an 'undefined' board revision for init value.

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message 4cf7896b.5090...@free.fr you wrote: Note that initialization should be unnecessary if the static variable is int rather than u8. It should ALWAYS be not necessary. Otherwise we have a bug, and that bug needs to be fixed rather than papered over. Best

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Albert ARIBAUD
Le 02/12/2010 13:01, Wolfgang Denk a écrit : Dear Albert ARIBAUD, In message4cf7896b.5090...@free.fr you wrote: Note that initialization should be unnecessary if the static variable is int rather than u8. It should ALWAYS be not necessary. I understand your point re: the linker warning,

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Premi, Sanjeev
-Original Message- From: Wolfgang Denk [mailto:w...@denx.de] Sent: Thursday, December 02, 2010 5:07 PM To: Premi, Sanjeev Cc: u-boot@lists.denx.de Subject: Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code. Dear Sanjeev Premi, In message 1291288812-12653-1-git-send

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message 4cf7922b.3020...@free.fr you wrote: Now, on an unrelated note, omap3_emv's code arbitrarily uses an u8 where an int (or enum) would be more appropriate, and this should be changed not because it removes a linker warning, but because the u8 choice is

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Albert ARIBAUD
Le 02/12/2010 14:58, Wolfgang Denk a écrit : Dear Albert ARIBAUD, In message4cf7922b.3020...@free.fr you wrote: Now, on an unrelated note, omap3_emv's code arbitrarily uses an u8 where an int (or enum) would be more appropriate, and this should be changed not because it removes a linker

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Wolfgang Denk
Dear Albert ARIBAUD, In message 4cf7c7f4.6030...@free.fr you wrote: Well, an u8 is as good a data type as any other. The available range of 0...255 seems more than sufficient to store the needed information, so why should I waste 4 bytes of storage when a single byte is sufficient as

Re: [U-Boot] [PATCH] omap3evm: Clean-up EVM detection code.

2010-12-02 Thread Albert ARIBAUD
Le 02/12/2010 19:51, Wolfgang Denk a écrit : Dear Albert ARIBAUD, In message4cf7c7f4.6030...@free.fr you wrote: Well, an u8 is as good a data type as any other. The available range of 0...255 seems more than sufficient to store the needed information, so why should I waste 4 bytes of