virtualization.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] vdpa: Consider device id larger than 31
@ 2021-11-25 18:09 Parav Pandit via Virtualization
  2021-11-26  2:48 ` Jason Wang
  0 siblings, 1 reply; 5+ messages in thread
From: Parav Pandit via Virtualization @ 2021-11-25 18:09 UTC (permalink / raw)
  To: virtualization, mst, jasowang
  Cc: kbuild-all, lkp, kbuild, linux-kernel, edumazet, elic,
	Dan Carpenter

virtio device id value can be more than 31. Hence, use BIT_ULL in
assignment.

Fixes: 33b347503f01 ("vdpa: Define vdpa mgmt device, ops and a netlink interface")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Parav Pandit <parav@nvidia.com>
---
 drivers/vdpa/vdpa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/vdpa/vdpa.c b/drivers/vdpa/vdpa.c
index 7332a74a4b00..e91c71aeeddf 100644
--- a/drivers/vdpa/vdpa.c
+++ b/drivers/vdpa/vdpa.c
@@ -404,7 +404,7 @@ static int vdpa_mgmtdev_fill(const struct vdpa_mgmt_dev *mdev, struct sk_buff *m
 		goto msg_err;
 
 	while (mdev->id_table[i].device) {
-		supported_classes |= BIT(mdev->id_table[i].device);
+		supported_classes |= BIT_ULL(mdev->id_table[i].device);
 		i++;
 	}
 
-- 
2.26.2

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-11-29  7:22 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-11-25 18:09 [PATCH] vdpa: Consider device id larger than 31 Parav Pandit via Virtualization
2021-11-26  2:48 ` Jason Wang
     [not found]   ` <20211128071435.GB99190@mtl-vdi-166.wap.labs.mlnx>
2021-11-28  7:45     ` Michael S. Tsirkin
2021-11-29  6:58     ` Dan Carpenter
2021-11-29  7:22       ` Parav Pandit via Virtualization

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).