Re: [PATCH] LoongArch: Refactor cache probe and flush methods

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Huacai,

I love your patch! Yet something to improve:

[auto build test ERROR on soc/for-next]
[also build test ERROR on linus/master v6.0-rc5 next-20220916]
[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#_base_tree_information]

url:    https://github.com/intel-lab-lkp/linux/commits/Huacai-Chen/LoongArch-Refactor-cache-probe-and-flush-methods/20220917-145926
base:   https://git.kernel.org/pub/scm/linux/kernel/git/soc/soc.git for-next
config: loongarch-randconfig-r023-20220916 (https://download.01.org/0day-ci/archive/20220917/202209171822.T8lQdBUd-lkp@xxxxxxxxx/config)
compiler: loongarch64-linux-gcc (GCC) 12.1.0
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://github.com/intel-lab-lkp/linux/commit/d3b59542d7583a2251e0a1f69331e57565de0f51
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Huacai-Chen/LoongArch-Refactor-cache-probe-and-flush-methods/20220917-145926
        git checkout d3b59542d7583a2251e0a1f69331e57565de0f51
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=loongarch SHELL=/bin/bash

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

All errors (new ones prefixed by >>):

   arch/loongarch/mm/cache.c:28:6: warning: no previous prototype for 'cache_error_setup' [-Wmissing-prototypes]
      28 | void cache_error_setup(void)
         |      ^~~~~~~~~~~~~~~~~
   arch/loongarch/mm/cache.c: In function 'flush_cache_leaf':
>> arch/loongarch/mm/cache.c:62:34: error: 'NODE_ADDRSPACE_SHIFT' undeclared (first use in this function)
      62 |                 addr += (1ULL << NODE_ADDRSPACE_SHIFT);
         |                                  ^~~~~~~~~~~~~~~~~~~~
   arch/loongarch/mm/cache.c:62:34: note: each undeclared identifier is reported only once for each function it appears in


vim +/NODE_ADDRSPACE_SHIFT +62 arch/loongarch/mm/cache.c

    43	
    44	static void flush_cache_leaf(unsigned int leaf)
    45	{
    46		int i, j, nr_nodes;
    47		uint64_t addr = CSR_DMW0_BASE;
    48		struct cache_desc *cdesc = current_cpu_data.cache_leaves + leaf;
    49	
    50		nr_nodes = cache_private(cdesc) ? 1 : loongson_sysconf.nr_nodes;
    51	
    52		do {
    53			for (i = 0; i < cdesc->sets; i++) {
    54				for (j = 0; j < cdesc->ways; j++) {
    55					flush_cache_line(leaf, addr);
    56					addr++;
    57				}
    58	
    59				addr -= cdesc->ways;
    60				addr += cdesc->linesz;
    61			}
  > 62			addr += (1ULL << NODE_ADDRSPACE_SHIFT);
    63		} while (--nr_nodes > 0);
    64	}
    65	

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



[Index of Archives]     [Linux Kernel]     [Kernel Newbies]     [x86 Platform Driver]     [Netdev]     [Linux Wireless]     [Netfilter]     [Bugtraq]     [Linux Filesystems]     [Yosemite Discussion]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]

  Powered by Linux