iPXE
|
CPIO archives. More...
Go to the source code of this file.
Functions | |
FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
void | cpio_set_field (char *field, unsigned long value) |
Set field within a CPIO header. More... | |
size_t | cpio_name_len (struct image *image) |
Get CPIO image filename. More... | |
static void | cpio_parse_cmdline (struct image *image, struct cpio_header *cpio) |
Parse CPIO image parameters. More... | |
size_t | cpio_header (struct image *image, struct cpio_header *cpio) |
Construct CPIO header for image, if applicable. More... | |
CPIO archives.
Definition in file cpio.c.
FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
void cpio_set_field | ( | char * | field, |
unsigned long | value | ||
) |
Set field within a CPIO header.
field | Field within CPIO header |
value | Value to set |
Definition at line 43 of file cpio.c.
References memcpy(), snprintf(), and value.
Referenced by cpio_header(), and cpio_parse_cmdline().
Get CPIO image filename.
image | Image |
len | CPIO filename length (0 for no filename) |
Definition at line 56 of file cpio.c.
References cpio_name(), len, name, strchr(), and strlen().
Referenced by bzimage_load_initrd(), cpio_header(), and efi_file_read_initrd().
|
static |
Parse CPIO image parameters.
image | Image |
cpio | CPIO header to fill in |
Definition at line 78 of file cpio.c.
References cpio_header::c_mode, cpio_set_field(), DBGC, end, image_argument(), and strtoul().
Referenced by cpio_header().
size_t cpio_header | ( | struct image * | image, |
struct cpio_header * | cpio | ||
) |
Construct CPIO header for image, if applicable.
image | Image |
cpio | CPIO header to fill in |
len | Length of magic CPIO header (including filename) |
Definition at line 102 of file cpio.c.
References cpio_header::c_filesize, cpio_header::c_magic, cpio_header::c_mode, cpio_header::c_namesize, cpio_header::c_nlink, CPIO_ALIGN, CPIO_MAGIC, cpio_name_len(), cpio_parse_cmdline(), cpio_set_field(), len, image::len, memcpy(), and memset().
Referenced by bzimage_load_initrd(), and efi_file_read_initrd().