Re: using ptrace to cancel a syscall on sparc

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

 



On Sun, Dec 20, 2015 at 12:47:54AM -0500, Mike Frysinger wrote:
> i've been playing with ptrace on sparc and trying to use it to watch and
> cancel specific syscalls.  i have this working for other arches already.
[...]
> i'm having trouble with canceling of the syscall itself.  seems like
> no matter what i stuff into o0, the kernel executes the unlink.  i've
> tried tracing arch/sparc/kernel/syscalls.S and kernel/head_64.S, the
> the entry is linux_sparc_syscall32 which calls linux_syscall_trace32,
> but it seems like the o0 stuff doesn't seem to work for me.  my sparc
> asm foo isn't strong enough to figure out what's going wrong :/.

Yes, sparc is odd in this respect: whatever you write to u_regs[] on
entering syscall, it doesn't affect syscall number or syscall arguments.


-- 
ldv

Attachment: pgpMGTy4nqyXn.pgp
Description: PGP signature


[Index of Archives]     [Kernel Development]     [DCCP]     [Linux ARM Development]     [Linux]     [Photo]     [Yosemite Help]     [Linux ARM Kernel]     [Linux SCSI]     [Linux x86_64]     [Linux Hams]

  Powered by Linux