|
@@ -140,7 +140,7 @@ vu_request_to_string(unsigned int req)
|
|
REQ(VHOST_USER_SET_VRING_ENABLE),
|
|
REQ(VHOST_USER_SET_VRING_ENABLE),
|
|
REQ(VHOST_USER_SEND_RARP),
|
|
REQ(VHOST_USER_SEND_RARP),
|
|
REQ(VHOST_USER_NET_SET_MTU),
|
|
REQ(VHOST_USER_NET_SET_MTU),
|
|
- REQ(VHOST_USER_SET_SLAVE_REQ_FD),
|
|
|
|
|
|
+ REQ(VHOST_USER_SET_BACKEND_REQ_FD),
|
|
REQ(VHOST_USER_IOTLB_MSG),
|
|
REQ(VHOST_USER_IOTLB_MSG),
|
|
REQ(VHOST_USER_SET_VRING_ENDIAN),
|
|
REQ(VHOST_USER_SET_VRING_ENDIAN),
|
|
REQ(VHOST_USER_GET_CONFIG),
|
|
REQ(VHOST_USER_GET_CONFIG),
|
|
@@ -1365,7 +1365,7 @@ bool vu_set_queue_host_notifier(VuDev *dev, VuVirtq *vq, int fd,
|
|
int qidx = vq - dev->vq;
|
|
int qidx = vq - dev->vq;
|
|
int fd_num = 0;
|
|
int fd_num = 0;
|
|
VhostUserMsg vmsg = {
|
|
VhostUserMsg vmsg = {
|
|
- .request = VHOST_USER_SLAVE_VRING_HOST_NOTIFIER_MSG,
|
|
|
|
|
|
+ .request = VHOST_USER_BACKEND_VRING_HOST_NOTIFIER_MSG,
|
|
.flags = VHOST_USER_VERSION | VHOST_USER_NEED_REPLY_MASK,
|
|
.flags = VHOST_USER_VERSION | VHOST_USER_NEED_REPLY_MASK,
|
|
.size = sizeof(vmsg.payload.area),
|
|
.size = sizeof(vmsg.payload.area),
|
|
.payload.area = {
|
|
.payload.area = {
|
|
@@ -1383,7 +1383,7 @@ bool vu_set_queue_host_notifier(VuDev *dev, VuVirtq *vq, int fd,
|
|
|
|
|
|
vmsg.fd_num = fd_num;
|
|
vmsg.fd_num = fd_num;
|
|
|
|
|
|
- if (!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_SLAVE_SEND_FD)) {
|
|
|
|
|
|
+ if (!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_BACKEND_SEND_FD)) {
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -1461,9 +1461,9 @@ vu_get_protocol_features_exec(VuDev *dev, VhostUserMsg *vmsg)
|
|
*/
|
|
*/
|
|
uint64_t features = 1ULL << VHOST_USER_PROTOCOL_F_MQ |
|
|
uint64_t features = 1ULL << VHOST_USER_PROTOCOL_F_MQ |
|
|
1ULL << VHOST_USER_PROTOCOL_F_LOG_SHMFD |
|
|
1ULL << VHOST_USER_PROTOCOL_F_LOG_SHMFD |
|
|
- 1ULL << VHOST_USER_PROTOCOL_F_SLAVE_REQ |
|
|
|
|
|
|
+ 1ULL << VHOST_USER_PROTOCOL_F_BACKEND_REQ |
|
|
1ULL << VHOST_USER_PROTOCOL_F_HOST_NOTIFIER |
|
|
1ULL << VHOST_USER_PROTOCOL_F_HOST_NOTIFIER |
|
|
- 1ULL << VHOST_USER_PROTOCOL_F_SLAVE_SEND_FD |
|
|
|
|
|
|
+ 1ULL << VHOST_USER_PROTOCOL_F_BACKEND_SEND_FD |
|
|
1ULL << VHOST_USER_PROTOCOL_F_REPLY_ACK |
|
|
1ULL << VHOST_USER_PROTOCOL_F_REPLY_ACK |
|
|
1ULL << VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS;
|
|
1ULL << VHOST_USER_PROTOCOL_F_CONFIGURE_MEM_SLOTS;
|
|
|
|
|
|
@@ -1494,7 +1494,7 @@ vu_set_protocol_features_exec(VuDev *dev, VhostUserMsg *vmsg)
|
|
|
|
|
|
if (vu_has_protocol_feature(dev,
|
|
if (vu_has_protocol_feature(dev,
|
|
VHOST_USER_PROTOCOL_F_INBAND_NOTIFICATIONS) &&
|
|
VHOST_USER_PROTOCOL_F_INBAND_NOTIFICATIONS) &&
|
|
- (!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_SLAVE_REQ) ||
|
|
|
|
|
|
+ (!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_BACKEND_REQ) ||
|
|
!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_REPLY_ACK))) {
|
|
!vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_REPLY_ACK))) {
|
|
/*
|
|
/*
|
|
* The use case for using messages for kick/call is simulation, to make
|
|
* The use case for using messages for kick/call is simulation, to make
|
|
@@ -1507,7 +1507,7 @@ vu_set_protocol_features_exec(VuDev *dev, VhostUserMsg *vmsg)
|
|
* that actually enables the simulation case.
|
|
* that actually enables the simulation case.
|
|
*/
|
|
*/
|
|
vu_panic(dev,
|
|
vu_panic(dev,
|
|
- "F_IN_BAND_NOTIFICATIONS requires F_SLAVE_REQ && F_REPLY_ACK");
|
|
|
|
|
|
+ "F_IN_BAND_NOTIFICATIONS requires F_BACKEND_REQ && F_REPLY_ACK");
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
|
|
|
|
@@ -1910,7 +1910,7 @@ vu_process_message(VuDev *dev, VhostUserMsg *vmsg)
|
|
return vu_get_queue_num_exec(dev, vmsg);
|
|
return vu_get_queue_num_exec(dev, vmsg);
|
|
case VHOST_USER_SET_VRING_ENABLE:
|
|
case VHOST_USER_SET_VRING_ENABLE:
|
|
return vu_set_vring_enable_exec(dev, vmsg);
|
|
return vu_set_vring_enable_exec(dev, vmsg);
|
|
- case VHOST_USER_SET_SLAVE_REQ_FD:
|
|
|
|
|
|
+ case VHOST_USER_SET_BACKEND_REQ_FD:
|
|
return vu_set_slave_req_fd(dev, vmsg);
|
|
return vu_set_slave_req_fd(dev, vmsg);
|
|
case VHOST_USER_GET_CONFIG:
|
|
case VHOST_USER_GET_CONFIG:
|
|
return vu_get_config(dev, vmsg);
|
|
return vu_get_config(dev, vmsg);
|
|
@@ -2416,9 +2416,9 @@ static void _vu_queue_notify(VuDev *dev, VuVirtq *vq, bool sync)
|
|
if (vq->call_fd < 0 &&
|
|
if (vq->call_fd < 0 &&
|
|
vu_has_protocol_feature(dev,
|
|
vu_has_protocol_feature(dev,
|
|
VHOST_USER_PROTOCOL_F_INBAND_NOTIFICATIONS) &&
|
|
VHOST_USER_PROTOCOL_F_INBAND_NOTIFICATIONS) &&
|
|
- vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_SLAVE_REQ)) {
|
|
|
|
|
|
+ vu_has_protocol_feature(dev, VHOST_USER_PROTOCOL_F_BACKEND_REQ)) {
|
|
VhostUserMsg vmsg = {
|
|
VhostUserMsg vmsg = {
|
|
- .request = VHOST_USER_SLAVE_VRING_CALL,
|
|
|
|
|
|
+ .request = VHOST_USER_BACKEND_VRING_CALL,
|
|
.flags = VHOST_USER_VERSION,
|
|
.flags = VHOST_USER_VERSION,
|
|
.size = sizeof(vmsg.payload.state),
|
|
.size = sizeof(vmsg.payload.state),
|
|
.payload.state = {
|
|
.payload.state = {
|