Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-05 Thread Borislav Petkov
On Mon, Jan 04, 2016 at 03:25:58PM -0800, Andy Lutomirski wrote: > On Mon, Jan 4, 2016 at 3:02 PM, Borislav Petkov wrote: > > On Mon, Jan 04, 2016 at 02:29:09PM -0800, Andy Lutomirski wrote: > >> Josh will argue with you if he sees that :) > > > > Except Josh doesn't need allyesconfigs. tinyconfig

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Andy Lutomirski
On Mon, Jan 4, 2016 at 3:02 PM, Borislav Petkov wrote: > On Mon, Jan 04, 2016 at 02:29:09PM -0800, Andy Lutomirski wrote: >> Josh will argue with you if he sees that :) > > Except Josh doesn't need allyesconfigs. tinyconfig's __ex_table is 2K. If we do the make-it-bigger approach, we get a really

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Tony Luck
On Mon, Jan 4, 2016 at 10:08 AM, Andy Lutomirski wrote: > On Mon, Jan 4, 2016 at 9:26 AM, Tony Luck wrote: >> On Mon, Jan 4, 2016 at 4:07 AM, Borislav Petkov wrote: >>> Why not simply: >>> >>> .long (to) - . + (bias) ; >>> >>> and >>> >>> " .long (" #to ") - . + "(" #bias ") "\n

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Borislav Petkov
On Tue, Jan 05, 2016 at 12:02:46AM +0100, Borislav Petkov wrote: > Except Josh doesn't need allyesconfigs. tinyconfig's __ex_table is 2K. Besides I just saved him 1.5K: https://lkml.kernel.org/r/1449481182-27541-1-git-send-email...@alien8.de :-) -- Regards/Gruss, Boris. ECO tip #101: Trim

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Borislav Petkov
On Mon, Jan 04, 2016 at 02:29:09PM -0800, Andy Lutomirski wrote: > Josh will argue with you if he sees that :) Except Josh doesn't need allyesconfigs. tinyconfig's __ex_table is 2K. > We could maybe come up with a way to compress the table and get that > space and more back, but maybe that should

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Andy Lutomirski
On Mon, Jan 4, 2016 at 1:02 PM, Borislav Petkov wrote: > On Mon, Jan 04, 2016 at 10:08:43AM -0800, Andy Lutomirski wrote: >> All of that's correct, including the part where it's confusing. The >> comments aren't the best. >> >> How about adding a comment like: >> >> - begin comment - >> >

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Borislav Petkov
On Mon, Jan 04, 2016 at 10:08:43AM -0800, Andy Lutomirski wrote: > All of that's correct, including the part where it's confusing. The > comments aren't the best. > > How about adding a comment like: > > - begin comment - > > The offset to the fixup is signed, and we're trying to use th

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Andy Lutomirski
On Mon, Jan 4, 2016 at 10:59 AM, Tony Luck wrote: >> - begin comment - >> >> The offset to the fixup is signed, and we're trying to use the high >> bits for a different purpose. In C, we could just do: >> >> u32 class_and_offset = ((target - here) & 0x3fff) | class; >> >> Then, to dec

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Tony Luck
> - begin comment - > > The offset to the fixup is signed, and we're trying to use the high > bits for a different purpose. In C, we could just do: > > u32 class_and_offset = ((target - here) & 0x3fff) | class; > > Then, to decode it, we'd mask off the class and sign-extend to recover

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Andy Lutomirski
On Mon, Jan 4, 2016 at 9:26 AM, Tony Luck wrote: > On Mon, Jan 4, 2016 at 4:07 AM, Borislav Petkov wrote: >>> + * (target - here) + (class) + 0x2000 >> >> I still don't understand that bit 29 thing. >> >> Because the offset is negative? > > I think so. The .fixup section is placed in the end

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Tony Luck
On Mon, Jan 4, 2016 at 4:07 AM, Borislav Petkov wrote: >> + * (target - here) + (class) + 0x2000 > > I still don't understand that bit 29 thing. > > Because the offset is negative? I think so. The .fixup section is placed in the end of .text, and the ex_table itself is pretty much right afte

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-04 Thread Borislav Petkov
On Wed, Dec 30, 2015 at 09:59:29AM -0800, Andy Lutomirski wrote: > This adds two bits of fixup class information to a fixup entry, > generalizing the uaccess_err hack currently in place. > > Forward-ported-from-3.9-by: Tony Luck > Signed-off-by: Andy Lutomirski > --- > arch/x86/include/asm/asm.

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-03 Thread Ingo Molnar
> Big OOPs ... this is "From:" me ... not Andy! But in any case it's missing your SOB line. If Andy is still the primary author (much of his original patch survived, you resolved conflicts or minor changes) then you can send this as: From: Tony Luck Subject: [PATCH v

Re: [PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-03 Thread Tony Luck
On Wed, Dec 30, 2015 at 9:59 AM, Andy Lutomirski wrote: > This adds two bits of fixup class information to a fixup entry, > generalizing the uaccess_err hack currently in place. > > Forward-ported-from-3.9-by: Tony Luck > Signed-off-by: Andy Lutomirski Crivens! I messed up when "git cherrypick

[PATCH v6 1/4] x86: Clean up extable entry format (and free up a bit)

2016-01-03 Thread Andy Lutomirski
This adds two bits of fixup class information to a fixup entry, generalizing the uaccess_err hack currently in place. Forward-ported-from-3.9-by: Tony Luck Signed-off-by: Andy Lutomirski --- arch/x86/include/asm/asm.h | 70 ++ arch/x86/mm/extable.c