Re: [RFC 1/6] vdso/extable: fix calculation of base
From: Sean Christopherson
Date: Fri Feb 26 2021 - 12:48:35 EST
On Fri, Feb 26, 2021, Nadav Amit wrote:
>
> > On Feb 25, 2021, at 1:16 PM, Sean Christopherson <seanjc@xxxxxxxxxx> wrote:
> > It's been literally years since I wrote this code, but I distinctly remember the
> > addresses being relative to the base. I also remember testing multiple entries,
> > but again, that was a long time ago.
> >
> > Assuming things have changed, or I was flat out wrong, the comment above the
> > macro magic should also be updated.
> >
> > /*
> > * Inject exception fixup for vDSO code. Unlike normal exception fixup,
> > * vDSO uses a dedicated handler the addresses are relative to the overall
> > * exception table, not each individual entry.
> > */
>
> I will update the comment. I am not very familiar with pushsection stuff,
> but the offsets were wrong.
>
> Since you say you checked it, I wonder whether it can somehow be caused
> by having exception table entries defined from multiple object files.
Oooh, I think that would do it. Have you checked what happens if there are
multiple object files and multiple fixups within an object file?
> Anyhow, this change follows the kernel’s (not vDSO) exception table
> scheme.