lkml.org 
[lkml]   [2021]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRE: [PATCH 1/3] arm64: ptrace: Add is_syscall_success to handle compat
    Date
    From: Mark Rutland
    > Sent: 16 April 2021 14:35
    ..
    > @@ -51,13 +48,7 @@ static inline void syscall_set_return_value(struct task_struct *task,
    > struct pt_regs *regs,
    > int error, long val)
    > {
    > - if (error)
    > - val = error;
    > -
    > - if (is_compat_thread(task_thread_info(task)))
    > - val = lower_32_bits(val);
    > -
    > - regs->regs[0] = val;
    > + regs->regs[0] = (long) error ? error : val;

    = error ? (long)error : rval;

    David

    -
    Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
    Registration No: 1397386 (Wales)

    \
     
     \ /
      Last update: 2021-04-17 15:20    [W:2.999 / U:0.120 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site