aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorMichael S. Tsirkin <mst@redhat.com>2014-12-11 18:55:03 -0500
committerMichael S. Tsirkin <mst@redhat.com>2014-12-15 16:50:40 -0500
commit8a38f339b6c31d5cc86bedef1c2d3eb3873cb76e (patch)
treef993d60edb1ac36f3ae039de87fd173337729114 /drivers/misc
parentb9f7ac8c72894c19bf258a54ecaa708df4ffbe80 (diff)
mic/host: fix up virtio 1.0 APIs
This just makes code sparse-clean by using new memory access APIs in one file I missed. The new feature bit is not yet negotiated. Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/mic/host/mic_debugfs.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/drivers/misc/mic/host/mic_debugfs.c b/drivers/misc/mic/host/mic_debugfs.c
index 028ba5d6fd1c..687e9aacf3bb 100644
--- a/drivers/misc/mic/host/mic_debugfs.c
+++ b/drivers/misc/mic/host/mic_debugfs.c
@@ -326,21 +326,27 @@ static int mic_vdev_info_show(struct seq_file *s, void *unused)
326 } 326 }
327 avail = vrh->vring.avail; 327 avail = vrh->vring.avail;
328 seq_printf(s, "avail flags 0x%x idx %d\n", 328 seq_printf(s, "avail flags 0x%x idx %d\n",
329 avail->flags, avail->idx & (num - 1)); 329 vringh16_to_cpu(vrh, avail->flags),
330 vringh16_to_cpu(vrh, avail->idx) & (num - 1));
330 seq_printf(s, "avail flags 0x%x idx %d\n", 331 seq_printf(s, "avail flags 0x%x idx %d\n",
331 avail->flags, avail->idx); 332 vringh16_to_cpu(vrh, avail->flags),
333 vringh16_to_cpu(vrh, avail->idx));
332 for (j = 0; j < num; j++) 334 for (j = 0; j < num; j++)
333 seq_printf(s, "avail ring[%d] %d\n", 335 seq_printf(s, "avail ring[%d] %d\n",
334 j, avail->ring[j]); 336 j, avail->ring[j]);
335 used = vrh->vring.used; 337 used = vrh->vring.used;
336 seq_printf(s, "used flags 0x%x idx %d\n", 338 seq_printf(s, "used flags 0x%x idx %d\n",
337 used->flags, used->idx & (num - 1)); 339 vringh16_to_cpu(vrh, used->flags),
340 vringh16_to_cpu(vrh, used->idx) & (num - 1));
338 seq_printf(s, "used flags 0x%x idx %d\n", 341 seq_printf(s, "used flags 0x%x idx %d\n",
339 used->flags, used->idx); 342 vringh16_to_cpu(vrh, used->flags),
343 vringh16_to_cpu(vrh, used->idx));
340 for (j = 0; j < num; j++) 344 for (j = 0; j < num; j++)
341 seq_printf(s, "used ring[%d] id %d len %d\n", 345 seq_printf(s, "used ring[%d] id %d len %d\n",
342 j, used->ring[j].id, 346 j, vringh32_to_cpu(vrh,
343 used->ring[j].len); 347 used->ring[j].id),
348 vringh32_to_cpu(vrh,
349 used->ring[j].len));
344 } 350 }
345 } 351 }
346 mutex_unlock(&mdev->mic_mutex); 352 mutex_unlock(&mdev->mic_mutex);