[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Support for sunxi-based ARM systems in d-i



On Thu, May 08, 2014 at 09:20:33PM +0100, Ian Campbell wrote:
> On Tue, 2014-05-06 at 21:24 +0200, Karsten Merker wrote:
> > So this means that on an armhf system set up by d-i, the symlinks
> > are actually in place where we need them for the boot scripts.  I
> > am very short on time at the moment, so I can't work on the
> > topic now, but I'll look into it again some time later this week.
> 
> It was mostly a case of cherry picking the bits of your patch which were
> still needed and since I had a few spare moments this evening it took a
> stab at it (I hope that's ok), the result is attached.
              ^^^^^^^^^^^^^^^^
Of course!

> Works for me on a DI installed system with 3.14-1-armmp built from SVN.
> My u-boot bootcmd is:
>         scsi scan;setenv device scsi;setenv partition 0;load ${device}
>         ${partition} ${scriptaddr} boot.scr;source ${scriptaddr}

I have run a few tests with your patchset and everything looks ok
as far as I can tell. Attached is a tiny additional patch to the
manpage to document the new "--force" option.

While running the tests I have stumbled over another issue that needs
to be tackled with regard to d-i.  Currently flash-kernel is not run
within d-i on an armhf/armmp system, due to
flash-kernel-installer.isinstallable only allowing it to be run for
specific archdetect results (covering iop32x, ixp4xx, kirkwood, mx5,
orion5x and s3c24xx).  Is there a specific reason why machine support
is checked using a list of archdetect results and not directly via the
flash-kernel machine db using the according functions (which are both
available in the flash-kernel-installer udeb)?

Having a separate list based on archdetect means additional information
to keep up to date and has other problems as well in the context of
multiplatform kernels: when adding armhf/generic to the list,
flash-kernel gets run in the "make the system bootable" step, but it
causes d-i do stop with a rather unspecific error if the particular
system is technically supported by the armmp kernel but does not have a
machine db entry in flash-kernel.  Responsible is the following
fragment of the flash-kernel main() function:

if ! check_supported "$machine"; then
        error "Unsupported platform."
fi

which exits with a return code of 1 and causes d-i to output

                Installation step failed
 An installation step failed. You can try to run the failing item
 again from the menu, or skip it and choose something else. The  
 failing step is: Make the system bootable

When checking platform support flash-kernel-installer.isinstallable
based on the flash-kernel machine db, this problem does not occur.

Regards,
Karsten
-- 
Gem. Par. 28 Abs. 4 Bundesdatenschutzgesetz widerspreche ich der Nutzung
sowie der Weitergabe meiner personenbezogenen Daten für Zwecke der
Werbung sowie der Markt- oder Meinungsforschung.
>From c60b6f324462fa68add369d69f287291b05d4a12 Mon Sep 17 00:00:00 2001
From: Karsten Merker <merker@debian.org>
Date: Sat, 10 May 2014 17:03:53 +0200
Subject: [PATCH] Document the --force option in the manpage.

---
 flash-kernel.8 | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/flash-kernel.8 b/flash-kernel.8
index 7b5bad5..ef61d4a 100644
--- a/flash-kernel.8
+++ b/flash-kernel.8
@@ -3,7 +3,7 @@
 .SH NAME
 flash-kernel \- put kernel and initramfs in boot location
 .SH SYNOPSIS
-.B flash-kernel [--supported] [kvers]
+.B flash-kernel [--supported] [--force] [kvers]
 .SH DESCRIPTION
 flash-kernel is a script which will put the kernel and initramfs in
 the boot location of embedded devices that don't load the kernel and
@@ -13,7 +13,8 @@ require a special boot image on the disk.
 .P
 Optionally, it can be passed a version of the kernel to flash; only
 the highest version will be flashed and other versions will be
-ignored.  Kernel and initrd are read from /boot.
+ignored unless the \-\-force option is used. Kernel and initrd are
+read from /boot.
 .P
 Prior to flashing the kernel, a check is performed to verify that
 the subarchitectures of the machine and the image to be flashed
-- 
2.0.0.rc2


Reply to: