From: Tom Rini Date: Tue, 4 Nov 2014 11:45:06 -0500 Subject: [U-Boot] [PATCH 01/11] am335x: make get_board_rev() function weak In-Reply-To: <1415007147-12562-2-git-send-email-grinberg@compulab.co.il> References: <1415007147-12562-1-git-send-email-grinberg@compulab.co.il> <1415007147-12562-2-git-send-email-grinberg@compulab.co.il> Message-ID: <20141104164506.GN15133@bill-the-cat> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Mon, Nov 03, 2014 at 11:32:17AM +0200, Igor Grinberg wrote: > Current get_board_rev() function returns a hard coded value which is > obviously incorrect for the majority of boards. > Allow boards to provide a correct implementation by making this > function weak. > > Signed-off-by: Igor Grinberg > --- > arch/arm/cpu/armv7/am33xx/sys_info.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/arch/arm/cpu/armv7/am33xx/sys_info.c b/arch/arm/cpu/armv7/am33xx/sys_info.c > index 2ce682f..c297fd8 100644 > --- a/arch/arm/cpu/armv7/am33xx/sys_info.c > +++ b/arch/arm/cpu/armv7/am33xx/sys_info.c > @@ -18,6 +18,7 @@ > #include > #include > #include > +#include > > struct ctrl_stat *cstat = (struct ctrl_stat *)CTRL_BASE; > > @@ -53,7 +54,7 @@ u32 get_cpu_type(void) > * get_board_rev() - setup to pass kernel board revision information > * returns:(bit[0-3] sub version, higher bit[7-4] is higher version) > */ > -u32 get_board_rev(void) > +u32 __weak get_board_rev(void) > { > return BOARD_REV_ID; > } Which is a hard-coded 0 anyhow. Can you please update the comment to say something along the lines of "Return 0 for the ATAG REVISION tag value" along with making it weak and nuke BOARD_REV_ID from the header as well? Thanks! -- Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: