public inbox for stable@vger.kernel.org
 help / color / mirror / Atom feed
From: K Prateek Nayak <kprateek.nayak@amd.com>
To: Shrikanth Hegde <sshegde@linux.ibm.com>,
	Naman Jain <namjain@linux.microsoft.com>
Cc: <stable@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	Steve Wahl <steve.wahl@hpe.com>,
	Saurabh Singh Sengar <ssengar@linux.microsoft.com>,
	<srivatsa@csail.mit.edu>, Michael Kelley <mhklinux@outlook.com>,
	Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Juri Lelli <juri.lelli@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
	Valentin Schneider <vschneid@redhat.com>
Subject: Re: [PATCH v3] sched/topology: Enable topology_span_sane check only for debug builds
Date: Tue, 11 Feb 2025 16:26:40 +0530	[thread overview]
Message-ID: <0f51023c-7413-4503-95d4-42113fa3e2e4@amd.com> (raw)
In-Reply-To: <ef199f2a-f970-4c86-a3f2-ddb6ad7abc96@linux.ibm.com>

Hello Shrikanth,

On 2/11/2025 11:22 AM, Shrikanth Hegde wrote:
> 
> [..snip..]
>>
>> What I'm getting to is that the arch specific topology parsing code
>> can set a "SDTL_ARCH_VERIFIED" flag indicating that the arch specific
>> bits have verified that the cpumasks are either equal or disjoint and
>> since sched_debug() is "false" by default, topology_span_sane() can
>> bail out if:
>>
>>      if (!sched_debug() && (tl->flags & SDTL_ARCH_VERIFIED))
>>          return;
>>
> 
> it would simpler to use sched_debug(). no?
> 
> Since it can be enabled at runtime by "echo Y > verbose", if one one needs to enable even after boot. Wouldn't that suffice to run topology_span_sane by doing a hotplug?

Ack! It was a suggestion in case folks felt apprehensive about guarding
the check behind sched_debug() ...

> 
>> In case arch specific parsing was wrong, "sched_verbose" can always
>> be used to double check the topology and for the arch that require
>> this sanity check, Steve's optimized version of
>> topology_span_sane() can be run to be sure of the sanity.
>>
>> All this justification is in case folks want to keep
>> topology_span_sane() around but if no one cares, Naman and Saurabh's
>> approach works as intended.

... which is why I ended that long explanation with this :)

Valentin seems to be on board with the current approach from Naman and
Saurabh and it works as intended.

>>
> 

-- 
Thanks and Regards,
Prateek


      parent reply	other threads:[~2025-02-11 10:56 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-02-03 11:47 [PATCH v3] sched/topology: Enable topology_span_sane check only for debug builds Naman Jain
2025-02-05  7:20 ` K Prateek Nayak
2025-02-05  7:23   ` Naman Jain
2025-02-10  9:53     ` Naman Jain
2025-02-05  9:48 ` K Prateek Nayak
2025-02-05  9:55   ` Peter Zijlstra
2025-02-05 10:13     ` K Prateek Nayak
2025-02-05 10:16       ` Peter Zijlstra
2025-02-06  9:10         ` K Prateek Nayak
2025-02-06  9:47           ` Naman Jain
2025-02-06 10:19             ` K Prateek Nayak
2025-02-06 10:55               ` Naman Jain
2025-02-06 15:24           ` Valentin Schneider
2025-02-06 15:30             ` Steve Wahl
2025-02-06 17:18             ` Naman Jain
2025-02-07  2:44             ` K Prateek Nayak
2025-02-11  5:52   ` Shrikanth Hegde
2025-02-11  7:06     ` Naman Jain
2025-02-11 10:56     ` K Prateek Nayak [this message]

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=0f51023c-7413-4503-95d4-42113fa3e2e4@amd.com \
    --to=kprateek.nayak@amd.com \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=juri.lelli@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mhklinux@outlook.com \
    --cc=mingo@redhat.com \
    --cc=namjain@linux.microsoft.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=srivatsa@csail.mit.edu \
    --cc=ssengar@linux.microsoft.com \
    --cc=sshegde@linux.ibm.com \
    --cc=stable@vger.kernel.org \
    --cc=steve.wahl@hpe.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox