diff options
author | Gautam Dawar | 2022-03-30 23:33:52 +0530 |
---|---|---|
committer | Michael S. Tsirkin | 2022-05-31 12:44:30 -0400 |
commit | a0c95f201170bd559737d3cdc8a950aea62f29c6 (patch) | |
tree | c97c0587b979fb484e0f0e226035805fb93dad78 /drivers/vhost | |
parent | 3ace88bd37436abc84906312146fe5158a469142 (diff) |
vhost-vdpa: introduce uAPI to get the number of address spaces
This patch introduces the uAPI for getting the number of address
spaces supported by this vDPA device.
Signed-off-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Gautam Dawar <gdawar@xilinx.com>
Message-Id: <20220330180436.24644-13-gdawar@xilinx.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/vhost')
-rw-r--r-- | drivers/vhost/vdpa.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c index 92f78df0f685..a017011ad1f5 100644 --- a/drivers/vhost/vdpa.c +++ b/drivers/vhost/vdpa.c @@ -563,6 +563,9 @@ static long vhost_vdpa_unlocked_ioctl(struct file *filep, r = copy_to_user(argp, &v->vdpa->ngroups, sizeof(v->vdpa->ngroups)); break; + case VHOST_VDPA_GET_AS_NUM: + r = copy_to_user(argp, &v->vdpa->nas, sizeof(v->vdpa->nas)); + break; case VHOST_SET_LOG_BASE: case VHOST_SET_LOG_FD: r = -ENOIOCTLCMD; |