[awilliam-vfio:next 2/11] drivers/vfio/vfio_iommu_type1.c:2147:35: warning: cast to smaller integer type 'enum iommu_cap' from 'void *'

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

 



tree:   https://github.com/awilliam/linux-vfio.git next
head:   7654a8881a54c335f176c7dc0a923480228497de
commit: eed20c782aea57b7efb42af2905dc381268b21e9 [2/11] vfio/type1: Simplify bus_type determination
config: x86_64-randconfig-a001 (https://download.01.org/0day-ci/archive/20220701/202207011538.py9XU340-lkp@xxxxxxxxx/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project a9119143a2d1f4d0d0bc1fe0d819e5351b4e0deb)
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/awilliam/linux-vfio/commit/eed20c782aea57b7efb42af2905dc381268b21e9
        git remote add awilliam-vfio https://github.com/awilliam/linux-vfio.git
        git fetch --no-tags awilliam-vfio next
        git checkout eed20c782aea57b7efb42af2905dc381268b21e9
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/vfio/

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

All warnings (new ones prefixed by >>):

>> drivers/vfio/vfio_iommu_type1.c:2147:35: warning: cast to smaller integer type 'enum iommu_cap' from 'void *' [-Wvoid-pointer-to-enum-cast]
           return device_iommu_capable(dev, (enum iommu_cap)data);
                                            ^~~~~~~~~~~~~~~~~~~~
   1 warning generated.


vim +2147 drivers/vfio/vfio_iommu_type1.c

  2143	
  2144	/* Redundantly walks non-present capabilities to simplify caller */
  2145	static int vfio_iommu_device_capable(struct device *dev, void *data)
  2146	{
> 2147		return device_iommu_capable(dev, (enum iommu_cap)data);
  2148	}
  2149	

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



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux