From: Wolfgang Denk Date: Sun, 09 Oct 2011 22:27:25 +0200 Subject: [U-Boot] [PATCH V3] cmd_time: add time command In-Reply-To: <1317980448-25774-1-git-send-email-clchiou@chromium.org> References: <1317798555-2720-1-git-send-email-clchiou@chromium.org> <1317980448-25774-1-git-send-email-clchiou@chromium.org> Message-ID: <20111009202725.70F311408753@gemini.denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Dear Che-Liang Chiou, In message <1317980448-25774-1-git-send-email-clchiou@chromium.org> you wrote: > The 'time' command runs and reports execution time of commands. > > Sample usage: > -------------------- > u-boot# time crc 0x1000 1000 > CRC32 for 00001000 ... 00001fff ==> ae94dc4b > > time: 0.004 seconds, 4 ticks > -------------------- > > Signed-off-by: Che-Liang Chiou > --- > > Changes since V2 > - Remove CONFIG_CMD_TIME from config_cmd_all.h > > Changes Since V1 > - Switch unsigned long int to ulong to match function prototype > - Remove unnecessary 'ifdef CONFIG_SYS_HZ' guard > - Factor out codes into the run_command_and_time_it() function > > README | 1 + > common/Makefile | 1 + > common/cmd_time.c | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++ > 3 files changed, 92 insertions(+), 0 deletions(-) > create mode 100644 common/cmd_time.c Applied, thanks. Best regards, Wolfgang Denk -- DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de War is never imperative. -- McCoy, "Balance of Terror", stardate 1709.2