mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2026-04-08 12:02:33 +02:00
platform/mellanox: mlxbf-tmfifo: fix vring_desc.len assignment
[ Upstream commit109f4d29da] Fix warnings reported by sparse, related to incorrect type: drivers/platform/mellanox/mlxbf-tmfifo.c:284:38: warning: incorrect type in assignment (different base types) drivers/platform/mellanox/mlxbf-tmfifo.c:284:38: expected restricted __virtio32 [usertype] len drivers/platform/mellanox/mlxbf-tmfifo.c:284:38: got unsigned long Reported-by: kernel test robot <lkp@intel.com> Closes: https://lore.kernel.org/oe-kbuild-all/202404040339.S7CUIgf3-lkp@intel.com/ Fixes:78034cbece("platform/mellanox: mlxbf-tmfifo: Drop the Rx packet if no more descriptors") Signed-off-by: David Thompson <davthompson@nvidia.com> Link: https://lore.kernel.org/r/20250613214608.2250130-1-davthompson@nvidia.com Reviewed-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Ilpo Järvinen <ilpo.jarvinen@linux.intel.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
896e0d9337
commit
f5fe78cfcb
@@ -281,7 +281,8 @@ static int mlxbf_tmfifo_alloc_vrings(struct mlxbf_tmfifo *fifo,
|
||||
vring->align = SMP_CACHE_BYTES;
|
||||
vring->index = i;
|
||||
vring->vdev_id = tm_vdev->vdev.id.device;
|
||||
vring->drop_desc.len = VRING_DROP_DESC_MAX_LEN;
|
||||
vring->drop_desc.len = cpu_to_virtio32(&tm_vdev->vdev,
|
||||
VRING_DROP_DESC_MAX_LEN);
|
||||
dev = &tm_vdev->vdev.dev;
|
||||
|
||||
size = vring_size(vring->num, vring->align);
|
||||
|
||||
Reference in New Issue
Block a user