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

Re: [PATCH v2 1/5] xen: define ACPI and DT device info sections macros



On Mon, 2024-09-23 at 12:08 +0200, Jan Beulich wrote:
> On 17.09.2024 18:15, Oleksii Kurochko wrote:
> > --- a/xen/include/xen/xen.lds.h
> > +++ b/xen/include/xen/xen.lds.h
> > @@ -114,6 +114,21 @@
> >  
> >  /* List of constructs other than *_SECTIONS in alphabetical order.
> > */
> >  
> > +#define USE_DECL_SECTION(x) DECL_SECTION(x)
> > +
> > +#define NOUSE_DECL_SECTION(x) x :
> > +
> > +#ifdef CONFIG_ACPI
> > +#define ACPI_DEV_INFO_SEC(secname, DECL_SECTION_MACROS_NAME)  \
> > +    DECL_SECTION_MACROS_NAME(secname) {                     \
> > +      _asdevice = .;                                        \
> > +      *(secname)                                            \
> > +      _aedevice = .;                                        \
> > +    } :text
> > +#else
> > +#define ACPI_DEV_INFO_SEC(secname, DECL_SECTION_MACROS_NAME)
> > +#endif /* CONFIG_ACPI */
> > +
> >  #define BUGFRAMES                               \
> >      __start_bug_frames_0 = .;                   \
> >      *(.bug_frames.0)                            \
> > @@ -131,6 +146,17 @@
> >      *(.bug_frames.3)                            \
> >      __stop_bug_frames_3 = .;
> >  
> > +#ifdef CONFIG_HAS_DEVICE_TREE
> > +#define DT_DEV_INFO_SEC(secname, DECL_SECTION_MACROS_NAME)  \
> > +    DECL_SECTION_MACROS_NAME(secname) {                     \
> > +      _sdevice = .;                                         \
> > +      *(secname)                                            \
> > +      _edevice = .;                                         \
> > +    } :text
> > +#else
> > +#define DECL_DT_DEV_INFO_SEC(secname, DECL_SECTION_MACROS_NAME)
> > +#endif /* CONFIG_HAS_DEVICE_TREE */
> 
> Any specific reason for the _SEC suffixes in the names? We don't have
> such elsewhere, as can be seen (by example) ...
> 
> >  #ifdef CONFIG_HYPFS
> >  #define HYPFS_PARAM              \
> >         . = ALIGN(POINTER_ALIGN); \
> 
> ... even in context here.

The _SEC suffixes can be removed; they were only used to highlight that
it was a section declaration. I'll drop it in the next patch version.

~ Oleksii

 


Rackspace

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