Revision 508c7cb3 block/raw-win32.c
b/block/raw-win32.c | ||
---|---|---|
306 | 306 |
} |
307 | 307 |
} |
308 | 308 |
|
309 |
static int hdev_probe_device(const char *filename) |
|
310 |
{ |
|
311 |
if (strstart(filename, "/dev/cdrom", NULL)) |
|
312 |
return 100; |
|
313 |
if (is_windows_drive(filename)) |
|
314 |
return 100; |
|
315 |
return 0; |
|
316 |
} |
|
317 |
|
|
309 | 318 |
static int hdev_open(BlockDriverState *bs, const char *filename, int flags) |
310 | 319 |
{ |
311 | 320 |
BDRVRawState *s = bs->opaque; |
... | ... | |
391 | 400 |
static BlockDriver bdrv_host_device = { |
392 | 401 |
.format_name = "host_device", |
393 | 402 |
.instance_size = sizeof(BDRVRawState), |
403 |
.bdrv_probe_device = hdev_probe_device, |
|
394 | 404 |
.bdrv_open = hdev_open, |
395 | 405 |
.bdrv_close = raw_close, |
396 | 406 |
.bdrv_flush = raw_flush, |
Also available in: Unified diff