• Luiz Capitulino's avatar
    block: BLOCK_IO_ERROR QMP event · 2582bfed
    Luiz Capitulino authored
    This commit introduces the bdrv_mon_event() function, which
    should be called by block subsystems (eg. IDE) when a I/O
    error occurs, so that an QMP event is emitted.
    The following information is currently provided in the event:
    - device name
    - operation (ie. "read" or "write")
    - action taken (eg. "stop")
    Event example:
    { "event": "BLOCK_IO_ERROR",
        "data": { "device": "ide0-hd1",
                  "operation": "write",
                  "action": "stop" },
        "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
    Signed-off-by: default avatarLuiz Capitulino <lcapitulino@redhat.com>
    Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
block.h 8.74 KB