aboutsummaryrefslogtreecommitdiffstats
path: root/netbsd-2.0-xen-sparse
diff options
context:
space:
mode:
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-05-20 19:34:47 +0000
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>2005-05-20 19:34:47 +0000
commit1fbd84c81a444b01084150cb334e91a40e67b00f (patch)
treeacfc3d50dc0cf7287792454e8a7808930e3b840f /netbsd-2.0-xen-sparse
parent9a00a27ea471d9828c2d5347bf2264b3ee826816 (diff)
downloadxen-1fbd84c81a444b01084150cb334e91a40e67b00f.tar.gz
xen-1fbd84c81a444b01084150cb334e91a40e67b00f.tar.bz2
xen-1fbd84c81a444b01084150cb334e91a40e67b00f.zip
bitkeeper revision 1.1492 (428e3bd7k7u4q5iZW-q27Jpez3WzGg)
Clean up vbd probing, and include hardware sector size in the probe information. blkback ensures that all requests are aligned to hardware sector size and returns error if this is not so. In blkfront we now have a request_queue per vbd, with hardsect_size set appropriately. It is now once again possible to mount a CDROM in a domU. Signed-off-by: Keir Fraser <keir@xensource.com>
Diffstat (limited to 'netbsd-2.0-xen-sparse')
-rw-r--r--netbsd-2.0-xen-sparse/sys/arch/xen/xen/xbd.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/netbsd-2.0-xen-sparse/sys/arch/xen/xen/xbd.c b/netbsd-2.0-xen-sparse/sys/arch/xen/xen/xbd.c
index 23a96241d3..101332691c 100644
--- a/netbsd-2.0-xen-sparse/sys/arch/xen/xen/xbd.c
+++ b/netbsd-2.0-xen-sparse/sys/arch/xen/xen/xbd.c
@@ -476,17 +476,11 @@ get_xbda(vdisk_t *xd)
case XEN_IDE7_MAJOR:
case XEN_IDE8_MAJOR:
case XEN_IDE9_MAJOR:
- switch (VDISK_TYPE(xd->info)) {
- case VDISK_TYPE_CDROM:
+ if (xd->info & VDISK_CDROM)
return &cd_ata;
- case VDISK_TYPE_DISK:
- if (xd->capacity == 0)
- return NULL;
- return &wd_ata;
- default:
+ if (xd->capacity == 0)
return NULL;
- }
- break;
+ return &wd_ata;
#endif
default:
if (xd->capacity == 0)