All of lore.kernel.org
 help / color / mirror / Atom feed
* 2.6.37 PV on HVM and emul_unplug=unnecessary
@ 2011-01-12 11:45 Alex Bligh
  2011-01-12 13:04 ` Paolo Bonzini
  0 siblings, 1 reply; 3+ messages in thread
From: Alex Bligh @ 2011-01-12 11:45 UTC (permalink / raw)
  To: xen-devel; +Cc: Alex Bligh

On modern mainline, when a PV on HVM kernel boots, it will detect the
ability to PCI unplug the PCI SD devices, so to avoid producing
/dev/xvdX and /dev/sdX referring to the same device. On Xen Dom0 prior
to 3.4.something, this fails because PCI unplug is not supported.
The check can be worked around by using emulunplug=unnecessary, but
this is not optimal as
 a) you still end up with 2 devices; and
 b) it requires modifying the kernel boot line, which is not always
    easy (e.g. if your bootloader is supplied by a third party IAAS
    provider and you wish to use a mainline kernel).

Another approach would be to stop sd_mod loading another way
(e.g. blacklist sd_mod). This does not work well as many kernels have
sd_mod built in.

I am trying to think of a non-intrusive way to prevent sd_mod initialising
if we are doing PV on HVM and PCI unplug is not supported (other than
upgrade Xen). One possibility would be to manually register dummy
block major device with the same major number as used by sd. This would
cause register_blkdev to return EBUSY and the module not to init. However,
it would leave the dummy block device around. Another more intrusive
method would simply be to put a check into sd_mod. Yet more intrusive
would be to modify the entire do_initcalls/module_init subsystem
to provide a generalised method for one bit of code to disable another.

Has someone already looked into this and concluded it's impossible? Or
is this worth a little time?


-- 
Alex Bligh

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

end of thread, other threads:[~2011-01-12 13:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-01-12 11:45 2.6.37 PV on HVM and emul_unplug=unnecessary Alex Bligh
2011-01-12 13:04 ` Paolo Bonzini
2011-01-12 13:25   ` Alex Bligh

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.