Bug#346387: Support for Xen as a subarch status
Am 2006-04-12 14:16:35, schrieb Manoj Srivastava: Hi, A version of kernel-package is now being uploaded with a fix to this issue. Thank you! Greetings Michelle Konzack -- Linux-User #280138 with the Linux Counter, http://counter.li.org/ # Debian GNU/Linux Consultant # Michelle Konzack Apt. 917 ICQ #328449886 50, rue de Soultz MSM LinuxMichi 0033/3/8845235667100 Strasbourg/France IRC #Debian (irc.icq.com) -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch status
Hi, A version of kernel-package is now being uploaded with a fix to this issue. manoj -- When I woke up this morning, my girlfriend asked if I had slept well. I said, No, I made a few mistakes. -- Steven Wright Manoj Srivastava [EMAIL PROTECTED] http://www.debian.org/%7Esrivasta/ 1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch status
Hi! Xen 3.0.2 was released yeaterday and the new kernel patch shipped doesn't provide the xen arch any longer, making xen a subarchitecture of x86 as Tore has explained. The bad news is that now make-kpkg fails when trying to build a xen kernel... Here is the build log, it seems that kernel-package is looking for a xen arch even if none exists anymore, and I haven't told it to! Of course building the kernel with make and installing it with make install produces a working kernel... I was wondering about the status of this bug, or if I can help providing more information or in some other way, to have this fixed! (sid)[EMAIL PROTECTED]:/usr/src/xen/linux-2.6.16$ make-kpkg --rootcmd=fakeroot kernel_image exec debian/rules DEBIAN_REVISION=2.6.16-10.00.Custom ROOT_CMD=fakeroot kernel_image == making target CONFIG-common [new prereqs: testdir]== == making target CONFIG-common [new prereqs: stamp-conf]== This is kernel package version 10.040. == making stamp-arch-conf because of == == making target CONFIG-arch [new prereqs: stamp-arch-conf]== == making target conf.vars [new prereqs: Makefile .config]== Makefile:524: /usr/src/xen/linux-2.6.16/arch/xen/Makefile: No such file or directory make[1]: *** No rule to make target `/usr/src/xen/linux-2.6.16/arch/xen/Makefile'. Stop. make: *** [conf.vars] Error 2 (sid)[EMAIL PROTECTED]:/usr/src/xen/linux-2.6.16$ Thanks! Guido -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
* Tore Anderson I think that file is only used if ARCH=xen. Which is correct for all released versions of Xen, but the new implementation that eventually will be merged into the kernel sources use ARCH=i386 (or x86_64), and then you choose Xen-compatible when asked for Subarchitecture Type under Processor type and features in menuconfig. This sets CONFIG_X86_XEN=y. * Manoj Srivastava Have your tried make-kpkg with ARCH=xen? I think I see code that'll allowit to do the right thing. Hmm. I think we're talking past each other. I'll try to explain. When the Xen project started releasing kernel patches, they made Xen a completely separate architecture. To build it you needed ARCH=xen. All released versions of Xen use ARCH=xen, and make-kpkg are able to build packages of these kernels just fine. This bug report is not about those kernels, however. Now, the Xen people wanted to have their code accepted into Linus' tarball. However, the attitude of the people on LKML was something like: «Why do you need a completely separate arch/xen/ when 90% of the code is the same as in arch/i386/? Think about the code duplication and the maintenance nightmare it will be. We won't accept your patch before it improves on these issues.» So the Xen people, determined on getting their code into Linus' tree, went back to the drawing board and came up with a plan that should please the LKML people. Instead of having Xen a separate architecture, they made it a sub architecture of i386 (and x86_64, and in the future probably all other architectures Xen is ported to as well). In essence, that means that the arch/xen/ is removed, and all attempts to build the kernel with ARCH=xen will just fail with an error message such as (example of make oldconfig from the Mercurial pull of today): Makefile:449: /usr/src/linux-2.6-xen/arch/xen/Makefile: No such file or directory make: *** No rule to make target `/usr/src/linux-2.6-xen/arch/xen/Makefile'. Stop. Instead, all Xen-specific code are moved to arch/i386/mach-xen/ (for i386 at least). Now, in order to build a Xen kernel, you make your *config target of choice (using ARCH=i386), and when you are asked for Subarchitecture type (where most people select PC-compatible), you must instead select Xen-compatible. This sets CONFIG_X86_XEN=y. Then you can go on to build the kernel image as normal, still using ARCH=i386. But not bzImage, only vmlinuz - that's where make-kpkg currently fail. My bug report applies to these kernels only. To the best of my knowlegde, the only way to obtain such a kernel source is through the Mercurial repository. All released stable, alpha, beta, etc. versions are the old ARCH=xen way. But that will change as the Xen-as-subarch three reaches maturity; I doubt they want to maintain two separate source trees for very long, and the ARCH=xen way is a dead end due to the kernel maintainers' refusal to merge it. It seems the Xen-as-subarch tree is where the developers are at too, linux-2.6-xen.hg has been at 2.6.15 for some time, while xen-unstable.hg (where the most recent ARCH=xen code is found) is still at 2.6.12. I hope that cleared things up? :-) Kind regards -- Tore Anderson
Bug#346387: Support for Xen as a subarch
On Thu, 12 Jan 2006 17:37:11 +0100, Tore Anderson [EMAIL PROTECTED] said: * Manoj Srivastava I see code in /usr/share/kernel-package/ruleset/arches/xen.mk to call and use vmlinuz insted of bzImage for kernel versions later than 2.5.41 -- is the version check not good enough? I think that file is only used if ARCH=xen. Which is correct for all released versions of Xen, but the new implementation that eventually will be merged into the kernel sources use ARCH=i386 (or x86_64), and then you choose Xen-compatible when asked for Subarchitecture Type under Processor type and features in menuconfig. This sets CONFIG_X86_XEN=y. Have your tried make-kpkg with ARCH=xen? I think I see code that'll allowit to do the right thing. manoj -- Sometimes, too long is too long. Joe Crowe Manoj Srivastava [EMAIL PROTECTED] http://www.debian.org/%7Esrivasta/ 1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
Hi, I see code in /usr/share/kernel-package/ruleset/arches/xen.mk to call and use vmlinuz insted of bzImage for kernel versions later than 2.5.41 -- is the version check not good enough? manoj -- Mirrors should reflect a little before throwing back images. Jean Cocteau Manoj Srivastava [EMAIL PROTECTED] http://www.debian.org/%7Esrivasta/ 1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
* Manoj Srivastava I see code in /usr/share/kernel-package/ruleset/arches/xen.mk to call and use vmlinuz insted of bzImage for kernel versions later than 2.5.41 -- is the version check not good enough? I think that file is only used if ARCH=xen. Which is correct for all released versions of Xen, but the new implementation that eventually will be merged into the kernel sources use ARCH=i386 (or x86_64), and then you choose Xen-compatible when asked for Subarchitecture Type under Processor type and features in menuconfig. This sets CONFIG_X86_XEN=y. -- Tore Anderson -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
Hi, I would be happy to add support, but I do not use Xen, and I can't test it. If you could tell me how you build Xen images manually (without kernel-package, just with the KConfig build system), and any suggestions on how one could distinguish between a normal i386 build and otherwise, I'll see what I can do to provide you with functionality for you to test. manoj -- I'm a Lisp variable -- bind me! Manoj Srivastava [EMAIL PROTECTED] http://www.debian.org/%7Esrivasta/ 1024D/BF24424C print 4966 F272 D093 B493 410B 924B 21BA DABB BF24 424C -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
* Manoj Srivastava I would be happy to add support, but I do not use Xen, and I can't test it. If you could tell me how you build Xen images manually (without kernel-package, just with the KConfig build system), and any suggestions on how one could distinguish between a normal i386 build and otherwise, I'll see what I can do to provide you with functionality for you to test. Hi Manoj. The only difference is that the generated kernel image is found in /usr/src/linux/vmlinuz instead of in /usr/src/linux/arch/i386/boot/bzImage. This is probably only because the kernel image doesn't need a boot sector, it's the Xen hypervisor (which isn't Linux at all) that are actually booted from Grub; the kernel image itself is in turn executed/booted from the Xen hypervisor, which has already done all the nasty stuff (bringing the CPU into protected mode, enabling additional CPUs, etc). Anyway, when I run make-kpkg I see that it attempts to do make the bzImage target, which is just a stub when CONFIG_X86_XEN=y is set, and does nothing (successfully). What is necessary is to make the vmlinuz target (or vmlinux for that matter), which will create the kernel image. When I build the kernels I actually use make-kpkg, but I build vmlinuz manually and then fool make-kpkg a bit with a symlink from bzImage. My small script for doing so is like this: REV=`date +%Y%m%d` make vmlinuz EXTRAVERSION=-xen$REV ln -sf ../../../vmlinuz arch/i386/boot/bzImage make-kpkg --initrd --rootcmd fakeroot --revision $REV --append-to-version -xen$REV --stem linux kernel_image ...which builds a linux-image.deb which works perfectly. So it's just a matter of figuring out when to use vmlinuz instead of bzImage. Maybe just grepping for CONFIG_X86_XEN=y in .config is adequate, but I don't think that will work with ia64 or x86_64 and I would assume you want a generic solution. Maybe simply a --use-vmlinuz-instead-of-bzImage command line option would suffice. In case you want to play around with this yourself and haven't used Mercurial before I'll include an ultra-concise guide to getting the Xen-as-subarch source tree here: apt-get install mercurial mkdir /usr/src/linux-2.6-xen cd /usr/src/linux-2.6-xen hg init . echo $'[paths]\ndefault = http://xenbits.xensource.com/linux-2.6-xen.hg' .hg/hgrc hg pull -u Kind regards -- Tore Anderson -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#346387: Support for Xen as a subarch
Package: kernel-package Severity: wishlist Hi. It seems make-kpkg fails at building a kernel image with Xen as an x86 subarch, because it expects a bzImage, whereas Xen can only start plain vmlinuz images (the Xen hypervisor itself is the only thing that needs an x86 boot sector). It would be really nice if make-kpkg supported this, as it appears this is the way the Xen port of Linux will be in the future. (The kernel developers refused to merge Xen as a separate architecture.) The subarch developement tree may be found in the Mercurial repository at http://xenbits.xensource.com/linux-2.6-xen.hg, by the way. Kind regards -- Tore Anderson -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]