[airlied:01.01-gsp-rm 87/180] drivers/gpu/drm/nouveau/nvkm/core/firmware.c:213:68: error: passing argument 3 of 'dma_alloc_coherent' from incompatible pointer type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   git://people.freedesktop.org/~airlied/linux.git 01.01-gsp-rm
head:   6be95d5e52818808565790c5ee3fd5569263bd36
commit: e7be44d4385351aaf43f09786faa38d153722673 [87/180] drm/nouveau/acr: use common falcon HS FW code for ACR FWs
config: microblaze-randconfig-r001-20221023 (attached as .config)
compiler: microblaze-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
        git remote add airlied git://people.freedesktop.org/~airlied/linux.git
        git fetch --no-tags airlied 01.01-gsp-rm
        git checkout e7be44d4385351aaf43f09786faa38d153722673
        # 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=microblaze SHELL=/bin/bash drivers/gpu/drm/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

   drivers/gpu/drm/nouveau/nvkm/core/firmware.c: In function 'nvkm_firmware_ctor':
>> drivers/gpu/drm/nouveau/nvkm/core/firmware.c:213:68: error: passing argument 3 of 'dma_alloc_coherent' from incompatible pointer type [-Werror=incompatible-pointer-types]
     213 |                 fw->img = dma_alloc_coherent(fw->device->dev, len, &fw->phys, GFP_KERNEL);
         |                                                                    ^~~~~~~~~
         |                                                                    |
         |                                                                    u64 * {aka long long unsigned int *}
   In file included from arch/microblaze/include/asm/pci.h:14,
                    from include/linux/pci.h:1910,
                    from drivers/gpu/drm/nouveau/include/nvif/os.h:8,
                    from drivers/gpu/drm/nouveau/include/nvkm/core/os.h:4,
                    from drivers/gpu/drm/nouveau/include/nvkm/core/oclass.h:3,
                    from drivers/gpu/drm/nouveau/include/nvkm/core/device.h:4,
                    from drivers/gpu/drm/nouveau/nvkm/core/firmware.c:22:
   include/linux/dma-mapping.h:426:29: note: expected 'dma_addr_t *' {aka 'unsigned int *'} but argument is of type 'u64 *' {aka 'long long unsigned int *'}
     426 |                 dma_addr_t *dma_handle, gfp_t gfp)
         |                 ~~~~~~~~~~~~^~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/dma_alloc_coherent +213 drivers/gpu/drm/nouveau/nvkm/core/firmware.c

   196	
   197	int
   198	nvkm_firmware_ctor(const struct nvkm_firmware_func *func, const char *name,
   199			   struct nvkm_device *device, const void *src, int len, struct nvkm_firmware *fw)
   200	{
   201		fw->func = func;
   202		fw->name = name;
   203		fw->device = device;
   204		fw->len = len;
   205	
   206		switch (fw->func->type) {
   207		case NVKM_FIRMWARE_IMG_RAM:
   208			fw->img = kmemdup(src, fw->len, GFP_KERNEL);
   209			break;
   210		case NVKM_FIRMWARE_IMG_DMA:
   211			len = ALIGN(fw->len, PAGE_SIZE);
   212	
 > 213			fw->img = dma_alloc_coherent(fw->device->dev, len, &fw->phys, GFP_KERNEL);

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux