public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Ming Lei <ming.lei@redhat.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	linux-kernel@vger.kernel.org, x86@kernel.org,
	Thomas Gleixner <tglx@linutronix.de>,
	Christoph Hellwig <hch@lst.de>, Jens Axboe <axboe@kernel.dk>
Subject: [tip:irq/core 8/9] lib/group_cpus.c:43:23: warning: unused function 'alloc_node_to_cpumask'
Date: Wed, 18 Jan 2023 21:34:23 +0800	[thread overview]
Message-ID: <202301182158.GgENalyU-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git irq/core
head:   6a6dcae8f486c3f3298d0767d34505121c7b0b81
commit: f7b3ea8cf72f3d6060fe08e461805181e7450a13 [8/9] genirq/affinity: Move group_cpus_evenly() into lib/
config: i386-randconfig-a003-20230116 (https://download.01.org/0day-ci/archive/20230118/202301182158.GgENalyU-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=f7b3ea8cf72f3d6060fe08e461805181e7450a13
        git remote add tip https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git
        git fetch --no-tags tip irq/core
        git checkout f7b3ea8cf72f3d6060fe08e461805181e7450a13
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash

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 >>):

>> lib/group_cpus.c:43:23: warning: unused function 'alloc_node_to_cpumask' [-Wunused-function]
   static cpumask_var_t *alloc_node_to_cpumask(void)
                         ^
>> lib/group_cpus.c:66:13: warning: unused function 'free_node_to_cpumask' [-Wunused-function]
   static void free_node_to_cpumask(cpumask_var_t *masks)
               ^
>> lib/group_cpus.c:75:13: warning: unused function 'build_node_to_cpumask' [-Wunused-function]
   static void build_node_to_cpumask(cpumask_var_t *masks)
               ^
>> lib/group_cpus.c:247:12: warning: unused function '__group_cpus_evenly' [-Wunused-function]
   static int __group_cpus_evenly(unsigned int startgrp, unsigned int numgrps,
              ^
   4 warnings generated.


vim +/alloc_node_to_cpumask +43 lib/group_cpus.c

    42	
  > 43	static cpumask_var_t *alloc_node_to_cpumask(void)
    44	{
    45		cpumask_var_t *masks;
    46		int node;
    47	
    48		masks = kcalloc(nr_node_ids, sizeof(cpumask_var_t), GFP_KERNEL);
    49		if (!masks)
    50			return NULL;
    51	
    52		for (node = 0; node < nr_node_ids; node++) {
    53			if (!zalloc_cpumask_var(&masks[node], GFP_KERNEL))
    54				goto out_unwind;
    55		}
    56	
    57		return masks;
    58	
    59	out_unwind:
    60		while (--node >= 0)
    61			free_cpumask_var(masks[node]);
    62		kfree(masks);
    63		return NULL;
    64	}
    65	
  > 66	static void free_node_to_cpumask(cpumask_var_t *masks)
    67	{
    68		int node;
    69	
    70		for (node = 0; node < nr_node_ids; node++)
    71			free_cpumask_var(masks[node]);
    72		kfree(masks);
    73	}
    74	
  > 75	static void build_node_to_cpumask(cpumask_var_t *masks)
    76	{
    77		int cpu;
    78	
    79		for_each_possible_cpu(cpu)
    80			cpumask_set_cpu(cpu, masks[cpu_to_node(cpu)]);
    81	}
    82	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests

                 reply	other threads:[~2023-01-18 14:01 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202301182158.GgENalyU-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=axboe@kernel.dk \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=llvm@lists.linux.dev \
    --cc=ming.lei@redhat.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox