From: kbuild test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: drivers/gpu/drm/drm_gem_shmem_helper.c:540:22: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct <anonymous>'} from type 'int'
Date: Tue, 02 Jun 2020 11:49:52 +0800 [thread overview]
Message-ID: <20200602034952.GD32005@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 5906 bytes --]
Hi Gerd,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 3d77e6a8804abcc0504c904bd6e5cdf3a5cf8162
commit: 0be895893607fb3447478d6e33dfb60644195a09 drm/shmem: switch shmem helper to &drm_gem_object_funcs.mmap
config: m68k-randconfig-r033-20200601 (attached as .config)
compiler: m68k-linux-gcc (GCC) 9.3.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
git checkout 0be895893607fb3447478d6e33dfb60644195a09
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=m68k
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>
All errors (new ones prefixed by >>, old ones prefixed by <<):
drivers/gpu/drm/drm_gem_shmem_helper.c: In function 'drm_gem_shmem_vmap_locked':
drivers/gpu/drm/drm_gem_shmem_helper.c:261:17: error: implicit declaration of function 'pgprot_writecombine' [-Werror=implicit-function-declaration]
261 | VM_MAP, pgprot_writecombine(PAGE_KERNEL));
| ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_gem_shmem_helper.c:261:17: error: incompatible type for argument 4 of 'vmap'
261 | VM_MAP, pgprot_writecombine(PAGE_KERNEL));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| int
In file included from include/asm-generic/io.h:887,
from arch/m68k/include/asm/io.h:11,
from arch/m68k/include/asm/pgtable_no.h:14,
from arch/m68k/include/asm/pgtable.h:3,
from include/linux/mm.h:99,
from include/linux/scatterlist.h:8,
from include/linux/dma-buf.h:18,
from drivers/gpu/drm/drm_gem_shmem_helper.c:6:
include/linux/vmalloc.h:119:14: note: expected 'pgprot_t' {aka 'struct <anonymous>'} but argument is of type 'int'
119 | extern void *vmap(struct page **pages, unsigned int count,
| ^~~~
drivers/gpu/drm/drm_gem_shmem_helper.c: In function 'drm_gem_shmem_mmap':
<< from drivers/gpu/drm/drm_gem_shmem_helper.c:6:
>> drivers/gpu/drm/drm_gem_shmem_helper.c:540:22: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct <anonymous>'} from type 'int'
540 | vma->vm_page_prot = pgprot_writecombine(vm_get_page_prot(vma->vm_flags));
| ^~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0be895893607fb3447478d6e33dfb60644195a09
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git remote update linus
git checkout 0be895893607fb3447478d6e33dfb60644195a09
vim +540 drivers/gpu/drm/drm_gem_shmem_helper.c
2194a63a818db7 Noralf Trønnes 2019-03-12 513
2194a63a818db7 Noralf Trønnes 2019-03-12 514 /**
2194a63a818db7 Noralf Trønnes 2019-03-12 515 * drm_gem_shmem_mmap - Memory-map a shmem GEM object
0be895893607fb Gerd Hoffmann 2019-10-16 516 * @obj: gem object
2194a63a818db7 Noralf Trønnes 2019-03-12 517 * @vma: VMA for the area to be mapped
2194a63a818db7 Noralf Trønnes 2019-03-12 518 *
2194a63a818db7 Noralf Trønnes 2019-03-12 519 * This function implements an augmented version of the GEM DRM file mmap
2194a63a818db7 Noralf Trønnes 2019-03-12 520 * operation for shmem objects. Drivers which employ the shmem helpers should
0be895893607fb Gerd Hoffmann 2019-10-16 521 * use this function as their &drm_gem_object_funcs.mmap handler.
2194a63a818db7 Noralf Trønnes 2019-03-12 522 *
2194a63a818db7 Noralf Trønnes 2019-03-12 523 * Returns:
2194a63a818db7 Noralf Trønnes 2019-03-12 524 * 0 on success or a negative error code on failure.
2194a63a818db7 Noralf Trønnes 2019-03-12 525 */
0be895893607fb Gerd Hoffmann 2019-10-16 526 int drm_gem_shmem_mmap(struct drm_gem_object *obj, struct vm_area_struct *vma)
2194a63a818db7 Noralf Trønnes 2019-03-12 527 {
2194a63a818db7 Noralf Trønnes 2019-03-12 528 struct drm_gem_shmem_object *shmem;
2194a63a818db7 Noralf Trønnes 2019-03-12 529 int ret;
2194a63a818db7 Noralf Trønnes 2019-03-12 530
0be895893607fb Gerd Hoffmann 2019-10-16 531 shmem = to_drm_gem_shmem_obj(obj);
2194a63a818db7 Noralf Trønnes 2019-03-12 532
2194a63a818db7 Noralf Trønnes 2019-03-12 533 ret = drm_gem_shmem_get_pages(shmem);
2194a63a818db7 Noralf Trønnes 2019-03-12 534 if (ret) {
2194a63a818db7 Noralf Trønnes 2019-03-12 535 drm_gem_vm_close(vma);
2194a63a818db7 Noralf Trønnes 2019-03-12 536 return ret;
2194a63a818db7 Noralf Trønnes 2019-03-12 537 }
2194a63a818db7 Noralf Trønnes 2019-03-12 538
0be895893607fb Gerd Hoffmann 2019-10-16 539 vma->vm_flags |= VM_IO | VM_MIXEDMAP | VM_DONTEXPAND | VM_DONTDUMP;
0be895893607fb Gerd Hoffmann 2019-10-16 @540 vma->vm_page_prot = pgprot_writecombine(vm_get_page_prot(vma->vm_flags));
0be895893607fb Gerd Hoffmann 2019-10-16 541 vma->vm_page_prot = pgprot_decrypted(vma->vm_page_prot);
0be895893607fb Gerd Hoffmann 2019-10-16 542 vma->vm_ops = &drm_gem_shmem_vm_ops;
2194a63a818db7 Noralf Trønnes 2019-03-12 543
2194a63a818db7 Noralf Trønnes 2019-03-12 544 /* Remove the fake offset */
2194a63a818db7 Noralf Trønnes 2019-03-12 545 vma->vm_pgoff -= drm_vma_node_start(&shmem->base.vma_node);
2194a63a818db7 Noralf Trønnes 2019-03-12 546
2194a63a818db7 Noralf Trønnes 2019-03-12 547 return 0;
2194a63a818db7 Noralf Trønnes 2019-03-12 548 }
2194a63a818db7 Noralf Trønnes 2019-03-12 549 EXPORT_SYMBOL_GPL(drm_gem_shmem_mmap);
2194a63a818db7 Noralf Trønnes 2019-03-12 550
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 24293 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com>
To: "Gerd, Hoffmann," <kraxel@redhat.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
Steven Price <steven.price@arm.com>
Subject: drivers/gpu/drm/drm_gem_shmem_helper.c:540:22: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct <anonymous>'} from type 'int'
Date: Tue, 2 Jun 2020 11:49:52 +0800 [thread overview]
Message-ID: <20200602034952.GD32005@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 5778 bytes --]
Hi Gerd,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 3d77e6a8804abcc0504c904bd6e5cdf3a5cf8162
commit: 0be895893607fb3447478d6e33dfb60644195a09 drm/shmem: switch shmem helper to &drm_gem_object_funcs.mmap
config: m68k-randconfig-r033-20200601 (attached as .config)
compiler: m68k-linux-gcc (GCC) 9.3.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
git checkout 0be895893607fb3447478d6e33dfb60644195a09
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=m68k
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp@intel.com>
All errors (new ones prefixed by >>, old ones prefixed by <<):
drivers/gpu/drm/drm_gem_shmem_helper.c: In function 'drm_gem_shmem_vmap_locked':
drivers/gpu/drm/drm_gem_shmem_helper.c:261:17: error: implicit declaration of function 'pgprot_writecombine' [-Werror=implicit-function-declaration]
261 | VM_MAP, pgprot_writecombine(PAGE_KERNEL));
| ^~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/drm_gem_shmem_helper.c:261:17: error: incompatible type for argument 4 of 'vmap'
261 | VM_MAP, pgprot_writecombine(PAGE_KERNEL));
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| int
In file included from include/asm-generic/io.h:887,
from arch/m68k/include/asm/io.h:11,
from arch/m68k/include/asm/pgtable_no.h:14,
from arch/m68k/include/asm/pgtable.h:3,
from include/linux/mm.h:99,
from include/linux/scatterlist.h:8,
from include/linux/dma-buf.h:18,
from drivers/gpu/drm/drm_gem_shmem_helper.c:6:
include/linux/vmalloc.h:119:14: note: expected 'pgprot_t' {aka 'struct <anonymous>'} but argument is of type 'int'
119 | extern void *vmap(struct page **pages, unsigned int count,
| ^~~~
drivers/gpu/drm/drm_gem_shmem_helper.c: In function 'drm_gem_shmem_mmap':
<< from drivers/gpu/drm/drm_gem_shmem_helper.c:6:
>> drivers/gpu/drm/drm_gem_shmem_helper.c:540:22: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct <anonymous>'} from type 'int'
540 | vma->vm_page_prot = pgprot_writecombine(vm_get_page_prot(vma->vm_flags));
| ^~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0be895893607fb3447478d6e33dfb60644195a09
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git remote update linus
git checkout 0be895893607fb3447478d6e33dfb60644195a09
vim +540 drivers/gpu/drm/drm_gem_shmem_helper.c
2194a63a818db7 Noralf Trønnes 2019-03-12 513
2194a63a818db7 Noralf Trønnes 2019-03-12 514 /**
2194a63a818db7 Noralf Trønnes 2019-03-12 515 * drm_gem_shmem_mmap - Memory-map a shmem GEM object
0be895893607fb Gerd Hoffmann 2019-10-16 516 * @obj: gem object
2194a63a818db7 Noralf Trønnes 2019-03-12 517 * @vma: VMA for the area to be mapped
2194a63a818db7 Noralf Trønnes 2019-03-12 518 *
2194a63a818db7 Noralf Trønnes 2019-03-12 519 * This function implements an augmented version of the GEM DRM file mmap
2194a63a818db7 Noralf Trønnes 2019-03-12 520 * operation for shmem objects. Drivers which employ the shmem helpers should
0be895893607fb Gerd Hoffmann 2019-10-16 521 * use this function as their &drm_gem_object_funcs.mmap handler.
2194a63a818db7 Noralf Trønnes 2019-03-12 522 *
2194a63a818db7 Noralf Trønnes 2019-03-12 523 * Returns:
2194a63a818db7 Noralf Trønnes 2019-03-12 524 * 0 on success or a negative error code on failure.
2194a63a818db7 Noralf Trønnes 2019-03-12 525 */
0be895893607fb Gerd Hoffmann 2019-10-16 526 int drm_gem_shmem_mmap(struct drm_gem_object *obj, struct vm_area_struct *vma)
2194a63a818db7 Noralf Trønnes 2019-03-12 527 {
2194a63a818db7 Noralf Trønnes 2019-03-12 528 struct drm_gem_shmem_object *shmem;
2194a63a818db7 Noralf Trønnes 2019-03-12 529 int ret;
2194a63a818db7 Noralf Trønnes 2019-03-12 530
0be895893607fb Gerd Hoffmann 2019-10-16 531 shmem = to_drm_gem_shmem_obj(obj);
2194a63a818db7 Noralf Trønnes 2019-03-12 532
2194a63a818db7 Noralf Trønnes 2019-03-12 533 ret = drm_gem_shmem_get_pages(shmem);
2194a63a818db7 Noralf Trønnes 2019-03-12 534 if (ret) {
2194a63a818db7 Noralf Trønnes 2019-03-12 535 drm_gem_vm_close(vma);
2194a63a818db7 Noralf Trønnes 2019-03-12 536 return ret;
2194a63a818db7 Noralf Trønnes 2019-03-12 537 }
2194a63a818db7 Noralf Trønnes 2019-03-12 538
0be895893607fb Gerd Hoffmann 2019-10-16 539 vma->vm_flags |= VM_IO | VM_MIXEDMAP | VM_DONTEXPAND | VM_DONTDUMP;
0be895893607fb Gerd Hoffmann 2019-10-16 @540 vma->vm_page_prot = pgprot_writecombine(vm_get_page_prot(vma->vm_flags));
0be895893607fb Gerd Hoffmann 2019-10-16 541 vma->vm_page_prot = pgprot_decrypted(vma->vm_page_prot);
0be895893607fb Gerd Hoffmann 2019-10-16 542 vma->vm_ops = &drm_gem_shmem_vm_ops;
2194a63a818db7 Noralf Trønnes 2019-03-12 543
2194a63a818db7 Noralf Trønnes 2019-03-12 544 /* Remove the fake offset */
2194a63a818db7 Noralf Trønnes 2019-03-12 545 vma->vm_pgoff -= drm_vma_node_start(&shmem->base.vma_node);
2194a63a818db7 Noralf Trønnes 2019-03-12 546
2194a63a818db7 Noralf Trønnes 2019-03-12 547 return 0;
2194a63a818db7 Noralf Trønnes 2019-03-12 548 }
2194a63a818db7 Noralf Trønnes 2019-03-12 549 EXPORT_SYMBOL_GPL(drm_gem_shmem_mmap);
2194a63a818db7 Noralf Trønnes 2019-03-12 550
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 24293 bytes --]
next reply other threads:[~2020-06-02 3:49 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-02 3:49 kbuild test robot [this message]
2020-06-02 3:49 ` drivers/gpu/drm/drm_gem_shmem_helper.c:540:22: error: incompatible types when assigning to type 'pgprot_t' {aka 'struct <anonymous>'} from type 'int' kbuild test robot
-- strict thread matches above, loose matches on Subject: below --
2020-06-20 1:22 kernel test robot
2020-06-20 1:22 ` kernel test robot
2020-06-20 23:50 kernel test robot
2020-06-20 23:50 ` kernel test robot
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=20200602034952.GD32005@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.