From: Stefan Jumarea Date: Fri, 8 Sep 2023 12:30:16 +0000 (+0300) Subject: click.cc: Update initrd structure members X-Git-Tag: RELEASE-0.15.0~6 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=e44da333806a6ef44c827eaeafe6b6392cd0c96f;p=unikraft%2Flibs%2Fclick.git click.cc: Update initrd structure members 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 Reviewed-by: Razvan Deaconescu Approved-by: Razvan Deaconescu Tested-by: Unikraft CI GitHub-Closes: #7 --- diff --git a/click.cc b/click.cc index e84d205..c2b7478 100644 --- a/click.cc +++ b/click.cc @@ -152,7 +152,7 @@ static String * get_config() { String *cfg = new String(macaddr_preamble); - struct ukplat_memregion_desc img; + struct ukplat_memregion_desc *img; char *cstr; size_t cstr_len; @@ -160,8 +160,8 @@ get_config() /* 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.