[PATCH v2 1/2] arm/build: Warn on orphan section placement
keescook at chromium.org
Wed Jun 24 15:43:41 EDT 2020
On Tue, Jun 23, 2020 at 05:03:46PM -0700, Nick Desaulniers wrote:
> On Mon, Jun 22, 2020 at 1:49 PM Kees Cook <keescook at chromium.org> wrote:
> > [...]
> > @@ -37,6 +38,13 @@
> > *(.idmap.text) \
> > __idmap_text_end = .; \
> > +#define ARM_COMMON_DISCARD \
> > + *(.ARM.attributes) \
> I could have sworn that someone (Eli?) once told me that this section
> (.ARM.attributes) is used for disambiguating which ARM version or
> which optional extensions were used when compiling, and that without
> this section, one would not be able to disassemble 32b ARM precisely.
> If that's the case, we might not want to discard it?
Perhaps we want to treat it like .comment and include it in the ELF?
> > +#define ARM_STUBS_TEXT \
> > + *(.gnu.warning) \
> > + *(.glue_7t) \
> > + *(.glue_7) \
> This changes the order of .glue_7t relative to .glue_7. Maybe that
> doesn't matter.
Good point. I'll swap it just for consistency.
More information about the linux-arm-kernel