Displaying 6 results from an estimated 6 matches for "virtio_iommu_s_nomem".
2019 Jul 22
3
[PATCH] iommu/virtio: Update to most recent specification
...tex mutex; /* protects viommu pointer */
unsigned int id;
+ u32 map_flags;
spinlock_t mappings_lock;
struct rb_root_cached mappings;
@@ -113,6 +117,8 @@ static int viommu_get_req_errno(void *buf, size_t len)
return -ENOENT;
case VIRTIO_IOMMU_S_FAULT:
return -EFAULT;
+ case VIRTIO_IOMMU_S_NOMEM:
+ return -ENOMEM;
case VIRTIO_IOMMU_S_IOERR:
case VIRTIO_IOMMU_S_DEVERR:
default:
@@ -607,15 +613,15 @@ static int viommu_domain_finalise(struct viommu_dev *viommu,
{
int ret;
struct viommu_domain *vdomain = to_viommu_domain(domain);
- unsigned int max_domain = viommu->domain_bits &...
2019 Jul 22
3
[PATCH] iommu/virtio: Update to most recent specification
...tex mutex; /* protects viommu pointer */
unsigned int id;
+ u32 map_flags;
spinlock_t mappings_lock;
struct rb_root_cached mappings;
@@ -113,6 +117,8 @@ static int viommu_get_req_errno(void *buf, size_t len)
return -ENOENT;
case VIRTIO_IOMMU_S_FAULT:
return -EFAULT;
+ case VIRTIO_IOMMU_S_NOMEM:
+ return -ENOMEM;
case VIRTIO_IOMMU_S_IOERR:
case VIRTIO_IOMMU_S_DEVERR:
default:
@@ -607,15 +613,15 @@ static int viommu_domain_finalise(struct viommu_dev *viommu,
{
int ret;
struct viommu_domain *vdomain = to_viommu_domain(domain);
- unsigned int max_domain = viommu->domain_bits &...
2019 Jul 22
0
[PATCH] iommu/virtio: Update to most recent specification
...unsigned int id;
> + u32 map_flags;
>
> spinlock_t mappings_lock;
> struct rb_root_cached mappings;
> @@ -113,6 +117,8 @@ static int viommu_get_req_errno(void *buf, size_t len)
> return -ENOENT;
> case VIRTIO_IOMMU_S_FAULT:
> return -EFAULT;
> + case VIRTIO_IOMMU_S_NOMEM:
> + return -ENOMEM;
> case VIRTIO_IOMMU_S_IOERR:
> case VIRTIO_IOMMU_S_DEVERR:
> default:
> @@ -607,15 +613,15 @@ static int viommu_domain_finalise(struct viommu_dev *viommu,
> {
> int ret;
> struct viommu_domain *vdomain = to_viommu_domain(domain);
> - unsig...
2019 Jul 22
0
[PATCH] iommu/virtio: Update to most recent specification
...unsigned int id;
> + u32 map_flags;
>
> spinlock_t mappings_lock;
> struct rb_root_cached mappings;
> @@ -113,6 +117,8 @@ static int viommu_get_req_errno(void *buf, size_t len)
> return -ENOENT;
> case VIRTIO_IOMMU_S_FAULT:
> return -EFAULT;
> + case VIRTIO_IOMMU_S_NOMEM:
> + return -ENOMEM;
> case VIRTIO_IOMMU_S_IOERR:
> case VIRTIO_IOMMU_S_DEVERR:
> default:
> @@ -607,15 +613,15 @@ static int viommu_domain_finalise(struct viommu_dev *viommu,
> {
> int ret;
> struct viommu_domain *vdomain = to_viommu_domain(domain);
> - unsig...
2019 May 30
0
[PATCH v8 5/7] iommu: Add virtio-iommu driver
...gt;status) {
+ case VIRTIO_IOMMU_S_OK:
+ return 0;
+ case VIRTIO_IOMMU_S_UNSUPP:
+ return -ENOSYS;
+ case VIRTIO_IOMMU_S_INVAL:
+ return -EINVAL;
+ case VIRTIO_IOMMU_S_RANGE:
+ return -ERANGE;
+ case VIRTIO_IOMMU_S_NOENT:
+ return -ENOENT;
+ case VIRTIO_IOMMU_S_FAULT:
+ return -EFAULT;
+ case VIRTIO_IOMMU_S_NOMEM:
+ return -ENOMEM;
+ case VIRTIO_IOMMU_S_IOERR:
+ case VIRTIO_IOMMU_S_DEVERR:
+ default:
+ return -EIO;
+ }
+}
+
+static void viommu_set_req_status(void *buf, size_t len, int status)
+{
+ struct virtio_iommu_req_tail *tail = buf + len - sizeof(*tail);
+
+ tail->status = status;
+}
+
+static of...
2019 May 30
10
[PATCH v8 0/7] Add virtio-iommu driver
Implement the virtio-iommu driver, following specification v0.12 [1].
Since last version [2] we've worked on improving the specification,
which resulted in the following changes to the interface:
* Remove the EXEC flag.
* Add feature bit for the MMIO flag.
* Change domain_bits to domain_range.
Given that there were small changes to patch 5/7, I removed the review
and test tags. Please find