18#define EMBED( _index, _path, _name ) \
19 extern char embedded_image_ ## _index ## _data[]; \
20 extern size_t ABS_SYMBOL ( embedded_image_ ## _index ## _len ); \
21 __asm__ ( ".section \".data\", \"aw\", " PROGBITS "\n\t" \
22 "\nembedded_image_" #_index "_data:\n\t" \
23 ".incbin \"" _path "\"\n\t" \
24 "\nembedded_image_" #_index "_end:\n\t" \
25 ".equ embedded_image_" #_index "_len, " \
26 "( embedded_image_" #_index "_end - " \
27 " embedded_image_" #_index "_data )\n\t" \
33#define EMBED( _index, _path, _name ) { \
34 .refcnt = REF_INIT ( free_image ), \
36 .flags = ( IMAGE_STATIC | IMAGE_STATIC_NAME ), \
37 .rwdata = embedded_image_ ## _index ## _data, \
38 .len = ABS_VALUE_INIT ( embedded_image_ ## _index ## _len ), \
61 DBG (
"Embedded image \"%s\": %zd bytes at %p\n",
64 DBG (
"Could not register embedded image \"%s\": "
73 DBG (
"Could not select embedded image \"%s\": %s\n",
struct arbelprm_rc_send_wqe rc
static struct image embedded_images[]
static void embedded_init(void)
Register all embedded images.
uint8_t data[48]
Additional event data.
#define DBG(...)
Print a debugging message.
#define INIT_LATE
Late initialisation.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
int register_image(struct image *image)
Register executable image.
int image_select(struct image *image)
Select image for execution.
static void image_trust(struct image *image)
Set image as trusted.
#define __init_fn(init_order)
Declare an initialisation functon.
char * strerror(int errno)
Retrieve string representation of error number.
size_t len
Length of raw file image.
An initialisation function.