Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 3:25 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: >> Here is the function: >> 00400842 : >> 400842: 53 push %rbx >> 400843: 55 push %rbp >> 400844: 41 54 push %r12 >> 400846: 41

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 3:25 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: >> Here is the function: >> 00400842 : >> 400842: 53 push %rbx >> 400843: 55 push %rbp >> 400844: 41 54 push %r12 >> 400846: 41

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 3:22 GMT+01:00 Dmitry Safonov : > On Fri, 2018-05-18 at 19:05 -0700, Andy Lutomirski wrote: >> > On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> >> > cpu family: 6 >> > model: 142 >> > model name: Intel(R) Core(TM) i7-7600U CPU @

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 3:22 GMT+01:00 Dmitry Safonov : > On Fri, 2018-05-18 at 19:05 -0700, Andy Lutomirski wrote: >> > On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> >> > cpu family: 6 >> > model: 142 >> > model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz >> > But I

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
On Fri, 2018-05-18 at 19:05 -0700, Andy Lutomirski wrote: > > On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> > > cpu family: 6 > > model: 142 > > model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz > > But I usually test kernels in VM. So, I use virt-manager as

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
On Fri, 2018-05-18 at 19:05 -0700, Andy Lutomirski wrote: > > On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> > > cpu family: 6 > > model: 142 > > model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz > > But I usually test kernels in VM. So, I use virt-manager as

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Andy Lutomirski
> On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> wrote: > Hi Andy, > 2018-05-18 23:03 GMT+01:00 Andy Lutomirski : >>> On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: >>> Some selftests are failing, but the same way as before the patch

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Andy Lutomirski
> On May 18, 2018, at 4:10 PM, Dmitry Safonov <0x7f454...@gmail.com> wrote: > Hi Andy, > 2018-05-18 23:03 GMT+01:00 Andy Lutomirski : >>> On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: >>> Some selftests are failing, but the same way as before the patch >>> (ITOW, it's not regression):

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 0:16 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: > 2018-05-19 0:10 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: >> Sure. >> I'm on Intel actually: >> cpu family: 6 >> model: 142 >> model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz >> >> But I usually test

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 0:16 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: > 2018-05-19 0:10 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: >> Sure. >> I'm on Intel actually: >> cpu family: 6 >> model: 142 >> model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz >> >> But I usually test

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 0:10 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: > Sure. > I'm on Intel actually: > cpu family: 6 > model: 142 > model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz > > But I usually test kernels in VM. So, I use virt-manager as it's > easier to manage > multiple

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
2018-05-19 0:10 GMT+01:00 Dmitry Safonov <0x7f454...@gmail.com>: > Sure. > I'm on Intel actually: > cpu family: 6 > model: 142 > model name: Intel(R) Core(TM) i7-7600U CPU @ 2.80GHz > > But I usually test kernels in VM. So, I use virt-manager as it's > easier to manage > multiple

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
Hi Andy, 2018-05-18 23:03 GMT+01:00 Andy Lutomirski : > On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: >> Some selftests are failing, but the same way as before the patch >> (ITOW, it's not regression): >> [root@localhost self]# grep FAIL out >> [FAIL]

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Dmitry Safonov
Hi Andy, 2018-05-18 23:03 GMT+01:00 Andy Lutomirski : > On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: >> Some selftests are failing, but the same way as before the patch >> (ITOW, it's not regression): >> [root@localhost self]# grep FAIL out >> [FAIL] Reg 1 mismatch: requested 0x0; got

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Andy Lutomirski
On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: > Some selftests are failing, but the same way as before the patch > (ITOW, it's not regression): > [root@localhost self]# grep FAIL out > [FAIL] Reg 1 mismatch: requested 0x0; got 0x3 > [FAIL] Reg 15 mismatch: requested

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Andy Lutomirski
On Thu, May 17, 2018 at 4:40 PM Dmitry Safonov wrote: > Some selftests are failing, but the same way as before the patch > (ITOW, it's not regression): > [root@localhost self]# grep FAIL out > [FAIL] Reg 1 mismatch: requested 0x0; got 0x3 > [FAIL] Reg 15 mismatch: requested 0x8badf00d5aadc0de;

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Cyrill Gorcunov
On Fri, May 18, 2018 at 12:35:10AM +0100, Dmitry Safonov wrote: > The x86 mmap() code selects the mmap base for an allocation depending on > the bitness of the syscall. For 64bit sycalls it select mm->mmap_base and > for 32bit mm->mmap_compat_base. > > exec() calls mmap() which in turn uses

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-18 Thread Cyrill Gorcunov
On Fri, May 18, 2018 at 12:35:10AM +0100, Dmitry Safonov wrote: > The x86 mmap() code selects the mmap base for an allocation depending on > the bitness of the syscall. For 64bit sycalls it select mm->mmap_base and > for 32bit mm->mmap_compat_base. > > exec() calls mmap() which in turn uses

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-17 Thread Dmitry Safonov
On Fri, 2018-05-18 at 00:35 +0100, Dmitry Safonov wrote: > The x86 mmap() code selects the mmap base for an allocation depending > on > the bitness of the syscall. For 64bit sycalls it select mm->mmap_base > and > for 32bit mm->mmap_compat_base. > > exec() calls mmap() which in turn uses

Re: [PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-17 Thread Dmitry Safonov
On Fri, 2018-05-18 at 00:35 +0100, Dmitry Safonov wrote: > The x86 mmap() code selects the mmap base for an allocation depending > on > the bitness of the syscall. For 64bit sycalls it select mm->mmap_base > and > for 32bit mm->mmap_compat_base. > > exec() calls mmap() which in turn uses

[PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-17 Thread Dmitry Safonov
The x86 mmap() code selects the mmap base for an allocation depending on the bitness of the syscall. For 64bit sycalls it select mm->mmap_base and for 32bit mm->mmap_compat_base. exec() calls mmap() which in turn uses in_compat_syscall() to check whether the mapping is for a 32bit or a 64bit

[PATCH] x86/mm: Drop TS_COMPAT on 64-bit exec() syscall

2018-05-17 Thread Dmitry Safonov
The x86 mmap() code selects the mmap base for an allocation depending on the bitness of the syscall. For 64bit sycalls it select mm->mmap_base and for 32bit mm->mmap_compat_base. exec() calls mmap() which in turn uses in_compat_syscall() to check whether the mapping is for a 32bit or a 64bit