mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 16:23:55 -06:00
virtio-blk: add virtio_blk_handle_read trace event
There already exists a virtio_blk_handle_write trace event as well as completion events. Add the virtio_blk_handle_read event so it's easy to trace virtio-blk requests for both read and write operations. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
parent
094f1ba10a
commit
81b6b9faef
2 changed files with 3 additions and 0 deletions
|
@ -346,6 +346,8 @@ static void virtio_blk_handle_read(VirtIOBlockReq *req)
|
|||
|
||||
bdrv_acct_start(req->dev->bs, &req->acct, req->qiov.size, BDRV_ACCT_READ);
|
||||
|
||||
trace_virtio_blk_handle_read(req, sector, req->qiov.size / 512);
|
||||
|
||||
if (sector & req->dev->sector_mask) {
|
||||
virtio_blk_rw_complete(req, -EIO);
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue