All of lore.kernel.org
 help / color / mirror / Atom feed
* sched: Update kerneldoc for sched_rr_get_interval()
@ 2017-12-11 22:56 Jonathan Corbet
  2017-12-11 23:14 ` Randy Dunlap
  0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Corbet @ 2017-12-11 22:56 UTC (permalink / raw)
  To: Ingo Molnar, Peter Zijlstra; +Cc: LKML, Al Viro

Commit abca5fc535a3e ("sched_rr_get_interval(): move compat to native, get
rid of set_fs()") changed the prototype of that function but left the
kerneldoc comments unchanged, leading to these docs-build warnings:

  ./kernel/sched/core.c:5113: warning: No description found for parameter 't'
  ./kernel/sched/core.c:5113: warning: Excess function parameter 'interval'
  			      description in 'sched_rr_get_interval'

Update the documentation (noting that it's not a user-space address
anymore) and make the docs build a little quieter.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>
---
 kernel/sched/core.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 75554f366fd3..a6e9edb55333 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -5100,12 +5100,12 @@ SYSCALL_DEFINE1(sched_get_priority_min, int, policy)
 /**
  * sys_sched_rr_get_interval - return the default timeslice of a process.
  * @pid: pid of the process.
- * @interval: userspace pointer to the timeslice value.
+ * @t: pointer to the timeslice value.
  *
  * this syscall writes the default timeslice value of a given process
- * into the user-space timespec buffer. A value of '0' means infinity.
+ * into the timespec64 buffer. A value of '0' means infinity.
  *
- * Return: On success, 0 and the timeslice is in @interval. Otherwise,
+ * Return: On success, 0 and the timeslice is in @t. Otherwise,
  * an error code.
  */
 static int sched_rr_get_interval(pid_t pid, struct timespec64 *t)
-- 
2.14.3

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: sched: Update kerneldoc for sched_rr_get_interval()
  2017-12-11 22:56 sched: Update kerneldoc for sched_rr_get_interval() Jonathan Corbet
@ 2017-12-11 23:14 ` Randy Dunlap
  2017-12-11 23:25   ` Jonathan Corbet
  0 siblings, 1 reply; 4+ messages in thread
From: Randy Dunlap @ 2017-12-11 23:14 UTC (permalink / raw)
  To: Jonathan Corbet, Ingo Molnar, Peter Zijlstra; +Cc: LKML, Al Viro

On 12/11/2017 02:56 PM, Jonathan Corbet wrote:
> Commit abca5fc535a3e ("sched_rr_get_interval(): move compat to native, get
> rid of set_fs()") changed the prototype of that function but left the
> kerneldoc comments unchanged, leading to these docs-build warnings:
> 
>   ./kernel/sched/core.c:5113: warning: No description found for parameter 't'
>   ./kernel/sched/core.c:5113: warning: Excess function parameter 'interval'
>   			      description in 'sched_rr_get_interval'
> 
> Update the documentation (noting that it's not a user-space address
> anymore) and make the docs build a little quieter.
> 
> Signed-off-by: Jonathan Corbet <corbet@lwn.net>

I sent a patch for this on DEC-03 to Al, Ingo, PeterZ, and LKML.
https://marc.info/?l=linux-kernel&m=151233595424349&w=2

or I could ack your patch.  :)

> ---
>  kernel/sched/core.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/kernel/sched/core.c b/kernel/sched/core.c
> index 75554f366fd3..a6e9edb55333 100644
> --- a/kernel/sched/core.c
> +++ b/kernel/sched/core.c
> @@ -5100,12 +5100,12 @@ SYSCALL_DEFINE1(sched_get_priority_min, int, policy)
>  /**
>   * sys_sched_rr_get_interval - return the default timeslice of a process.
>   * @pid: pid of the process.
> - * @interval: userspace pointer to the timeslice value.
> + * @t: pointer to the timeslice value.
>   *
>   * this syscall writes the default timeslice value of a given process
> - * into the user-space timespec buffer. A value of '0' means infinity.
> + * into the timespec64 buffer. A value of '0' means infinity.
>   *
> - * Return: On success, 0 and the timeslice is in @interval. Otherwise,
> + * Return: On success, 0 and the timeslice is in @t. Otherwise,
>   * an error code.
>   */
>  static int sched_rr_get_interval(pid_t pid, struct timespec64 *t)
> 


-- 
~Randy

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: sched: Update kerneldoc for sched_rr_get_interval()
  2017-12-11 23:14 ` Randy Dunlap
@ 2017-12-11 23:25   ` Jonathan Corbet
  2017-12-12 10:18     ` Ingo Molnar
  0 siblings, 1 reply; 4+ messages in thread
From: Jonathan Corbet @ 2017-12-11 23:25 UTC (permalink / raw)
  To: Randy Dunlap; +Cc: Ingo Molnar, Peter Zijlstra, LKML, Al Viro

On Mon, 11 Dec 2017 15:14:21 -0800
Randy Dunlap <rdunlap@infradead.org> wrote:

> On 12/11/2017 02:56 PM, Jonathan Corbet wrote:
> > Commit abca5fc535a3e ("sched_rr_get_interval(): move compat to native, get
> > rid of set_fs()") changed the prototype of that function but left the
> > kerneldoc comments unchanged, leading to these docs-build warnings:
> > 
> >   ./kernel/sched/core.c:5113: warning: No description found for parameter 't'
> >   ./kernel/sched/core.c:5113: warning: Excess function parameter 'interval'
> >   			      description in 'sched_rr_get_interval'
> > 
> > Update the documentation (noting that it's not a user-space address
> > anymore) and make the docs build a little quieter.
> > 
> > Signed-off-by: Jonathan Corbet <corbet@lwn.net>  
> 
> I sent a patch for this on DEC-03 to Al, Ingo, PeterZ, and LKML.
> https://marc.info/?l=linux-kernel&m=151233595424349&w=2
> 
> or I could ack your patch.  :)

OK, looking more closely, your patch is more correct than mine and is the
one that should be applied.  Sorry I didn't see it before.

jon

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: sched: Update kerneldoc for sched_rr_get_interval()
  2017-12-11 23:25   ` Jonathan Corbet
@ 2017-12-12 10:18     ` Ingo Molnar
  0 siblings, 0 replies; 4+ messages in thread
From: Ingo Molnar @ 2017-12-12 10:18 UTC (permalink / raw)
  To: Jonathan Corbet; +Cc: Randy Dunlap, Ingo Molnar, Peter Zijlstra, LKML, Al Viro


* Jonathan Corbet <corbet@lwn.net> wrote:

> On Mon, 11 Dec 2017 15:14:21 -0800
> Randy Dunlap <rdunlap@infradead.org> wrote:
> 
> > On 12/11/2017 02:56 PM, Jonathan Corbet wrote:
> > > Commit abca5fc535a3e ("sched_rr_get_interval(): move compat to native, get
> > > rid of set_fs()") changed the prototype of that function but left the
> > > kerneldoc comments unchanged, leading to these docs-build warnings:
> > > 
> > >   ./kernel/sched/core.c:5113: warning: No description found for parameter 't'
> > >   ./kernel/sched/core.c:5113: warning: Excess function parameter 'interval'
> > >   			      description in 'sched_rr_get_interval'
> > > 
> > > Update the documentation (noting that it's not a user-space address
> > > anymore) and make the docs build a little quieter.
> > > 
> > > Signed-off-by: Jonathan Corbet <corbet@lwn.net>  
> > 
> > I sent a patch for this on DEC-03 to Al, Ingo, PeterZ, and LKML.
> > https://marc.info/?l=linux-kernel&m=151233595424349&w=2
> > 
> > or I could ack your patch.  :)
> 
> OK, looking more closely, your patch is more correct than mine and is the
> one that should be applied.  Sorry I didn't see it before.

Yeah, I have applied Randy's patch to the sched/urgent tree yesterday:

  2064a5ab0470: sched/core: Fix kernel-doc warnings after code movement

It's still not pushed out though, because I'm chasing an (unrelated) regression.

Thanks,

	Ingo

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-12-12 10:18 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-12-11 22:56 sched: Update kerneldoc for sched_rr_get_interval() Jonathan Corbet
2017-12-11 23:14 ` Randy Dunlap
2017-12-11 23:25   ` Jonathan Corbet
2017-12-12 10:18     ` Ingo Molnar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.