Re: Fix handling of HVM boot parameters

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Aug 10, 2006 at 04:08:30PM +0100, Daniel P. Berrange wrote:
> On Thu, Aug 10, 2006 at 02:12:26PM +0100, Daniel P. Berrange wrote:
> > On Thu, Aug 10, 2006 at 08:02:20AM -0400, Jeremy Katz wrote:
> > > 
> > > But read-only isn't all that you want -- think about giving access to a
> > > CD-R drive.  It's not read-only, but we still need to have it exposed as
> > > a CD device.  And with things like the bios for qemu and HVM guests, if
> > > a device is a CD-ROM or a hard drive makes a large difference.
> > > 
> > > Thinking out loud, what if we went with something like
> > >   <cdrom type='file'>
> > >     <source file='/root/boot.iso'/>
> > >     <target dev='hdc'/>
> > >   </cdrom>
> > > for CDs and then similarly <floppy .../> for floppies
> > 
> > I wouldn't do this for CDROMs, since they basically share the same device
> > namespace as disks already - with versions Xen / QEMU any hda -> hdd
> > can be labelled as a cdrom by appending :cdrom - so they're best handled
> > under same XML tag as disks
> > 
> > For floppy disks though we could certainly have a separate <floppy>
> > tag name instead of <disk> - it would be clearer than distinguishing
> > based on the value of the 'dev' attribute.
> 
> Actually I take that back. There is a potentially never ending list of
> different disk interfaces (IDE, FD, SCSI, XVDA) - I don't think we really
> need to dstingiush between them by having separate <floppy> <disk>, <cdrom>
> tags, since the value of the 'dev' attribute is always unique.

  Well hdc could as well be an ide disk or an ide CD-Rom or an ide 
CD-RW. I though that the readonly element should be sufficient at the
emulation level, but Jeremy don't think so. making new element name
ain't good from an XML perspective. But we could hint at the expected
kind of device as an extra attribute on <disk>, 

   <disk type='file' device='cdrom'>
     <source file='/root/boot.iso'/>
     <target dev='hdc'/>
     <readonly/>
   </disk>

the problem would then to maintain a list of supported device values
the default being a disk if the attribute is ommited.
I think that would be relatively sane at the XML level, then the lower
layer may or may not be able to make sense of it (an UML backend would not
for example) depending on how the device are emulated.

Daniel

-- 
Red Hat Virtualization group http://redhat.com/virtualization/
Daniel Veillard      | virtualization library  http://libvirt.org/
veillard@xxxxxxxxxx  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine  http://rpmfind.net/


[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]