|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v4 04/11] xen: introduce domain-layout.h with common domain_use_host_layout()
On 5/7/26 9:25 AM, Jan Beulich wrote: On 06.05.2026 17:47, Oleksii Kurochko wrote:On 5/4/26 2:59 PM, Jan Beulich wrote:On 28.04.2026 16:33, Oleksii Kurochko wrote:--- /dev/null +++ b/xen/include/xen/domain-layout.h @@ -0,0 +1,27 @@ +#ifndef __XEN_DOMAIN_LAYOUT_H__ +#define __XEN_DOMAIN_LAYOUT_H__ + +#include <xen/domain.h>This isn't really needed. It is ...+#include <xen/paging.h> +#include <xen/sched.h>... included by this one anyway (pretty much unavoidably right now, I guess).Then it will be needed to re-order them. Do you want to put the comment above xen/sched.h: /* * Ensure xen/sched.h is included before xen/paging.h, since paging.h depends * on xen/domain.h, which is pulled in via sched.h. */ #include <xen/sched.h> #include <xen/paging.h> or just add this to commit message instead?No. xen/paging.h only includes two asm/*.h, so doesn't itself require anything. If there's anything missing for that header to be included first, I would assume it's then RISC-V's asm/paging.h or asm/p2m.h which lack a necessary #include? Yet without you indicating what exactly the missing piece is, this is somewhat guesswork on my part. The first time I read compiler error inattentively.The following compilation error occurs after xen/domain.h is dropped from xen/domain-layout.h:
In file included from ./include/xen/paging.h:4,
from ./include/xen/domain-layout.h:6,
from common/device-tree/domain-build.c:4:
./arch/riscv/include/asm/paging.h:17:48: error: 'struct page_info'
declared inside parameter list will not be visible outside of this
definition or declaration [-Werror]
17 | void paging_free_page(struct domain *d, struct page_info *pg);So the correct fix is to add forward declaration of struct page_info to RISC-V's asm/paging.h.
I will add the following to commit message:
"
To avoid the following compilation issue:
In file included from ./include/xen/paging.h:4,
from ./include/xen/domain-layout.h:6,
from common/device-tree/domain-build.c:4:
./arch/riscv/include/asm/paging.h:17:48: error: 'struct page_info'
declared inside parameter list will not be visible outside of this
definition or declaration [-Werror]
17 | void paging_free_page(struct domain *d, struct page_info *pg); add the forward declaration of struct page_info to RISC-V's asm/paging.h. " ~ Oleksii
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |