linux-stable/include/xen
Daniel Kiper 080e2be788 xen/balloon: memory hotplug support for Xen balloon driver
Memory hotplug support for Xen balloon driver.  It should be mentioned
that hotplugged memory is not onlined automatically.  It should be onlined
by user through standard sysfs interface.

Memory could be hotplugged in following steps:

  1) dom0: xl mem-max <domU> <maxmem>
     where <maxmem> is >= requested memory size,

  2) dom0: xl mem-set <domU> <memory>
     where <memory> is requested memory size; alternatively memory
     could be added by writing proper value to
     /sys/devices/system/xen_memory/xen_memory0/target or
     /sys/devices/system/xen_memory/xen_memory0/target_kb on dumU,

  3) domU: for i in /sys/devices/system/memory/memory*/state; do \
             [ "`cat "$i"`" = offline ] && echo online > "$i"; done

Memory could be onlined automatically on domU by adding following line to
udev rules:

  SUBSYSTEM=="memory", ACTION=="add", RUN+="/bin/sh -c '[ -f /sys$devpath/state ] && echo online > /sys$devpath/state'"

In that case step 3 should be omitted.

Signed-off-by: Daniel Kiper <dkiper@net-space.pl>
Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Cc: Ian Campbell <ian.campbell@citrix.com>
Cc: Jeremy Fitzhardinge <jeremy@goop.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2011-07-25 20:57:08 -07:00
..
interface Merge branch 'stable/vga.support' into stable/drivers 2011-06-21 09:25:41 -04:00
balloon.h xen/balloon: memory hotplug support for Xen balloon driver 2011-07-25 20:57:08 -07:00
events.h xen/pci: Remove 'xen_allocate_pirq_gsi'. 2011-07-11 13:19:33 -04:00
evtchn.h xen: add /dev/xen/evtchn driver 2009-03-30 09:26:49 -07:00
features.h
gntalloc.h xen/gntalloc,gntdev: Add unmap notify ioctl 2011-02-14 14:16:17 -05:00
gntdev.h xen/gntalloc,gntdev: Add unmap notify ioctl 2011-02-14 14:16:17 -05:00
grant_table.h xen: introduce gnttab_map_refs and gnttab_unmap_refs 2011-01-11 14:32:00 -05:00
hvc-console.h xen: Add __attribute__((format(printf... where appropriate 2011-06-30 12:14:40 -04:00
hvm.h x86/xen: event channels delivery on HVM. 2010-07-22 16:45:59 -07:00
Kbuild xen: add privcmd driver 2010-10-20 16:22:29 -07:00
page.h xen: add extra pages to balloon 2010-11-19 22:15:59 -08:00
platform_pci.h xen: pvhvm: make it clearer that XEN_UNPLUG_* define bits in a bitfield 2010-08-23 12:01:35 +01:00
privcmd.h xen: fix header export to userspace 2010-11-16 10:57:05 -08:00
swiotlb-xen.h swiotlb-xen: SWIOTLB library for Xen PV guest with PCI passthrough. 2010-07-27 11:51:00 -04:00
tmem.h xen: tmem: self-ballooning and frontswap-selfshrinking 2011-07-08 12:26:21 -06:00
xen-ops.h xen: suspend: add "arch" to pre/post suspend hooks 2011-02-25 16:43:12 +00:00
xen.h xen: move Xen-testing predicates to common header 2009-11-04 08:47:24 -08:00
xenbus.h xen: Add __attribute__((format(printf... where appropriate 2011-06-30 12:14:40 -04:00
xencomm.h xen: import arch generic part of xencomm 2008-04-24 23:57:32 +02:00