All of lore.kernel.org
 help / color / mirror / Atom feed
* [Patch] "Helper" for  dom0/domU Kernels
@ 2007-04-27 15:26 Robert Valentan
  2007-04-27 15:33 ` Keir Fraser
  0 siblings, 1 reply; 3+ messages in thread
From: Robert Valentan @ 2007-04-27 15:26 UTC (permalink / raw)
  To: xen-devel

[-- Attachment #1: Type: text/plain, Size: 252 bytes --]

This patch add's a XEN_SPLIT_KERNEL to Config.mk and use it
in config/Linux.mk
This patch is also needed for my vnet-patch (some minutes before)
to get the kernel_src dir.

Signed-off-by: Robert Valentan <R.Valentan@solid-soft.at>

-- 
Robert Valentan

[-- Attachment #2: dom0_domU.patch --]
[-- Type: text/x-patch, Size: 691 bytes --]

diff -r ee16cdeddade Config.mk
--- a/Config.mk	Wed Apr 25 09:39:08 2007
+++ b/Config.mk	Fri Apr 27 18:01:44 2007
@@ -13,6 +13,9 @@
 endif
 
 CONFIG_$(XEN_OS) := y
+
+# own kernels for dom0 and domU y/n
+XEN_SPLIT_KERNEL := y
 
 SHELL     ?= /bin/sh
 
diff -r ee16cdeddade config/Linux.mk
--- a/config/Linux.mk	Wed Apr 25 09:39:08 2007
+++ b/config/Linux.mk	Fri Apr 27 18:01:44 2007
@@ -1,7 +1,11 @@
 include $(XEN_ROOT)/config/StdGNU.mk
 
 # You may use wildcards, e.g. KERNELS=*2.6*
+ifeq ($(XEN_SPLIT_KERNEL),y)
+KERNELS ?= linux-2.6-xen0 linux-2.6-xenU
+else
 KERNELS ?= linux-2.6-xen
+endif
 
 XKERNELS := $(foreach kernel, $(KERNELS), \
               $(patsubst buildconfigs/mk.%,%, \

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

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

* Re: [Patch] "Helper" for  dom0/domU Kernels
  2007-04-27 15:26 [Patch] "Helper" for dom0/domU Kernels Robert Valentan
@ 2007-04-27 15:33 ` Keir Fraser
  2007-04-27 19:23   ` Robert Valentan
  0 siblings, 1 reply; 3+ messages in thread
From: Keir Fraser @ 2007-04-27 15:33 UTC (permalink / raw)
  To: Robert Valentan, xen-devel

On 27/4/07 16:26, "Robert Valentan" <R.Valentan@solid-soft.at> wrote:

> This patch add's a XEN_SPLIT_KERNEL to Config.mk and use it
> in config/Linux.mk
> This patch is also needed for my vnet-patch (some minutes before)
> to get the kernel_src dir.
> 
> Signed-off-by: Robert Valentan <R.Valentan@solid-soft.at>

Can't you just do some grep hack on the KERNELS variable in the vnet
Makefile? I think it's enough that KERNELS can be overridden -- we don't
need yet another top-level config option.

 -- Keir

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

* Re: [Patch] "Helper" for  dom0/domU Kernels
  2007-04-27 15:33 ` Keir Fraser
@ 2007-04-27 19:23   ` Robert Valentan
  0 siblings, 0 replies; 3+ messages in thread
From: Robert Valentan @ 2007-04-27 19:23 UTC (permalink / raw)
  To: Keir Fraser; +Cc: xen-devel

[-- Attachment #1: Type: text/plain, Size: 647 bytes --]

Keir Fraser schrieb:
> On 27/4/07 16:26, "Robert Valentan" <R.Valentan@solid-soft.at> wrote:
> 
>> This patch add's a XEN_SPLIT_KERNEL to Config.mk and use it
>> in config/Linux.mk
>> This patch is also needed for my vnet-patch (some minutes before)
>> to get the kernel_src dir.
>>
>> Signed-off-by: Robert Valentan <R.Valentan@solid-soft.at>
> 
> Can't you just do some grep hack on the KERNELS variable in the vnet
> Makefile? I think it's enough that KERNELS can be overridden -- we don't
> need yet another top-level config option.

Attached the modified patch.

Signed-off-by: Robert Valentan <R.Valentan@solid-soft.at>

-- 
Robert Valentan

[-- Attachment #2: vnet_2.patch --]
[-- Type: text/x-patch, Size: 4407 bytes --]

diff -r ee16cdeddade tools/vnet/vnet-module/00README
--- a/tools/vnet/vnet-module/00README	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnet-module/00README	Fri Apr 27 22:19:39 2007
@@ -9,8 +9,8 @@
 LINUX_SERIES:   linux release to compile for: 2.4, or 2.6 (default).
 XEN_ROOT:       root of the xen tree containing kernel source.
 KERNEL_VERSION: kernel version, default got from XEN_ROOT.
-KERNEL_MINOR:   kernel minor version, default -xen0.
-KERNEL_SRC:     path to kernel source, default linux-<VERSION> under XEN_ROOT.
+KERNEL_SRC:     path to kernel source, default build-linux-<VERSION> 
+                under XEN_ROOT.
 
 *) For 2.4 kernel
 
diff -r ee16cdeddade tools/vnet/vnet-module/Makefile.ver
--- a/tools/vnet/vnet-module/Makefile.ver	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnet-module/Makefile.ver	Fri Apr 27 22:19:39 2007
@@ -19,7 +19,6 @@
 #============================================================================
 
 LINUX_SERIES?=2.6
-KERNEL_MINOR=-xen
 
 LINUX_VERSION?=$(shell (/bin/ls -d $(XEN_ROOT)/pristine-linux-$(LINUX_SERIES).* 2>/dev/null) | \
                       sed -e 's!^.*linux-\(.\+\)!\1!' )
@@ -28,22 +27,25 @@
 $(error Kernel source for linux $(LINUX_SERIES) not found)
 endif
 
-KERNEL_VERSION=$(LINUX_VERSION)$(KERNEL_MINOR)
+KERNEL_VERSION?=$(shell (/bin/ls -d $(XEN_ROOT)/build-linux-$(LINUX_VERSION)-xen* 2>/dev/null) | \
+                      grep -v -m 1 -e '-xenU' | \
+                      sed -e 's!^.*linux-\(.\+\)!\1!' )
 
-KERNEL_SRC?=$(shell cd $(XEN_ROOT)/linux-$(KERNEL_VERSION) && pwd)
+KERNEL_SRC ?= $(XEN_ROOT)/build-linux-$(KERNEL_VERSION)
 
 ifeq ($(KERNEL_SRC),)
 $(error Kernel source for kernel $(KERNEL_VERSION) not found)
 endif
 
 # Get the full kernel release version from its makefile, as the source path
-# may not have the extraversion, e.g. linux-2.6.12-xen0 may contain release 2.6.12.6-xen0.
+# may not have the extraversion, e.g. linux-2.6.12-xen0 may contain release 
+# 2.6.12.6-xen0.
 KERNEL_RELEASE=$(shell make -s -C $(KERNEL_SRC) kernelrelease)
 
-KERNEL_MODULE_DIR=/lib/modules/$$(KERNEL_RELEASE)/kernel
+KERNEL_MODULE_DIR=/lib/modules/$(KERNEL_RELEASE)/kernel
 
 $(warning KERNEL_SRC		$(KERNEL_SRC))
 $(warning LINUX_VERSION		$(LINUX_VERSION))
 $(warning KERNEL_VERSION	$(KERNEL_VERSION))
 $(warning KERNEL_RELEASE	$(KERNEL_RELEASE))
-$(warning KERNEL_ MODULE_DIR	$(KERNEL_MODULE_DIR))
+$(warning KERNEL_MODULE_DIR	$(KERNEL_MODULE_DIR))
diff -r ee16cdeddade tools/vnet/vnet-module/varp.c
--- a/tools/vnet/vnet-module/varp.c	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnet-module/varp.c	Fri Apr 27 22:19:39 2007
@@ -1530,12 +1530,7 @@
     dprintf("<\n");
 }
 
-#ifdef MODULE_PARM
-MODULE_PARM(varp_mcaddr, "s");
-MODULE_PARM(varp_device, "s");
-#else
 module_param(varp_mcaddr, charp, 0644);
 module_param(varp_device, charp, 0644);
-#endif
 MODULE_PARM_DESC(varp_mcaddr, "VARP multicast address");
 MODULE_PARM_DESC(varp_device, "VARP network device");
diff -r ee16cdeddade tools/vnet/vnet-module/vnet.c
--- a/tools/vnet/vnet-module/vnet.c	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnet-module/vnet.c	Fri Apr 27 22:19:39 2007
@@ -693,12 +693,7 @@
 module_exit(vnet_module_exit);
 MODULE_LICENSE("GPL");
 
-#ifdef MODULE_PARM
-MODULE_PARM(vnet_encaps, "s");
-#else
 module_param(vnet_encaps, charp, 0644);
+MODULE_PARM_DESC(vnet_encaps, "Vnet encapsulation: etherip or udp.");
+
 #endif
-
-MODULE_PARM_DESC(vnet_encaps, "Vnet encapsulation: etherip or udp.");
-
-#endif
diff -r ee16cdeddade tools/vnet/vnetd/Makefile
--- a/tools/vnet/vnetd/Makefile	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnetd/Makefile	Fri Apr 27 22:19:39 2007
@@ -16,7 +16,7 @@
 # Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 #----------------------------------------------------------------------------
 
-VNET_ROOT = $(shell cd .. && pwd)
+VNET_ROOT ?= $(shell cd .. && pwd)
 include $(VNET_ROOT)/Make.env
 
 .PHONY: all
@@ -26,6 +26,8 @@
 
 # Comment out when outside xen.
 #include $(XEN_ROOT)/tools/Rules.mk
+
+INSTALL_PROG ?= $(INSTALL) -m0755 -p
 
 VNETD_INSTALL_DIR = /usr/sbin
 
diff -r ee16cdeddade tools/vnet/vnetd/sys_kernel.h
--- a/tools/vnet/vnetd/sys_kernel.h	Wed Apr 25 09:39:08 2007
+++ b/tools/vnet/vnetd/sys_kernel.h	Fri Apr 27 22:19:39 2007
@@ -45,6 +45,7 @@
 #define module_exit(x)
 #define MODULE_LICENSE(x)
 #define MODULE_PARM(v, t)
+#define module_param(v, t, s)
 #define MODULE_PARM_DESC(v, s)
 
 enum {

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xensource.com
http://lists.xensource.com/xen-devel

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

end of thread, other threads:[~2007-04-27 19:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-04-27 15:26 [Patch] "Helper" for dom0/domU Kernels Robert Valentan
2007-04-27 15:33 ` Keir Fraser
2007-04-27 19:23   ` Robert Valentan

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.