public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Josh Don <joshdon@google.com>, Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Juri Lelli <juri.lelli@redhat.com>,
	Vincent Guittot <vincent.guittot@linaro.org>,
	Tejun Heo <tj@kernel.org>
Cc: kbuild-all@lists.01.org,
	Dietmar Eggemann <dietmar.eggemann@arm.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	Ben Segall <bsegall@google.com>, Mel Gorman <mgorman@suse.de>,
	Daniel Bristot de Oliveira <bristot@redhat.com>,
	Valentin Schneider <vschneid@redhat.com>,
	linux-kernel@vger.kernel.org,
	Cruz Zhao <CruzZhao@linux.alibaba.com>,
	Josh Don <joshdon@google.com>
Subject: Re: [PATCH v2] sched/core: add forced idle accounting for cgroups
Date: Sat, 21 May 2022 11:19:01 +0800	[thread overview]
Message-ID: <202205211108.a5tqwV7v-lkp@intel.com> (raw)
In-Reply-To: <20220520235138.3140590-1-joshdon@google.com>

Hi Josh,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on tj-cgroup/for-next]
[also build test WARNING on tip/sched/core tip/master v5.18-rc7 next-20220520]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/intel-lab-lkp/linux/commits/Josh-Don/sched-core-add-forced-idle-accounting-for-cgroups/20220521-075311
base:   https://git.kernel.org/pub/scm/linux/kernel/git/tj/cgroup.git for-next
config: um-i386_defconfig (https://download.01.org/0day-ci/archive/20220521/202205211108.a5tqwV7v-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-1) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/0575a42c9f10cda618b09b949cc42fe97abea479
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Josh-Don/sched-core-add-forced-idle-accounting-for-cgroups/20220521-075311
        git checkout 0575a42c9f10cda618b09b949cc42fe97abea479
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=um SUBARCH=i386 SHELL=/bin/bash kernel/cgroup/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   In file included from include/linux/math.h:6,
                    from include/linux/math64.h:6,
                    from include/linux/time64.h:5,
                    from include/linux/restart_block.h:10,
                    from include/linux/thread_info.h:14,
                    from include/asm-generic/current.h:5,
                    from ./arch/um/include/generated/asm/current.h:1,
                    from include/linux/sched.h:12,
                    from include/linux/cgroup.h:12,
                    from kernel/cgroup/cgroup-internal.h:5,
                    from kernel/cgroup/rstat.c:2:
   kernel/cgroup/rstat.c: In function 'cgroup_base_stat_cputime_show':
>> arch/x86/include/asm/div64.h:30:17: warning: 'forceidle_time' is used uninitialized [-Wuninitialized]
      30 |                 asm("" : "=a" (__low), "=d" (__high) : "A" (n));\
         |                 ^~~
   kernel/cgroup/rstat.c:465:28: note: 'forceidle_time' was declared here
     465 |         u64 __maybe_unused forceidle_time;
         |                            ^~~~~~~~~~~~~~


vim +/forceidle_time +30 arch/x86/include/asm/div64.h

428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20   9  
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  10  /*
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  11   * do_div() is NOT a C function. It wants to return
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  12   * two values (the quotient and the remainder), but
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  13   * since that doesn't work very well in C, what it
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  14   * does is:
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  15   *
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  16   * - modifies the 64-bit dividend _in_place_
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  17   * - returns the 32-bit remainder
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  18   *
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  19   * This ends up being the most efficient "calling
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  20   * convention" on x86.
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  21   */
925a09b27fc735 include/asm-x86/div64.h      Joe Perches               2008-03-23  22  #define do_div(n, base)						\
925a09b27fc735 include/asm-x86/div64.h      Joe Perches               2008-03-23  23  ({								\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  24  	unsigned long __upper, __low, __high, __mod, __base;	\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  25  	__base = (base);					\
668b4484660618 arch/x86/include/asm/div64.h Sebastian Andrzej Siewior 2011-11-30  26  	if (__builtin_constant_p(__base) && is_power_of_2(__base)) { \
668b4484660618 arch/x86/include/asm/div64.h Sebastian Andrzej Siewior 2011-11-30  27  		__mod = n & (__base - 1);			\
668b4484660618 arch/x86/include/asm/div64.h Sebastian Andrzej Siewior 2011-11-30  28  		n >>= ilog2(__base);				\
668b4484660618 arch/x86/include/asm/div64.h Sebastian Andrzej Siewior 2011-11-30  29  	} else {						\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20 @30  		asm("" : "=a" (__low), "=d" (__high) : "A" (n));\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  31  		__upper = __high;				\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  32  		if (__high) {					\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  33  			__upper = __high % (__base);		\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  34  			__high = __high / (__base);		\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  35  		}						\
925a09b27fc735 include/asm-x86/div64.h      Joe Perches               2008-03-23  36  		asm("divl %2" : "=a" (__low), "=d" (__mod)	\
925a09b27fc735 include/asm-x86/div64.h      Joe Perches               2008-03-23  37  			: "rm" (__base), "0" (__low), "1" (__upper));	\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  38  		asm("" : "=A" (n) : "a" (__low), "d" (__high));	\
668b4484660618 arch/x86/include/asm/div64.h Sebastian Andrzej Siewior 2011-11-30  39  	}							\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  40  	__mod;							\
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  41  })
428c5a2339f6d5 include/asm-x86/div64.h      Chris Snook               2007-10-20  42  

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

  parent reply	other threads:[~2022-05-21  3:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-20 23:51 [PATCH v2] sched/core: add forced idle accounting for cgroups Josh Don
2022-05-21  1:31 ` kernel test robot
2022-05-21  2:38 ` kernel test robot
2022-05-21  3:19 ` kernel test robot [this message]
2022-05-21 10:00 ` Peter Zijlstra
2022-05-23 21:19   ` Josh Don
2022-05-23 11:27 ` Dan Carpenter
2022-05-23 21:20   ` Josh Don

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=202205211108.a5tqwV7v-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=CruzZhao@linux.alibaba.com \
    --cc=bristot@redhat.com \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=joshdon@google.com \
    --cc=juri.lelli@redhat.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=rostedt@goodmis.org \
    --cc=tj@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox