Re: [PATCH] MIPS: Fix ptrace(2) PTRACE_PEEKUSR and PTRACE_POKEUSR accesses to o32 FGRs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, May 14, 2018 at 04:49:43PM +0100, Maciej W. Rozycki wrote:
> Check the TIF_32BIT_FPREGS task setting of the tracee rather than the 
> tracer in determining the layout of floating-point general registers in 
> the floating-point context, correcting access to odd-numbered registers 
> for o32 tracees where the setting disagrees between the two processes.
> 
> Cc: stable@xxxxxxxxxxxxxxx # 3.14+
> Fixes: 597ce1723e0f ("MIPS: Support for 64-bit FP with O32 binaries")
> Signed-off-by: Maciej W. Rozycki <macro@xxxxxxxx>
> ---
> Hi,
> 
>  These are not the usual requests used by GDB to access the floating-point 
> context, which is likely why it went unnoticed so long.  They are only 
> used as a fallback in the case where PTRACE_GETFPREGS and PTRACE_SETFPREGS 
> requests are not supported, i.e. with ancient kernels.
> 
>  However to verify an unrelated GDB bug fix I have tweaked GDB to always 
> use PTRACE_PEEKUSR and PTRACE_POKEUSR, and then discovered this issue in 
> native GDB regression testing, as it showed regressions from corrupt FGR 
> contents across numerous tests compared to the usual results.  This fix 
> removed those regressions then.
> 
>  Not being typically used does not mean we ought to keep the interface 
> broken.  Therefore please apply.

Looks good. Applied to fixes branch for 4.17.

Thanks
James

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux MIPS Home]     [LKML Archive]     [Linux ARM Kernel]     [Linux ARM]     [Linux]     [Git]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux