p The arguments are as follows: l -tag -width Fl . t Fl A Po Xo .Li arm Ns \||\| Ns .Li arm64 Ns \||\| Ns .Li i386 Ns \||\| Ns .Li mips Ns \||\| Ns .Li mips64 Ns \||\| Ns .Li or1k Ns \||\| Ns .Li powerpc Ns \||\| Ns .Li riscv Ns \||\| Ns .Li sh .Xc Pc Defines the architecture. This is required for .Ql uimg format images. . t Fl a Ar address Sets the image load address. This is an integer between 0 and .Dv UINT32_MAX . This is required for all .Ql uimg image types except for .Li script , ramdisk , and .Li kernel_noload . . t Fl C Po Xo .Li bz2 Ns \||\| Ns .Li gz Ns \||\| Ns .Li lzma Ns \||\| Ns .Li lzo Ns \||\| Ns .Li none .Xc Pc Defines the compression. The default is .Ql none . . t Fl E Ar address Define the entry point. This is an integer between 0 and .Dv UINT32_MAX . This option is the same as .Fl e but it inverts the bytes to convert the 32 bit integer from little to big endian (or vice versa). If .Fl E or .Fl e are not set, the entry point defaults to the image load address
q Fl a . . t Fl e Ar address Define the entry point. This is an integer between 0 and .Dv UINT32_MAX . If .Fl E or .Fl e are not set, the entry point defaults to the image load address
q Fl a . . t Fl f Po Xo .Li arm64 Ns \||\| Ns .Li uimg .Xc Pc Defines the output image format type. The default is .Ql uimg . . t Fl h Display the usage and exit. . t Fl m Ar magic Set the magic used for .Ql uimg format images. This is an integer between 0 and .Dv UINT32_MAX . The default is .Ql 0x27051956 . . t Fl n Ar name Defines the image name. This is required. . t Fl O Po Xo .Li freebsd Ns \||\| Ns .Li linux Ns \||\| Ns .Li netbsd Ns \||\| Ns .Li openbsd .Xc Pc Defines the operating system type. The default OS name is .Ql netbsd . . t Fl T Po Xo .Li fs Ns \||\| Ns .Li kernel Ns \||\| Ns .Li kernel_noload Ns \||\| Ns .Li ramdisk Ns \||\| Ns .Li script Ns \||\| Ns .Li standalone .Xc Pc Defines the image type. This is required for .Ql uimg format images. . t Fl t Ar epoch Use given epoch timestamp as image creation time.
q This is only used for legacy U-Boot images. . t Fl u Update the header in an existing file instead of creating a new one. . .El
p
The required
.Ar source
argument is the filename of the kernel that is read.
The required
.Ar destination
argument is the filename of the image file that is created.
.Sh EXIT STATUS
.Nm
returns 1 on failure to read the kernel,
generate a header, or create the image.
.Sh EXAMPLES
Before the image is written, the header is displayed to standard out;
for example:
d -literal -offset indent image type: uimg
magic: 0x27051956
time: Tue May 21 18:05:09 2024
size: 137
load addr: 0x00000000
entry point: 0x00000000
data crc: 0xface05f2
os: 2 (netbsd)
arch: 2 (arm)
type: 6 (script)
comp: 0 (none)
name: NetBSD/armv7 boot
header crc: 0x2164b567
.Ed
.Sh FILES
.Sh SEE ALSO
.Rs
.%T Das U-Boot \(en the Universal Boot Loader
.%U http://www.denx.de/wiki/U-Boot/
.Re
.Sh STANDARDS
.Sh HISTORY
The
.Nm
command first appeared in
.Nx 6.0 .
.Sh AUTHORS
.An -nosplit
The
.Nm
utility was originally written by
.An Jared McNeill .
This manual page was written by
.An Jeremy C. Reed .
.Sh CAVEATS
.Sh BUGS
.Sh SECURITY CONSIDERATIONS