From: Ingo Molnar <mingo@kernel.org>
To: Cyril Hrubis <chrubis@suse.cz>
Cc: Juri Lelli <juri.lelli@redhat.com>,
Valentin Schneider <vschneid@redhat.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
Peter Zijlstra <peterz@infradead.org>,
linux-kernel@vger.kernel.org,
Steven Rostedt <rostedt@goodmis.org>,
Ben Segall <bsegall@google.com>, Ingo Molnar <mingo@redhat.com>,
Mel Gorman <mgorman@suse.de>,
Daniel Bristot de Oliveira <bristot@redhat.com>,
Dietmar Eggemann <dietmar.eggemann@arm.com>,
ltp@lists.linux.it
Subject: Re: [LTP] [PATCH] sched/rt: Disallow writing invalid values to sched_rt_period_us
Date: Fri, 22 Sep 2023 11:46:17 +0200 [thread overview]
Message-ID: <ZQ1iabFEs93OZMSE@gmail.com> (raw)
In-Reply-To: <ZPIqsmTbJh7z-LcO@yuki>
* Cyril Hrubis <chrubis@suse.cz> wrote:
> Hi!
> > Documentation/scheduller/sched-rt-group.rst [1] specifies this as values from -1 to
> > (INT_MAX - 1), I guess due int range. Looking into proc_dointvec_minmax() [2]
> > even INT_MAX would pass the check. I suppose we can do nothing about that,
> > because there is no value in sysctl_vals[] which would represent INT_MAX - 1.
> >
> > And you specify in LTP test range: from -1 to INT_MAX.
> >
> > But even much shorter value than INT_MAX fails:
> >
> > $ echo 1234567 > /proc/sys/kernel/sched_rt_runtime_us
> > sh: echo: write error: Invalid argument
>
> That is because runtime_us must be < period_us by definition, since
> runtime_us defines how much time is allocated from the period_us. I
> guess that this is not described good enough in the kernel docs.
Mind adding a second patch to your series, clarifying
Documentation/scheduler/sched-rt-group.rst?
Thanks,
Ingo
--
Mailing list info: https://lists.linux.it/listinfo/ltp
next prev parent reply other threads:[~2023-09-22 9:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-01 15:43 [LTP] [PATCH] sched/rt: Disallow writing invalid values to sched_rt_period_us Cyril Hrubis
2023-09-01 17:45 ` Petr Vorel
2023-09-01 18:17 ` Cyril Hrubis
2023-09-02 20:22 ` Petr Vorel
2023-09-22 9:46 ` Ingo Molnar [this message]
2023-09-22 11:43 ` Cyril Hrubis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ZQ1iabFEs93OZMSE@gmail.com \
--to=mingo@kernel.org \
--cc=bristot@redhat.com \
--cc=bsegall@google.com \
--cc=chrubis@suse.cz \
--cc=dietmar.eggemann@arm.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=ltp@lists.linux.it \
--cc=mgorman@suse.de \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=vincent.guittot@linaro.org \
--cc=vschneid@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.