From: Wolfgang Denk Date: Sat, 12 Jan 2008 02:04:44 +0100 Subject: [U-Boot-Users] [PATCH 02/13] [new uImage] Define a API for image handling operations In-Reply-To: Your message of "Fri, 11 Jan 2008 15:28:25 +0100." <20080111142800.8025.66590.stgit@hekate.izotz.org> Message-ID: <20080112010444.3109E24656@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 In message <20080111142800.8025.66590.stgit@hekate.izotz.org> you wrote: > - Add inline helper macros for basic header processing > - Move common non inline code common/image.c > - Replace direct header access with the API routines > - Rename IH_CPU_* to IH_ARCH_* Please review your patches and make sure to keep the original for- matting of the U-Boot output; for example: --- a/common/cmd_bootm.c +++ b/common/cmd_bootm.c ... - if (crc32 (0, (uchar *)data, len) != ntohl(hdr->ih_dcrc)) { - puts (" Bad Data CRC\n"); - } - puts ("OK\n"); + if (!image_check_dcrc(hdr)) + puts ("Bad Data CRC\n"); This is IMO a change to the worse. Please fix. --- a/include/image.h +++ b/include/image.h ... +char *strncpy(char *dest, const char *src, size_t count); Please don't do this! Include the appropriate header file instead. +static inline int image_check_target_arch(image_header_t *hdr) Theoretical thought: could it ever happen that we might have a multi-architecture image? 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 Q: What is "SMOORPLAY"? A: It's what SMURFS do before they SMUCK, of course!