All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild@lists.01.org
Subject: Re: [RFC PATCH 1/2] sched/topology: Get rid of NUMA overlapping groups
Date: Wed, 03 Feb 2021 21:38:40 +0300	[thread overview]
Message-ID: <20210203183840.GY2696@kadam> (raw)
In-Reply-To: <20210203155432.10293-2-valentin.schneider@arm.com>

[-- Attachment #1: Type: text/plain, Size: 3771 bytes --]

Hi Valentin,

url:    https://github.com/0day-ci/linux/commits/Valentin-Schneider/sched-topology-Get-rid-of-overlapping-groups/20210204-000142
base:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git 075a28439d0c8eb6d3c799e1eed24bb9bc7750cd
config: s390-randconfig-m031-20210204 (attached as .config)
compiler: s390-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>

smatch warnings:
kernel/sched/topology.c:1012 find_node_domain() error: uninitialized symbol 'parent'.

vim +/parent +1012 kernel/sched/topology.c

02d81c8f49452e Valentin Schneider   2021-02-03   985  static struct sched_domain *find_node_domain(struct sched_domain *sd)
02d81c8f49452e Valentin Schneider   2021-02-03   986  {
02d81c8f49452e Valentin Schneider   2021-02-03   987  	struct sched_domain *parent;
02d81c8f49452e Valentin Schneider   2021-02-03   988  
02d81c8f49452e Valentin Schneider   2021-02-03   989  	BUG_ON(!(sd->flags & SD_NUMA));
02d81c8f49452e Valentin Schneider   2021-02-03   990  
02d81c8f49452e Valentin Schneider   2021-02-03   991  	/* Get to the level above NODE */
02d81c8f49452e Valentin Schneider   2021-02-03   992  	while (sd && sd->child) {

Presumably this is always true when the function is called so this
warning is a false positive?

02d81c8f49452e Valentin Schneider   2021-02-03   993  		parent = sd;
02d81c8f49452e Valentin Schneider   2021-02-03   994  		sd = sd->child;
02d81c8f49452e Valentin Schneider   2021-02-03   995  
02d81c8f49452e Valentin Schneider   2021-02-03   996  		if (!(sd->flags & SD_NUMA))
02d81c8f49452e Valentin Schneider   2021-02-03   997  			break;
02d81c8f49452e Valentin Schneider   2021-02-03   998  	}
02d81c8f49452e Valentin Schneider   2021-02-03   999  	/*
02d81c8f49452e Valentin Schneider   2021-02-03  1000  	 * We're going to create cross topology level sched_group_capacity
02d81c8f49452e Valentin Schneider   2021-02-03  1001  	 * references. This can only work if the domains resulting from said
02d81c8f49452e Valentin Schneider   2021-02-03  1002  	 * levels won't be degenerated, as we need said sgc to be periodically
02d81c8f49452e Valentin Schneider   2021-02-03  1003  	 * updated: it needs to be attached to the local group of a domain
02d81c8f49452e Valentin Schneider   2021-02-03  1004  	 * that didn't get degenerated.
02d81c8f49452e Valentin Schneider   2021-02-03  1005  	 *
02d81c8f49452e Valentin Schneider   2021-02-03  1006  	 * Of course, groups aren't available yet, so we can't call the usual
02d81c8f49452e Valentin Schneider   2021-02-03  1007  	 * sd_degenerate(). Checking domain spans is the closest we get.
02d81c8f49452e Valentin Schneider   2021-02-03  1008  	 * Start from NODE's parent, and keep going up until we get a domain
02d81c8f49452e Valentin Schneider   2021-02-03  1009  	 * we're sure won't be degenerated.
02d81c8f49452e Valentin Schneider   2021-02-03  1010  	 */
02d81c8f49452e Valentin Schneider   2021-02-03  1011  	while (sd->parent &&
02d81c8f49452e Valentin Schneider   2021-02-03 @1012  	       cpumask_equal(sched_domain_span(sd), sched_domain_span(parent))) {
02d81c8f49452e Valentin Schneider   2021-02-03  1013  		sd = parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1014  		parent = sd->parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1015  	}
02d81c8f49452e Valentin Schneider   2021-02-03  1016  
02d81c8f49452e Valentin Schneider   2021-02-03  1017  	return parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1018  }

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 22621 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: kbuild-all@lists.01.org
Subject: Re: [RFC PATCH 1/2] sched/topology: Get rid of NUMA overlapping groups
Date: Wed, 03 Feb 2021 21:38:40 +0300	[thread overview]
Message-ID: <20210203183840.GY2696@kadam> (raw)
In-Reply-To: <20210203155432.10293-2-valentin.schneider@arm.com>

[-- Attachment #1: Type: text/plain, Size: 3771 bytes --]

Hi Valentin,

url:    https://github.com/0day-ci/linux/commits/Valentin-Schneider/sched-topology-Get-rid-of-overlapping-groups/20210204-000142
base:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git 075a28439d0c8eb6d3c799e1eed24bb9bc7750cd
config: s390-randconfig-m031-20210204 (attached as .config)
compiler: s390-linux-gcc (GCC) 9.3.0

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>

smatch warnings:
kernel/sched/topology.c:1012 find_node_domain() error: uninitialized symbol 'parent'.

vim +/parent +1012 kernel/sched/topology.c

02d81c8f49452e Valentin Schneider   2021-02-03   985  static struct sched_domain *find_node_domain(struct sched_domain *sd)
02d81c8f49452e Valentin Schneider   2021-02-03   986  {
02d81c8f49452e Valentin Schneider   2021-02-03   987  	struct sched_domain *parent;
02d81c8f49452e Valentin Schneider   2021-02-03   988  
02d81c8f49452e Valentin Schneider   2021-02-03   989  	BUG_ON(!(sd->flags & SD_NUMA));
02d81c8f49452e Valentin Schneider   2021-02-03   990  
02d81c8f49452e Valentin Schneider   2021-02-03   991  	/* Get to the level above NODE */
02d81c8f49452e Valentin Schneider   2021-02-03   992  	while (sd && sd->child) {

Presumably this is always true when the function is called so this
warning is a false positive?

02d81c8f49452e Valentin Schneider   2021-02-03   993  		parent = sd;
02d81c8f49452e Valentin Schneider   2021-02-03   994  		sd = sd->child;
02d81c8f49452e Valentin Schneider   2021-02-03   995  
02d81c8f49452e Valentin Schneider   2021-02-03   996  		if (!(sd->flags & SD_NUMA))
02d81c8f49452e Valentin Schneider   2021-02-03   997  			break;
02d81c8f49452e Valentin Schneider   2021-02-03   998  	}
02d81c8f49452e Valentin Schneider   2021-02-03   999  	/*
02d81c8f49452e Valentin Schneider   2021-02-03  1000  	 * We're going to create cross topology level sched_group_capacity
02d81c8f49452e Valentin Schneider   2021-02-03  1001  	 * references. This can only work if the domains resulting from said
02d81c8f49452e Valentin Schneider   2021-02-03  1002  	 * levels won't be degenerated, as we need said sgc to be periodically
02d81c8f49452e Valentin Schneider   2021-02-03  1003  	 * updated: it needs to be attached to the local group of a domain
02d81c8f49452e Valentin Schneider   2021-02-03  1004  	 * that didn't get degenerated.
02d81c8f49452e Valentin Schneider   2021-02-03  1005  	 *
02d81c8f49452e Valentin Schneider   2021-02-03  1006  	 * Of course, groups aren't available yet, so we can't call the usual
02d81c8f49452e Valentin Schneider   2021-02-03  1007  	 * sd_degenerate(). Checking domain spans is the closest we get.
02d81c8f49452e Valentin Schneider   2021-02-03  1008  	 * Start from NODE's parent, and keep going up until we get a domain
02d81c8f49452e Valentin Schneider   2021-02-03  1009  	 * we're sure won't be degenerated.
02d81c8f49452e Valentin Schneider   2021-02-03  1010  	 */
02d81c8f49452e Valentin Schneider   2021-02-03  1011  	while (sd->parent &&
02d81c8f49452e Valentin Schneider   2021-02-03 @1012  	       cpumask_equal(sched_domain_span(sd), sched_domain_span(parent))) {
02d81c8f49452e Valentin Schneider   2021-02-03  1013  		sd = parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1014  		parent = sd->parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1015  	}
02d81c8f49452e Valentin Schneider   2021-02-03  1016  
02d81c8f49452e Valentin Schneider   2021-02-03  1017  	return parent;
02d81c8f49452e Valentin Schneider   2021-02-03  1018  }

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 22621 bytes --]

  reply	other threads:[~2021-02-03 18:38 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-03 15:54 [RFC PATCH 0/2] sched/topology: Get rid of overlapping groups Valentin Schneider
2021-02-03 15:54 ` [RFC PATCH 1/2] sched/topology: Get rid of NUMA " Valentin Schneider
2021-02-03 18:38   ` Dan Carpenter [this message]
2021-02-03 18:38     ` Dan Carpenter
2021-02-03 19:26     ` Valentin Schneider
2021-02-08 10:04   ` Song Bao Hua (Barry Song)
2021-02-08 11:47     ` Valentin Schneider
2021-02-09  0:12       ` Song Bao Hua (Barry Song)
2021-02-09 10:41         ` Valentin Schneider
2021-02-03 15:54 ` [RFC PATCH 2/2] Revert "sched/topology: Warn when NUMA diameter > 2" Valentin Schneider
2021-02-08 10:27   ` Song Bao Hua (Barry Song)
2021-02-03 15:54 ` [RFC PATCH 3/2] sched/topology: Alternative diameter >= 2 fixup Valentin Schneider
  -- strict thread matches above, loose matches on Subject: below --
2021-02-03 18:31 [RFC PATCH 1/2] sched/topology: Get rid of NUMA overlapping groups kernel test robot

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=20210203183840.GY2696@kadam \
    --to=dan.carpenter@oracle.com \
    --cc=kbuild@lists.01.org \
    /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.