From: kernel test robot <lkp@intel.com>
To: Li Chen <me@linux.beauty>,
Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <will@kernel.org>, Rob Herring <robh+dt@kernel.org>,
Frank Rowand <frowand.list@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>
Cc: kbuild-all@lists.01.org,
Linux Memory Management List <linux-mm@kvack.org>,
Li Chen <lchen@ambarella.com>,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH 1/4] of: add struct page support to rmem
Date: Sat, 16 Jul 2022 08:38:27 +0800 [thread overview]
Message-ID: <202207160854.nSdKYSY8-lkp@intel.com> (raw)
In-Reply-To: <20220711122459.13773-2-me@linux.beauty>
Hi Li,
Thank you for the patch! Perhaps something to improve:
[auto build test WARNING on robh/for-next]
[also build test WARNING on arm64/for-next/core arm-perf/for-next/perf linus/master v5.19-rc6 next-20220715]
[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/Li-Chen/add-struct-page-and-Direct-I-O-support-to-reserved-memory/20220711-202957
base: https://git.kernel.org/pub/scm/linux/kernel/git/robh/linux.git for-next
config: arm64-allyesconfig (https://download.01.org/0day-ci/archive/20220716/202207160854.nSdKYSY8-lkp@intel.com/config)
compiler: aarch64-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/8b66b4b9614f1c7bb8b2d8fac17d5a2a73acf954
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Li-Chen/add-struct-page-and-Direct-I-O-support-to-reserved-memory/20220711-202957
git checkout 8b66b4b9614f1c7bb8b2d8fac17d5a2a73acf954
# 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=arm64 SHELL=/bin/bash drivers/mailbox/ drivers/of/
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 >>):
drivers/of/of_reserved_mem.c: In function 'reserved_mem_memremap_pages':
drivers/of/of_reserved_mem.c:633:50: error: invalid application of 'sizeof' to incomplete type 'struct dev_pagemap'
633 | pgmap_rmem_dio = devm_kzalloc(dev, sizeof(*pgmap_rmem_dio), GFP_KERNEL);
| ^
drivers/of/of_reserved_mem.c:635:23: error: invalid use of undefined type 'struct dev_pagemap'
635 | pgmap_rmem_dio->range.start = rmem->base;
| ^~
drivers/of/of_reserved_mem.c:636:23: error: invalid use of undefined type 'struct dev_pagemap'
636 | pgmap_rmem_dio->range.end = rmem->base + rmem->size - 1;
| ^~
drivers/of/of_reserved_mem.c:637:23: error: invalid use of undefined type 'struct dev_pagemap'
637 | pgmap_rmem_dio->nr_range = 1;
| ^~
drivers/of/of_reserved_mem.c:638:23: error: invalid use of undefined type 'struct dev_pagemap'
638 | pgmap_rmem_dio->type = MEMORY_DEVICE_GENERIC;
| ^~
drivers/of/of_reserved_mem.c:638:32: error: 'MEMORY_DEVICE_GENERIC' undeclared (first use in this function)
638 | pgmap_rmem_dio->type = MEMORY_DEVICE_GENERIC;
| ^~~~~~~~~~~~~~~~~~~~~
drivers/of/of_reserved_mem.c:638:32: note: each undeclared identifier is reported only once for each function it appears in
In file included from include/linux/printk.h:584,
from include/linux/kernel.h:29,
from include/linux/cpumask.h:10,
from include/linux/smp.h:13,
from include/linux/lockdep.h:14,
from include/linux/mutex.h:17,
from include/linux/kernfs.h:11,
from include/linux/sysfs.h:16,
from include/linux/kobject.h:20,
from include/linux/of.h:17,
from drivers/of/of_reserved_mem.c:15:
drivers/of/of_reserved_mem.c:641:42: error: invalid use of undefined type 'struct dev_pagemap'
641 | __func__, pgmap_rmem_dio->range.start, pgmap_rmem_dio->range.end);
| ^~
include/linux/dynamic_debug.h:134:29: note: in definition of macro '__dynamic_func_call'
134 | func(&id, ##__VA_ARGS__); \
| ^~~~~~~~~~~
include/linux/dynamic_debug.h:162:9: note: in expansion of macro '_dynamic_func_call'
162 | _dynamic_func_call(fmt, __dynamic_pr_debug, \
| ^~~~~~~~~~~~~~~~~~
include/linux/printk.h:599:9: note: in expansion of macro 'dynamic_pr_debug'
599 | dynamic_pr_debug(fmt, ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~
drivers/of/of_reserved_mem.c:640:9: note: in expansion of macro 'pr_debug'
640 | pr_debug("%s, will do devm_memremap_pages, start from %llx, to %llx\n",
| ^~~~~~~~
drivers/of/of_reserved_mem.c:641:71: error: invalid use of undefined type 'struct dev_pagemap'
641 | __func__, pgmap_rmem_dio->range.start, pgmap_rmem_dio->range.end);
| ^~
include/linux/dynamic_debug.h:134:29: note: in definition of macro '__dynamic_func_call'
134 | func(&id, ##__VA_ARGS__); \
| ^~~~~~~~~~~
include/linux/dynamic_debug.h:162:9: note: in expansion of macro '_dynamic_func_call'
162 | _dynamic_func_call(fmt, __dynamic_pr_debug, \
| ^~~~~~~~~~~~~~~~~~
include/linux/printk.h:599:9: note: in expansion of macro 'dynamic_pr_debug'
599 | dynamic_pr_debug(fmt, ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~
drivers/of/of_reserved_mem.c:640:9: note: in expansion of macro 'pr_debug'
640 | pr_debug("%s, will do devm_memremap_pages, start from %llx, to %llx\n",
| ^~~~~~~~
drivers/of/of_reserved_mem.c:643:17: error: implicit declaration of function 'devm_memremap_pages'; did you mean 'devm_free_pages'? [-Werror=implicit-function-declaration]
643 | vaddr = devm_memremap_pages(dev, pgmap_rmem_dio);
| ^~~~~~~~~~~~~~~~~~~
| devm_free_pages
>> drivers/of/of_reserved_mem.c:643:15: warning: assignment to 'void *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
643 | vaddr = devm_memremap_pages(dev, pgmap_rmem_dio);
| ^
cc1: some warnings being treated as errors
vim +643 drivers/of/of_reserved_mem.c
610
611 /**
612 * reserved_mem_memremap_pages() - build struct pages for reserved mem
613 * @dev: device pointer
614 * @rmem: reserved memory region from dts, which can be get by
615 * get_reserved_mem_from_dev(dev)
616 *
617 * Returns: 0 on success or a negative error-code on failure.
618 */
619 void *reserved_mem_memremap_pages(struct device *dev, struct reserved_mem *rmem)
620 {
621 struct dev_pagemap *pgmap_rmem_dio;
622 void *vaddr;
623 struct page **pages;
624 int i;
625 unsigned long offset = 0;
626 struct page *page;
627
628 rmem->nr_pages = DIV_ROUND_UP(rmem->size, PAGE_SIZE);
629 pages = kvmalloc_array(rmem->nr_pages, sizeof(*pages), GFP_KERNEL);
630 if (!pages)
631 return ERR_PTR(-ENOMEM);
632
633 pgmap_rmem_dio = devm_kzalloc(dev, sizeof(*pgmap_rmem_dio), GFP_KERNEL);
634
635 pgmap_rmem_dio->range.start = rmem->base;
636 pgmap_rmem_dio->range.end = rmem->base + rmem->size - 1;
637 pgmap_rmem_dio->nr_range = 1;
638 pgmap_rmem_dio->type = MEMORY_DEVICE_GENERIC;
639
640 pr_debug("%s, will do devm_memremap_pages, start from %llx, to %llx\n",
641 __func__, pgmap_rmem_dio->range.start, pgmap_rmem_dio->range.end);
642
> 643 vaddr = devm_memremap_pages(dev, pgmap_rmem_dio);
--
0-DAY CI Kernel Test Service
https://01.org/lkp
next prev parent reply other threads:[~2022-07-16 0:38 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-07-11 12:24 [PATCH 0/4] add struct page and Direct I/O support to reserved memory Li Chen
2022-07-11 12:24 ` [PATCH 1/4] of: add struct page support to rmem Li Chen
2022-07-11 13:36 ` Arnd Bergmann
2022-07-11 14:51 ` Li Chen
2022-07-11 15:06 ` Arnd Bergmann
2022-07-12 3:13 ` Li Chen
2022-07-16 0:38 ` kernel test robot [this message]
2022-07-18 13:21 ` Dan Carpenter
2022-07-11 12:24 ` [PATCH 2/4] mm/sparse: skip no-map memblock check when fill_subsection_map Li Chen
2022-07-11 14:53 ` David Hildenbrand
2022-07-12 4:23 ` Li Chen
2022-07-12 7:31 ` David Hildenbrand
2022-07-12 9:31 ` Li Chen
2022-07-14 18:45 ` kernel test robot
2022-07-11 12:24 ` [PATCH 3/4] arm64: mm: move memblock_clear_nomap after __add_pages Li Chen
2022-07-11 12:24 ` [PATCH 4/4] sample/reserved_mem: Introduce a sample of struct page and dio support to no-map rmem Li Chen
2022-07-11 13:28 ` Arnd Bergmann
2022-07-12 0:26 ` Li Chen
2022-07-12 7:50 ` Arnd Bergmann
2022-07-12 9:58 ` Li Chen
2022-07-12 10:08 ` Arnd Bergmann
2022-07-12 10:20 ` Arnd Bergmann
2022-07-12 10:55 ` Li Chen
2022-07-12 12:10 ` Arnd Bergmann
2022-08-04 7:17 ` Li Chen
2022-08-04 8:24 ` Arnd Bergmann
2022-08-04 10:07 ` Li Chen
2022-08-05 14:09 ` Arnd Bergmann
2022-08-05 15:28 ` David Hildenbrand
2022-07-11 15:01 ` [PATCH 0/4] add struct page and Direct I/O support to reserved memory Christoph Hellwig
2022-07-11 16:05 ` Li Chen
2022-07-11 16:09 ` Christoph Hellwig
2022-07-12 0:14 ` Li Chen
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=202207160854.nSdKYSY8-lkp@intel.com \
--to=lkp@intel.com \
--cc=akpm@linux-foundation.org \
--cc=catalin.marinas@arm.com \
--cc=devicetree@vger.kernel.org \
--cc=frowand.list@gmail.com \
--cc=kbuild-all@lists.01.org \
--cc=lchen@ambarella.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=me@linux.beauty \
--cc=robh+dt@kernel.org \
--cc=will@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;
as well as URLs for NNTP newsgroup(s).