[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH v3 25/25] xen/arm: split domain_build.c



On Thu, 16 Aug 2018, Julien Grall wrote:
> Hi Stefano,
> 
> On 08/16/2018 01:25 AM, Stefano Stabellini wrote:
> > On Mon, 13 Aug 2018, Julien Grall wrote:
> > > > +
> > > > +#ifndef CONFIG_ACPI
> > > > +static inline int prepare_acpi(struct domain *d, struct kernel_info
> > > > *kinfo)
> > > > +{
> > > > +    /* Only booting with ACPI will hit here */
> > > > +    BUG();
> > > > +    return -EINVAL;
> > > > +}
> > > > +#else
> > > > +int prepare_acpi(struct domain *d, struct kernel_info *kinfo);
> > > > +#endif
> > > 
> > > This one should go in asm-arm/acpi.h.
> > > 
> > > So this header is not necessary anymore.
> > 
> > I was unable to add prepare_acpi to asm-arm/acpi.h because it causes a
> > #include dependency hell, I am thinking of adding it to
> > asm-arm/domain_build.h.
> > 
> > In file included from
> > /local/repos/xen-upstream/xen/include/xen/sched.h:11:0,
> >                   from /local/repos/xen-upstream/xen/include/asm/domain.h:5,
> >                   from
> > /local/repos/xen-upstream/xen/include/asm/kernel.h:10,
> >                   from /local/repos/xen-upstream/xen/include/asm/acpi.h:27,
> >                   from
> > /local/repos/xen-upstream/xen/include/acpi/platform/aclinux.h:58,
> >                   from
> > /local/repos/xen-upstream/xen/include/acpi/platform/acenv.h:142,
> >                   from /local/repos/xen-upstream/xen/include/acpi/acpi.h:56,
> >                   from /local/repos/xen-upstream/xen/include/xen/acpi.h:33,
> >                   from pl011.c:307:
> > /local/repos/xen-upstream/xen/include/xen/domain.h:59:31: error: ‘struct
> > xen_domctl_createdomain’ declared inside parameter list will not be visible
> > outside of this definition or declaration [-Werror]
> >                          struct xen_domctl_createdomain *config);
> 
> Xen Arm headers are a bit a mess. :/
> 
> It looks like create_dom0 lives in setup.h, would it be possible to move the
> prototypes there?

It doesn't work either :-/

The problem is that the prototype of prepare_acpi needs the definition
of struct kernel_info, which triggers the include mess. Leaving the
prototypes in asm-arm/domain_build.h work though.
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.