aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorBorislav Petkov <bp@alien8.de>2013-05-22 10:46:39 -0400
committerIngo Molnar <mingo@kernel.org>2013-05-28 06:11:32 -0400
commit46ff53874bd935ab9955dee56d60212857e89bf3 (patch)
tree068d7d512970bb3c2feb011102f620869f25c061 /arch
parente4aa937ec75df0eea0bee03bffa3303ad36c986b (diff)
x86, platform, kvm, kconfig: Turn existing .config's into KVM-capable configs
Add an config file snippet which enables additional options useful for running the kernel in a kvm guest. When you execute 'make kvmconfig' it merges those options with an already existing user config before you build the kernel. Based on an patch from the external lkvm tree. Signed-off-by: Borislav Petkov <bp@suse.de> Acked-by: Pekka Enberg <penberg@kernel.org> Cc: David Rientjes <rientjes@google.com> Cc: Michal Marek <mmarek@suse.cz> Cc: Randy Dunlap <rdunlap@infradead.org> Cc: penberg@kernel.org Cc: levinsasha928@gmail.com Cc: mtosatti@redhat.com Cc: fengguang.wu@intel.com Link: http://lkml.kernel.org/r/20130522144638.GB15085@pd.tnic Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/Makefile6
-rw-r--r--arch/x86/configs/kvm_guest.config28
2 files changed, 34 insertions, 0 deletions
diff --git a/arch/x86/Makefile b/arch/x86/Makefile
index 5c477260294f..91ee171f1cff 100644
--- a/arch/x86/Makefile
+++ b/arch/x86/Makefile
@@ -220,6 +220,11 @@ archclean:
220 $(Q)$(MAKE) $(clean)=$(boot) 220 $(Q)$(MAKE) $(clean)=$(boot)
221 $(Q)$(MAKE) $(clean)=arch/x86/tools 221 $(Q)$(MAKE) $(clean)=arch/x86/tools
222 222
223kvmconfig:
224 $(if $(wildcard $(objtree)/.config),, $(error You need an existing .config for this target))
225 $(Q)$(CONFIG_SHELL) $(srctree)/scripts/kconfig/merge_config.sh -m -O $(objtree) $(objtree)/.config arch/x86/configs/kvm_guest.config
226 $(Q)yes "" | $(MAKE) oldconfig
227
223define archhelp 228define archhelp
224 echo '* bzImage - Compressed kernel image (arch/x86/boot/bzImage)' 229 echo '* bzImage - Compressed kernel image (arch/x86/boot/bzImage)'
225 echo ' install - Install kernel using' 230 echo ' install - Install kernel using'
@@ -233,4 +238,5 @@ define archhelp
233 echo ' bzdisk/fdimage*/isoimage also accept:' 238 echo ' bzdisk/fdimage*/isoimage also accept:'
234 echo ' FDARGS="..." arguments for the booted kernel' 239 echo ' FDARGS="..." arguments for the booted kernel'
235 echo ' FDINITRD=file initrd for the booted kernel' 240 echo ' FDINITRD=file initrd for the booted kernel'
241 echo ' kvmconfig - Enable additional options for guest kernel support'
236endef 242endef
diff --git a/arch/x86/configs/kvm_guest.config b/arch/x86/configs/kvm_guest.config
new file mode 100644
index 000000000000..f9affcc3b9f1
--- /dev/null
+++ b/arch/x86/configs/kvm_guest.config
@@ -0,0 +1,28 @@
1CONFIG_NET=y
2CONFIG_NET_CORE=y
3CONFIG_NETDEVICES=y
4CONFIG_BLOCK=y
5CONFIG_BLK_DEV=y
6CONFIG_NETWORK_FILESYSTEMS=y
7CONFIG_INET=y
8CONFIG_TTY=y
9CONFIG_SERIAL_8250=y
10CONFIG_SERIAL_8250_CONSOLE=y
11CONFIG_IP_PNP=y
12CONFIG_IP_PNP_DHCP=y
13CONFIG_BINFMT_ELF=y
14CONFIG_PCI=y
15CONFIG_PCI_MSI=y
16CONFIG_DEBUG_KERNEL=y
17CONFIG_VIRTUALIZATION=y
18CONFIG_HYPERVISOR_GUEST=y
19CONFIG_PARAVIRT=y
20CONFIG_KVM_GUEST=y
21CONFIG_VIRTIO=y
22CONFIG_VIRTIO_PCI=y
23CONFIG_VIRTIO_BLK=y
24CONFIG_VIRTIO_CONSOLE=y
25CONFIG_VIRTIO_NET=y
26CONFIG_9P_FS=y
27CONFIG_NET_9P=y
28CONFIG_NET_9P_VIRTIO=y