return !virtio_has_feature(vdev, VIRTIO_F_ACCESS_PLATFORM);
}
-static inline
-struct virtqueue *virtio_find_single_vq(struct virtio_device *vdev,
- vq_callback_t *c, const char *n)
-{
- vq_callback_t *callbacks[] = { c };
- const char *names[] = { n };
- struct virtqueue *vq;
- int err = vdev->config->find_vqs(vdev, 1, &vq, callbacks, names, NULL,
- NULL);
- if (err < 0)
- return ERR_PTR(err);
- return vq;
-}
-
static inline
int virtio_find_vqs_ctx(struct virtio_device *vdev, unsigned nvqs,
struct virtqueue *vqs[], vq_callback_t *callbacks[],
names, NULL, desc);
}
+static inline
+struct virtqueue *virtio_find_single_vq(struct virtio_device *vdev,
+ vq_callback_t *c, const char *n)
+{
+ vq_callback_t *callbacks[] = { c };
+ const char *names[] = { n };
+ struct virtqueue *vq;
+ int err = virtio_find_vqs(vdev, 1, &vq, callbacks, names, NULL);
+
+ if (err < 0)
+ return ERR_PTR(err);
+ return vq;
+}
+
/**
* virtio_synchronize_cbs - synchronize with virtqueue callbacks
* @dev: the virtio device