Re: [PATCH vfio 2/6] vfio/mlx5: Allow loading of larger images than 512 MB

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

 



On 01/01/2023 1:39, kernel test robot wrote:
Hi Yishai,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on v6.2-rc1 next-20221226]
[cannot apply to awilliam-vfio/next awilliam-vfio/for-linus]
[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/Yishai-Hadas/vfio-mlx5-Fix-UBSAN-note/20221229-181908
patch link:    https://lore.kernel.org/r/20221229100734.224388-3-yishaih%40nvidia.com
patch subject: [PATCH vfio 2/6] vfio/mlx5: Allow loading of larger images than 512 MB
config: csky-allyesconfig
compiler: csky-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/88b79e8face73c38db6ca0d13fd1c22a0fb4a818
         git remote add linux-review https://github.com/intel-lab-lkp/linux
         git fetch --no-tags linux-review Yishai-Hadas/vfio-mlx5-Fix-UBSAN-note/20221229-181908
         git checkout 88b79e8face73c38db6ca0d13fd1c22a0fb4a818
         # 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=csky olddefconfig
         COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=csky SHELL=/bin/bash drivers/block/rnbd/ drivers/vfio/pci/mlx5/

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

All warnings (new ones prefixed by >>):

    In file included from include/linux/bits.h:6,
                     from include/linux/ratelimit_types.h:5,
                     from include/linux/ratelimit.h:5,
                     from include/linux/dev_printk.h:16,
                     from include/linux/device.h:15,
                     from drivers/vfio/pci/mlx5/main.c:6:
    drivers/vfio/pci/mlx5/main.c: In function 'mlx5vf_resume_read_image_no_header':
include/vdso/bits.h:7:40: warning: left shift count >= width of type [-Wshift-count-overflow]
        7 | #define BIT(nr)                 (UL(1) << (nr))
          |                                        ^~
    drivers/vfio/pci/mlx5/main.c:25:24: note: in expansion of macro 'BIT'
       25 | #define MAX_LOAD_SIZE (BIT(__mlx5_bit_sz(load_vhca_state_in, size)) - 1)
          |                        ^~~
    drivers/vfio/pci/mlx5/main.c:568:32: note: in expansion of macro 'MAX_LOAD_SIZE'
      568 |         if (requested_length > MAX_LOAD_SIZE)
          |                                ^~~~~~~~~~~~~
    drivers/vfio/pci/mlx5/main.c: In function 'mlx5vf_resume_read_header':
include/vdso/bits.h:7:40: warning: left shift count >= width of type [-Wshift-count-overflow]
        7 | #define BIT(nr)                 (UL(1) << (nr))
          |                                        ^~
    drivers/vfio/pci/mlx5/main.c:25:24: note: in expansion of macro 'BIT'
       25 | #define MAX_LOAD_SIZE (BIT(__mlx5_bit_sz(load_vhca_state_in, size)) - 1)
          |                        ^~~
    drivers/vfio/pci/mlx5/main.c:652:51: note: in expansion of macro 'MAX_LOAD_SIZE'
      652 |                 if (vhca_buf->header_image_size > MAX_LOAD_SIZE) {
          |                                                   ^~~~~~~~~~~~~


vim +7 include/vdso/bits.h

3945ff37d2f48d Vincenzo Frascino 2020-03-20  6
3945ff37d2f48d Vincenzo Frascino 2020-03-20 @7  #define BIT(nr)			(UL(1) << (nr))
3945ff37d2f48d Vincenzo Frascino 2020-03-20  8

I'll fix as part of V1 to use BIT_ULL instead of BIT.

In the meantime, I run some extra testing over 6.2 RC2 but I get wired OOPs once the GFP_KERNEL_ACCOUNT is used over alloc_pages_bulk_array() as part of this patch.

Maybe some issue that came from the merge window in the SG area, still not sure about the root cause.

Alex,

This wasn't the case over your vfio/next which is yet over 6.1.

So, let's hold on here, once I'll have a working series over 6.2 may re-post V1.

Thanks,
Yishai




[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