* mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration
@ 2022-09-02 14:23 kernel test robot
2022-09-02 15:37 ` Qi Zheng
0 siblings, 1 reply; 3+ messages in thread
From: kernel test robot @ 2022-09-02 14:23 UTC (permalink / raw)
To: Qi Zheng; +Cc: kbuild-all, linux-kernel, 0day robot
tree: https://github.com/intel-lab-lkp/linux/commits/UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
head: 32b787e37af17f7fe75f9b9c9bb22bf044722229
commit: 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e mm: thp: fix build error with CONFIG_SHMEM disabled
date: 30 hours ago
config: sparc-randconfig-r023-20220901 (https://download.01.org/0day-ci/archive/20220902/202209022248.TEjW4Cld-lkp@intel.com/config)
compiler: sparc64-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/7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
git checkout 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
# 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=sparc 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 >>):
>> mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration
2046 | static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
| ^~~~~~~~~~~~~~~~~~
mm/khugepaged.c: In function 'khugepaged_scan_mm_slot':
mm/khugepaged.c:2076:45: error: passing argument 1 of 'khugepaged_collapse_pte_mapped_thps' from incompatible pointer type [-Werror=incompatible-pointer-types]
2076 | khugepaged_collapse_pte_mapped_thps(mm_slot);
| ^~~~~~~
| |
| struct mm_slot *
mm/khugepaged.c:2046:76: note: expected 'struct khugepaged_mm_slot *' but argument is of type 'struct mm_slot *'
2046 | static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
cc1: some warnings being treated as errors
vim +2046 mm/khugepaged.c
2045
> 2046 static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
2047 {
2048 }
2049 #endif
2050
--
0-DAY CI Kernel Test Service
https://01.org/lkp
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration
2022-09-02 14:23 mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration kernel test robot
@ 2022-09-02 15:37 ` Qi Zheng
2022-09-05 2:02 ` [kbuild-all] " Chen, Rong A
0 siblings, 1 reply; 3+ messages in thread
From: Qi Zheng @ 2022-09-02 15:37 UTC (permalink / raw)
To: kernel test robot, Andrew Morton; +Cc: kbuild-all, linux-kernel
On 2022/9/2 22:23, kernel test robot wrote:
> tree: https://github.com/intel-lab-lkp/linux/commits/UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
> head: 32b787e37af17f7fe75f9b9c9bb22bf044722229
> commit: 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e mm: thp: fix build error with CONFIG_SHMEM disabled
> date: 30 hours ago
> config: sparc-randconfig-r023-20220901 (https://download.01.org/0day-ci/archive/20220902/202209022248.TEjW4Cld-lkp@intel.com/config)
> compiler: sparc64-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/7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
> git remote add linux-review https://github.com/intel-lab-lkp/linux
> git fetch --no-tags linux-review UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
> git checkout 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
> # 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=sparc 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 >>):
>
>>> mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration
> 2046 | static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
> | ^~~~~~~~~~~~~~~~~~
> mm/khugepaged.c: In function 'khugepaged_scan_mm_slot':
> mm/khugepaged.c:2076:45: error: passing argument 1 of 'khugepaged_collapse_pte_mapped_thps' from incompatible pointer type [-Werror=incompatible-pointer-types]
> 2076 | khugepaged_collapse_pte_mapped_thps(mm_slot);
> | ^~~~~~~
> | |
> | struct mm_slot *
It looks like the robot tested "mm: thp: fix build error with
CONFIG_SHMEM disabled" alone without "[PATCH v2 2/7] mm: thp: convert to
use common struct mm_slot". So this is a false positive.
> mm/khugepaged.c:2046:76: note: expected 'struct khugepaged_mm_slot *' but argument is of type 'struct mm_slot *'
> 2046 | static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
> cc1: some warnings being treated as errors
>
>
> vim +2046 mm/khugepaged.c
>
> 2045
>> 2046 static void khugepaged_collapse_pte_mapped_thps(struct khugepaged_mm_slot *mm_slot)
> 2047 {
> 2048 }
> 2049 #endif
> 2050
>
--
Thanks,
Qi
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [kbuild-all] Re: mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration
2022-09-02 15:37 ` Qi Zheng
@ 2022-09-05 2:02 ` Chen, Rong A
0 siblings, 0 replies; 3+ messages in thread
From: Chen, Rong A @ 2022-09-05 2:02 UTC (permalink / raw)
To: Qi Zheng, kernel test robot, Andrew Morton; +Cc: kbuild-all, linux-kernel
On 9/2/2022 11:37 PM, Qi Zheng wrote:
>
>
> On 2022/9/2 22:23, kernel test robot wrote:
>> tree:
>> https://github.com/intel-lab-lkp/linux/commits/UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
>>
>> head: 32b787e37af17f7fe75f9b9c9bb22bf044722229
>> commit: 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e mm: thp: fix build
>> error with CONFIG_SHMEM disabled
>> date: 30 hours ago
>> config: sparc-randconfig-r023-20220901
>> (https://download.01.org/0day-ci/archive/20220902/202209022248.TEjW4Cld-lkp@intel.com/config)
>>
>> compiler: sparc64-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/7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
>>
>> git remote add linux-review
>> https://github.com/intel-lab-lkp/linux
>> git fetch --no-tags linux-review
>> UPDATE-20220901-154717/Qi-Zheng/add-common-struct-mm_slot-and-use-it-in-THP-and-KSM/20220831-112149
>>
>> git checkout 7ad02cf1645071c2bf1ed6ae0e48907aa0a3119e
>> # 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=sparc 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 >>):
>>
>>>> mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot'
>>>> declared inside parameter list will not be visible outside of this
>>>> definition or declaration
>> 2046 | static void khugepaged_collapse_pte_mapped_thps(struct
>> khugepaged_mm_slot *mm_slot)
>> |
>> ^~~~~~~~~~~~~~~~~~
>> mm/khugepaged.c: In function 'khugepaged_scan_mm_slot':
>> mm/khugepaged.c:2076:45: error: passing argument 1 of
>> 'khugepaged_collapse_pte_mapped_thps' from incompatible pointer type
>> [-Werror=incompatible-pointer-types]
>> 2076 | khugepaged_collapse_pte_mapped_thps(mm_slot);
>> | ^~~~~~~
>> | |
>> | struct mm_slot *
>
> It looks like the robot tested "mm: thp: fix build error with
> CONFIG_SHMEM disabled" alone without "[PATCH v2 2/7] mm: thp: convert to
> use common struct mm_slot". So this is a false positive.
Hi Qi,
Thanks for the explanation, you are right, the robot was considered this
patch as a replacement of "[PATCH v2 2/7] mm: thp: convert to use common
struct mm_slot".
Best Regards,
Rong Chen
>
>> mm/khugepaged.c:2046:76: note: expected 'struct khugepaged_mm_slot
>> *' but argument is of type 'struct mm_slot *'
>> 2046 | static void khugepaged_collapse_pte_mapped_thps(struct
>> khugepaged_mm_slot *mm_slot)
>> |
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
>> cc1: some warnings being treated as errors
>>
>>
>> vim +2046 mm/khugepaged.c
>>
>> 2045
>>> 2046 static void khugepaged_collapse_pte_mapped_thps(struct
>>> khugepaged_mm_slot *mm_slot)
>> 2047 {
>> 2048 }
>> 2049 #endif
>> 2050
>>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-09-05 2:02 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-02 14:23 mm/khugepaged.c:2046:56: warning: 'struct khugepaged_mm_slot' declared inside parameter list will not be visible outside of this definition or declaration kernel test robot
2022-09-02 15:37 ` Qi Zheng
2022-09-05 2:02 ` [kbuild-all] " Chen, Rong A
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®