On Fri, Jun 14, 2013 at 06:36:06PM +0100, Peter Maydell wrote: > On 14 June 2013 18:14, Sören Brinkmann <soren.brinkm...@xilinx.com> wrote: > > On Fri, Jun 14, 2013 at 05:56:31PM +0100, Peter Maydell wrote: > >> If we're providing separate functions for kernel and > >> ramdisk loading shouldn't they check that the uimage > >> has the appropriate type? > > I'm not sure I understand what you mean here. Moving the check for the > > appropriate u-boot header type down here? I tried to find some > > reasonable way to further split the load_uboot_image() routine to move > > some of it's functionality into the two functions down here. But it all > > seemed pretty messy and I left pretty much all functionality in > > load_uboot_image() and just pass errors through. > > I had in mind that these functions should pass the "expected" > type byte in to the load_uboot_image() function so it can > fail if the blob it is passed isn't actually the right type > (eg you pass the kernel to -initrd and vice-versa). Thanks for the clarification. I agree. I'll add such a check.
Sören