qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] raw-posix: Don't use file name for host_cdrom detection on Linux
@ 2010-09-02 15:50 Kevin Wolf
  2010-09-02 16:50 ` Christoph Hellwig
  0 siblings, 1 reply; 2+ messages in thread
From: Kevin Wolf @ 2010-09-02 15:50 UTC (permalink / raw)
  To: qemu-devel; +Cc: kwolf

On Linux, we have code to detect CD-ROMs using an ioctl. We shouldn't lose
anything but false positives by removing the check for a /dev/cd* path.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
---
 block/raw-posix.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/block/raw-posix.c b/block/raw-posix.c
index 240d84d..a3500f1 100644
--- a/block/raw-posix.c
+++ b/block/raw-posix.c
@@ -1159,9 +1159,6 @@ static int cdrom_probe_device(const char *filename)
     int fd, ret;
     int prio = 0;
 
-    if (strstart(filename, "/dev/cd", NULL))
-        prio = 50;
-
     fd = open(filename, O_RDONLY | O_NONBLOCK);
     if (fd < 0) {
         goto out;
-- 
1.7.2.2

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-09-02 16:52 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-02 15:50 [Qemu-devel] [PATCH] raw-posix: Don't use file name for host_cdrom detection on Linux Kevin Wolf
2010-09-02 16:50 ` Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).