public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* RE: [RFC PATCH 35/35] Add Xen virtual block device driver.
@ 2006-03-22 16:52 Ian Pratt
  2006-03-22 17:09 ` Anthony Liguori
                   ` (2 more replies)
  0 siblings, 3 replies; 26+ messages in thread
From: Ian Pratt @ 2006-03-22 16:52 UTC (permalink / raw)
  To: Anthony Liguori, Chris Wright
  Cc: virtualization, xen-devel, linux-kernel, Ian Pratt, ian.pratt

> This is another thing that has always put me off.  The 
> virtual block device driver has the ability to masquerade as 
> other types of block devices.  It actually claims to be an 
> IDE or SCSI device allocating the appropriate major/minor numbers.
> 
> This seems to be pretty evil and creating interesting failure 
> conditions for users who load IDE or SCSI modules.  I've seen 
> it trip up a number of people in the past.  I think we should 
> only ever use the major number that was actually allocated to us.

We certainly should be pushing everyone toward using the 'xdX' etc
devices that are allocated to us. However, the installers of certain
older distros and other user space tools won't except anything other
than hdX/sdX, so its useful from a compatibility POV even if it never
goes into mainline, which I agree it probably shouldn't. 

Ian

^ permalink raw reply	[flat|nested] 26+ messages in thread
* [RFC PATCH 00/35] Xen i386 paravirtualization support
@ 2006-05-09  8:49 Chris Wright
  2006-05-09  7:00 ` [RFC PATCH 35/35] Add Xen virtual block device driver Chris Wright
  0 siblings, 1 reply; 26+ messages in thread
From: Chris Wright @ 2006-05-09  8:49 UTC (permalink / raw)
  To: linux-kernel; +Cc: virtualization, xen-devel

Unlike full virtualization in which the virtual machine provides 
the same platform interface as running natively on the hardware,
paravirtualization requires modification to the guest operating system
to work with the platform interface provided by the hypervisor.

Xen was designed with performance in mind.  Calls to the hypervisor
are minimized, batched if necessary, and non-critical codepaths are left
unmodified in the case where the privileged instruction can be trapped and
emulated by the hypervisor.  The Xen API is designed to be OS agnostic and
has had Linux, NetBSD, FreeBSD, Solaris, Plan9 and Netware ported to it.
Xen also provides support for running directly on native hardware.

The following patch series provides the minimal support required to
launch Xen paravirtual guests on standard x86 hardware running the Xen
hypervisor.  These patches effectively port the Linux kernel to run on the
platform interface provided by Xen.  This port is done as an i386 subarch.
In the future, we will break this patchset up to place the general
infrastrcture and subarch bits that may have common users at the
beginning of the series, ripe for picking off and pushing upstream.

With these patches you will be able to launch an unprivileged guest
running the modified Linux kernel and unmodified userspace.  This guest
is x86, UP only, runs in shadow translated mode, and has no direct access
to hardware.  This simplifies the patchset to the minimum functionality
needed to support a paravirtualized guest.  It's worth noting that
a fair amount of this patchset deals with paravirtualizing I/O, not
just CPU-only.  The additional missing functionality is primarily about
full SMP support, optimizations such as direct writable page tables,
and the management interface.

At a high-level, the patches provide the following:

- Kconfig and Makefile changes required to support Xen
- subarch changes to allow more platform functionality to be
  implemented by an i386 subarch
- Xen subarch implementation
- start of day code for running in the hypervisor provided environment (paging
  enabled)
- basic Xen drivers to provide a fully functional guest

The Xen platform API encapsulates the following types of requirements:

- idt, gdt, ldt (descriptor table handling)
- cr2, fpu_taskswitch, debug registers (privileged register handling)
- mmu (page table, tlb, and cache handling)
- memory reservations
- time and timer
- vcpu (init, up/down vcpu)
- schedule (processor yield, shutdown, etc)
- event channel (generalized virtual interrupt handling)
- grant table (shared memory interface for high speed interdomain communication)
- block device I/O
- network device I/O
- console device I/O
- Xen feature map
- Xen version info

Thanks to all have reviewed earlier versions of these patches.
-chris
--

^ permalink raw reply	[flat|nested] 26+ messages in thread
* [RFC PATCH 00/35] Xen i386 paravirtualization support
@ 2006-03-22  6:30 Chris Wright
  2006-03-22  6:31 ` [RFC PATCH 35/35] Add Xen virtual block device driver Chris Wright
  0 siblings, 1 reply; 26+ messages in thread
From: Chris Wright @ 2006-03-22  6:30 UTC (permalink / raw)
  To: linux-kernel; +Cc: xen-devel, virtualization

Unlike full virtualization in which the virtual machine provides 
the same platform interface as running natively on the hardware,
paravirtualization requires modification to the guest operating system
to work with the platform interface provided by the hypervisor.

Xen was designed with performance in mind.  Calls to the hypervisor
are minimized, batched if necessary, and non-critical codepaths are left
unmodified in the case where the privileged instruction can be trapped and
emulated by the hypervisor.  The Xen API is designed to be OS agnostic and
has had Linux, NetBSD, FreeBSD, Solaris, Plan9 and Netware ported to it.
Xen also provides support for running directly on native hardware.

The following patch series provides the minimal support required to
launch Xen paravirtual guests on standard x86 hardware running the Xen
hypervisor.  These patches effectively port the Linux kernel to run on the
platform interface provided by Xen.  This port is done as an i386 subarch.

With these patches you will be able to launch an unprivileged guest
running the modified Linux kernel and unmodified userspace.  This guest
is x86, UP only, runs in shadow translated mode, and has no direct access
to hardware.  This simplifies the patchset to the minimum functionality
needed to support a paravirtualized guest.  It's worth noting that
a fair amount of this patchset deals with paravirtualizing I/O, not
just CPU-only.  The additional missing functionality is primarily about
full SMP support, optimizations such as direct writable page tables,
and the management interface.  Those refinements will be posted later.

At a high-level, the patches provide the following:

- Kconfig and Makefile changes required to support Xen
- subarch changes to allow more platform functionality to be
  implemented by an i386 subarch
- Xen subarch implementation
- start of day code for running in the hypervisor provided environment (paging
  enabled)
- basic Xen drivers to provide a fully functional guest

The Xen platform API encapsulates the following types of requirements:

- idt, gdt, ldt (descriptor table handling)
- cr2, fpu_taskswitch, debug registers (privileged register handling)
- mmu (page table, tlb, and cache handling)
- memory reservations
- time and timer
- vcpu (init, up/down vcpu)
- schedule (processor yield, shutdown, etc)
- event channel (generalized virtual interrupt handling)
- grant table (shared memory interface for high speed interdomain communication)
- block device I/O
- network device I/O
- console device I/O
- Xen feature map
- Xen version info

Thanks to those who provided early feedback to this patchset: Andi Kleen,
Gerd Hoffmann, Jan Beulich, Rik van Riel, Stephen Tweedie, and the Xen team.
And thanks to the Xen community: AMD, HP, IBM, Intel, Novell, Red Hat,
Virtual Iron, XenSource -- see Xen changelog for full details.

Known issues:

	CodingStyle conformance is still in progress
	/proc interface needs to be replaced with something more appropriate
	entry.S cleanups are possible


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

end of thread, other threads:[~2006-05-09 12:01 UTC | newest]

Thread overview: 26+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-22 16:52 [RFC PATCH 35/35] Add Xen virtual block device driver Ian Pratt
2006-03-22 17:09 ` Anthony Liguori
2006-03-22 23:09 ` Jeff Garzik
2006-03-24 12:17   ` Alan Cox
2006-03-24 12:38     ` Jeff Garzik
2006-03-24 13:37       ` Jeff Garzik
2006-03-24 13:40         ` Arjan van de Ven
2006-03-24 13:50           ` Jeff Garzik
2006-03-24 15:33             ` Dave C Boutcher
2006-03-24 19:04               ` Mike Christie
2006-03-24 19:19                 ` Dave C Boutcher
2006-03-25  0:32                   ` FUJITA Tomonori
2006-03-25  0:47                   ` Roland Dreier
2006-03-24 15:55       ` Alan Cox
2006-03-25 10:03         ` Rusty Russell
2006-03-27 10:14   ` Peter Chubb
2006-03-23  8:19 ` Arjan van de Ven
2006-03-23  9:34   ` Keir Fraser
2006-03-23  9:41     ` Arjan van de Ven
2006-03-23  9:42     ` Arjan van de Ven
  -- strict thread matches above, loose matches on Subject: below --
2006-05-09  8:49 [RFC PATCH 00/35] Xen i386 paravirtualization support Chris Wright
2006-05-09  7:00 ` [RFC PATCH 35/35] Add Xen virtual block device driver Chris Wright
2006-05-09 12:01   ` Christoph Hellwig
2006-03-22  6:30 [RFC PATCH 00/35] Xen i386 paravirtualization support Chris Wright
2006-03-22  6:31 ` [RFC PATCH 35/35] Add Xen virtual block device driver Chris Wright
2006-03-22 16:39   ` Anthony Liguori
2006-03-22 16:54     ` Christoph Hellwig
2006-03-27  8:42     ` Gerd Hoffmann

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox