From: Ian Campbell <ian.campbell@citrix.com>
To: ian.jackson@eu.citrix.com
Cc: Ian Campbell <ian.campbell@citrix.com>, xen-devel@lists.xen.org
Subject: [PATCH 06/10] ts-host-install: Add need-kernel-deb host flag
Date: Wed, 4 Sep 2013 17:58:19 +0100 [thread overview]
Message-ID: <1378313903-10539-6-git-send-email-ian.campbell@citrix.com> (raw)
In-Reply-To: <1378313870.17510.172.camel@kazak.uk.xensource.com>
This can be used to request a specific kernel binary and initrd overlay (for
modules). These are already collected and created by
mg-debian-installer-update for the armhf "armmp" flavour.
---
ts-host-install | 29 ++++++++++++++++++++++++++++-
1 file changed, 28 insertions(+), 1 deletion(-)
diff --git a/ts-host-install b/ts-host-install
index b974365..9151940 100755
--- a/ts-host-install
+++ b/ts-host-install
@@ -130,6 +130,8 @@ sub setup_pxeboot_firstboot($) {
my $src_initrd= "$d_i/initrd.gz";
my @initrds= "$c{TftpPath}/$src_initrd";
+ my $kernel;
+
foreach my $fp (keys %{ $ho->{Flags} }) {
$fp =~ s/^need-firmware-deb-// or next;
my $cpio= "$c{TftpPath}/$d_i/$fp.cpio.gz";
@@ -143,6 +145,31 @@ sub setup_pxeboot_firstboot($) {
}
}
+ foreach my $kp (keys %{ $ho->{Flags} }) {
+ $kp =~ s/need-kernel-deb-// or next;
+ my $kern= "$c{TftpPath}/$d_i/linux.$kp";
+ if (stat $kern) {
+ logm("using kernel from: $kern");
+ $kernel = "/$d_i/linux.$kp";
+ } elsif ($! == &ENOENT) {
+ logm("warning: no kernel found for $kp at $kern");
+ } else {
+ die "$kp $kern $!";
+ }
+
+ my $cpio= "$c{TftpPath}/$d_i/$kp.cpio.gz";
+ if (stat $cpio) {
+ logm("using kernel modules from: $cpio");
+ push @initrds, $cpio;
+ } elsif ($! == &ENOENT) {
+ logm("warning: no kernel module cpio found for $kp at $cpio");
+ } else {
+ die "$kp $cpio $!";
+ }
+ }
+
+ $kernel = "/$d_i/linux" unless $kernel;
+
my $initrd_overlay= "tmp/t.$ho->{Name}.initrd";
system qw(rm -rf --),"$initrd_overlay.d";
mkdir "$initrd_overlay.d" or die "$initrd_overlay.d: $!";
@@ -190,7 +217,7 @@ timeout 5
label overwrite
menu label ^Overwrite
menu default
- kernel /$d_i/linux
+ kernel $kernel
append $installcmdline
default overwrite
END
--
1.7.10.4
next prev parent reply other threads:[~2013-09-04 16:58 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-04 16:57 [PATCH osstest 00/10] Add initial support for testing arm32 on arm servers (Calxeda Midway) Ian Campbell
2013-09-04 16:58 ` [PATCH 01/10] README: Point to current test report mail Ian Campbell
2013-09-04 16:58 ` [PATCH 02/10] Allow hyphen in host names when parsing properties Ian Campbell
2013-09-04 16:58 ` [PATCH 03/10] standalone-reset: configure for armhf too Ian Campbell
2013-09-04 16:58 ` [PATCH 04/10] mg-debian-installer-update: support armhf Ian Campbell
2013-09-04 16:58 ` [PATCH 05/10] ts-host-install: Support for different console devices Ian Campbell
2013-09-04 16:58 ` Ian Campbell [this message]
2013-09-04 16:58 ` [PATCH 07/10] Debian: Honour need-kernel-deb- flag in the installed system too Ian Campbell
2013-09-04 16:58 ` [PATCH 08/10] Debian: New host flag need-uboot-bootstr Ian Campbell
2013-09-04 16:58 ` [PATCH 09/10] Debian: New host flag "no-di-kernel" Ian Campbell
2013-09-04 16:58 ` [PATCH 10/10] make-flight: make an armhf flight Ian Campbell
2013-09-04 17:42 ` [PATCH osstest 00/10] Add initial support for testing arm32 on arm servers (Calxeda Midway) Ian Campbell
2013-09-05 11:27 ` Ian Campbell
2013-09-05 11:31 ` Ian Jackson
2013-09-05 11:36 ` Ian Campbell
2013-09-06 15:12 ` Ian Campbell
2013-09-06 16:13 ` Ian Jackson
2013-09-09 9:51 ` Ian Campbell
2013-09-10 16:54 ` Ian Jackson
2013-09-11 9:24 ` Ian Campbell
2013-09-11 16:17 ` Ian Jackson
2013-09-12 8:46 ` Ian Campbell
2013-09-12 11:00 ` Ian Jackson
2013-09-12 11:19 ` Ian Campbell
2013-09-12 14:22 ` Ian Jackson
2013-09-12 14:27 ` Ian Campbell
2013-09-12 11:28 ` Ian Campbell
2013-09-12 14:46 ` Ian Jackson
2013-09-10 16:54 ` Ian Jackson
2013-09-09 10:01 ` Ian Campbell
2013-09-09 10:34 ` Ian Campbell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1378313903-10539-6-git-send-email-ian.campbell@citrix.com \
--to=ian.campbell@citrix.com \
--cc=ian.jackson@eu.citrix.com \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).