Re: [PATCH] mm-page_alloc-use-static-global-work_struct-for-draining-per-cpu-pages-fix

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

 



Hi Michal,

[auto build test ERROR on mmotm/master]
[also build test ERROR on v4.10-rc7 next-20170207]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Michal-Hocko/mm-page_alloc-use-static-global-work_struct-for-draining-per-cpu-pages-fix/20170208-050036
base:   git://git.cmpxchg.org/linux-mmotm.git master
config: i386-randconfig-x001-201706 (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All error/warnings (new ones prefixed by >>):

   In file included from include/asm-generic/percpu.h:6:0,
                    from arch/x86/include/asm/percpu.h:542,
                    from arch/x86/include/asm/preempt.h:5,
                    from include/linux/preempt.h:59,
                    from include/linux/spinlock.h:50,
                    from include/linux/mmzone.h:7,
                    from include/linux/gfp.h:5,
                    from include/linux/mm.h:9,
                    from mm/page_alloc.c:18:
   mm/page_alloc.c: In function 'drain_all_pages':
>> include/linux/percpu-defs.h:91:33: error: section attribute cannot be specified for local variables
     extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;  \
                                    ^
>> include/linux/percpu-defs.h:116:2: note: in expansion of macro 'DEFINE_PER_CPU_SECTION'
     DEFINE_PER_CPU_SECTION(type, name, "")
     ^~~~~~~~~~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
   include/linux/percpu-defs.h:92:26: error: section attribute cannot be specified for local variables
     __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;   \
                             ^
>> include/linux/percpu-defs.h:116:2: note: in expansion of macro 'DEFINE_PER_CPU_SECTION'
     DEFINE_PER_CPU_SECTION(type, name, "")
     ^~~~~~~~~~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
>> include/linux/percpu-defs.h:92:26: error: declaration of '__pcpu_unique_pcpu_drain' with no linkage follows extern declaration
     __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;   \
                             ^
>> include/linux/percpu-defs.h:116:2: note: in expansion of macro 'DEFINE_PER_CPU_SECTION'
     DEFINE_PER_CPU_SECTION(type, name, "")
     ^~~~~~~~~~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
   include/linux/percpu-defs.h:91:33: note: previous declaration of '__pcpu_unique_pcpu_drain' was here
     extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name;  \
                                    ^
>> include/linux/percpu-defs.h:116:2: note: in expansion of macro 'DEFINE_PER_CPU_SECTION'
     DEFINE_PER_CPU_SECTION(type, name, "")
     ^~~~~~~~~~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:44: error: section attribute cannot be specified for local variables
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
                                               ^
   include/linux/percpu-defs.h:93:44: note: in definition of macro 'DEFINE_PER_CPU_SECTION'
     extern __PCPU_ATTRS(sec) __typeof__(type) name;   \
                                               ^~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:44: error: section attribute cannot be specified for local variables
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
                                               ^
   include/linux/percpu-defs.h:95:19: note: in definition of macro 'DEFINE_PER_CPU_SECTION'
     __typeof__(type) name
                      ^~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:44: error: weak declaration of 'pcpu_drain' must be public
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
                                               ^
   include/linux/percpu-defs.h:95:19: note: in definition of macro 'DEFINE_PER_CPU_SECTION'
     __typeof__(type) name
                      ^~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
>> mm/page_alloc.c:2354:44: error: declaration of 'pcpu_drain' with no linkage follows extern declaration
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
                                               ^
   include/linux/percpu-defs.h:95:19: note: in definition of macro 'DEFINE_PER_CPU_SECTION'
     __typeof__(type) name
                      ^~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~
   mm/page_alloc.c:2354:44: note: previous declaration of 'pcpu_drain' was here
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
                                               ^
   include/linux/percpu-defs.h:93:44: note: in definition of macro 'DEFINE_PER_CPU_SECTION'
     extern __PCPU_ATTRS(sec) __typeof__(type) name;   \
                                               ^~~~
>> mm/page_alloc.c:2354:9: note: in expansion of macro 'DEFINE_PER_CPU'
     static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
            ^~~~~~~~~~~~~~

vim +2354 mm/page_alloc.c

  2348	 * When zone parameter is non-NULL, spill just the single zone's pages.
  2349	 *
  2350	 * Note that this can be extremely slow as the draining happens in a workqueue.
  2351	 */
  2352	void drain_all_pages(struct zone *zone)
  2353	{
> 2354		static DEFINE_PER_CPU(struct work_struct, pcpu_drain);
  2355		static DEFINE_MUTEX(pcpu_drain_mutex);
  2356		int cpu;
  2357	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]
  Powered by Linux