* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls [not found] ` <1277287401-28571-32-git-send-email-imunsie@au1.ibm.com> @ 2010-06-23 10:19 ` Andi Kleen 2010-06-23 10:29 ` Frederic Weisbecker 2010-06-23 10:30 ` KOSAKI Motohiro 0 siblings, 2 replies; 8+ messages in thread From: Andi Kleen @ 2010-06-23 10:19 UTC (permalink / raw) To: Ian Munsie Cc: Christoph Lameter, WANG Cong, Frederic Weisbecker, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, Benjamin Herrenschmidt, Ingo Molnar, Arnd Bergmann, David Rientjes, Steven Rostedt, Michael Ellerman, Alexander Viro, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller , Ian Munsie wrote: > From: Ian Munsie<imunsie@au1.ibm.com> > > This patch converts numerous trivial compat syscalls through the generic > kernel code to use the COMPAT_SYSCALL_DEFINE family of macros. Why? This just makes the code look uglier and the functions harder to grep for. -Andi _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 10:19 ` [PATCH 31/40] trace syscalls: Convert various generic compat syscalls Andi Kleen @ 2010-06-23 10:29 ` Frederic Weisbecker 2010-06-23 10:37 ` Andi Kleen 2010-06-23 10:30 ` KOSAKI Motohiro 1 sibling, 1 reply; 8+ messages in thread From: Frederic Weisbecker @ 2010-06-23 10:29 UTC (permalink / raw) To: Andi Kleen Cc: Christoph Lameter, WANG Cong, Benjamin Herrenschmidt, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, David Rientjes, Ingo Molnar, Arnd Bergmann, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote: > , Ian Munsie wrote: >> From: Ian Munsie<imunsie@au1.ibm.com> >> >> This patch converts numerous trivial compat syscalls through the generic >> kernel code to use the COMPAT_SYSCALL_DEFINE family of macros. > > Why? This just makes the code look uglier and the functions harder > to grep for. Because it makes them usable with syscall tracing. _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 10:29 ` Frederic Weisbecker @ 2010-06-23 10:37 ` Andi Kleen 2010-06-23 11:38 ` Frederic Weisbecker 0 siblings, 1 reply; 8+ messages in thread From: Andi Kleen @ 2010-06-23 10:37 UTC (permalink / raw) To: Frederic Weisbecker Cc: Christoph Lameter, WANG Cong, Benjamin Herrenschmidt, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, David Rientjes, Ingo Molnar, Arnd Bergmann, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro , Frederic Weisbecker wrote: > On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote: >> , Ian Munsie wrote: >>> From: Ian Munsie<imunsie@au1.ibm.com> >>> >>> This patch converts numerous trivial compat syscalls through the generic >>> kernel code to use the COMPAT_SYSCALL_DEFINE family of macros. >> >> Why? This just makes the code look uglier and the functions harder >> to grep for. > > > Because it makes them usable with syscall tracing. Ok that information is missing in the changelog then. Also I hope the uglification<->usefullness factor is really worth it. The patch is certainly no slouch on the uglification side. It also has maintenance costs, e.g. I doubt ctags and cscope will be able to deal with these kinds of macros, so it has a high cost for everyone using these tools. For those it would be actually better if you used separate annotation that does not confuse standard C parsers. -Andi _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 10:37 ` Andi Kleen @ 2010-06-23 11:38 ` Frederic Weisbecker 2010-06-23 12:35 ` Andi Kleen 2010-06-23 15:51 ` H. Peter Anvin 0 siblings, 2 replies; 8+ messages in thread From: Frederic Weisbecker @ 2010-06-23 11:38 UTC (permalink / raw) To: Andi Kleen Cc: Christoph Lameter, WANG Cong, Benjamin Herrenschmidt, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, David Rientjes, Ingo Molnar, Arnd Bergmann, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro On Wed, Jun 23, 2010 at 12:37:44PM +0200, Andi Kleen wrote: > , Frederic Weisbecker wrote: >> On Wed, Jun 23, 2010 at 12:19:38PM +0200, Andi Kleen wrote: >>> , Ian Munsie wrote: >>>> From: Ian Munsie<imunsie@au1.ibm.com> >>>> >>>> This patch converts numerous trivial compat syscalls through the generic >>>> kernel code to use the COMPAT_SYSCALL_DEFINE family of macros. >>> >>> Why? This just makes the code look uglier and the functions harder >>> to grep for. >> >> >> Because it makes them usable with syscall tracing. > > Ok that information is missing in the changelog then. Agreed, the changelog lacks the purpose of what it does. > Also I hope the uglification<->usefullness factor is really worth it. > The patch is certainly no slouch on the uglification side. It's worth because the kernel's syscall tracing is not complete, we lack all the compat part. These wrappers let us create TRACE_EVENT() for every syscalls automatically. If we had to create them manually, the uglification would be way much more worse. Most syscalls use the syscall wrappers already, so the uglification is there mostly. We just forgot to uglify a bunch of them :) > It also has maintenance costs, e.g. I doubt ctags and cscope > will be able to deal with these kinds of macros, so it has a > high cost for everyone using these tools. For those > it would be actually better if you used separate annotation > that does not confuse standard C parsers. I haven't heard any complains about existing syscalls wrappers. What kind of annotations could solve that? _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 11:38 ` Frederic Weisbecker @ 2010-06-23 12:35 ` Andi Kleen 2010-06-23 12:41 ` Christoph Hellwig 2010-06-23 15:51 ` H. Peter Anvin 1 sibling, 1 reply; 8+ messages in thread From: Andi Kleen @ 2010-06-23 12:35 UTC (permalink / raw) To: Frederic Weisbecker Cc: Christoph Lameter, WANG Cong, Benjamin Herrenschmidt, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, David Rientjes, Ingo Molnar, Arnd Bergmann, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro > > I haven't heard any complains about existing syscalls wrappers. At least for me they always interrupt my grepping. > > What kind of annotations could solve that? If you put the annotation in a separate macro and leave the original prototype alone. Then C parsers could still parse it. -Andi _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 12:35 ` Andi Kleen @ 2010-06-23 12:41 ` Christoph Hellwig 0 siblings, 0 replies; 8+ messages in thread From: Christoph Hellwig @ 2010-06-23 12:41 UTC (permalink / raw) To: Andi Kleen Cc: Christoph Lameter, WANG Cong, Frederic Weisbecker, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, Benjamin Herrenschmidt, Ingo Molnar, Arnd Bergmann, David Rientjes, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro On Wed, Jun 23, 2010 at 02:35:38PM +0200, Andi Kleen wrote: > >I haven't heard any complains about existing syscalls wrappers. > > At least for me they always interrupt my grepping. > > > > >What kind of annotations could solve that? > > If you put the annotation in a separate macro and leave the original > prototype alone. Then C parsers could still parse it. I personally hate the way SYSCALL_DEFINE works with passion, mostly for the grep reason, but also because it looks horribly ugly. But there is no reason not to be consistent here. We already use the wrappers for all native system calls, so leaving the compat calls out doesn't make any sense. And I'd cheer for anyone who comes up with a better scheme for the native and compat wrappers. _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 11:38 ` Frederic Weisbecker 2010-06-23 12:35 ` Andi Kleen @ 2010-06-23 15:51 ` H. Peter Anvin 1 sibling, 0 replies; 8+ messages in thread From: H. Peter Anvin @ 2010-06-23 15:51 UTC (permalink / raw) To: Frederic Weisbecker Cc: Christoph Lameter, WANG Cong, Benjamin Herrenschmidt, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, Sam Ravnborg, Andi Kleen, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, KOSAKI Motohiro, David Rientjes, Ingo Molnar, Arnd Bergmann, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro On 06/23/2010 04:38 AM, Frederic Weisbecker wrote: > > I haven't heard any complains about existing syscalls wrappers. > Then you truly haven't been listening. -hpa -- H. Peter Anvin, Intel Open Source Technology Center I work for Intel. I don't speak on their behalf. _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH 31/40] trace syscalls: Convert various generic compat syscalls 2010-06-23 10:19 ` [PATCH 31/40] trace syscalls: Convert various generic compat syscalls Andi Kleen 2010-06-23 10:29 ` Frederic Weisbecker @ 2010-06-23 10:30 ` KOSAKI Motohiro 1 sibling, 0 replies; 8+ messages in thread From: KOSAKI Motohiro @ 2010-06-23 10:30 UTC (permalink / raw) To: Andi Kleen Cc: Christoph Lameter, WANG Cong, Frederic Weisbecker, Heiko Carstens, Oleg Nesterov, David Howells, linuxppc-dev, Paul Mackerras, H. Peter Anvin, Sam Ravnborg, Mike Frysinger, Eric Dumazet, Jeff Moyer, Ingo Molnar, kosaki.motohiro, Benjamin Herrenschmidt, Ingo Molnar, Arnd Bergmann, David Rientjes, Steven Rostedt, Michael Ellerman, Ian Munsie, Thomas Gleixner, Johannes Berg, Roland McGrath, Dinakar Guniguntala, Lee Schermerhorn, Arnaldo Carvalho de Melo, Neil Horman, linux-mm, netdev, Jason Baron, Greg Kroah-Hartman, Roel Kluin, linux-kernel, kexec, Eric Biederman, linux-fsdevel, Simon Kagstrom, Andrew Morton, David S. Miller, Alexander Viro > , Ian Munsie wrote: > > From: Ian Munsie<imunsie@au1.ibm.com> > > > > This patch converts numerous trivial compat syscalls through the generic > > kernel code to use the COMPAT_SYSCALL_DEFINE family of macros. > > Why? This just makes the code look uglier and the functions harder > to grep for. I guess trace-syscall feature need to override COMPAT_SYSCALL_DEFINE. but It's only guess... _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec ^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2010-06-23 15:53 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1277287401-28571-1-git-send-email-imunsie@au1.ibm.com>
[not found] ` <1277287401-28571-32-git-send-email-imunsie@au1.ibm.com>
2010-06-23 10:19 ` [PATCH 31/40] trace syscalls: Convert various generic compat syscalls Andi Kleen
2010-06-23 10:29 ` Frederic Weisbecker
2010-06-23 10:37 ` Andi Kleen
2010-06-23 11:38 ` Frederic Weisbecker
2010-06-23 12:35 ` Andi Kleen
2010-06-23 12:41 ` Christoph Hellwig
2010-06-23 15:51 ` H. Peter Anvin
2010-06-23 10:30 ` KOSAKI Motohiro
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox