OSDN Git Service

vdpa_sim_blk: implement ramdisk behaviour
authorStefano Garzarella <sgarzare@redhat.com>
Mon, 15 Mar 2021 16:34:48 +0000 (17:34 +0100)
committerMichael S. Tsirkin <mst@redhat.com>
Mon, 3 May 2021 08:55:53 +0000 (04:55 -0400)
commit7d189f617f83f780915b737896a696ff605bd19f
tree87916c1fb03b0dadb9f7b91d610cfbc816365a76
parent0c853c2c2924464bd86537164ed18d5d953b4909
vdpa_sim_blk: implement ramdisk behaviour

The previous implementation wrote only the status of each request.
This patch implements a more accurate block device simulator,
providing a ramdisk-like behavior and adding input validation.

Acked-by: Jason Wang <jasowang@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Stefano Garzarella <sgarzare@redhat.com>
Link: https://lore.kernel.org/r/20210315163450.254396-13-sgarzare@redhat.com
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
drivers/vdpa/vdpa_sim/vdpa_sim_blk.c