From: Christian Loehle <christian.loehle@arm.com>
To: Juri Lelli <juri.lelli@redhat.com>
Cc: Shuah Khan <shuah@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
Dietmar Eggemann <dietmar.eggemann@arm.com>,
Steven Rostedt <rostedt@goodmis.org>,
Valentin Schneider <vschneid@redhat.com>,
Clark Williams <williams@redhat.com>,
Gabriele Monaco <gmonaco@redhat.com>,
Tommaso Cucinotta <tommaso.cucinotta@santannapisa.it>,
Luca Abeni <luca.abeni@santannapisa.it>,
linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH RFC 5/7] selftests/sched: Add SCHED_DEADLINE bandwidth tests to kselftest
Date: Wed, 11 Mar 2026 14:26:19 +0000 [thread overview]
Message-ID: <1d09f674-0c0b-47fc-abaf-6db6b01c775c@arm.com> (raw)
In-Reply-To: <da6b6b85-25f1-4b22-9638-d68b161331a4@arm.com>
On 3/11/26 13:44, Christian Loehle wrote:
> On 3/11/26 13:23, Juri Lelli wrote:
>> On 11/03/26 09:31, Christian Loehle wrote:
>>> On 3/6/26 16:10, Juri Lelli wrote:
>>
>> ...
>>
>>>> + /* Start one cpuhog per CPU at max bandwidth */
>>>> + printf(" Starting %d cpuhog tasks at max bandwidth...\n", num_cpus);
>>>> +
>>>> + for (i = 0; i < num_cpus; i++) {
>>>> + pids[i] = dl_create_cpuhog(runtime_ns, deadline_ns, period_ns, 0);
>>>> + if (pids[i] < 0) {
>>>> + printf(" Task %d failed to start: %s\n",
>>>> + i + 1, strerror(errno));
>>>> + goto cleanup;
>>>> + }
>>>> + started++;
>>>> + }
>>>
>>> Would it be okay to just have one task per max-cap CPU to make this pass on HMP?
>>> Or something more sophisticated?
>>>
>>
>> On HMP we should probably have max bandwidth hogs on big CPUs and then
>> scale runtime (bandwidth) considering smaller CPUs capacities. Cannot
>> quickly check atm, but that info (max cap per-CPU) is available
>> somewhere in sys or proc, is it?
>
> Yes it's here:
> /sys/devices/system/cpu/cpu0/cpu_capacity
>
> FWIW I've attached the two patches to get a pass out of arm64 HMP.
Wait nevermind, this isn't right, this would expect a 10 CPU system with
[1024, 128, 128, 128, 128, 128, 128, 128, 128, 128]
= 2176
would allow for 2 1024-equivalent hogs, but that is obviously wrong as
the capacity -> bandwidth calculation must be capped in practice by
only summing the k-highest-cap-CPUs if there's only k deadline-tasks.
Let me go and read how this is actually supposed to work.
next prev parent reply other threads:[~2026-03-11 14:26 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-06 16:10 [PATCH RFC 0/7] selftests/sched: Add comprehensive SCHED_DEADLINE test suite Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 1/7] selftests/sched: Add SCHED_DEADLINE test framework infrastructure Juri Lelli
2026-03-09 8:20 ` Gabriele Monaco
2026-03-09 9:10 ` Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 2/7] selftests/sched: Add SCHED_DEADLINE utility library Juri Lelli
2026-03-11 9:39 ` Christian Loehle
2026-03-11 13:15 ` Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 3/7] selftests/sched: Integrate SCHED_DEADLINE tests into kselftest framework Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 4/7] selftests/sched: Add basic SCHED_DEADLINE functionality tests Juri Lelli
2026-03-09 8:15 ` Gabriele Monaco
2026-03-09 9:11 ` Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 5/7] selftests/sched: Add SCHED_DEADLINE bandwidth tests to kselftest Juri Lelli
2026-03-11 9:31 ` Christian Loehle
2026-03-11 13:23 ` Juri Lelli
2026-03-11 13:44 ` Christian Loehle
2026-03-11 14:26 ` Christian Loehle [this message]
2026-03-12 10:43 ` Christian Loehle
2026-03-12 11:30 ` Christian Loehle
2026-03-12 14:13 ` Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 6/7] selftests/sched: Add SCHED_DEADLINE fair_server " Juri Lelli
2026-03-06 16:10 ` [PATCH RFC 7/7] selftests/sched: Add SCHED_DEADLINE ENQUEUE_REPLENISH bug test Juri Lelli
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=1d09f674-0c0b-47fc-abaf-6db6b01c775c@arm.com \
--to=christian.loehle@arm.com \
--cc=dietmar.eggemann@arm.com \
--cc=gmonaco@redhat.com \
--cc=juri.lelli@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=luca.abeni@santannapisa.it \
--cc=mingo@redhat.com \
--cc=peterz@infradead.org \
--cc=rostedt@goodmis.org \
--cc=shuah@kernel.org \
--cc=tommaso.cucinotta@santannapisa.it \
--cc=vincent.guittot@linaro.org \
--cc=vschneid@redhat.com \
--cc=williams@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox