dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: kbuild test robot <lkp@intel.com>
Cc: kbuild-all@lists.01.org, Thomas Zimmermann <tzimmermann@suse.de>,
	sam@ravnborg.org, dri-devel@lists.freedesktop.org,
	airlied@redhat.com, sean@poorly.run, emil.velikov@collabora.com
Subject: Re: [PATCH 3/3] drm/udl: Switch to SHMEM
Date: Wed, 30 Oct 2019 08:15:59 +0800	[thread overview]
Message-ID: <201910300810.2EC0SwHS%lkp@intel.com> (raw)
In-Reply-To: <20191028084549.30243-4-tzimmermann@suse.de>

[-- Attachment #1: Type: text/plain, Size: 4329 bytes --]

Hi Thomas,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on linus/master]
[cannot apply to v5.4-rc5 next-20191029]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Thomas-Zimmermann/drm-udl-Convert-to-SHMEM/20191030-065855
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 23fdb198ae81f47a574296dab5167c5e136a02ba
config: nds32-allyesconfig (attached as .config)
compiler: nds32le-linux-gcc (GCC) 8.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=8.1.0 make.cross ARCH=nds32 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/gpu/drm/udl/udl_gem.c: In function 'udl_gem_object_mmap':
   drivers/gpu/drm/udl/udl_gem.c:41:27: error: passing argument 1 of 'drm_gem_shmem_mmap' from incompatible pointer type [-Werror=incompatible-pointer-types]
     ret = drm_gem_shmem_mmap(obj, vma);
                              ^~~
   In file included from drivers/gpu/drm/udl/udl_gem.c:10:
   include/drm/drm_gem_shmem_helper.h:146:37: note: expected 'struct file *' but argument is of type 'struct drm_gem_object *'
    int drm_gem_shmem_mmap(struct file *filp, struct vm_area_struct *vma);
                           ~~~~~~~~~~~~~^~~~
   drivers/gpu/drm/udl/udl_gem.c: At top level:
   drivers/gpu/drm/udl/udl_gem.c:61:3: error: 'const struct drm_gem_object_funcs' has no member named 'mmap'; did you mean 'vmap'?
     .mmap = udl_gem_object_mmap,
      ^~~~
      vmap
>> drivers/gpu/drm/udl/udl_gem.c:61:10: error: initialization of 'const struct vm_operations_struct *' from incompatible pointer type 'int (*)(struct drm_gem_object *, struct vm_area_struct *)' [-Werror=incompatible-pointer-types]
     .mmap = udl_gem_object_mmap,
             ^~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/udl/udl_gem.c:61:10: note: (near initialization for 'udl_gem_object_funcs.vm_ops')
   cc1: some warnings being treated as errors

vim +61 drivers/gpu/drm/udl/udl_gem.c

     8	
     9	#include <drm/drm_drv.h>
  > 10	#include <drm/drm_gem_shmem_helper.h>
    11	#include <drm/drm_mode.h>
    12	#include <drm/drm_prime.h>
    13	
    14	#include "udl_drv.h"
    15	
    16	/*
    17	 * GEM object funcs
    18	 */
    19	
    20	static void udl_gem_object_free_object(struct drm_gem_object *obj)
    21	{
    22		struct drm_gem_shmem_object *shmem = to_drm_gem_shmem_obj(obj);
    23	
    24		/* Fbdev emulation vmaps the buffer. Unmap it here for consistency
    25		 * with the original udl GEM code.
    26		 *
    27		 * TODO: Switch to generic fbdev emulation and release the
    28		 *       GEM object with drm_gem_shmem_free_object().
    29		 */
    30		if (shmem->vaddr)
    31			drm_gem_shmem_vunmap(obj, shmem->vaddr);
    32	
    33		drm_gem_shmem_free_object(obj);
    34	}
    35	
    36	static int udl_gem_object_mmap(struct drm_gem_object *obj,
    37				       struct vm_area_struct *vma)
    38	{
    39		int ret;
    40	
    41		ret = drm_gem_shmem_mmap(obj, vma);
    42		if (ret)
    43			return ret;
    44	
    45		vma->vm_page_prot = vm_get_page_prot(vma->vm_flags);
    46		if (obj->import_attach)
    47			vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot);
    48		vma->vm_page_prot = pgprot_decrypted(vma->vm_page_prot);
    49	
    50		return 0;
    51	}
    52	
    53	static const struct drm_gem_object_funcs udl_gem_object_funcs = {
    54		.free = udl_gem_object_free_object,
    55		.print_info = drm_gem_shmem_print_info,
    56		.pin = drm_gem_shmem_pin,
    57		.unpin = drm_gem_shmem_unpin,
    58		.get_sg_table = drm_gem_shmem_get_sg_table,
    59		.vmap = drm_gem_shmem_vmap,
    60		.vunmap = drm_gem_shmem_vunmap,
  > 61		.mmap = udl_gem_object_mmap,
    62	};
    63	

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53305 bytes --]

[-- Attachment #3: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com>
To: Thomas Zimmermann <tzimmermann@suse.de>
Cc: kbuild-all@lists.01.org, Thomas Zimmermann <tzimmermann@suse.de>,
	sam@ravnborg.org, dri-devel@lists.freedesktop.org,
	airlied@redhat.com, sean@poorly.run, emil.velikov@collabora.com
Subject: Re: [PATCH 3/3] drm/udl: Switch to SHMEM
Date: Wed, 30 Oct 2019 08:15:59 +0800	[thread overview]
Message-ID: <201910300810.2EC0SwHS%lkp@intel.com> (raw)
Message-ID: <20191030001559.1DdbUHCZK4E61U280-PyTdR5XgZThYNrHcmHZnuZtD8@z> (raw)
In-Reply-To: <20191028084549.30243-4-tzimmermann@suse.de>

[-- Attachment #1: Type: text/plain, Size: 4329 bytes --]

Hi Thomas,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on linus/master]
[cannot apply to v5.4-rc5 next-20191029]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]

url:    https://github.com/0day-ci/linux/commits/Thomas-Zimmermann/drm-udl-Convert-to-SHMEM/20191030-065855
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 23fdb198ae81f47a574296dab5167c5e136a02ba
config: nds32-allyesconfig (attached as .config)
compiler: nds32le-linux-gcc (GCC) 8.1.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # save the attached .config to linux build tree
        GCC_VERSION=8.1.0 make.cross ARCH=nds32 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   drivers/gpu/drm/udl/udl_gem.c: In function 'udl_gem_object_mmap':
   drivers/gpu/drm/udl/udl_gem.c:41:27: error: passing argument 1 of 'drm_gem_shmem_mmap' from incompatible pointer type [-Werror=incompatible-pointer-types]
     ret = drm_gem_shmem_mmap(obj, vma);
                              ^~~
   In file included from drivers/gpu/drm/udl/udl_gem.c:10:
   include/drm/drm_gem_shmem_helper.h:146:37: note: expected 'struct file *' but argument is of type 'struct drm_gem_object *'
    int drm_gem_shmem_mmap(struct file *filp, struct vm_area_struct *vma);
                           ~~~~~~~~~~~~~^~~~
   drivers/gpu/drm/udl/udl_gem.c: At top level:
   drivers/gpu/drm/udl/udl_gem.c:61:3: error: 'const struct drm_gem_object_funcs' has no member named 'mmap'; did you mean 'vmap'?
     .mmap = udl_gem_object_mmap,
      ^~~~
      vmap
>> drivers/gpu/drm/udl/udl_gem.c:61:10: error: initialization of 'const struct vm_operations_struct *' from incompatible pointer type 'int (*)(struct drm_gem_object *, struct vm_area_struct *)' [-Werror=incompatible-pointer-types]
     .mmap = udl_gem_object_mmap,
             ^~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/udl/udl_gem.c:61:10: note: (near initialization for 'udl_gem_object_funcs.vm_ops')
   cc1: some warnings being treated as errors

vim +61 drivers/gpu/drm/udl/udl_gem.c

     8	
     9	#include <drm/drm_drv.h>
  > 10	#include <drm/drm_gem_shmem_helper.h>
    11	#include <drm/drm_mode.h>
    12	#include <drm/drm_prime.h>
    13	
    14	#include "udl_drv.h"
    15	
    16	/*
    17	 * GEM object funcs
    18	 */
    19	
    20	static void udl_gem_object_free_object(struct drm_gem_object *obj)
    21	{
    22		struct drm_gem_shmem_object *shmem = to_drm_gem_shmem_obj(obj);
    23	
    24		/* Fbdev emulation vmaps the buffer. Unmap it here for consistency
    25		 * with the original udl GEM code.
    26		 *
    27		 * TODO: Switch to generic fbdev emulation and release the
    28		 *       GEM object with drm_gem_shmem_free_object().
    29		 */
    30		if (shmem->vaddr)
    31			drm_gem_shmem_vunmap(obj, shmem->vaddr);
    32	
    33		drm_gem_shmem_free_object(obj);
    34	}
    35	
    36	static int udl_gem_object_mmap(struct drm_gem_object *obj,
    37				       struct vm_area_struct *vma)
    38	{
    39		int ret;
    40	
    41		ret = drm_gem_shmem_mmap(obj, vma);
    42		if (ret)
    43			return ret;
    44	
    45		vma->vm_page_prot = vm_get_page_prot(vma->vm_flags);
    46		if (obj->import_attach)
    47			vma->vm_page_prot = pgprot_writecombine(vma->vm_page_prot);
    48		vma->vm_page_prot = pgprot_decrypted(vma->vm_page_prot);
    49	
    50		return 0;
    51	}
    52	
    53	static const struct drm_gem_object_funcs udl_gem_object_funcs = {
    54		.free = udl_gem_object_free_object,
    55		.print_info = drm_gem_shmem_print_info,
    56		.pin = drm_gem_shmem_pin,
    57		.unpin = drm_gem_shmem_unpin,
    58		.get_sg_table = drm_gem_shmem_get_sg_table,
    59		.vmap = drm_gem_shmem_vmap,
    60		.vunmap = drm_gem_shmem_vunmap,
  > 61		.mmap = udl_gem_object_mmap,
    62	};
    63	

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

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 53305 bytes --]

[-- Attachment #3: Type: text/plain, Size: 159 bytes --]

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

  reply	other threads:[~2019-10-30  0:16 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-10-28  8:45 [PATCH 0/3] drm/udl: Convert to SHMEM Thomas Zimmermann
2019-10-28  8:45 ` [PATCH 1/3] drm/udl: Remove flags field from struct udl_gem_object Thomas Zimmermann
2019-11-05 11:05   ` Gerd Hoffmann
2019-10-28  8:45 ` [PATCH 2/3] drm/udl: Allocate GEM object via struct drm_driver.gem_create_object Thomas Zimmermann
2019-11-05 11:05   ` Gerd Hoffmann
2019-10-28  8:45 ` [PATCH 3/3] drm/udl: Switch to SHMEM Thomas Zimmermann
2019-10-30  0:15   ` kbuild test robot [this message]
2019-10-30  0:15     ` kbuild test robot
2019-10-31 12:53   ` kbuild test robot
2019-10-31 12:53     ` kbuild test robot
2019-11-05 11:05   ` Gerd Hoffmann
2019-11-06  8:22     ` Thomas Zimmermann
2019-10-28  8:48 ` [PATCH 0/3] drm/udl: Convert " Thomas Zimmermann
2019-10-28  8:48   ` Thomas Zimmermann

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=201910300810.2EC0SwHS%lkp@intel.com \
    --to=lkp@intel.com \
    --cc=airlied@redhat.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=emil.velikov@collabora.com \
    --cc=kbuild-all@lists.01.org \
    --cc=sam@ravnborg.org \
    --cc=sean@poorly.run \
    --cc=tzimmermann@suse.de \
    /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