From: Charles Manning Date: Wed, 5 Mar 2014 17:36:47 +1300 Subject: [U-Boot] [PATCH v6] socfpga: Add socfpga preloader signing to mkimage In-Reply-To: <201402281143.47592.manningc2@actrix.gen.nz> References: <1393377465-23602-1-git-send-email-cdhmanning@gmail.com> <20140227215721.84F69381344@gemini.denx.de> <201402281143.47592.manningc2@actrix.gen.nz> Message-ID: <201403051736.47665.manningc2@actrix.gen.nz> 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 Further to my last response On Friday 28 February 2014 11:43:47 Charles Manning wrote: > On Friday 28 February 2014 10:57:21 Wolfgang Denk wrote: > > > +static uint32_t get_le32(const uint8_t *buf) > > > +{ > > > + uint32_t retval; > > > + > > > + retval = (((uint32_t) buf[0]) << 0) | > > > + (((uint32_t) buf[1]) << 8) | > > > + (((uint32_t) buf[2]) << 16) | > > > + (((uint32_t) buf[3]) << 24); > > > + return retval; > > > +} > > > > Why do you not use existing code (like get_unaligned_le16(), > > get_unaligned_le32()) ? From what I see these get_aligned_xxx() functions and friends exist in target space, not host land. From my limited understanding of these matters, it is unwise to call these functions here. Are you Ok with that explanation? I will be fixing the other issues you raised one way or another. Best regards Charles