search for: print_features

Displaying 8 results from an estimated 8 matches for "print_features".

2020 Aug 21
3
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...LATION(mvdev->mdev, virtio_version_1_0)) - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_VERSION_1); - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_ACCESS_PLATFORM); + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_VERSION_1); + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_ACCESS_PLATFORM); print_features(mvdev, ndev->mvdev.mlx_features, false); return ndev->mvdev.mlx_features; } static int verify_min_features(struct mlx5_vdpa_dev *mvdev, u64 features) { - if (!(features & BIT(VIRTIO_F_ACCESS_PLATFORM))) + if (!(features & BIT_ULL(VIRTIO_F_ACCESS_PLATFORM))) return -EOPNOTSUP...
2020 Aug 21
3
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...LATION(mvdev->mdev, virtio_version_1_0)) - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_VERSION_1); - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_ACCESS_PLATFORM); + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_VERSION_1); + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_ACCESS_PLATFORM); print_features(mvdev, ndev->mvdev.mlx_features, false); return ndev->mvdev.mlx_features; } static int verify_min_features(struct mlx5_vdpa_dev *mvdev, u64 features) { - if (!(features & BIT(VIRTIO_F_ACCESS_PLATFORM))) + if (!(features & BIT_ULL(VIRTIO_F_ACCESS_PLATFORM))) return -EOPNOTSUP...
2020 Aug 10
0
linux-next: Tree for Aug 10 (drivers/vdpa/mlx5/net)
...m ../include/linux/bits.h:6:0, from ../include/linux/bitops.h:5, from ../include/linux/kernel.h:12, from ../include/linux/vdpa.h:5, from ../drivers/vdpa/mlx5/net/mlx5_vnet.c:4: ../drivers/vdpa/mlx5/net/mlx5_vnet.c: In function 'print_features': ../include/vdso/bits.h:7:26: warning: left shift count >= width of type [-Wshift-count-overflow] #define BIT(nr) (UL(1) << (nr)) ^ ../drivers/vdpa/mlx5/net/mlx5_vnet.c:27:60: note: in expansion of macro 'BIT' BIT(VIRTIO_NET_F_MQ) | BIT(VIRTIO_N...
2020 Aug 21
0
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...rtio_version_1_0)) > - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_VERSION_1); > - ndev->mvdev.mlx_features |= BIT(VIRTIO_F_ACCESS_PLATFORM); > + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_VERSION_1); > + ndev->mvdev.mlx_features |= BIT_ULL(VIRTIO_F_ACCESS_PLATFORM); > print_features(mvdev, ndev->mvdev.mlx_features, false); > return ndev->mvdev.mlx_features; > } > > static int verify_min_features(struct mlx5_vdpa_dev *mvdev, u64 features) > { > - if (!(features & BIT(VIRTIO_F_ACCESS_PLATFORM))) > + if (!(features & BIT_ULL(VIRTIO_F_ACCE...
2023 Mar 27
0
[PATCH] vdpa/mlx5: Avoid losing link state updates
...v->status_lock); > +} > + > static int mlx5_vdpa_set_driver_features(struct vdpa_device *vdev, u64 features) > { > struct mlx5_vdpa_dev *mvdev = to_mvdev(vdev); > struct mlx5_vdpa_net *ndev = to_mlx5_vdpa_ndev(mvdev); > + u64 cur_features; > int err; > > print_features(mvdev, features, true); > @@ -2310,7 +2362,11 @@ static int mlx5_vdpa_set_driver_features(struct vdpa_device *vdev, u64 features) > if (err) > return err; > > + cur_features = ndev->mvdev.actual_features; > ndev->mvdev.actual_features = features & ndev->mvdev...
2020 Jul 17
0
[PATCH vhost next 10/10] vdpa/mlx5: Add VDPA driver for supported mlx5 devices
...MMU_PLATFORM); >>> + if (mlx5_vdpa_max_qps(ndev->mvdev.max_vqs) > 1) >>> + ndev->mvdev.mlx_features |= BIT(VIRTIO_NET_F_MQ); > Also this, since multqueue requires configuration vq which is not > supported in this version. Yes. > >>> + >>> + print_features(mvdev, ndev->mvdev.mlx_features, false); >>> + return ndev->mvdev.mlx_features; >>> +} >>> + >>> +static int verify_min_features(struct mlx5_vdpa_dev *mvdev, u64 features) >>> +{ >>> + /* FIXME: qemu currently does not set all the feaures...
2023 Apr 03
0
[Patch v3] vdpa/mlx5: Avoid losing link state updates
...t vdpa_device *vdev, u64 features) > >> { > >> struct mlx5_vdpa_dev *mvdev = to_mvdev(vdev); > >> struct mlx5_vdpa_net *ndev = to_mlx5_vdpa_ndev(mvdev); > >> + u64 old; > >> int err; > >> > >> print_features(mvdev, features, true); > >> @@ -2334,7 +2439,11 @@ static int mlx5_vdpa_set_driver_features(struct vdpa_device *vdev, u64 features) > >> if (err) > >> return err; > >> > >> + old = ndev->mvdev.actual_features; > &gt...
2020 Jul 16
0
[PATCH vhost next 10/10] vdpa/mlx5: Add VDPA driver for supported mlx5 devices
...E); > + MLX5_LOG_VIO_STAT(VIRTIO_CONFIG_S_DRIVER); > + MLX5_LOG_VIO_STAT(VIRTIO_CONFIG_S_DRIVER_OK); > + MLX5_LOG_VIO_STAT(VIRTIO_CONFIG_S_FEATURES_OK); > + MLX5_LOG_VIO_STAT(VIRTIO_CONFIG_S_NEEDS_RESET); > + MLX5_LOG_VIO_STAT(VIRTIO_CONFIG_S_FAILED); > +} > + > +static void print_features(struct mlx5_vdpa_dev *mvdev, u64 features, bool set) > +{ > + if (features & ~VALID_FEATURES_MASK) > + mlx5_vdpa_warn(mvdev, "There are invalid feature bits 0x%llx\n", > + features & ~VALID_FEATURES_MASK); > + > + if (!mlx5_vdpa_debug) > + return; &...