[syslinux] simple message under BIOS/CSM/LEGACY

lacsaP Patatetom patatetom at gmail.com
Thu Jul 6 06:13:17 PDT 2023


Le lun. 21 nov. 2022 à 10:00, Pascal <patatetom at gmail.com> a écrit :

> hi,
>
> I'm coming back to you on this subject (eg. display a short message
> inviting the user to switch the PC to EFI/UEFI) after some field feedback.
>
> here is the code now used :
>
> ; nasm nobioscsm.asm -f bin -o nobioscsm
> bits 16
> org 0x7C00
> start:
>     sti
>     cld
>     mov si, msg
>     mov ah, 0x0E
>     .loop lodsb
>     or al, al
>     jz halt
>     int 0x10
>     jmp .loop
> halt:
>     hlt
>     jmp halt
> msg:
>     db 0x0D, 0x0A, 'Boot with BIOS/CSM/LEGACY no longer supported : reboot
> with EFI/UEFI', 0
>
> and here is what appears on the screen (Lenovo Thinkcenter M720) instead
> of the expected message :
>
> [image: clover.jpg]
>
> the problem occurs mainly with the Lenovo brand (Thinkcentre M70
> <https://www.google.com/search?q=Lenovo+Thinkcenter+M70>, Thinkcentre M720
> <https://www.google.com/search?q=Lenovo+Thinkcenter+M720>), but not only
> according to my information.
>
> changing the partitioning to BIOS/Intel/MBR (instead of GPT) does not
> change the problem : this last point makes me strongly believe that the
> problem comes from the code...
>
> regards, lacsaP.
>
> Le mer. 12 oct. 2022 à 11:22, Frederic Pasteleurs <lists at askarel.be> a
> écrit :
>
>> Hello,
>>
>> Here is how i would customize your code:
>>
>> ; nasm nobioscsm.asm -f bin -o nobioscsm
>>
>> bits 16
>> org 0x7C00
>>
>> start:
>>      sti ; no need to clear interrupts here: since we're going to crash
>> anyway, leave them on
>>      cld ; Make sure we go forward
>>      mov si, msg
>>      mov ah, 0x0E
>>      .loop lodsb
>>      or al, al
>>      jz halt
>>      int 0x10
>>      jmp .loop
>>
>> halt:
>>      hlt
>>      jmp halt ; The  hlt instruction sometimes behaves like a NOP. Just
>> run in an infinite loop. CTRL-ALT-DEL should still continue to work to
>> restart the machine
>>
>> msg:
>>      db 0x0D, 0x0A, '** Boot with BIOS/CSM no longer supported : reboot
>> with
>> EFI/UEFI **', 0
>>
>> ;times 510 - ($-$$) db 0
>> ;dw 0xAA55
>>
>>
>> On 1/08/22 09:51, Pascal via Syslinux wrote:
>> > hi,
>> >
>> > I have a live system with only UEFI boot supported.
>> >
>> > to indicate this to users who have not yet switched to UEFI, I have
>> below
>> > this simple little piece of code (partly found on the internet) that I
>> > compile with nasm and I push onto the MBR.
>> >
>> > it runs perfectly on some PCs and in virtual machine with Qemu, but
>> refuses
>> > to run on other PCs by displaying either a kind of smiley logo or a
>> simple
>> > blinking cursor.
>> >
>> > does anyone have any idea or clue about this?
>> >
>> > regards, lacsaP.
>> >
>> > 8<--------------------------------
>> > ; nasm nobioscsm.asm -f bin -o nobioscsm
>> >
>> > bits 16
>> > org 0x7C00
>> >
>> > start:
>> >      cli
>> >      mov si, msg
>> >      mov ah, 0x0E
>> >      .loop lodsb
>> >      or al, al
>> >      jz halt
>> >      int 0x10
>> >      jmp .loop
>> >
>> > halt:
>> >      hlt
>> >
>> > msg:
>> >      db 0x0D, 0x0A, '** Boot with BIOS/CSM no longer supported : reboot
>> with
>> > EFI/UEFI **', 0
>> >
>> > ;times 510 - ($-$$) db 0
>> > ;dw 0xAA55
>> > _______________________________________________
>> > Syslinux mailing list
>> > Submissions to Syslinux at syslinux.org
>> > Unsubscribe or set options at:
>> > https://lists.syslinux.org/syslinux
>>
>
hi,

a little feedback on this subject we broached at the end of last year.

I think I've identified the problem, which is linked to the workstation's
UEFI, which "jams" when the GPT is "malformed".
so, the problem has nothing to do with the little piece of code designed to
display the warning...

the USB media is initially "burned" with a small disk image in GPT format :
the GPT defined in this small disk image is no longer valid for this USB
media once the disk image has been dropped onto it (for example, the backup
copy expected at the end of the USB media is not there or is not the right
one).

disk image
[[GPT#1][P1 NTFS][P2 ESP][GPT#2]]
USB media
[[GPT#1][P1 NTFS][P2 ESP][GPT#2]             ]
- or -
[[GPT#1][P1 NTFS][P2 ESP][GPT#2]      [OLD#2]]

the same USB media "initialized" (this initialization, performed in
initramfs at first boot, consists in repartitioning the USB media to occupy
all its space) on a second workstation that does not pose this problem,
then no longer poses a problem on the first workstation.

USB media initialized
[[GPT#1][P1 NTFS:::::::::::::][P2 ESP][GPT#2]]

the repartitioning operation "corrects" the GPT and the recalcitrant
workstation is no longer recalcitrant following this correction.

I hope I've made my explanations clear.

regards, lacsaP.

(ps : I still don't have any recalcitrant workstation available)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: clover.jpg
Type: image/jpeg
Size: 210569 bytes
Desc: not available
URL: <https://lists.syslinux.org/archives/syslinux/attachments/20230706/3160a99a/attachment-0001.jpg>


More information about the Syslinux mailing list