diff options
author | Markus Armbruster <armbru@redhat.com> | 2011-09-06 18:58:59 +0200 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2011-09-12 15:17:22 +0200 |
commit | 19f61ce5effc0366fe3df13ee88c6a027ec7d6fb (patch) | |
tree | 656e821d5db201a05fd20e4fd69069e0e79a850f /block.h | |
parent | 006f7626fcd24962daa614dbb215454f41a67cba (diff) | |
download | qemu-19f61ce5effc0366fe3df13ee88c6a027ec7d6fb.tar.gz qemu-19f61ce5effc0366fe3df13ee88c6a027ec7d6fb.tar.bz2 qemu-19f61ce5effc0366fe3df13ee88c6a027ec7d6fb.zip |
block: New change_media_cb() parameter load
To let device models distinguish between eject and load.
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'block.h')
-rw-r--r-- | block.h | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -32,11 +32,12 @@ typedef struct QEMUSnapshotInfo { typedef struct BlockDevOps { /* * Runs when virtual media changed (monitor commands eject, change) + * Argument load is true on load and false on eject. * Beware: doesn't run when a host device's physical media * changes. Sure would be useful if it did. * Device models with removable media must implement this callback. */ - void (*change_media_cb)(void *opaque); + void (*change_media_cb)(void *opaque, bool load); /* * Is the virtual tray open? * Device models implement this only when the device has a tray. |