Re: [patch V181 35/54] x86/entry: Align entry text section to PMD boundary

From: Thomas Gleixner
Date: Fri May 18 2018 - 05:42:33 EST


On Thu, 17 May 2018, Josh Poimboeuf wrote:

> On Wed, Dec 20, 2017 at 10:35:38PM +0100, Thomas Gleixner wrote:
> > From: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
> >
> > The (irq)entry text must be visible in the user space page tables. To allow
> > simple PMD based sharing, make the entry text PMD aligned.
> >
> > Signed-off-by: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
> > Signed-off-by: Ingo Molnar <mingo@xxxxxxxxxx>
>
> With my config, this patch adds 2.5M (+~25%) to the kernel text size.
> Is there a more granular way to achieve this?

We could make it PTE granular with some effort, but that would make the
whole PTI handling more complex. So not sure, if that's worth it.

Thanks,

tglx