aboutsummaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorEli Cohen <[email protected]>2020-08-04 19:20:44 +0300
committerMichael S. Tsirkin <[email protected]>2020-08-05 19:00:23 -0400
commit23750e39d57433d0e3d89658f0bc448f9c42ff49 (patch)
tree9f377ffa73d12ea6d7b8c8a9196f5250e923eb2b /include/linux
parentaac50c0bd434794b9950181349099e709ca4edad (diff)
vdpa: Modify get_vq_state() to return error code
Modify get_vq_state() so it returns an error code. In case of hardware acceleration, the available index may be retrieved from the device, an operation that can possibly fail. Reviewed-by: Parav Pandit <[email protected]> Signed-off-by: Eli Cohen <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Michael S. Tsirkin <[email protected]> Acked-by: Jason Wang <[email protected]>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/vdpa.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/vdpa.h b/include/linux/vdpa.h
index d7399c983734..eae0bfd87d91 100644
--- a/include/linux/vdpa.h
+++ b/include/linux/vdpa.h
@@ -193,8 +193,8 @@ struct vdpa_config_ops {
bool (*get_vq_ready)(struct vdpa_device *vdev, u16 idx);
int (*set_vq_state)(struct vdpa_device *vdev, u16 idx,
const struct vdpa_vq_state *state);
- void (*get_vq_state)(struct vdpa_device *vdev, u16 idx,
- struct vdpa_vq_state *state);
+ int (*get_vq_state)(struct vdpa_device *vdev, u16 idx,
+ struct vdpa_vq_state *state);
struct vdpa_notification_area
(*get_vq_notification)(struct vdpa_device *vdev, u16 idx);
/* vq irq is not expected to be changed once DRIVER_OK is set */