Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Linus Torvalds
Date: Wednesday, March 19, 2008 - 7:40 pm

On Wed, 19 Mar 2008, Roland McGrath wrote:

Hmm.. I see the whole series, and I see this patch, but I think it adds 
new code and new complexity, and I don't really see *why*.

So I'm obviously not going to apply it outside the merge window anyway, 
but even for later I'd really like to know what you're building up 
towards, because without understanding the upsides it just feels like it 
adds ugly code and unnecessary infrastructure without any real point to 
it.

And I have to say, I really hate that

		ret = arch_ptrace(child, request, addr, data);
		if (ret == -ENOSYS && !forced_successful_syscall_return())
			ret = ptrace_request(child, request, addr, data);

thing. Instead of doing it that ugly way (return value and a special 
per-arch forced_successful_syscall_return() thing), this really smells 
like you just want to change the calling conventions for "arch_ptrace()" 
instead.

Wouldn't it be nicer to just let "arch_ptrace()" return a flag saying 
whether it handled things or not?

			Linus
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Roland McGrath, (Wed Mar 19, 2:20 pm)
[PATCH 7/8] x86 ptrace: arch_ptrace -ENOSYS return, Roland McGrath, (Wed Mar 19, 2:20 pm)
[PATCH 8/8] powerpc ptrace: arch_ptrace -ENOSYS return, Roland McGrath, (Wed Mar 19, 2:21 pm)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Linus Torvalds, (Wed Mar 19, 7:40 pm)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Christoph Hellwig, (Thu Mar 20, 12:40 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Roland McGrath, (Thu Mar 20, 1:16 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Thomas Gleixner, (Fri Mar 21, 6:50 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Christoph Hellwig, (Fri Mar 21, 7:07 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Sam Ravnborg, (Fri Mar 21, 7:10 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Linus Torvalds, (Fri Mar 21, 7:55 am)
Re: [PATCH 6/8] ptrace: arch_ptrace -ENOSYS return, Ingo Molnar, (Fri Mar 21, 8:07 am)