search for: bit_ull

Displaying 20 results from an estimated 132 matches for "bit_ull".

2020 Aug 21
3
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...^~~~~~~~~~~~~~~~~~~~~~~ This is related to the BIT macro, which uses an unsigned long literal, which is 32-bit on ARM so having a shift equal to or larger than 32 will cause this warning, such as the above, where VIRTIO_F_VERSION_1 is 32. To avoid this, use BIT_ULL, which will be an unsigned long long. This matches the size of the features field throughout this driver, which is u64 so there should be no functional change. Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Link: https://github.com/ClangBuiltLinux/linux/iss...
2020 Aug 21
3
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...^~~~~~~~~~~~~~~~~~~~~~~ This is related to the BIT macro, which uses an unsigned long literal, which is 32-bit on ARM so having a shift equal to or larger than 32 will cause this warning, such as the above, where VIRTIO_F_VERSION_1 is 32. To avoid this, use BIT_ULL, which will be an unsigned long long. This matches the size of the features field throughout this driver, which is u64 so there should be no functional change. Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Link: https://github.com/ClangBuiltLinux/linux/iss...
2020 Aug 21
0
[PATCH] vdpa/mlx5: Avoid warnings about shifts on 32-bit platforms
...^~~~~~~~~~~~~~~~~~~~~~~ > > This is related to the BIT macro, which uses an unsigned long literal, > which is 32-bit on ARM so having a shift equal to or larger than 32 will > cause this warning, such as the above, where VIRTIO_F_VERSION_1 is 32. > To avoid this, use BIT_ULL, which will be an unsigned long long. This > matches the size of the features field throughout this driver, which is > u64 so there should be no functional change. > > Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") > Link: https://github.com/...
2023 Mar 17
0
[PATCH v2 1/2] vdpa/mlx5: Extend driver support for new features
...TSO4 = 8, > + MLX5_VIRTIO_NET_F_GUEST_CSUM = 9, > + MLX5_VIRTIO_NET_F_CSUM = 10, > + MLX5_VIRTIO_NET_F_HOST_TSO6 = 11, > + MLX5_VIRTIO_NET_F_HOST_TSO4 = 12, > +}; > + > +static u16 get_features(u64 features) > { > - return (!!(features & BIT_ULL(VIRTIO_NET_F_HOST_TSO4)) << 9) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_HOST_TSO6)) << 8) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_CSUM)) << 7) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_GUEST_CSUM)) << 6); > +...
2023 Mar 21
0
[PATCH v3 1/2] vdpa/mlx5: Extend driver support for new features
...t; + MLX5_VIRTIO_NET_F_GUEST_TSO4 = 8, > + MLX5_VIRTIO_NET_F_GUEST_CSUM = 9, > + MLX5_VIRTIO_NET_F_CSUM = 10, > + MLX5_VIRTIO_NET_F_HOST_TSO6 = 11, > + MLX5_VIRTIO_NET_F_HOST_TSO4 = 12, > +}; > + > +static u16 get_features(u64 features) > { > - return (!!(features & BIT_ULL(VIRTIO_NET_F_HOST_TSO4)) << 9) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_HOST_TSO6)) << 8) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_CSUM)) << 7) | > - (!!(features & BIT_ULL(VIRTIO_NET_F_GUEST_CSUM)) << 6); > + return (!!(feature...
2023 Feb 03
6
[PATCH v3 0/6] features provisioning fixes and mlx5_vdpa support
This patchset is pre-requisite to export and provision device config attributes and features for vdpa live migration, in a way backward and forward compatibility can be retained. The follow up work [1] will need to be built around the new feature provisioning uAPI, with which it's easier to formalize migration compatibility support at the driver level. Thanks, -Siwei [1] [PATCH v3 0/4] vDPA:
2023 Jan 30
6
[PATCH 0/6] features provisioning fixes and mlx5_vdpa support
This patchset is pre-requisite to export and provision device config attributes and features for vdpa live migration, in a way backward and forward compatibility can be retained. The follow up work [1] will need to be built around the new feature provisioning uAPI, with which it's easier to formalize migration compatibility support at the driver level. Thanks, -Siwei [1] [PATCH v3 0/4] vDPA:
2023 Feb 06
7
[PATCH v4 0/6] features provisioning fixes and mlx5_vdpa support
This patchset is pre-requisite to export and provision device config attributes and features for vdpa live migration, in a way backward and forward compatibility can be retained. The follow up work [1] will need to be built around the new feature provisioning uAPI, with which it's easier to formalize migration compatibility support at the driver level. Thanks, -Siwei [1] [PATCH v3 0/4] vDPA:
2023 Jan 31
7
[PATCH v2 0/7] features provisioning fixes and mlx5_vdpa support
This patchset is pre-requisite to export and provision device config attributes and features for vdpa live migration, in a way backward and forward compatibility can be retained. The follow up work [1] will need to be built around the new feature provisioning uAPI, with which it's easier to formalize migration compatibility support at the driver level. Thanks, -Siwei [1] [PATCH v3 0/4] vDPA:
2023 Sep 09
0
[PATCH RFC v2 2/3] vhost-vdpa: introduce descriptor group backend feature
..._vdpa *v, u64 __user *featurep) { struct vdpa_device *vdpa = v->vdpa; @@ -679,6 +687,7 @@ static long vhost_vdpa_unlocked_ioctl(struct file *filep, if (copy_from_user(&features, featurep, sizeof(features))) return -EFAULT; if (features & ~(VHOST_VDPA_BACKEND_FEATURES | + BIT_ULL(VHOST_BACKEND_F_DESC_ASID) | BIT_ULL(VHOST_BACKEND_F_SUSPEND) | BIT_ULL(VHOST_BACKEND_F_RESUME))) return -EOPNOTSUPP; @@ -688,6 +697,12 @@ static long vhost_vdpa_unlocked_ioctl(struct file *filep, if ((features & BIT_ULL(VHOST_BACKEND_F_RESUME)) && !vhost_vdpa...
2014 Nov 25
2
[PATCH v4 04/42] virtio: disable virtio 1.0 in transports
.../lguest_device.c +++ b/drivers/lguest/lguest_device.c @@ -106,7 +106,8 @@ static u64 lg_get_features(struct virtio_device *vdev) if (in_features[i / 8] & (1 << (i % 8))) features |= (1ULL << i); - return features; + /* lguest is not in virtio 1.0 */ + return features & ~BIT_ULL(VIRTIO_F_VERSION_1); } /* diff --git a/drivers/misc/mic/card/mic_virtio.c b/drivers/misc/mic/card/mic_virtio.c index 6d94f04..edc77f1 100644 --- a/drivers/misc/mic/card/mic_virtio.c +++ b/drivers/misc/mic/card/mic_virtio.c @@ -82,6 +82,8 @@ static u64 mic_get_features(struct virtio_device *vdev...
2014 Nov 25
2
[PATCH v4 04/42] virtio: disable virtio 1.0 in transports
.../lguest_device.c +++ b/drivers/lguest/lguest_device.c @@ -106,7 +106,8 @@ static u64 lg_get_features(struct virtio_device *vdev) if (in_features[i / 8] & (1 << (i % 8))) features |= (1ULL << i); - return features; + /* lguest is not in virtio 1.0 */ + return features & ~BIT_ULL(VIRTIO_F_VERSION_1); } /* diff --git a/drivers/misc/mic/card/mic_virtio.c b/drivers/misc/mic/card/mic_virtio.c index 6d94f04..edc77f1 100644 --- a/drivers/misc/mic/card/mic_virtio.c +++ b/drivers/misc/mic/card/mic_virtio.c @@ -82,6 +82,8 @@ static u64 mic_get_features(struct virtio_device *vdev...
2023 Mar 22
1
[PATCH v4 1/2] vdpa/mlx5: Make VIRTIO_NET_F_MRG_RXBUF off by default
...et.c > +++ b/drivers/vdpa/mlx5/net/mlx5_vnet.c > @@ -3122,6 +3122,8 @@ static int mlx5_vdpa_dev_add(struct vdpa_mgmt_dev *v_mdev, const char *name, > return -EINVAL; > } > device_features &= add_config->device_features; > + } else { > + device_features &= ~BIT_ULL(VIRTIO_NET_F_MRG_RXBUF); > } > if (!(device_features & BIT_ULL(VIRTIO_F_VERSION_1) && > device_features & BIT_ULL(VIRTIO_F_ACCESS_PLATFORM))) { > -- > 2.38.1
2020 Jul 01
0
[PATCH v3 3/5] nouveau: fix mapping 2MB sysmem pages
...tei, u32 ptes) +{ + bool dma = false; + + nvkm_kmap(pt->memory); + while (ptes--) { + u32 datalo = nvkm_ro32(pt->memory, pt->base + ptei * 16 + 0); + u32 datahi = nvkm_ro32(pt->memory, pt->base + ptei * 16 + 4); + u64 data = (u64)datahi << 32 | datalo; + + if ((data & BIT_ULL(0)) && (data & (3ULL << 1)) != 0) { + VMM_WO064(pt, vmm, ptei * 16, data & ~BIT_ULL(0)); + dma = true; + } + ptei++; + } + nvkm_done(pt->memory); + return dma; +} + +static void +gp100_vmm_pd0_pfn(struct nvkm_vmm *vmm, struct nvkm_mmu_pt *pt, + u32 ptei, u32 ptes,...
2023 Jun 30
4
[PATCH virtio 0/4] pds_vdpa: mac, reset, and irq updates
v2 for internal review - heavily reworked NET_F_MAC patch, matches recent PR-68875 - reordered to put "clean and reset vqs" before "alloc-irq" to make them slightly simpler patches - other minor cleanups for simpler patches These are some fixes for device providing a MAC address, for allocating irq resources later to support vhost use, and for properly cleaning vq info
2023 Jun 30
4
[PATCH virtio 0/4] pds_vdpa: mac, reset, and irq updates
v2 for internal review - heavily reworked NET_F_MAC patch, matches recent PR-68875 - reordered to put "clean and reset vqs" before "alloc-irq" to make them slightly simpler patches - other minor cleanups for simpler patches These are some fixes for device providing a MAC address, for allocating irq resources later to support vhost use, and for properly cleaning vq info
2023 Sep 09
4
[PATCH RFC v2 0/4] vdpa: decouple reset of iotlb mapping from device reset
In order to reduce needlessly high setup and teardown cost of iotlb mapping during live migration, it's crucial to decouple the vhost-vdpa iotlb abstraction from the virtio device life cycle, i.e. iotlb mappings should be left intact across virtio device reset [1]. For it to work, the on-chip IOMMU parent device should implement a separate .reset_map() operation callback to restore 1:1 DMA
2023 Sep 09
4
[PATCH RFC v3 0/4] vdpa: decouple reset of iotlb mapping from device reset
In order to reduce needlessly high setup and teardown cost of iotlb mapping during live migration, it's crucial to decouple the vhost-vdpa iotlb abstraction from the virtio device life cycle, i.e. iotlb mappings should be left intact across virtio device reset [1]. For it to work, the on-chip IOMMU parent device should implement a separate .reset_map() operation callback to restore 1:1 DMA
2023 Sep 09
4
[PATCH RFC v2 0/3] vdpa: dedicated descriptor table group
Following patchset introduces dedicated group for descriptor table to reduce live migration downtime when passthrough VQ is being switched to shadow VQ. This RFC v2 is sent to incorporate the early feedback from reviewers on the uAPI and driver API part of changes, the associated driver patch set consuming ths API will come around soon along with formal submission of this series. Some initial
2023 Jul 03
0
[PATCH] vdpa: reject F_ENABLE_AFTER_DRIVER_OK if backend does not support it
...ET_BACKEND_FEATURES) { > if (copy_from_user(&features, featurep, sizeof(features))) > return -EFAULT; > + if (ops->get_backend_features) > + parent_features = ops->get_backend_features(v->vdpa); > if (features & ~(VHOST_VDPA_BACKEND_FEATURES | > BIT_ULL(VHOST_BACKEND_F_SUSPEND) | > BIT_ULL(VHOST_BACKEND_F_RESUME) | > - BIT_ULL(VHOST_BACKEND_F_ENABLE_AFTER_DRIVER_OK))) > + parent_features)) > return -EOPNOTSUPP; > if ((features & BIT_ULL(VHOST_BACKEND_F_SUSPEND)) && > !vhost_vdpa_can_suspen...