Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1626068
| From | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() |
| Date | 2017-04-19 14:50 +0200 |
| Message-ID | <txXdv-3vn-13@gated-at.bofh.it> (permalink) |
| References | (3 earlier) <txEuf-8r4-45@gated-at.bofh.it> <txHV8-29d-21@gated-at.bofh.it> <txIo9-2iz-1@gated-at.bofh.it> <txRrs-8mT-23@gated-at.bofh.it> <txTMB-1zl-17@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On Wed, 19 Apr 2017 11:08:35 +0200 (CEST) Thomas Gleixner <tglx@linutronix.de> wrote: > > In the grand scheme of things, true. But there are more people running > > with lockdep enabled than there are people writing code, of which there > > are more than people reading relevant comments while writing code. > > Therefore having the lockdep annotation is two orders better than a > > comment ;-) > > > > Also, I would argue that an "assert" at the start of a function is a > > fairly readable 'comment' all by itself. > > > > In any case, I don't care too much. But I typically remove such comments > > when I stick a lockdep_assert_held() in. > > I think that's wrong. We are striving for better documentation and the > kernel-doc comments above a function are part of that. Calling conventions > are definitely something which belongs there. I agree with Thomas. Removing the comment because a "lockdep_assert_held()" exists at the top of the code, assumes someone that is about to use that function did more that read the kerneldoc and actually looked at the code. If there's a kerneldoc to a function, than that header should contain all the info that a developer needs to use that function. -- Steve
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Peter Zijlstra <peterz@infradead.org> - 2017-04-18 12:40 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Peter Zijlstra <peterz@infradead.org> - 2017-04-18 15:10 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Steven Rostedt <rostedt@goodmis.org> - 2017-04-18 18:50 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Peter Zijlstra <peterz@infradead.org> - 2017-04-18 22:30 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Thomas Gleixner <tglx@linutronix.de> - 2017-04-18 23:00 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Peter Zijlstra <peterz@infradead.org> - 2017-04-19 08:40 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Thomas Gleixner <tglx@linutronix.de> - 2017-04-19 11:10 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Steven Rostedt <rostedt@goodmis.org> - 2017-04-19 14:50 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Peter Zijlstra <peterz@infradead.org> - 2017-04-19 16:10 +0200
Re: [PATCH 2/3] jump_label: Provide static_key_slow_inc_nohp() Steven Rostedt <rostedt@goodmis.org> - 2017-04-19 16:30 +0200
[tip:smp/hotplug] jump_label: Provide static_key_slow_inc_cpuslocked() "tip-bot for Peter Zijlstra (Intel)" <tipbot@zytor.com> - 2017-04-20 13:40 +0200
csiph-web