vdpa: allow a 32 bit vq alignment
get_vq_align returns u16 now, but that's not enough for systems/devices with 64K pages. All callers assign it to a u32 variable anyway, so let's just change the return value type to u32. Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
5038a56790
commit
425a507023
@ -226,7 +226,7 @@ static u32 ifcvf_vdpa_get_vendor_id(struct vdpa_device *vdpa_dev)
|
||||
return IFCVF_SUBSYS_VENDOR_ID;
|
||||
}
|
||||
|
||||
static u16 ifcvf_vdpa_get_vq_align(struct vdpa_device *vdpa_dev)
|
||||
static u32 ifcvf_vdpa_get_vq_align(struct vdpa_device *vdpa_dev)
|
||||
{
|
||||
return IFCVF_QUEUE_ALIGNMENT;
|
||||
}
|
||||
|
@ -435,7 +435,7 @@ static u64 vdpasim_get_vq_state(struct vdpa_device *vdpa, u16 idx)
|
||||
return vrh->last_avail_idx;
|
||||
}
|
||||
|
||||
static u16 vdpasim_get_vq_align(struct vdpa_device *vdpa)
|
||||
static u32 vdpasim_get_vq_align(struct vdpa_device *vdpa)
|
||||
{
|
||||
return VDPASIM_QUEUE_ALIGN;
|
||||
}
|
||||
|
@ -164,7 +164,7 @@ struct vdpa_config_ops {
|
||||
u64 (*get_vq_state)(struct vdpa_device *vdev, u16 idx);
|
||||
|
||||
/* Device ops */
|
||||
u16 (*get_vq_align)(struct vdpa_device *vdev);
|
||||
u32 (*get_vq_align)(struct vdpa_device *vdev);
|
||||
u64 (*get_features)(struct vdpa_device *vdev);
|
||||
int (*set_features)(struct vdpa_device *vdev, u64 features);
|
||||
void (*set_config_cb)(struct vdpa_device *vdev,
|
||||
|
Loading…
Reference in New Issue
Block a user