From: "Zach O'Keefe" <zokeefe@google.com>
To: kernel test robot <lkp@intel.com>
Cc: Alex Shi <alex.shi@linux.alibaba.com>,
David Hildenbrand <david@redhat.com>,
David Rientjes <rientjes@google.com>,
Matthew Wilcox <willy@infradead.org>,
Michal Hocko <mhocko@suse.com>,
Pasha Tatashin <pasha.tatashin@soleen.com>,
SeongJae Park <sj@kernel.org>, Song Liu <songliubraving@fb.com>,
Vlastimil Babka <vbabka@suse.cz>, Yang Shi <shy828301@gmail.com>,
Zi Yan <ziy@nvidia.com>,
linux-mm@kvack.org, kbuild-all@lists.01.org,
Andrea Arcangeli <aarcange@redhat.com>,
Andrew Morton <akpm@linux-foundation.org>,
Arnd Bergmann <arnd@arndb.de>,
Axel Rasmussen <axelrasmussen@google.com>,
Chris Kennelly <ckennelly@google.com>,
Chris Zankel <chris@zankel.net>, Helge Deller <deller@gmx.de>,
Hugh Dickins <hughd@google.com>,
Ivan Kokshaysky <ink@jurassic.park.msu.ru>,
"James E.J. Bottomley" <James.Bottomley@hansenpartnership.com>,
Jens Axboe <axboe@kernel.dk>,
"Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>,
Matt Turner <mattst88@gmail.com>,
Max Filippov <jcmvbkbc@gmail.com>,
Miaohe Lin <linmiaohe@huawei.com>,
Minchan Kim <minchan@kernel.org>,
Patrick Xia <patrickx@google.com>
Subject: Re: [PATCH 06/12] mm/khugepaged: remove khugepaged prefix from shared collapse functions
Date: Mon, 11 Apr 2022 12:42:00 -0500 [thread overview]
Message-ID: <CAAa6QmQGi9p9DZ3CCXshs-gzeDgrivCBJ8CBVdLsDWGGGTgbSg@mail.gmail.com> (raw)
In-Reply-To: <202204110041.MnMCeEi6-lkp@intel.com>
Sorry about this. Due to a misplaced "#ifdef CONFIG_NUMA". Fixed in
"[PATCH 05/12] mm/madvise: introduce MADV_COLLAPSE sync hugepage
collapse". Fixed now.
On Sun, Apr 10, 2022 at 12:06 PM kernel test robot <lkp@intel.com> wrote:
>
> Hi Zach,
>
> Thank you for the patch! Perhaps something to improve:
>
> [auto build test WARNING on hnaz-mm/master]
>
> url: https://github.com/intel-lab-lkp/linux/commits/Zach-O-Keefe/mm-userspace-hugepage-collapse/20220410-215722
> base: https://github.com/hnaz/linux-mm master
> config: arc-allyesconfig (https://download.01.org/0day-ci/archive/20220411/202204110041.MnMCeEi6-lkp@intel.com/config)
> compiler: arceb-elf-gcc (GCC) 11.2.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/18407cfcbdad0f4e11dfe2e40028687fc64093c5
> git remote add linux-review https://github.com/intel-lab-lkp/linux
> git fetch --no-tags linux-review Zach-O-Keefe/mm-userspace-hugepage-collapse/20220410-215722
> git checkout 18407cfcbdad0f4e11dfe2e40028687fc64093c5
> # save the config file to linux build tree
> mkdir build_dir
> COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross O=build_dir ARCH=arc SHELL=/bin/bash
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> mm/khugepaged.c: In function 'find_pmd_or_thp_or_none':
> mm/khugepaged.c:1019:9: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
> 1019 | pmd_t pmde;
> | ^~~~~
> mm/khugepaged.c: In function 'khugepaged':
> mm/khugepaged.c:2355:32: error: initialization of 'struct page * (*)(struct collapse_control *, gfp_t, int)' {aka 'struct page * (*)(struct collapse_control *, unsigned int, int)'} from incompatible pointer type 'struct page * (*)(struct collapse_control *, gfp_t)' {aka 'struct page * (*)(struct collapse_control *, unsigned int)'} [-Werror=incompatible-pointer-types]
> 2355 | .alloc_hpage = &khugepaged_alloc_page,
> | ^
> mm/khugepaged.c:2355:32: note: (near initialization for 'cc.alloc_hpage')
> mm/khugepaged.c: At top level:
> mm/khugepaged.c:2469:5: warning: no previous prototype for 'madvise_collapse_errno' [-Wmissing-prototypes]
> 2469 | int madvise_collapse_errno(enum scan_result r)
> | ^~~~~~~~~~~~~~~~~~~~~~
> mm/khugepaged.c:914:12: warning: 'khugepaged_find_target_node' defined but not used [-Wunused-function]
> 914 | static int khugepaged_find_target_node(struct collapse_control *cc)
> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~
> mm/khugepaged.c: In function 'collapse_file':
> >> mm/khugepaged.c:863:55: warning: array subscript -2147483648 is below array bounds of 'int[1]' [-Warray-bounds]
> 863 | if (max_value == cc->node_load[nid]) {
> | ~~~~~~~~~~~~~^~~~~
> mm/khugepaged.c:91:13: note: while referencing 'node_load'
> 91 | int node_load[MAX_NUMNODES];
> | ^~~~~~~~~
> mm/khugepaged.c: In function 'collapse_huge_page':
> >> mm/khugepaged.c:863:55: warning: array subscript -2147483648 is below array bounds of 'int[1]' [-Warray-bounds]
> 863 | if (max_value == cc->node_load[nid]) {
> | ~~~~~~~~~~~~~^~~~~
> mm/khugepaged.c:91:13: note: while referencing 'node_load'
> 91 | int node_load[MAX_NUMNODES];
> | ^~~~~~~~~
> cc1: some warnings being treated as errors
>
>
> vim +863 mm/khugepaged.c
>
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 847
> 18407cfcbdad0f Zach O'Keefe 2022-04-10 848 static int find_target_node(struct collapse_control *cc)
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 849 {
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 850 int nid, target_node = 0, max_value = 0;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 851
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 852 /* find first node with max normal pages hit */
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 853 for (nid = 0; nid < MAX_NUMNODES; nid++)
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 854 if (cc->node_load[nid] > max_value) {
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 855 max_value = cc->node_load[nid];
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 856 target_node = nid;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 857 }
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 858
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 859 /* do some balance if several nodes have the same hit record */
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 860 if (target_node <= cc->last_target_node)
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 861 for (nid = cc->last_target_node + 1; nid < MAX_NUMNODES;
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 862 nid++) {
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 @863 if (max_value == cc->node_load[nid]) {
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 864 target_node = nid;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 865 break;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 866 }
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 867 }
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 868
> b6a99a2eb2cc19 Zach O'Keefe 2022-04-10 869 cc->last_target_node = target_node;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 870 return target_node;
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 871 }
> b46e756f5e4703 Kirill A. Shutemov 2016-07-26 872
>
> --
> 0-DAY CI Kernel Test Service
> https://01.org/lkp
>
next prev parent reply other threads:[~2022-04-11 17:42 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-10 13:54 [PATCH 00/12] mm: userspace hugepage collapse Zach O'Keefe
2022-04-10 13:54 ` [PATCH 01/12] mm/khugepaged: record SCAN_PMD_MAPPED when scan_pmd() finds THP Zach O'Keefe
2022-04-10 13:54 ` [PATCH 02/12] mm/khugepaged: add struct collapse_control Zach O'Keefe
2022-04-10 13:54 ` [PATCH 03/12] mm/khugepaged: make hugepage allocation context-specific Zach O'Keefe
2022-04-10 17:47 ` kernel test robot
2022-04-10 17:47 ` kernel test robot
2022-04-11 17:28 ` Zach O'Keefe
2022-04-10 13:54 ` [PATCH 04/12] mm/khugepaged: add struct collapse_result Zach O'Keefe
2022-04-10 13:54 ` [PATCH 05/12] mm/madvise: introduce MADV_COLLAPSE sync hugepage collapse Zach O'Keefe
2022-04-10 16:04 ` kernel test robot
2022-04-10 16:14 ` kernel test robot
2022-04-11 17:18 ` Zach O'Keefe
2022-04-10 13:54 ` [PATCH 06/12] mm/khugepaged: remove khugepaged prefix from shared collapse functions Zach O'Keefe
2022-04-10 17:06 ` kernel test robot
2022-04-11 17:42 ` Zach O'Keefe [this message]
2022-04-10 13:54 ` [PATCH 07/12] mm/khugepaged: add flag to ignore khugepaged_max_ptes_* Zach O'Keefe
2022-04-10 13:54 ` [PATCH 08/12] mm/khugepaged: add flag to ignore page young/referenced requirement Zach O'Keefe
2022-04-10 13:54 ` [PATCH 09/12] mm/madvise: add MADV_COLLAPSE to process_madvise() Zach O'Keefe
2022-04-10 13:54 ` [PATCH 10/12] selftests/vm: modularize collapse selftests Zach O'Keefe
2022-04-10 13:54 ` [PATCH 11/12] selftests/vm: add MADV_COLLAPSE collapse context to selftests Zach O'Keefe
2022-04-10 13:54 ` [PATCH 12/12] selftests/vm: add test to verify recollapse of THPs Zach O'Keefe
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=CAAa6QmQGi9p9DZ3CCXshs-gzeDgrivCBJ8CBVdLsDWGGGTgbSg@mail.gmail.com \
--to=zokeefe@google.com \
--cc=James.Bottomley@hansenpartnership.com \
--cc=aarcange@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=alex.shi@linux.alibaba.com \
--cc=arnd@arndb.de \
--cc=axboe@kernel.dk \
--cc=axelrasmussen@google.com \
--cc=chris@zankel.net \
--cc=ckennelly@google.com \
--cc=david@redhat.com \
--cc=deller@gmx.de \
--cc=hughd@google.com \
--cc=ink@jurassic.park.msu.ru \
--cc=jcmvbkbc@gmail.com \
--cc=kbuild-all@lists.01.org \
--cc=kirill.shutemov@linux.intel.com \
--cc=linmiaohe@huawei.com \
--cc=linux-mm@kvack.org \
--cc=lkp@intel.com \
--cc=mattst88@gmail.com \
--cc=mhocko@suse.com \
--cc=minchan@kernel.org \
--cc=pasha.tatashin@soleen.com \
--cc=patrickx@google.com \
--cc=rientjes@google.com \
--cc=shy828301@gmail.com \
--cc=sj@kernel.org \
--cc=songliubraving@fb.com \
--cc=vbabka@suse.cz \
--cc=willy@infradead.org \
--cc=ziy@nvidia.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;
as well as URLs for NNTP newsgroup(s).