On Jun 25, 2015, at 12:12 PM, Laurent Vivier wrote: > > > On 25/06/2015 17:48, Paolo Bonzini wrote: >> >> On 25/06/2015 17:32, Programmingkid wrote: >>>> I think we are going to have to agree to disagree. I have never >>>> used the /dev/sr(0 | 1) devices and don't see how they would be >>>> effected by this patch. Are you trying to say the /dev/sr(0 | 1) >>>> devices *should* be handled by this patch? >>> >>> Thinking about your question some more, I see what you mean. On Linux >>> /dev/sr0 refers to the cdrom drive. Also on Linux, the /dev/cdrom >>> link refers to the /dev/sr0 device file. So if you just use >>> /dev/cdrom, you are good. >> >> Well, that's not how things work. >> >> If you do things like that, you end up with a bunch of hacks, not with a >> decent piece of software. >> >> There is support for CD-ROM passthrough on Linux and FreeBSD in >> block/raw-posix.c. Perhaps the FreeBSD support can be extended to OS X >> as well. >> > > In fact, programmingkid, you should fix it in hdev_open() where there is > already a #if __APPLE__ .
Nice to hear from you again Laurent. The only way a solution in hdev_open() would work is if it could prevent find_image_format() from executing. Otherwise find_image_format() would just quit QEMU with an error.