[U-Boot] iminfo and zImages

Is it just not possible for the zImages in RAM to be decoded as per the uImages ?
If I simply use mkimage to convert the image back as a uImage ( essentially take off the first 64 bytes ? ) then iminfo will display the kernel info
The uImage file is only 64 bytes smaller so hasn't fundamentally been uncompressed but also offsetting the iminfo by the 64 bytes makes no odds either
Did I miss the point somewhere?!
=> tftp 82000000 uImage
done
Bytes transferred = 7954944 (796200 hex)
=> iminfo
## Checking Image at 82000000 ...
Legacy image found
Image Name: Linux kernel
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 7954880 Bytes = 7.6 MiB
Load Address: 82000000
Entry Point: 82000000
Verifying Checksum ... OK
=> tftp 82000000 zImage
done
Bytes transferred = 7954880 (7961c0 hex)
## Checking Image at 82000000 ...
Unknown image format!
=> iminfo 82000040
## Checking Image at 82000040 ...
Unknown image format!
=>

On Mon, Mar 12, 2018 at 02:03:54PM +0000, Andy Rea wrote:
Is it just not possible for the zImages in RAM to be decoded as per the uImages ?
Well, in short, "patches welcome". Part of the problem is that the Linux Kernel ARM zImage doesn't contain a ton of info. That's less true of say the aarch64 Image format. And both of these are architecture specific. If you can come up with a patch that does something useful for iminfo for zImage, I don't see a problem in theory with that. Thanks!

Dear Andy,
In message MM1P123MB126008DA9E9DF7F8F08BB81EB2D30@MM1P123MB1260.GBRP123.PROD.OUTLOOK.COM you wrote:
Is it just not possible for the zImages in RAM to be decoded as per the uImages ?
You can decode only the information that is in there. uImage adds an extra 64 byte header with informnation I considered useful to have, like names, timestamp, checksum.
If I simply use mkimage to convert the image back as a uImage ( essentially take off the first 64 bytes ? ) then iminfo will display the kernel info
You confuse things here. mkimage _adds_ a 64 byte header to create the uImage file from zImage (or similar). iminfo displays this uImage header. Similar when using FIT images.
The uImage file is only 64 bytes smaller so hasn't fundamentally been uncompressed but also offsetting the iminfo by the 64 bytes makes no odds either
Wrong, uImage has 64 bytes header _added_ - and all this has nothing to do with compression at all.
Best regards,
Wolfgang Denk
participants (3)
-
Andy Rea
-
Tom Rini
-
Wolfgang Denk