On Thu, Jul 2, 2015 at 3:49 AM, Borislav Petkov <b...@alien8.de> wrote:
> On Mon, Jun 29, 2015 at 12:33:43PM -0700, Andy Lutomirski wrote:
>> These need to be migrated together, as the compat case used to jump
>> into the middle of the 64-bit exit code.
>>

>> diff --git a/arch/x86/entry/entry_64_compat.S 
>> b/arch/x86/entry/entry_64_compat.S
>> index efe0b1e499fa..ac0658142ae1 100644
>> --- a/arch/x86/entry/entry_64_compat.S
>> +++ b/arch/x86/entry/entry_64_compat.S
>> @@ -209,10 +209,10 @@ sysexit_from_sys_call:
>>       .endm
>>
>>       .macro auditsys_exit exit
>> -     testl   $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT), 
>> ASM_THREAD_INFO(TI_flags, %rsp, SIZEOF_PTREGS)
>> -     jnz     ia32_ret_from_sys_call
>>       TRACE_IRQS_ON
>>       ENABLE_INTERRUPTS(CLBR_NONE)
>> +     testl $(_TIF_ALLWORK_MASK & ~_TIF_SYSCALL_AUDIT), 
>> ASM_THREAD_INFO(TI_flags, %rsp, SIZEOF_PTREGS)
>> +     jnz ia32_ret_from_sys_call
>
> I guess you want to use tabs here like the rest of the macro does.
>

Oops.  I wrote this before everything got tabified and I guess I
didn't fix it up right.

>>       movl    %eax, %esi              /* second arg, syscall return value */
>>       cmpl    $-MAX_ERRNO, %eax       /* is it an error ? */
>>       jbe     1f
>> @@ -227,11 +227,10 @@ sysexit_from_sys_call:
>>       testl   %edi, ASM_THREAD_INFO(TI_flags, %rsp, SIZEOF_PTREGS)
>>       jz      \exit
>>       xorl    %eax, %eax              /* Do not leak kernel information */
>> -     movq    %rax, R11(%rsp)
>
> I guess that change needs at least some explanation in the commit
> message. AFAIU, this is RIP we shouldn't be zeroing for we need it in
> int_ret_from_sys_call...

This change is a mistake.  There was another rebase issue in here that
I fixed, but apparently I still haven't gotten it right.  Sigh.

--Andy
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to