Update initrd structures to match the updates to the Unikraft core.
Use `pbase` instead of `base`, and pass a `struct ukplat_memregion desc **`
to the `find_initrd` function.
Signed-off-by: Stefan Jumarea <stefanjumarea02@gmail.com>
Reviewed-by: Razvan Deaconescu <razvand@unikraft.io>
Approved-by: Razvan Deaconescu <razvand@unikraft.io>
Tested-by: Unikraft CI <monkey@unikraft.io>
GitHub-Closes: #7
get_config()
{
String *cfg = new String(macaddr_preamble);
- struct ukplat_memregion_desc img;
+ struct ukplat_memregion_desc *img;
char *cstr;
size_t cstr_len;
/* First, try initrd */
if (ukplat_memregion_find_initrd0(&img) >= 0) {
- cstr = (char *)img.base;
- cstr_len = img.len;
+ cstr = (char *)img->pbase;
+ cstr_len = img->len;
} else {
/* If we can't find a config: use a fallback one statically
* compiled in.