From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mike Frysinger Date: Mon, 9 Jan 2012 12:33:42 -0500 Subject: [U-Boot] [RFC PATCH v2 13/15] bootstage: Add microsecond boot time measurement In-Reply-To: References: <1323551287-5351-1-git-send-email-sjg@chromium.org> <201201080335.31904.vapier@gentoo.org> Message-ID: <201201091233.43471.vapier@gentoo.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Sunday 08 January 2012 12:42:02 Simon Glass wrote: > On Sun, Jan 8, 2012 at 12:35 AM, Mike Frysinger wrote: > > On Saturday 10 December 2011 16:08:05 Simon Glass wrote: > >> --- a/include/bootstage.h > >> +++ b/include/bootstage.h > >> > >> +static inline ulong bootstage_mark(enum bootstage_id id) > >> { > >> - show_boot_progress(-val); > >> +#ifdef CONFIG_SHOW_BOOT_PROGRESS > >> + show_boot_progress(id); > >> +#endif > >> + return 0; > >> } > >> > >> +static inline ulong bootstage_error(enum bootstage_id id) > >> +{ > >> +#ifdef CONFIG_SHOW_BOOT_PROGRESS > >> + show_boot_progress(-id); > >> +#endif > >> + return 0; > >> +} > > > > why isn't show_boot_progress() just a stub when CONFIG_SHOW_BOOT_PROGRESS > > isn't defined ? then you don't have to protect the call sites. > > show_boot_progress() has been part of U-Boot for a while. Quite a lot > of boards define this function with the expectation that they can turn > CONFIG_SHOW_BOOT_PROGRESS on and off independently. So If I do what > you suggest I will break that expectation. > > One fix would be to bracket all show_boot_progress() function > implementations in the boards with CONFIG_SHOW_BOOT_PROGRESS, but I > haven't done that. it seemed like part of your clean up series was to merge show_boot_progress() into your new bootstage framework. in which case, we have full control over it now, and ifdef bracketing for it should go away ... -mike -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part. URL: