[SLOF] [PATCH] boot: stop booting when we encounter HALT

Nikunj A Dadhania nikunj at linux.vnet.ibm.com
Mon Oct 26 15:38:43 AEDT 2015

Alexey Kardashevskiy <aik at ozlabs.ru> writes:

> On 10/26/2015 03:05 PM, Nikunj A Dadhania wrote:
>> Alexey Kardashevskiy <aik at ozlabs.ru> writes:
>>> On 10/14/2015 10:25 PM, Nikunj A Dadhania wrote:
>>>> QEMU when started with "-boot strict=on", appends "HALT" at the end of
>>>> the bootlist. Handle this in the boot order.
>>> Without an additional comment, handling looks like ignoring which is ok but
>>> why exactly? We stop after the end of the bootlist anyway?
>> Without this patch SLOF tries to boot from device named "HALT" :-)
> Sure.
>> It fails and with error saying failed booting from device HALT, which is
>> confusing.
> QEMU's c8a6ae8bb9547 "add a boot option to do strict boot" says:
> ===
> Seabios already added a new device type to halt booting.
> Qemu can add "HALT" at the end of bootindex string, then
> seabios will halt booting after trying to boot from all
> selected devices.
> ===
> So seabios works different with and without this "HALT" - it stops booting 
> or continues trying other boot targets. But you just ignore this. This part 
> confuses me.

What I understand is HALT is the last entry in the list. So when we
encounter HALT, it comes out without processing. I have put an
EXIT here.

Other option is to ABORT when we see a HALT, so that will not give the
impression of just ignoring "HALT"

Although, the outcome is the same, we need to stop processing when the
last entry "HALT" is seen.

>>>> +   2dup " HALT" str= IF 2drop 0 EXIT THEN

More information about the SLOF mailing list