Debian Bug report logs - #731345
flash-kernel: add support for DT based kernels on Sheeva Plug

version graph

Package: flash-kernel; Maintainer for flash-kernel is Debian Install System Team <debian-boot@lists.debian.org>; Source for flash-kernel is src:flash-kernel (PTS, buildd, popcon).

Reported by: Marc Kleine-Budde <mkl@blackshift.org>

Date: Wed, 4 Dec 2013 13:27:02 UTC

Severity: normal

Tags: patch

Found in version flash-kernel/3.11

Fixed in version flash-kernel/3.12

Done: Ian Campbell <ijc@hellion.org.uk>

Bug is archived. No further changes may be made.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 04 Dec 2013 13:27:07 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
New Bug report received and forwarded. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 04 Dec 2013 13:27:07 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Wed, 04 Dec 2013 14:23:58 +0100
[Message part 1 (text/plain, inline)]
Package: flash-kernel
Version: 3.11
Severity: normal
Tags: patch

Hello, I've two patches to support DT based kernel on Sheeva
Plug. These patches are needed to boot 3.12 (which is currently in
experimental).

regards,
Marc

-- System Information:
Debian Release: jessie/sid
  APT prefers testing
  APT policy: (700, 'testing'), (70, 'experimental'), (70, 'unstable')
Architecture: armel (armv5tel)

Kernel: Linux 3.12-trunk-kirkwood
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages flash-kernel depends on:
ii  devio            1.2-1+b1
ii  initramfs-tools  0.115
ii  linux-base       3.5

flash-kernel recommends no packages.

Versions of packages flash-kernel suggests:
ii  u-boot-tools  2013.01.01-4

-- no debconf information
[0001-all.db-add-dtb-support-for-Sheeva-Plug.patch (text/x-diff, attachment)]
[0002-all.db-add-section-for-DT-based-Sheeva-Plug.patch (text/x-diff, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 10:54:04 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 10:54:04 GMT) (full text, mbox, link).


Message #10 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Martin Michlmayr <tbm@cyrius.com>
Cc: 731345@bugs.debian.org, Ian Campbell <ijc@hellion.org.uk>
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 11:49:45 +0100
[Message part 1 (text/plain, inline)]
On 12/05/2013 11:43 AM, Martin Michlmayr wrote:
> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-04 14:23]:
>> Hello, I've two patches to support DT based kernel on Sheeva
>> Plug. These patches are needed to boot 3.12 (which is currently in
>> experimental).
> 
> When I spoke to Ian Campbell recently, I got the impression that the
> plan was to keep devices that were not using DT in wheezy as non-DT
> in future releases.  So maybe the kernel config for 3.12 should be
> changed?

That's no option, as non DT Sheeva Plug support has been removed from
the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:

ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug

This patch was first released on mainline linux in v3.12-rc1.

Marc

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 10:57:07 GMT) (full text, mbox, link).


Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 10:57:07 GMT) (full text, mbox, link).


Message #15 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Martin Michlmayr <tbm@cyrius.com>
To: Marc Kleine-Budde <mkl@blackshift.org>, 731345@bugs.debian.org
Cc: Ian Campbell <ijc@hellion.org.uk>
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 5 Dec 2013 10:43:21 +0000
* Marc Kleine-Budde <mkl@blackshift.org> [2013-12-04 14:23]:
> Hello, I've two patches to support DT based kernel on Sheeva
> Plug. These patches are needed to boot 3.12 (which is currently in
> experimental).

When I spoke to Ian Campbell recently, I got the impression that the
plan was to keep devices that were not using DT in wheezy as non-DT
in future releases.  So maybe the kernel config for 3.12 should be
changed?

-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 11:39:04 GMT) (full text, mbox, link).


Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 11:39:04 GMT) (full text, mbox, link).


Message #20 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Martin Michlmayr <tbm@cyrius.com>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: 731345@bugs.debian.org, Ian Campbell <ijc@hellion.org.uk>
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 5 Dec 2013 11:34:06 +0000
* Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> That's no option, as non DT Sheeva Plug support has been removed from
> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> 
> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug

Interesting.  I thought they promised not to remove non-DT support for
existing devices.

Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
add a check to flash-kernel whether DT is required or not.  i.e. that
flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
but not on previous kernels.

-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 11:48:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 11:48:04 GMT) (full text, mbox, link).


Message #25 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Martin Michlmayr <tbm@cyrius.com>
Cc: Marc Kleine-Budde <mkl@blackshift.org>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 11:45:00 +0000
On Thu, 2013-12-05 at 11:34 +0000, Martin Michlmayr wrote:
> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> > That's no option, as non DT Sheeva Plug support has been removed from
> > the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> > 
> > ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> 
> Interesting.  I thought they promised not to remove non-DT support for
> existing devices.

Yes :-/

> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> add a check to flash-kernel whether DT is required or not.  i.e. that
> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> but not on previous kernels.

That was my thought -- whether flash-kernel would ignore the DT if it
wasn't present in the kernel package or if it would fail?

We want to support upgrading flash-kernel without upgrading the kernel,
or if you want to downgrade your kernel for some reason, so it needs to
cope gracefully.

We probably do need some sort of relationship between the kernel image
and f-k though such that f-k gets upgraded at the same time. Since we
don't have a dependency (because some platforms don't need/use f-k) what
should that relationship be? Does a Breaks do the trick?

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 11:48:08 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 11:48:08 GMT) (full text, mbox, link).


Message #30 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Martin Michlmayr <tbm@cyrius.com>
Cc: 731345@bugs.debian.org, Ian Campbell <ijc@hellion.org.uk>
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 12:46:06 +0100
[Message part 1 (text/plain, inline)]
On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
>> That's no option, as non DT Sheeva Plug support has been removed from
>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
>>
>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> 
> Interesting.  I thought they promised not to remove non-DT support for
> existing devices.

I personally don't mind, if it's removed once the DT works properly.

> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> add a check to flash-kernel whether DT is required or not.  i.e. that
> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> but not on previous kernels.

Yes, sounds like the way to go. Otherwise you have to tie certain
flash-kernel versions to the non-DT and DT kernels. This will probably
not scale when more no-DT board are removed from the kernel.

Where should this information go? What about adding another field to
all.db which limits an entry to certain kernel versions? Something like
this:

Machine: Marvell SheevaPlug Reference Board
Kernel-Flavors: kirkwood
Kernel-Version: < 3.12
U-Boot-Kernel-Address: 0x00008000
U-Boot-Initrd-Address: 0x0
Boot-Kernel-Path: /boot/uImage
Boot-Initrd-Path: /boot/uInitrd
Required-Packages: u-boot-tools
Bootloader-Sets-Root: no

Machine: Marvell SheevaPlug Reference Board
Kernel-Flavors: kirkwood
Kernel-Version: >= 3.12
DTB-Id: kirkwood-sheevaplug.dtb
DTB-Append: yes
U-Boot-Kernel-Address: 0x00008000
U-Boot-Initrd-Address: 0x0
Boot-Kernel-Path: /boot/uImage
Boot-Initrd-Path: /boot/uInitrd
Boot-DTB-Path: dtb
Required-Packages: u-boot-tools
Bootloader-Sets-Root: no

Marc


[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 12:00:10 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 12:00:10 GMT) (full text, mbox, link).


Message #35 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 11:57:35 +0000
On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
> > * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> >> That's no option, as non DT Sheeva Plug support has been removed from
> >> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> >>
> >> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> > 
> > Interesting.  I thought they promised not to remove non-DT support for
> > existing devices.
> 
> I personally don't mind, if it's removed once the DT works properly.
> 
> > Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> > add a check to flash-kernel whether DT is required or not.  i.e. that
> > flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> > but not on previous kernels.
> 
> Yes, sounds like the way to go. Otherwise you have to tie certain
> flash-kernel versions to the non-DT and DT kernels. This will probably
> not scale when more no-DT board are removed from the kernel.
> 
> Where should this information go? What about adding another field to
> all.db which limits an entry to certain kernel versions? Something like
> this:

I think it would be sufficient to have a field marking the DTB as
optional and have f-k only do the append if there is a dtb present in
the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
bug in the kernel (until we get to the point of burning DTBs into
firmware, but lets not worry about that now!).

I take it from your original patches that the machine ID differs with DT
vs non as well?

> 
> Machine: Marvell SheevaPlug Reference Board
> Kernel-Flavors: kirkwood
> Kernel-Version: < 3.12
> U-Boot-Kernel-Address: 0x00008000
> U-Boot-Initrd-Address: 0x0
> Boot-Kernel-Path: /boot/uImage
> Boot-Initrd-Path: /boot/uInitrd
> Required-Packages: u-boot-tools
> Bootloader-Sets-Root: no
> 
> Machine: Marvell SheevaPlug Reference Board
> Kernel-Flavors: kirkwood
> Kernel-Version: >= 3.12
> DTB-Id: kirkwood-sheevaplug.dtb
> DTB-Append: yes
> U-Boot-Kernel-Address: 0x00008000
> U-Boot-Initrd-Address: 0x0
> Boot-Kernel-Path: /boot/uImage
> Boot-Initrd-Path: /boot/uInitrd
> Boot-DTB-Path: dtb
> Required-Packages: u-boot-tools
> Bootloader-Sets-Root: no
> 
> Marc
> 
> 





Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 12:09:19 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 12:09:19 GMT) (full text, mbox, link).


Message #40 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Ian Campbell <ijc@hellion.org.uk>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 13:04:54 +0100
[Message part 1 (text/plain, inline)]
On 12/05/2013 12:57 PM, Ian Campbell wrote:
> On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
>> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
>>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
>>>> That's no option, as non DT Sheeva Plug support has been removed from
>>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
>>>>
>>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
>>>
>>> Interesting.  I thought they promised not to remove non-DT support for
>>> existing devices.
>>
>> I personally don't mind, if it's removed once the DT works properly.
>>
>>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
>>> add a check to flash-kernel whether DT is required or not.  i.e. that
>>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
>>> but not on previous kernels.
>>
>> Yes, sounds like the way to go. Otherwise you have to tie certain
>> flash-kernel versions to the non-DT and DT kernels. This will probably
>> not scale when more no-DT board are removed from the kernel.
>>
>> Where should this information go? What about adding another field to
>> all.db which limits an entry to certain kernel versions? Something like
>> this:
> 
> I think it would be sufficient to have a field marking the DTB as
> optional and have f-k only do the append if there is a dtb present in
> the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
> handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
> bug in the kernel (until we get to the point of burning DTBs into
> firmware, but lets not worry about that now!).

...or when the DT sources will be move into a separate repository.

> I take it from your original patches that the machine ID differs with DT
> vs non as well?

Yes, this is why the second patch adds another entry.

Marc

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 12:18:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 12:18:04 GMT) (full text, mbox, link).


Message #45 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 12:15:46 +0000
On Thu, 2013-12-05 at 13:04 +0100, Marc Kleine-Budde wrote:
> On 12/05/2013 12:57 PM, Ian Campbell wrote:
> > On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
> >> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
> >>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> >>>> That's no option, as non DT Sheeva Plug support has been removed from
> >>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> >>>>
> >>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> >>>
> >>> Interesting.  I thought they promised not to remove non-DT support for
> >>> existing devices.
> >>
> >> I personally don't mind, if it's removed once the DT works properly.
> >>
> >>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> >>> add a check to flash-kernel whether DT is required or not.  i.e. that
> >>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> >>> but not on previous kernels.
> >>
> >> Yes, sounds like the way to go. Otherwise you have to tie certain
> >> flash-kernel versions to the non-DT and DT kernels. This will probably
> >> not scale when more no-DT board are removed from the kernel.
> >>
> >> Where should this information go? What about adding another field to
> >> all.db which limits an entry to certain kernel versions? Something like
> >> this:
> > 
> > I think it would be sufficient to have a field marking the DTB as
> > optional and have f-k only do the append if there is a dtb present in
> > the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
> > handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
> > bug in the kernel (until we get to the point of burning DTBs into
> > firmware, but lets not worry about that now!).
> 
> ...or when the DT sources will be move into a separate repository.

Indeed.

Actually, now that I think about it -- a non-DT aware kernel just
shouldn't care if you append a DT to it, it won't ever go looking. It's
probably safe to just append it unconditionally.

Which is what you did, so we've come full circle, sorry for the
distraction.

I suppose it would be nice to just check that the Wheezy kernel doesn't
complain about or get confused by the appended DTB. Can you check that?

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 12:42:12 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 12:42:12 GMT) (full text, mbox, link).


Message #50 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Ian Campbell <ijc@hellion.org.uk>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 13:39:57 +0100
[Message part 1 (text/plain, inline)]
On 12/05/2013 01:15 PM, Ian Campbell wrote:
> On Thu, 2013-12-05 at 13:04 +0100, Marc Kleine-Budde wrote:
>> On 12/05/2013 12:57 PM, Ian Campbell wrote:
>>> On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
>>>> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
>>>>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
>>>>>> That's no option, as non DT Sheeva Plug support has been removed from
>>>>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
>>>>>>
>>>>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
>>>>>
>>>>> Interesting.  I thought they promised not to remove non-DT support for
>>>>> existing devices.
>>>>
>>>> I personally don't mind, if it's removed once the DT works properly.
>>>>
>>>>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
>>>>> add a check to flash-kernel whether DT is required or not.  i.e. that
>>>>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
>>>>> but not on previous kernels.
>>>>
>>>> Yes, sounds like the way to go. Otherwise you have to tie certain
>>>> flash-kernel versions to the non-DT and DT kernels. This will probably
>>>> not scale when more no-DT board are removed from the kernel.
>>>>
>>>> Where should this information go? What about adding another field to
>>>> all.db which limits an entry to certain kernel versions? Something like
>>>> this:
>>>
>>> I think it would be sufficient to have a field marking the DTB as
>>> optional and have f-k only do the append if there is a dtb present in
>>> the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
>>> handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
>>> bug in the kernel (until we get to the point of burning DTBs into
>>> firmware, but lets not worry about that now!).
>>
>> ...or when the DT sources will be move into a separate repository.
> 
> Indeed.
> 
> Actually, now that I think about it -- a non-DT aware kernel just
> shouldn't care if you append a DT to it, it won't ever go looking. It's
> probably safe to just append it unconditionally.

Yes, should be safe.

> Which is what you did, so we've come full circle, sorry for the
> distraction.

It's good to talk about the implications. If we want to handle
downgrading of kernels with an updated flash-kernel, I think, that
cannot be done without an additional Kernel-Version field.

This is because v3.11 ships with:

/usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb

But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
is used with current flash-kernel and v3.11. Although v3.10 and v3.11
are not Wheezy's kernels.

> I suppose it would be nice to just check that the Wheezy kernel doesn't
> complain about or get confused by the appended DTB. Can you check that?

I don't have physical access to that Sheeva Plug.

Marc

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 17:12:14 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 17:12:14 GMT) (full text, mbox, link).


Message #55 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 17:01:41 +0000
On Thu, 2013-12-05 at 13:39 +0100, Marc Kleine-Budde wrote:
> On 12/05/2013 01:15 PM, Ian Campbell wrote:
> > On Thu, 2013-12-05 at 13:04 +0100, Marc Kleine-Budde wrote:
> >> On 12/05/2013 12:57 PM, Ian Campbell wrote:
> >>> On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
> >>>> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
> >>>>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> >>>>>> That's no option, as non DT Sheeva Plug support has been removed from
> >>>>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> >>>>>>
> >>>>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> >>>>>
> >>>>> Interesting.  I thought they promised not to remove non-DT support for
> >>>>> existing devices.
> >>>>
> >>>> I personally don't mind, if it's removed once the DT works properly.
> >>>>
> >>>>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> >>>>> add a check to flash-kernel whether DT is required or not.  i.e. that
> >>>>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> >>>>> but not on previous kernels.
> >>>>
> >>>> Yes, sounds like the way to go. Otherwise you have to tie certain
> >>>> flash-kernel versions to the non-DT and DT kernels. This will probably
> >>>> not scale when more no-DT board are removed from the kernel.
> >>>>
> >>>> Where should this information go? What about adding another field to
> >>>> all.db which limits an entry to certain kernel versions? Something like
> >>>> this:
> >>>
> >>> I think it would be sufficient to have a field marking the DTB as
> >>> optional and have f-k only do the append if there is a dtb present in
> >>> the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
> >>> handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
> >>> bug in the kernel (until we get to the point of burning DTBs into
> >>> firmware, but lets not worry about that now!).
> >>
> >> ...or when the DT sources will be move into a separate repository.
> > 
> > Indeed.
> > 
> > Actually, now that I think about it -- a non-DT aware kernel just
> > shouldn't care if you append a DT to it, it won't ever go looking. It's
> > probably safe to just append it unconditionally.
> 
> Yes, should be safe.
> 
> > Which is what you did, so we've come full circle, sorry for the
> > distraction.
> 
> It's good to talk about the implications. If we want to handle
> downgrading of kernels with an updated flash-kernel, I think, that
> cannot be done without an additional Kernel-Version field.
> 
> This is because v3.11 ships with:
> 
> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
> 
> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
> are not Wheezy's kernels.

Is 3.11+DTB actively broken though?

> > I suppose it would be nice to just check that the Wheezy kernel doesn't
> > complain about or get confused by the appended DTB. Can you check that?
> 
> I don't have physical access to that Sheeva Plug.

Hrm, this would be something which would be good to try somewhere.

Now I think of it the Wheezy kirkwood kernel did have DT and
APPENDED_DTB support enabled, in order to support dreamplugs.

I have a feeling that would mean that it wouldn't boot if you appended a
dtb to it. Which would mean we do have to think about versioned checks
or something.

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Thu, 05 Dec 2013 17:45:11 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Thu, 05 Dec 2013 17:45:11 GMT) (full text, mbox, link).


Message #60 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Ian Campbell <ijc@hellion.org.uk>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Thu, 05 Dec 2013 18:42:13 +0100
[Message part 1 (text/plain, inline)]
On 12/05/2013 06:01 PM, Ian Campbell wrote:
> On Thu, 2013-12-05 at 13:39 +0100, Marc Kleine-Budde wrote:
>> On 12/05/2013 01:15 PM, Ian Campbell wrote:
>>> On Thu, 2013-12-05 at 13:04 +0100, Marc Kleine-Budde wrote:
>>>> On 12/05/2013 12:57 PM, Ian Campbell wrote:
>>>>> On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
>>>>>> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
>>>>>>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
>>>>>>>> That's no option, as non DT Sheeva Plug support has been removed from
>>>>>>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
>>>>>>>>
>>>>>>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
>>>>>>>
>>>>>>> Interesting.  I thought they promised not to remove non-DT support for
>>>>>>> existing devices.
>>>>>>
>>>>>> I personally don't mind, if it's removed once the DT works properly.
>>>>>>
>>>>>>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
>>>>>>> add a check to flash-kernel whether DT is required or not.  i.e. that
>>>>>>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
>>>>>>> but not on previous kernels.
>>>>>>
>>>>>> Yes, sounds like the way to go. Otherwise you have to tie certain
>>>>>> flash-kernel versions to the non-DT and DT kernels. This will probably
>>>>>> not scale when more no-DT board are removed from the kernel.
>>>>>>
>>>>>> Where should this information go? What about adding another field to
>>>>>> all.db which limits an entry to certain kernel versions? Something like
>>>>>> this:
>>>>>
>>>>> I think it would be sufficient to have a field marking the DTB as
>>>>> optional and have f-k only do the append if there is a dtb present in
>>>>> the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
>>>>> handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
>>>>> bug in the kernel (until we get to the point of burning DTBs into
>>>>> firmware, but lets not worry about that now!).
>>>>
>>>> ...or when the DT sources will be move into a separate repository.
>>>
>>> Indeed.
>>>
>>> Actually, now that I think about it -- a non-DT aware kernel just
>>> shouldn't care if you append a DT to it, it won't ever go looking. It's
>>> probably safe to just append it unconditionally.
>>
>> Yes, should be safe.
>>
>>> Which is what you did, so we've come full circle, sorry for the
>>> distraction.
>>
>> It's good to talk about the implications. If we want to handle
>> downgrading of kernels with an updated flash-kernel, I think, that
>> cannot be done without an additional Kernel-Version field.
>>
>> This is because v3.11 ships with:
>>
>> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
>>
>> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
>> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
>> are not Wheezy's kernels.
> 
> Is 3.11+DTB actively broken though?

v3.11+DT works on Sheeva Plug, just tested it.

I was thinking of the following scenario:

I have installed current flash-kernel (without DT support) and kernel
v3.11. Then the new flash-kernel with
append-DT-if-present-in-the-Kernel-package feature is released together
with a new DT only kernel (=v3.12). I upgrade, because I want to have
the shiny new kernel.

For whatever reason I want to downgrade to v3.11, then I end up with
v3.11 with DT, because the flash-kernel is still the new one.

The system does not behave as I expected. I downgraded to the same
kernel but now the DT Sheeva Plug is booted.

Although the bootloader sets the ARCH number, a attached DT seems to be
preferred.

>>> I suppose it would be nice to just check that the Wheezy kernel doesn't
>>> complain about or get confused by the appended DTB. Can you check that?
>>
>> I don't have physical access to that Sheeva Plug.
> 
> Hrm, this would be something which would be good to try somewhere.

On Wheezy there is no Sheevaplug DTB to attach...

> Now I think of it the Wheezy kirkwood kernel did have DT and
> APPENDED_DTB support enabled, in order to support dreamplugs.

http://packages.debian.org/wheezy/armel/linux-image-3.2.0-4-kirkwood/filelist

Wheezy has two dtb files:

/usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-dreamplug.dtb
/usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-iconnect.dtb

> I have a feeling that would mean that it wouldn't boot if you appended a
> dtb to it. Which would mean we do have to think about versioned checks
> or something.

Just stating the obvious: The Sheeva Plug probably wouldn't boot if I
attach a dreamplug dtb to it. :)

Marc

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Fri, 06 Dec 2013 08:33:08 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Fri, 06 Dec 2013 08:33:08 GMT) (full text, mbox, link).


Message #65 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Fri, 06 Dec 2013 08:31:40 +0000
[Message part 1 (text/plain, inline)]
On Thu, 2013-12-05 at 18:42 +0100, Marc Kleine-Budde wrote:
> On 12/05/2013 06:01 PM, Ian Campbell wrote:
> > On Thu, 2013-12-05 at 13:39 +0100, Marc Kleine-Budde wrote:
> >> On 12/05/2013 01:15 PM, Ian Campbell wrote:
> >>> On Thu, 2013-12-05 at 13:04 +0100, Marc Kleine-Budde wrote:
> >>>> On 12/05/2013 12:57 PM, Ian Campbell wrote:
> >>>>> On Thu, 2013-12-05 at 12:46 +0100, Marc Kleine-Budde wrote:
> >>>>>> On 12/05/2013 12:34 PM, Martin Michlmayr wrote:
> >>>>>>> * Marc Kleine-Budde <mkl@blackshift.org> [2013-12-05 11:49]:
> >>>>>>>> That's no option, as non DT Sheeva Plug support has been removed from
> >>>>>>>> the kernel in ffbc50663b69462adc9d97b93b6b92c4fe74b94c:
> >>>>>>>>
> >>>>>>>> ffbc506 ARM: kirkwood: remove support for legacy booting of Sheevaplug
> >>>>>>>
> >>>>>>> Interesting.  I thought they promised not to remove non-DT support for
> >>>>>>> existing devices.
> >>>>>>
> >>>>>> I personally don't mind, if it's removed once the DT works properly.
> >>>>>>
> >>>>>>> Anyway, Marc, so thanks for your patch.  I wonder if it makes sense to
> >>>>>>> add a check to flash-kernel whether DT is required or not.  i.e. that
> >>>>>>> flash-kernel would append the DT blob on 3.12+ kernels on SheevaPlug
> >>>>>>> but not on previous kernels.
> >>>>>>
> >>>>>> Yes, sounds like the way to go. Otherwise you have to tie certain
> >>>>>> flash-kernel versions to the non-DT and DT kernels. This will probably
> >>>>>> not scale when more no-DT board are removed from the kernel.
> >>>>>>
> >>>>>> Where should this information go? What about adding another field to
> >>>>>> all.db which limits an entry to certain kernel versions? Something like
> >>>>>> this:
> >>>>>
> >>>>> I think it would be sufficient to have a field marking the DTB as
> >>>>> optional and have f-k only do the append if there is a dtb present in
> >>>>> the DTS directory (/usr/lib/linux-X.Y/whatever) for the version it is
> >>>>> handling. If the kernel needs a DTB but doesn't ship one, well ,that's a
> >>>>> bug in the kernel (until we get to the point of burning DTBs into
> >>>>> firmware, but lets not worry about that now!).
> >>>>
> >>>> ...or when the DT sources will be move into a separate repository.
> >>>
> >>> Indeed.
> >>>
> >>> Actually, now that I think about it -- a non-DT aware kernel just
> >>> shouldn't care if you append a DT to it, it won't ever go looking. It's
> >>> probably safe to just append it unconditionally.
> >>
> >> Yes, should be safe.
> >>
> >>> Which is what you did, so we've come full circle, sorry for the
> >>> distraction.
> >>
> >> It's good to talk about the implications. If we want to handle
> >> downgrading of kernels with an updated flash-kernel, I think, that
> >> cannot be done without an additional Kernel-Version field.
> >>
> >> This is because v3.11 ships with:
> >>
> >> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
> >>
> >> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
> >> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
> >> are not Wheezy's kernels.
> > 
> > Is 3.11+DTB actively broken though?
> 
> v3.11+DT works on Sheeva Plug, just tested it.

That's good. Do you know if v3.10 or earlier shipped a DT in the kernel
package?

> I was thinking of the following scenario:
> 
> I have installed current flash-kernel (without DT support) and kernel
> v3.11. Then the new flash-kernel with
> append-DT-if-present-in-the-Kernel-package feature is released together
> with a new DT only kernel (=v3.12). I upgrade, because I want to have
> the shiny new kernel.
> 
> For whatever reason I want to downgrade to v3.11, then I end up with
> v3.11 with DT, because the flash-kernel is still the new one.

Right, this is the scenario I am worried about.

> The system does not behave as I expected. I downgraded to the same
> kernel but now the DT Sheeva Plug is booted.

Ideally v3.11+DT would work well enough that the user wouldn't care
about the difference. even if not I think so long as v3.11+DT works well
enough to be able to manually fix things (e.g. by downgrading f-k) then
this would be an acceptable trade-off to support such partial upgrades.

> Although the bootloader sets the ARCH number, an attached DT seems to be
> preferred.

That is what I would expect, yes.

> >>> I suppose it would be nice to just check that the Wheezy kernel doesn't
> >>> complain about or get confused by the appended DTB. Can you check that?
> >>
> >> I don't have physical access to that Sheeva Plug.
> > 
> > Hrm, this would be something which would be good to try somewhere.
> 
> On Wheezy there is no Sheevaplug DTB to attach...

Oh yes, of course.

> > Now I think of it the Wheezy kirkwood kernel did have DT and
> > APPENDED_DTB support enabled, in order to support dreamplugs.
> 
> http://packages.debian.org/wheezy/armel/linux-image-3.2.0-4-kirkwood/filelist
> 
> Wheezy has two dtb files:
> 
> /usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-dreamplug.dtb
> /usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-iconnect.dtb
> 
> > I have a feeling that would mean that it wouldn't boot if you appended a
> > dtb to it. Which would mean we do have to think about versioned checks
> > or something.
> 
> Just stating the obvious: The Sheeva Plug probably wouldn't boot if I
> attach a dreamplug dtb to it. :)

Right, I was thinking/worrying that it won't boot if you attach any DTB
to it, including a newer one for the shivaplug. But of course f-k
wouldn't ever do that.

So the only concern is intermediate kernel versions which have a DT file
but prefer non-DT operation. As I say I think so long as it boots well
enough to allow repair then this is ok.

Do shivaplugs typically provide u-boot console access as standard or
does that require soldering and/or cracking the case open?

Ian.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Fri, 06 Dec 2013 08:54:04 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Fri, 06 Dec 2013 08:54:04 GMT) (full text, mbox, link).


Message #70 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Ian Campbell <ijc@hellion.org.uk>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Fri, 06 Dec 2013 09:51:51 +0100
[Message part 1 (text/plain, inline)]
On 12/06/2013 09:31 AM, Ian Campbell wrote:
>>>> It's good to talk about the implications. If we want to handle
>>>> downgrading of kernels with an updated flash-kernel, I think, that
>>>> cannot be done without an additional Kernel-Version field.
>>>>
>>>> This is because v3.11 ships with:
>>>>
>>>> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
>>>>
>>>> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
>>>> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
>>>> are not Wheezy's kernels.
>>>
>>> Is 3.11+DTB actively broken though?
>>
>> v3.11+DT works on Sheeva Plug, just tested it.
> 
> That's good. Do you know if v3.10 or earlier shipped a DT in the kernel
> package?

There is no DT for Sheeva Plug in Debian's v3.10, but 25 dtb in total.

>> I was thinking of the following scenario:
>>
>> I have installed current flash-kernel (without DT support) and kernel
>> v3.11. Then the new flash-kernel with
>> append-DT-if-present-in-the-Kernel-package feature is released together
>> with a new DT only kernel (=v3.12). I upgrade, because I want to have
>> the shiny new kernel.
>>
>> For whatever reason I want to downgrade to v3.11, then I end up with
>> v3.11 with DT, because the flash-kernel is still the new one.
> 
> Right, this is the scenario I am worried about.
> 
>> The system does not behave as I expected. I downgraded to the same
>> kernel but now the DT Sheeva Plug is booted.
> 
> Ideally v3.11+DT would work well enough that the user wouldn't care
> about the difference. even if not I think so long as v3.11+DT works well
> enough to be able to manually fix things (e.g. by downgrading f-k) then
> this would be an acceptable trade-off to support such partial upgrades.

Yes works for me.

>> Although the bootloader sets the ARCH number, an attached DT seems to be
>> preferred.
> 
> That is what I would expect, yes.
> 
>>>>> I suppose it would be nice to just check that the Wheezy kernel doesn't
>>>>> complain about or get confused by the appended DTB. Can you check that?
>>>>
>>>> I don't have physical access to that Sheeva Plug.
>>>
>>> Hrm, this would be something which would be good to try somewhere.
>>
>> On Wheezy there is no Sheevaplug DTB to attach...
> 
> Oh yes, of course.
> 
>>> Now I think of it the Wheezy kirkwood kernel did have DT and
>>> APPENDED_DTB support enabled, in order to support dreamplugs.
>>
>> http://packages.debian.org/wheezy/armel/linux-image-3.2.0-4-kirkwood/filelist
>>
>> Wheezy has two dtb files:
>>
>> /usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-dreamplug.dtb
>> /usr/lib/linux-image-3.2.0-4-kirkwood/kirkwood-iconnect.dtb
>>
>>> I have a feeling that would mean that it wouldn't boot if you appended a
>>> dtb to it. Which would mean we do have to think about versioned checks
>>> or something.
>>
>> Just stating the obvious: The Sheeva Plug probably wouldn't boot if I
>> attach a dreamplug dtb to it. :)
> 
> Right, I was thinking/worrying that it won't boot if you attach any DTB
> to it, including a newer one for the shivaplug. But of course f-k
> wouldn't ever do that.
> 
> So the only concern is intermediate kernel versions which have a DT file
> but prefer non-DT operation. As I say I think so long as it boots well
> enough to allow repair then this is ok.

In Debian, v3.11 is the first kernel that ships with a Sheeva Plug DT
and that works for me.

> Do shivaplugs typically provide u-boot console access as standard or
> does that require soldering and/or cracking the case open?

No, just plug in a Mini USB Cable and you have a serial console (and a
JTAG for debricking via openocd).

Marc

[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Sat, 07 Dec 2013 10:09:05 GMT) (full text, mbox, link).


Acknowledgement sent to Christian PERRIER <bubulle@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Sat, 07 Dec 2013 10:09:05 GMT) (full text, mbox, link).


Message #75 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Christian PERRIER <bubulle@debian.org>
To: Marc Kleine-Budde <mkl@blackshift.org>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Sat, 7 Dec 2013 11:06:37 +0100
[Message part 1 (text/plain, inline)]
Quoting Marc Kleine-Budde (mkl@blackshift.org):
> Package: flash-kernel
> Version: 3.11
> Severity: normal
> Tags: patch
> 
> Hello, I've two patches to support DT based kernel on Sheeva
> Plug. These patches are needed to boot 3.12 (which is currently in
> experimental).

I actually know nearly nothing about these kind of things but it seems
to me that we should be able to commi tthis without a big risk to
break anything. Cyril, objections?


[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Sat, 07 Dec 2013 10:24:04 GMT) (full text, mbox, link).


Acknowledgement sent to Cyril Brulebois <kibi@debian.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Sat, 07 Dec 2013 10:24:04 GMT) (full text, mbox, link).


Message #80 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Cyril Brulebois <kibi@debian.org>
To: Christian PERRIER <bubulle@debian.org>, 731345@bugs.debian.org
Cc: Marc Kleine-Budde <mkl@blackshift.org>
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Sat, 7 Dec 2013 11:20:54 +0100
[Message part 1 (text/plain, inline)]
Christian PERRIER <bubulle@debian.org> (2013-12-07):
> Quoting Marc Kleine-Budde (mkl@blackshift.org):
> > Package: flash-kernel
> > Version: 3.11
> > Severity: normal
> > Tags: patch
> > 
> > Hello, I've two patches to support DT based kernel on Sheeva
> > Plug. These patches are needed to boot 3.12 (which is currently in
> > experimental).
> 
> I actually know nearly nothing about these kind of things but it seems
> to me that we should be able to commi tthis without a big risk to
> break anything. Cyril, objections?

I'd rather see Martin or Ian come to a conclusion on their own, given
the length of the thread already, and the DT-specific subtleties.

Mraw,
KiBi.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Sun, 15 Dec 2013 20:15:04 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Sun, 15 Dec 2013 20:15:04 GMT) (full text, mbox, link).


Message #85 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Ian Campbell <ijc@hellion.org.uk>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Sun, 15 Dec 2013 21:13:28 +0100
[Message part 1 (text/plain, inline)]
On 12/06/2013 09:31 AM, Ian Campbell wrote:
[...]

>>>> This is because v3.11 ships with:
>>>>
>>>> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
>>>>
>>>> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
>>>> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
>>>> are not Wheezy's kernels.
>>>
>>> Is 3.11+DTB actively broken though?
>>
>> v3.11+DT works on Sheeva Plug, just tested it.
> 
> That's good. Do you know if v3.10 or earlier shipped a DT in the kernel
> package?

I just noticed that the Ethernet is missing with v3.11+DT.

Ethernet support was added with v3.12-rc1~114^2~10^2~12. So probably
don't want to use v3.11-DT on the Sheeva Plug.

Marc


[signature.asc (application/pgp-signature, attachment)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Mon, 16 Dec 2013 08:33:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Mon, 16 Dec 2013 08:33:05 GMT) (full text, mbox, link).


Message #90 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, 731345@bugs.debian.org
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Mon, 16 Dec 2013 08:28:55 +0000
On Sun, 2013-12-15 at 21:13 +0100, Marc Kleine-Budde wrote:
> On 12/06/2013 09:31 AM, Ian Campbell wrote:
> [...]
> 
> >>>> This is because v3.11 ships with:
> >>>>
> >>>> /usr/lib/linux-image-3.11-2-kirkwood/kirkwood-sheevaplug.dtb
> >>>>
> >>>> But non-DT Sheeva support is still in the kernel, so non-DT Sheeva Plug
> >>>> is used with current flash-kernel and v3.11. Although v3.10 and v3.11
> >>>> are not Wheezy's kernels.
> >>>
> >>> Is 3.11+DTB actively broken though?
> >>
> >> v3.11+DT works on Sheeva Plug, just tested it.
> > 
> > That's good. Do you know if v3.10 or earlier shipped a DT in the kernel
> > package?
> 
> I just noticed that the Ethernet is missing with v3.11+DT.

Hrm, that's rather unfortunate.

I suppose a field describing the minimum kernel version for dtb support
is the only way to go here. :-/ At least the linux-version tool is
available to simplify the logic.

> Ethernet support was added with v3.12-rc1~114^2~10^2~12. So probably
> don't want to use v3.11-DT on the Sheeva Plug.

Indeed not.

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 08:39:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 08:39:04 GMT) (full text, mbox, link).


Message #95 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Martin Michlmayr <tbm@cyrius.com>
Cc: Markus Krebs <mk@drkrebs.de>, 731345@bugs.debian.org
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 08 Jan 2014 08:35:37 +0000
[Message part 1 (text/plain, inline)]
(adding the bug)

On Wed, 2014-01-08 at 08:22 +0100, Martin Michlmayr wrote:
> Hi Markus,
> 
> * Markus Krebs <mk@drkrebs.de> [2014-01-08 06:25]:
> > I just wanted to let you know that the last kernel update in testing
> > ("jessie") to 3.12-1 went really bad on my SheevaPlug. It wouldn't
> > boot anymore ("Error: unrecognized/unsupported machine ID (r1 =
> > 0x00000831)"). Also the uImage.bak and the uInitrd.bak which had been
> 
> flash-kernel needs the patch from #731345.
> 
> Ian, 3.12 is in testing now.  Is the patch from #731345 ready now and
> can you make an upload?

When I was testing the ts41x DT patches from Andrew Lunn at the weekend
I found that the approach of just adding the DTB-Append option broke
with older kernels, complaining (rightly) that the DTB file wasn't
present.

So, assuming I've not misdiagnosed it, the patch needs to be expanded
with some sort of conditional to cope with this, I haven't had time to
look into that. The bug thread came to the same conclusion, although the
rationale was different.

An alternative would be for f-k to declare Breaks against older kernels.
I don't really want to do that though, since it would make upgrades
harder than they need to be.

The best option is probably a "DTB-Optional-Before: version" field I
guess?

Ian.
[signature.asc (application/pgp-signature, inline)]

Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 09:12:10 GMT) (full text, mbox, link).


Acknowledgement sent to Martin Michlmayr <tbm@cyrius.com>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 09:12:10 GMT) (full text, mbox, link).


Message #100 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Martin Michlmayr <tbm@cyrius.com>
To: Ian Campbell <ijc@hellion.org.uk>, Marc Kleine-Budde <mkl@blackshift.org>
Cc: Markus Krebs <mk@drkrebs.de>, 731345@bugs.debian.org
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 8 Jan 2014 10:09:39 +0100
Adding Marc, who proposed the initial patch.

* Ian Campbell <ijc@hellion.org.uk> [2014-01-08 08:35]:
> (adding the bug)
> 
> On Wed, 2014-01-08 at 08:22 +0100, Martin Michlmayr wrote:
> > Hi Markus,
> > 
> > * Markus Krebs <mk@drkrebs.de> [2014-01-08 06:25]:
> > > I just wanted to let you know that the last kernel update in testing
> > > ("jessie") to 3.12-1 went really bad on my SheevaPlug. It wouldn't
> > > boot anymore ("Error: unrecognized/unsupported machine ID (r1 =
> > > 0x00000831)"). Also the uImage.bak and the uInitrd.bak which had been
> > 
> > flash-kernel needs the patch from #731345.
> > 
> > Ian, 3.12 is in testing now.  Is the patch from #731345 ready now and
> > can you make an upload?
> 
> When I was testing the ts41x DT patches from Andrew Lunn at the weekend
> I found that the approach of just adding the DTB-Append option broke
> with older kernels, complaining (rightly) that the DTB file wasn't
> present.
> 
> So, assuming I've not misdiagnosed it, the patch needs to be expanded
> with some sort of conditional to cope with this, I haven't had time to
> look into that. The bug thread came to the same conclusion, although the
> rationale was different.
> 
> An alternative would be for f-k to declare Breaks against older kernels.
> I don't really want to do that though, since it would make upgrades
> harder than they need to be.
> 
> The best option is probably a "DTB-Optional-Before: version" field I
> guess?
> 
> Ian.



-- 
Martin Michlmayr
http://www.cyrius.com/



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 09:21:04 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 09:21:04 GMT) (full text, mbox, link).


Message #105 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Martin Michlmayr <tbm@cyrius.com>,Ian Campbell <ijc@hellion.org.uk>
Cc: Markus Krebs <mk@drkrebs.de>,731345@bugs.debian.org
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 08 Jan 2014 10:17:00 +0100

Martin Michlmayr <tbm@cyrius.com> wrote:
>Adding Marc, who proposed the initial patch.
>
>* Ian Campbell <ijc@hellion.org.uk> [2014-01-08 08:35]:
>> (adding the bug)
>> 
>> On Wed, 2014-01-08 at 08:22 +0100, Martin Michlmayr wrote:
>> > Hi Markus,
>> > 
>> > * Markus Krebs <mk@drkrebs.de> [2014-01-08 06:25]:
>> > > I just wanted to let you know that the last kernel update in
>testing
>> > > ("jessie") to 3.12-1 went really bad on my SheevaPlug. It
>wouldn't
>> > > boot anymore ("Error: unrecognized/unsupported machine ID (r1 =
>> > > 0x00000831)"). Also the uImage.bak and the uInitrd.bak which had
>been
>> > 
>> > flash-kernel needs the patch from #731345.
>> > 
>> > Ian, 3.12 is in testing now.  Is the patch from #731345 ready now
>and
>> > can you make an upload?
>> 
>> When I was testing the ts41x DT patches from Andrew Lunn at the
>weekend
>> I found that the approach of just adding the DTB-Append option broke
>> with older kernels, complaining (rightly) that the DTB file wasn't
>> present.
>> 
>> So, assuming I've not misdiagnosed it, the patch needs to be expanded
>> with some sort of conditional to cope with this, I haven't had time
>to
>> look into that. The bug thread came to the same conclusion, although
>the
>> rationale was different.
>> 
>> An alternative would be for f-k to declare Breaks against older
>kernels.
>> I don't really want to do that though, since it would make upgrades
>> harder than they need to be.
>> 
>> The best option is probably a "DTB-Optional-Before: version" field I
>> guess?

Not quite, as 3.11 comes with DT for the sheeva plug, but that DT lacks ethernet support.

Marc




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 09:27:10 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 09:27:10 GMT) (full text, mbox, link).


Message #110 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, Markus Krebs <mk@drkrebs.de>, 731345@bugs.debian.org
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 08 Jan 2014 09:23:04 +0000
On Wed, 2014-01-08 at 10:17 +0100, Marc Kleine-Budde wrote:
> >> The best option is probably a "DTB-Optional-Before: version" field I
> >> guess?
> 
> Not quite, as 3.11 comes with DT for the sheeva plug, but that DT
> lacks ethernet support.

Yes, thinking about it "DTB-After: version" probably makes more logical
sense.

It looks like this issue is also going to affect the QNAP platforms,
e.g. ts219 has already been converted and there is a patch to do the
same for ts419 as well. The issue there is that there are two separate
DTBs covering what was once a single board file, that's going to be
tricky...

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 17:30:04 GMT) (full text, mbox, link).


Acknowledgement sent to Marc Kleine-Budde <mkl@blackshift.org>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 17:30:04 GMT) (full text, mbox, link).


Message #115 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Marc Kleine-Budde <mkl@blackshift.org>
To: Andrew Lunn <andrew@lunn.ch>,tbm@cyrius.com,jc@hellion.org.uk
Cc: 731345@bugs.debian.org,mk@drkrebs.de
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Wed, 08 Jan 2014 18:28:51 +0100

Andrew Lunn <andrew@lunn.ch> wrote:
>> Not quite, as 3.11 comes with DT for the sheeva plug, but that DT
>> lacks ethernet support.
>
>Hi Marc
>
>I've not tested it, but ethernet should work. Adding DT support to the
>ethernet driver took time, so during the transition, we instantiated
>ethernet using old style platform_driver.
>
>If it really does not work, it is a bug, which i will fix and get put
>into stable.
>
>Feel free to ask me about such issues.

Sheeva Plug without DT works on 3.11, but there isn't any Ethernet with 3.11 and appended DT. I'm in 3.12 with my proposed patches and everything is fine.

Marc



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 17:54:04 GMT) (full text, mbox, link).


Acknowledgement sent to Andrew Lunn <andrew@lunn.ch>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 17:54:04 GMT) (full text, mbox, link).


Message #120 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Andrew Lunn <andrew@lunn.ch>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Andrew Lunn <andrew@lunn.ch>, tbm@cyrius.com, ijc@hellion.org.uk, 731345@bugs.debian.org, mk@drkrebs.de
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Wed, 8 Jan 2014 18:50:27 +0100
> >Hi Marc
> >
> >I've not tested it, but ethernet should work. Adding DT support to the
> >ethernet driver took time, so during the transition, we instantiated
> >ethernet using old style platform_driver.
> >
> >If it really does not work, it is a bug, which i will fix and get put
> >into stable.
> >
> >Feel free to ask me about such issues.
> 

> Sheeva Plug without DT works on 3.11, but there isn't any Ethernet
> with 3.11 and appended DT. I'm in 3.12 with my proposed patches and
> everything is fine.

So i looked at 3.11. The code is there to start the ethernet on Sheeva
plug. So it is not obvious why it does not work.

If you are happy with 3.12, i won't debug further. But if 3.11 is of
interest, i can help figure out what is wrong.

   Andrew



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 17:57:08 GMT) (full text, mbox, link).


Acknowledgement sent to Andrew Lunn <andrew@lunn.ch>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 17:57:08 GMT) (full text, mbox, link).


Message #125 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Andrew Lunn <andrew@lunn.ch>
To: mkl@blackshift.org, tbm@cyrius.com, jc@hellion.org.uk
Cc: 731345@bugs.debian.org, mk@drkrebs.de
Subject: Re: Bug#731345: flash-kernel: add support for DT based kernels on Sheeva Plug
Date: Wed, 8 Jan 2014 18:24:03 +0100
> Not quite, as 3.11 comes with DT for the sheeva plug, but that DT
> lacks ethernet support.

Hi Marc

I've not tested it, but ethernet should work. Adding DT support to the
ethernet driver took time, so during the transition, we instantiated
ethernet using old style platform_driver.

If it really does not work, it is a bug, which i will fix and get put
into stable.

Feel free to ask me about such issues.

     Andrew



Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 18:57:10 GMT) (full text, mbox, link).


Acknowledgement sent to Simon Baatz <gmbnomis@gmail.com>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 18:57:10 GMT) (full text, mbox, link).


Message #130 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Simon Baatz <gmbnomis@gmail.com>
To: Marc Kleine-Budde <mkl@blackshift.org>
Cc: Martin Michlmayr <tbm@cyrius.com>, Ian Campbell <ijc@hellion.org.uk>, Markus Krebs <mk@drkrebs.de>, 731345@bugs.debian.org, andrew@lunn.ch
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 8 Jan 2014 19:53:29 +0100
Hi Marc,

On Wed, Jan 08, 2014 at 10:17:00AM +0100, Marc Kleine-Budde wrote:
> 
> 
> Martin Michlmayr <tbm@cyrius.com> wrote:
> >Adding Marc, who proposed the initial patch.
...
> >> An alternative would be for f-k to declare Breaks against older
> >kernels.
> >> I don't really want to do that though, since it would make upgrades
> >> harder than they need to be.
> >> 
> >> The best option is probably a "DTB-Optional-Before: version" field I
> >> guess?
> 
> Not quite, as 3.11 comes with DT for the sheeva plug, but that DT lacks ethernet support.

FWIW, Ethernet should work with DT sheevaplug on 3.11. DT support for
the Ethernet driver was added in 3.12.  Therefore, there is a small
board file in 3.11 which just inits the Ethernet
(board-sheevaplug.c).  However, CONFIG_MACH_SHEEVAPLUG_DT needs to be
set for that to work. If that is not defined, the board probably
boots fine, but Ethernet does not work.

- Simon




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 19:36:04 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 19:36:04 GMT) (full text, mbox, link).


Message #135 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: Simon Baatz <gmbnomis@gmail.com>
Cc: Marc Kleine-Budde <mkl@blackshift.org>, Martin Michlmayr <tbm@cyrius.com>, Markus Krebs <mk@drkrebs.de>, 731345@bugs.debian.org, andrew@lunn.ch
Subject: Re: Kirkwood Kernel 3.12-1
Date: Wed, 08 Jan 2014 19:32:27 +0000
On Wed, 2014-01-08 at 19:53 +0100, Simon Baatz wrote:

> FWIW, Ethernet should work with DT sheevaplug on 3.11. DT support for
> the Ethernet driver was added in 3.12.  Therefore, there is a small
> board file in 3.11 which just inits the Ethernet
> (board-sheevaplug.c).  However, CONFIG_MACH_SHEEVAPLUG_DT needs to be
> set for that to work. If that is not defined, the board probably
> boots fine, but Ethernet does not work.

The Debian package of 3.11 doesn't set this. Since Debian has already
moved on to 3.12 we can't easily fix this, so I intend to set the
minimum kernel version for DTB append to 3.12 in the flash-kernel tool.

Ian.




Information forwarded to debian-bugs-dist@lists.debian.org, Debian Install System Team <debian-boot@lists.debian.org>:
Bug#731345; Package flash-kernel. (Wed, 08 Jan 2014 21:33:09 GMT) (full text, mbox, link).


Acknowledgement sent to Ian Campbell <ijc@hellion.org.uk>:
Extra info received and forwarded to list. Copy sent to Debian Install System Team <debian-boot@lists.debian.org>. (Wed, 08 Jan 2014 21:33:09 GMT) (full text, mbox, link).


Message #140 received at 731345@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: 731345@bugs.debian.org
Cc: Marc Kleine-Budde <mkl@blackshift.org>, Martin Michlmayr <tbm@cyrius.com>, Markus Krebs <mk@drkrebs.de>
Subject: Re: Bug#731345: Kirkwood Kernel 3.12-1
Date: Wed, 08 Jan 2014 21:28:22 +0000
On Wed, 2014-01-08 at 09:23 +0000, Ian Campbell wrote:
> Yes, thinking about it "DTB-After: version" probably makes more
> logical sense. 

Hi Marc,

Please can you try this flash-kernel patch on your SheevaPlug?

I've tried it on a ts-419 with Andrew Lunn's DTB patches for that
platform and in some basic tests it seems fine but the Sheevaplug
specific runes need validating.

I'm going to run a more complete set of combinations too, so where for
me 3.13 needs DTB appended and 3.12 I intend to test:

Installing 3.12 while running 3.12 (reran flash-kernel manually)
Installing 3.13 while running 3.13 (reran flash-kernel manually)
Installing 3.12 while running 3.13 (dpkg --purge linux-image-3.13...)
Installing 3.13 while running 3.12 (dpkg -i linux-image-3.13...)

If you could do something similar for the Sheeva case that would be
awesome.

Ian.


8<---------------------------------

From c0543194c1fae562fa4c8042aa7ff4e37a49e970 Mon Sep 17 00:00:00 2001
From: Ian Campbell <ijc@hellion.org.uk>
Date: Thu, 2 Jan 2014 14:40:39 +0000
Subject: [PATCH] Support requirement to append a DTB on Sheevaplug from kernel
 v3.12 onwards

We want to support both flashing a new (DT based) kernel while running an old
(board file based) kernel as well as flashing an old kernel while running a new
(which normally corresponds to removing a new kernel package).

Therefore add two db entries, one which matches the old board file based
platform and one wich matches the new DT based platform.

We also need to know which kernels need the DTB. We cannot just append the DTB
and rely on the old kernels ignoring it because at least some older kernels
will malfunction if given an appended DTB while they would function fine with
their built in board support. Therefore introduce a new db field
"DTB-Append-From" which is compared against the kernel we are flashing to
determine if the DTB should be appended.

DTB-Append and DTB-Append-From now override/mask Machine-ID since DTB based
systems do not use Machine-ID.

Closes: #731345.
---
 README           |  8 +++++++-
 db/all.db        | 15 +++++++++++++++
 debian/changelog |  7 +++++++
 functions        | 23 ++++++++++++++++-------
 test_db          |  2 +-
 test_functions   | 17 +++++++++++++++++
 6 files changed, 63 insertions(+), 9 deletions(-)

diff --git a/README b/README
index 674a88a..6093d78 100644
--- a/README
+++ b/README
@@ -92,13 +92,19 @@ The supported fields are:
   suffix, installation is aborted
 
 * Machine-Id: (optional) linux mach-type to set before starting vmlinuz;
-  will be set by a small piece of ARM code prepended to the kernel image
+  will be set by a small piece of ARM code prepended to the kernel image.
+  This option is ignored if a DTB is to be appended, via either DTB-Append or
+  DTB-Append-From.
 
 * DTB-Id: (optional) specifies the name of the DTB file for this device
 
 * DTB-Append: (optional) when yes the DTB specified by DTB-Id will be appended
   to the kernel image.
 
+* DTB-Append-From: (optional): Can be used instead of DTB-Append. The argument
+  is a kernel version, if the kernel to be installed is at least this version
+  then the DTB specified named by DTB-Id will be appended to the kernel image.
+
 * U-Boot-Kernel-Address, U-Boot-Kernel-Entry-Point, U-Boot-Initrd-Address:
   (optional) address where to load in (physical) RAM the kernel, entry point
   and initrd, respectively; this also indicates that U-Boot images should be
diff --git a/db/all.db b/db/all.db
index 76e99fd..b62f821 100644
--- a/db/all.db
+++ b/db/all.db
@@ -250,10 +250,25 @@ Bootloader-Sets-Root: no
 
 Machine: Marvell SheevaPlug Reference Board
 Kernel-Flavors: kirkwood
+DTB-Id: kirkwood-sheevaplug.dtb
+DTB-Append-From: 3.12
 U-Boot-Kernel-Address: 0x00008000
 U-Boot-Initrd-Address: 0x0
 Boot-Kernel-Path: /boot/uImage
 Boot-Initrd-Path: /boot/uInitrd
+Boot-DTB-Path: dtb
+Required-Packages: u-boot-tools
+Bootloader-Sets-Root: no
+
+Machine: Globalscale Technologies SheevaPlug
+Kernel-Flavors: kirkwood
+DTB-Id: kirkwood-sheevaplug.dtb
+DTB-Append-From: 3.12
+U-Boot-Kernel-Address: 0x00008000
+U-Boot-Initrd-Address: 0x0
+Boot-Kernel-Path: /boot/uImage
+Boot-Initrd-Path: /boot/uInitrd
+Boot-DTB-Path: dtb
 Required-Packages: u-boot-tools
 Bootloader-Sets-Root: no
 
diff --git a/debian/changelog b/debian/changelog
index f9654c1..716606d 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+flash-kernel (3.12) UNRELEASED; urgency=low
+
+  * Append a DTB on Sheevaplug from kernel version 3.12 onwards. Based on a
+    patch by Marc Kleine-Budde. (Closes: #731345).
+
+ -- Ian Campbell <ijc@hellion.org.uk>  Wed, 08 Jan 2014 19:55:43 +0000
+
 flash-kernel (3.11) unstable; urgency=low
 
   [ Updated translations ]
diff --git a/functions b/functions
index 66e9738..d75f139 100644
--- a/functions
+++ b/functions
@@ -319,6 +319,10 @@ abootimg_get_image_size() {
 	echo "$abootimg" | sed -rn 's/^\* image size = ([0-9]+) bytes.*/\1/p'
 }
 
+dtb_append_required() {
+	linux-version compare "$kvers" ge "$dtb_append_from"
+}
+
 # XXX needs testsuite coverage
 android_flash() {
 	local device="$1"
@@ -405,6 +409,7 @@ mtd_kernel="$(get_machine_field "$machine" "Mtd-Kernel")" || :
 mtd_initrd="$(get_machine_field "$machine" "Mtd-Initrd")" || :
 dtb_name="$(get_machine_field "$machine" "DTB-Id")" || :
 dtb_append="$(get_machine_field "$machine" "DTB-Append")" || :
+dtb_append_from="$(get_machine_field "$machine" "DTB-Append-From")" || :
 ukaddr="$(get_machine_field "$machine" "U-Boot-Kernel-Address")" || :
 ukepoint="$(get_machine_field "$machine" "U-Boot-Kernel-Entry-Point")" || :
 uiaddr="$(get_machine_field "$machine" "U-Boot-Initrd-Address")" || :
@@ -419,6 +424,14 @@ boot_dtb_path="$(get_machine_field "$machine" "Boot-DTB-Path")" || :
 boot_multi_path="$(get_machine_field "$machine" "Boot-Multi-Path")" || :
 android_boot_device="$(get_machine_field "$machine" "Android-Boot-Device")" || :
 
+if [ -n "$dtb_append_from" ]; then
+    if dtb_append_required; then
+	dtb_append="yes"
+    else
+	dtb_append="no"
+    fi
+fi
+
 if [ -n "$mtd_kernel" ] || [ -n "$mtd_initrd" ]; then
 	if [ ! -e "$PROC_MTD" ]; then
 		error "$PROC_MTD doesn't exist"
@@ -491,13 +504,6 @@ case "$method" in
 	"generic")
 		kernel="$kfile"
 		initrd="$ifile"
-		if [ -n "$machine_id" ]; then
-			if [ "$dtb_append" = "yes" ]; then
-				error "Can't set Machine-Id and DTB-Append"
-			fi
-			gen_kernel "$kernel" "$tmpdir/kernel" "$machine_id"
-			kernel="$tmpdir/kernel"
-		fi
 		if [ "$dtb_append" = "yes" ]; then
 			dtb="/usr/lib/linux-image-$kvers/$dtb_name"
 			if [ ! -f "$dtb" ]; then
@@ -505,6 +511,9 @@ case "$method" in
 			fi
 			append_dtb "$kernel" "$dtb" "$tmpdir/kernel"
 			kernel="$tmpdir/kernel"
+		elif [ -n "$machine_id" ]; then
+			gen_kernel "$kernel" "$tmpdir/kernel" "$machine_id"
+			kernel="$tmpdir/kernel"
 		fi
 		if [ -n "$ukaddr" ]; then
 			if [ -n "$ukepoint" ]; then
diff --git a/test_db b/test_db
index dd066d8..aec83f1 100755
--- a/test_db
+++ b/test_db
@@ -22,7 +22,7 @@
 MACHINE_DB="$(cat "${FK_CHECKOUT:-$FK_DIR}/db/"*.db)"
 
 test_no_unknown_fields() {
-    local expected='Android-Boot-Device Boot-Device Boot-DTB-Path Boot-Initrd-Path Boot-Kernel-Path Boot-Multi-Path Boot-Script-Path Bootloader-Sets-Root DTB-Append DTB-Id Kernel-Flavors Machine Machine-Id Method Mtd-Initrd Mtd-Kernel Optional-Packages Required-Packages U-Boot-Initrd-Address U-Boot-Kernel-Address U-Boot-Kernel-Entry-Point U-Boot-Multi-Address U-Boot-Script-Address U-Boot-Script-Name'
+    local expected='Android-Boot-Device Boot-Device Boot-DTB-Path Boot-Initrd-Path Boot-Kernel-Path Boot-Multi-Path Boot-Script-Path Bootloader-Sets-Root DTB-Append DTB-Append-From DTB-Id Kernel-Flavors Machine Machine-Id Method Mtd-Initrd Mtd-Kernel Optional-Packages Required-Packages U-Boot-Initrd-Address U-Boot-Kernel-Address U-Boot-Kernel-Entry-Point U-Boot-Multi-Address U-Boot-Script-Address U-Boot-Script-Name'
     expected="$(echo "$expected" | sed 's/ /\n/g' | sort -u | xargs)"
     local fields="$(echo "$MACHINE_DB" | sed -n '/^[^#]*:/s/:.*//p' | sort -u | xargs)"
     if [ "$fields" != "$expected" ]; then
diff --git a/test_functions b/test_functions
index 9874d1b..93fe269 100755
--- a/test_functions
+++ b/test_functions
@@ -497,6 +497,23 @@ test_flash_initrd() {
 }
 add_test test_flash_initrd
 
+test_dtb_append_from() {
+    (
+	. "$functions"
+	dtb_append_from="3.12"
+	kvers=3.11-1-kirkwood
+	if dtb_append_required ; then
+	    echo "Kernel $kvers does not need appended DTB, but got true" >&2
+	    exit 1
+	fi
+	kvers=3.12-1-kirkwood
+	if ! dtb_append_required ; then
+	    echo "Kernel $kvers does need appended DTB, but got false" >&2
+	    exit 1
+	fi
+    )
+}
+add_test test_dtb_append_from
 
 test_main
 
-- 
1.8.4.rc3






Added tag(s) pending. Request was from Ian Campbell <ijc@hellion.org.uk> to control@bugs.debian.org. (Sun, 12 Jan 2014 12:45:08 GMT) (full text, mbox, link).


Reply sent to Ian Campbell <ijc@hellion.org.uk>:
You have taken responsibility. (Sun, 12 Jan 2014 16:06:13 GMT) (full text, mbox, link).


Notification sent to Marc Kleine-Budde <mkl@blackshift.org>:
Bug acknowledged by developer. (Sun, 12 Jan 2014 16:06:13 GMT) (full text, mbox, link).


Message #147 received at 731345-close@bugs.debian.org (full text, mbox, reply):

From: Ian Campbell <ijc@hellion.org.uk>
To: 731345-close@bugs.debian.org
Subject: Bug#731345: fixed in flash-kernel 3.12
Date: Sun, 12 Jan 2014 16:03:34 +0000
Source: flash-kernel
Source-Version: 3.12

We believe that the bug you reported is fixed in the latest version of
flash-kernel, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 731345@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Ian Campbell <ijc@hellion.org.uk> (supplier of updated flash-kernel package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Sun, 12 Jan 2014 15:15:49 +0000
Source: flash-kernel
Binary: flash-kernel flash-kernel-installer
Architecture: source armel
Version: 3.12
Distribution: sid
Urgency: medium
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Changed-By: Ian Campbell <ijc@hellion.org.uk>
Description: 
 flash-kernel - utility to make certain embedded devices bootable
 flash-kernel-installer - Make the system bootable (udeb)
Closes: 721485 725754 731345 734130 734769
Changes: 
 flash-kernel (3.12) unstable; urgency=medium
 .
   * Append a DTB on Sheevaplug from kernel version 3.12 onwards. Based on a
     patch by Marc Kleine-Budde. (Closes: #731345).
   * Append a DTB on Guruplug from kernel version 3.12 onwards. Based on a patch
     from William Boughton. (Closes: #734769).
   * Allow multiple Machine names per stanza in the db.
   * Correct check for debconf, avoiding hang on error when running in Debian
     Installer. (Closes: #721485).
   * Add support for "Buffalo Linkstation LS-CHLv2" (Closes: #734130).
   * Add support for "Plat'Home OpenBlocksA6" (Closes: #725754).
Checksums-Sha1: 
 4a8c9d0388f4f1e9d847ff7e60f6f728f6af6944 1789 flash-kernel_3.12.dsc
 76e7fda38c0ac636dc226759083501c946630409 73304 flash-kernel_3.12.tar.gz
 27878fe78fdc570bbc07745317420f878c49dd61 25450 flash-kernel_3.12_armel.deb
 624e4272c50c279c170ea4d5c97cf99ea992c4b4 19572 flash-kernel-installer_3.12_armel.udeb
Checksums-Sha256: 
 2b2256a87fdf40cc082ae74bceafb8f84addbdd513dadf1007525dd3f4f02506 1789 flash-kernel_3.12.dsc
 d16cd20c9d3569e2abd5622e15ba41e8c5604d11d508be34307b78eae94ad613 73304 flash-kernel_3.12.tar.gz
 a15b2a9f5baa4119b6da0ee7c75a9297a75c215c9eb4ea173920eca6bbd48106 25450 flash-kernel_3.12_armel.deb
 7ed6a962b464bc65f487783da8c0991679900fa09f2f259cf625a2a9fafbb4ac 19572 flash-kernel-installer_3.12_armel.udeb
Files: 
 16e0a5193ab26e47c101e07ce72a725f 1789 utils optional flash-kernel_3.12.dsc
 48429768c084647bdf1acfeaba2bb540 73304 utils optional flash-kernel_3.12.tar.gz
 f4043c5e5ce3c9b3aeba556d21bec6b9 25450 utils optional flash-kernel_3.12_armel.deb
 0343a2cf0dd6faab24d9d850304284ef 19572 debian-installer standard flash-kernel-installer_3.12_armel.udeb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)

iQIcBAEBCAAGBQJS0rwRAAoJECouJZ9pWkbG0EEP+QE0wAEbME5Q+WaNQ9p8UoMR
Nihos0PcZyh+uQ71BDohykroNQLUClqMzGACRgh5E4y2z6jKB2JNHkhzYZq3+/Th
T1I6j8k4G3FEJfvL2AMrH4rPi10wr5XC/b5yfY6+S0OR8sBi81PUODl8OVib3dij
jxQiEKlNNGK+URpXfVA4Ade3iTxq5usPHUHzHzejxFEZenbjotKQQ9lD0HmE/KFq
/3/RmhVe+HsPlgymJ5n0yEL+8l/+uplTNhHnlfFw0zBK5DWNNjBtYQBYZWB/1ifB
z+nBu5SEL+Pofi6Mc6voP9k+HJNLw4nLhyF+49zu4HzNBbkmfCfUqdx2TocaJzGo
svE8yl+39B/WHX+vIiI62uwlF3Rsb5+eR788GL/I4THQ5GkLmGN9Oy/IBEfqcP5j
lmzmgvsjnTDnlWdu209BB4admjJ/q8viDHuZMrA+63EBVl9hv+c8Qh4pbWWl4pZA
3EUJKrWRhQCysshitAJSLfkGP28PtNKRSOJ1/UF3rHC9Lb+5+028YrnYftF78+sw
Zis2e8m9fZixwE3SL4rlSpJOzx65ynMm5KsXYqsQ7IxN0tvxcmtDWI6mjcWf3Jzo
NYBQvgVilhtQuhjrDw/jpbINNaPE9twIqpeinzyVr9NTEaIVpO8gAjJKSgJWdAGY
zUyXfrKGUSAXQtYj2S8B
=vmFJ
-----END PGP SIGNATURE-----




Bug archived. Request was from Debbugs Internal Request <owner@bugs.debian.org> to internal_control@bugs.debian.org. (Sat, 15 Feb 2014 07:33:44 GMT) (full text, mbox, link).


Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Tue Jul 11 01:40:05 2023; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.