Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1602747
| From | Linus Torvalds <torvalds@linux-foundation.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller |
| Date | 2017-03-16 19:30 +0100 |
| Message-ID | <tlIjV-2f6-53@gated-at.bofh.it> (permalink) |
| References | <tlHnP-1ze-5@gated-at.bofh.it> <tlHnQ-1ze-15@gated-at.bofh.it> <tlHHc-1ID-17@gated-at.bofh.it> <tlI0y-25v-33@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Thu, Mar 16, 2017 at 11:09 AM, Steven Rostedt <rostedt@goodmis.org> wrote:
> +
> + /* Since we don't care about cs, move flags there to simplify return */
> + movl 14*4(%esp), %eax
> + movl %eax, 13*4(%esp)
> +
> + /* Move return ip back to its original location */
> + movl 12*4(%esp), %eax
> + movl %eax, 14*4(%esp)
Could this perhaps be removed entirely?
The return code could instead do:
... restore all the normal registers ..
# Now restore flags that is under the return address and our
fake __KERNEL_CS
pushl 8(%esp)
popfl
# and then return, skipping __KERNEL_CS and %flasg
ret $8
which is smaller and simpler than (again) playing games with stack entries.
Linus
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 4/5 v2] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 18:30 +0100
Re: [PATCH 4/5 v2] ftrace/x86_32: Clean up ftrace_regs_caller Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-16 18:50 +0100
Re: [PATCH 4/5 v2] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 19:00 +0100
[PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 19:10 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-16 19:30 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-16 20:30 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 20:50 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 20:30 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Linus Torvalds <torvalds@linux-foundation.org> - 2017-03-16 20:40 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 21:00 +0100
Re: [PATCH 4/5 v3] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 20:30 +0100
[PATCH 4/5 v3.1] ftrace/x86_32: Clean up ftrace_regs_caller Steven Rostedt <rostedt@goodmis.org> - 2017-03-16 21:20 +0100
csiph-web