|
|
|
|
|
|
|
|
|
|
xen-devel
[Xen-devel] [QEMU][PATCH] Fix hvm cdrom issues
This patch adds the following functionality:
1. CDROM tray un-locking - calls the generic scsi ioctl
(ALLOW_MEDIUM_REMOVAL) in order to unlock the tray each time the cdrom's
status changed. If this patch is not applied, the cdrom physical button
doesn't have any effect.
2. Added cdrom-changed functionality to raw_media_changed()
3. File descriptor caching issue solved - when the cdrom status has
changed, the file descriptor must be re-opened. buggy cdrom drivers
(such as the ide_cd / cdrom generic modules) does not invalidate the
cache. This claim is based on empirical evidence: if you open
/dev/cdrom, get a file descriptor, eject the disk and then read from the
fd, you get cached data. It creates weird behavior when trying to mess
with the emulated cd drive.
How to use?
The cdrom block device path must be '/dev/cdrom" in the HVM
configuration file.
It was tested using a windows xp sp2 hvm guest.
Known Issues:
This patch may need additional work, I guess that it'll be propagated to
qemu if it'll be found useful.
The ALLOW_MEDIUM_REMOVAL ioctl may be harsh with certain distros I guess
(If they interfere and try to mount the cdrom drive).
Didn't check how this affect floppies.
Thanks to Yoav Weiss in his help to identify the problem.
Signed-off-by: Yoav Weiss <yoav@xxxxxxxxxxxx>
Signed-off-by: Guy Zana <guy@xxxxxxxxxxxx>
Thanks,
Guy.
cdrom_fix.patch
Description: cdrom_fix.patch
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-devel] [QEMU][PATCH] Fix hvm cdrom issues,
Guy Zana <=
|
|
|
|
|