From: Masahiro Yamada Date: Tue, 19 Nov 2013 16:50:27 +0900 Subject: [U-Boot] [PATCH] cmd_test: fix a compile error on Blackfin In-Reply-To: <20131119070144.70D40380481@gemini.denx.de> References: <1384830117-25345-1-git-send-email-yamada.m@jp.panasonic.com> <20131119070144.70D40380481@gemini.denx.de> Message-ID: <20131119165027.30BC.AA925319@jp.panasonic.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Hello Wolfgang > In message <1384830117-25345-1-git-send-email-yamada.m@jp.panasonic.com> you wrote: > > Before this commit, common/cmd_test.c defined > > _STDBOOL_H in order to avoid including . > > But this work-around is not a good idea. > > Actually it is a good idea, as it attempts to be independent of the > actual implementation of the bool data types - it does the same no > matter if "true" and "flase" are members or a union or #define'd > constants. If you think so, the following also depends on the impilementation of , doesn't it? #define _STDBOOL_H #include #include For example, if used _STDBOOL_H_ or __STDBOOL_H instead of _STDBOOL_H, would be included and common/cmd_test.c would not be compiled correctly. > I don't like this. I feel we should not change global files (that > build fine for everyone else) to work around problems in one specific > implementation. Instead, we should fix the problem at the root cause, > for example like that. Could you please test if this patch fixes the > problem, too? > > > From f68e524dd72c9cc08e86b479b82eff59ef6d591b Mon Sep 17 00:00:00 2001 > From: Wolfgang Denk > Date: Tue, 19 Nov 2013 07:50:46 +0100 > Subject: [PATCH] Blackfin: don't use 'bool' when it causes problems [snipped] > @@ -51,7 +51,7 @@ extern u_long get_dclk(void); > > # define bfin_revid() (bfin_read_CHIPID() >> 28) > > -extern bool bfin_os_log_check(void); > +extern int bfin_os_log_check(void); > extern void bfin_os_log_dump(void); > > extern void blackfin_icache_flush_range(const void *, const void *); Yes. Your patch fixed the build error. Best Regards Masahiro Yamada