Re: [PATCH 2/6] vmlinux.lds.h: drop unused HEADERED_SECTION* macros

From: jim . cromie

Date: Mon Nov 23 2026 - 13:12:43 EST


On Sun, Nov 22, 2026 at 4:55 AM David Laight
<david.laight.linux@xxxxxxxxx> wrote:
>
> On Sat, 21 Nov 2026 15:49:20 -0700
> Jim Cromie via B4 Relay <devnull+jim.cromie.gmail.com@xxxxxxxxxx> wrote:
>
> > From: Jim Cromie <jim.cromie@xxxxxxxxx>
> >
> > These macros are unused, no point in carrying them any more.
> >
> > NB: these macros were just moved to bounded_sections.lds.h, from
> > vmlinux.lds.h, which is the known entity, and therefore more
> > meaningful in the 1-line summary, so thats what I used as the topic.
>
> Maybe remove them first?
>

yea, I'll do that.
thanks

> David
>
> >
> > Signed-off-by: Jim Cromie <jim.cromie@xxxxxxxxx>
> > ---
> > include/asm-generic/bounded_sections.lds.h | 15 ---------------
> > 1 file changed, 15 deletions(-)
> >
> > diff --git a/include/asm-generic/bounded_sections.lds.h b/include/asm-generic/bounded_sections.lds.h
> > index 8c29293ca7fb..268cdc34389b 100644
> > --- a/include/asm-generic/bounded_sections.lds.h
> > +++ b/include/asm-generic/bounded_sections.lds.h
> > @@ -18,19 +18,4 @@
> >
> > #define BOUNDED_SECTION(_sec) BOUNDED_SECTION_BY(_sec, _sec)
> >
> > -#define HEADERED_SECTION_PRE_LABEL(_sec_, _label_, _BEGIN_, _END_, _HDR_) \
> > - _HDR_##_label_ = .; \
> > - KEEP(*(.gnu.linkonce.##_sec_)) \
> > - BOUNDED_SECTION_PRE_LABEL(_sec_, _label_, _BEGIN_, _END_)
> > -
> > -#define HEADERED_SECTION_POST_LABEL(_sec_, _label_, _BEGIN_, _END_, _HDR_) \
> > - _label_##_HDR_ = .; \
> > - KEEP(*(.gnu.linkonce.##_sec_)) \
> > - BOUNDED_SECTION_POST_LABEL(_sec_, _label_, _BEGIN_, _END_)
> > -
> > -#define HEADERED_SECTION_BY(_sec_, _label_) \
> > - HEADERED_SECTION_PRE_LABEL(_sec_, _label_, __start, __stop)
> > -
> > -#define HEADERED_SECTION(_sec) HEADERED_SECTION_BY(_sec, _sec)
> > -
> > #endif /* _ASM_GENERIC_BOUNDED_SECTIONS_H */
> >
>