Page 1 of 2

Clock gating

Posted: 2022-05-22 06:13
by fch
Hello I am having problems installing Debian on a new machine, after installing after the reboot I get the error "booting from "SATA: Star Drives SATA SSD' failed: verify it contains a 64-bit UEFI OS. it comes with a configurable Coreboot firmware, one of the options is to activate the legacy 8254 timer, is that required by Debian?
I tested other distros, like ubuntu, manjaro and they work. I had some problems with MX linux too, but I really want to fix that and install Debian.
The machine is a starlabs lite mk3
In the starlabs support page there's this about this firmware function:
Clock Gating
Enables or disables the 8254 legacy timer. Reduces power consumption when enabled but must be disabled for distributions such as Qubes.
https://support.starlabs.systems/kb/gui ... nfigurator

Re: Clock gating

Posted: 2022-05-22 09:14
by p.H
The firmware seems to want an EFI boot loader. What does it have to do with clock gating or legacy timer ?
Check EFI boot variables with efibootmgr -v and the presence and contents of an EFI system partition.

Re: Clock gating

Posted: 2022-05-23 05:17
by fch
I don't know what it has to do with clock gating, that's why I asked.
I got this output of efibootmgr -v:

Code: Select all

BootCurrent: 0001
Timeout: 1 seconds
BootOrder: 0003,0000,0001,0002
Boot0000* UiApp	MemoryMapped(11,0x803860,0xb2885f)/FvFile(462caa21-7614-4503-836e-8ab6f4662331)
Boot0001* SATA: Star Drive SATA SSD 	PciRoot(0x0)/Pci(0x12,0x0)/Sata(0,65535,0)N.....YM....R,Y.
Boot0002* UEFI Shell	MemoryMapped(11,0x803860,0xb2885f)/FvFile(7c04a583-9e3e-4f1c-ad65-e05268d0b4d1)
Boot0003* ubuntu	HD(1,GPT,85704b1d-494c-41e7-8d45-b56270211742,0x800,0x100000)/File(\EFI\ubuntu\shimx64.efi)

Re: Clock gating

Posted: 2022-05-23 18:50
by p.H
What about the other part (EFI partition presence and content) ?

Re: Clock gating

Posted: 2022-05-29 13:48
by fch
I found what is the problem and was able to boot, in the coreboot bios there is the option to boot from file, there I found the grubx64.efi. But after adding that as and option, the coreboot holds it only for that session after a reboot it's gone and I have to boot from file again.

Re: Clock gating

Posted: 2022-05-29 16:44
by p.H
fch wrote: 2022-05-29 13:48 I found what is the problem
What is it ?
fch wrote: 2022-05-29 13:48 in the coreboot bios there is the option to boot from file
I have that option in HP UEFI boot menu. It is a non-persistent one-time boot option.

Will you show the contents of the EFI partition at last ?
There is no EFI boot variable for the regular location used by Debian. There seems to be a generic boot variable for the whole SSD, but it will work only if GRUB is installed in the so-called "removable media path".

Re: Clock gating

Posted: 2022-05-29 19:44
by fch
p.H wrote: 2022-05-23 18:50 What about the other part (EFI partition presence and content) ?
I am not sure of how to check that, if on the BIOS this is the path I am using to start the machine properly:
\EFI\Debian\shimx64.efi
inside EFI there's:
<.>
<..>
<Debian>
<boot>

inside the above folder Debian there`s:
shimx64.efi
grubx64.efi
mmx64.efi
fbx64.efi

Not sure if that's what you asked, let me know.

Re: Clock gating

Posted: 2022-05-29 19:56
by p.H
What's in EFI/boot ?

Re: Clock gating

Posted: 2022-05-29 21:06
by fch
there's only:
<.>
<..>


there's also the option to create a folder or file inside it

Re: Clock gating

Posted: 2022-05-29 21:58
by p.H
The removable media path is empty, no wonder why it does not boot.
Try this

Code: Select all

grub-install --force-extra-removable

Re: Clock gating

Posted: 2022-05-29 22:30
by fch
p.H wrote: 2022-05-29 21:58 The removable media path is empty, no wonder why it does not boot.
Try this

Code: Select all

grub-install --force-extra-removable
it returns a command not found, then I tried installing grub, it outputs that 'grub-legacy' is selected instead of 'grub'. If I choose to go forward and install grub-legacy, it says those packages will be removed:
efibootmgr grub-efi-amd64-bin grub-efi-amd64-signed mokutil
shim-helpers-amd64-signed shim-signed-common shim-unsigned
Should I do it? Will it not brake my install?

Re: Clock gating

Posted: 2022-05-30 07:09
by p.H
Of course you should NOT do it. grub-legacy is obsolete and does not support EFI boot. The proper package is grub-efi-amd64 which is already installed.
Are you sure you ran the command in a proper root environment with $PATH containing /sbin and /usr/sbin ? Or did you use "su" without "-", "-l" or "--login", which creates an incomplete environment ?

Re: Clock gating

Posted: 2022-05-30 07:53
by fch
Here's what I did first:
$ grub-install --force-extra-removable
bash: grub-install: command not found

Then I fought it happened because grub may not installed , the I ran 'sudo apt install grub' and got that output above saying those packages would be removed.

Re: Clock gating

Posted: 2022-05-30 08:00
by fch
I am also asking the devs of the coreboot I am using about this problem:
https://github.com/StarLabsLtd/firmware/issues/40

Re: Clock gating

Posted: 2022-05-30 08:13
by p.H
This command requires root privileges, like apt install. "$" in the shell prompt means that you are not root, it should be "#". Use sudo before the command or start a root shell with "su -".

Re: Clock gating

Posted: 2022-05-30 08:20
by fch
oh man, it worked!! thank you so much for your patient and time!

Re: Clock gating

Posted: 2022-05-30 08:22
by p.H
Can you post the output of efibootmgr again, check if a new boot entry was created for Debian, and if it was actually used for booting (in BootCurrent) ?

Re: Clock gating

Posted: 2022-05-30 09:00
by fch
BootCurrent: 0001
Timeout: 1 seconds
BootOrder: 0003,0000,0001,0002
Boot0000* UiApp
Boot0001* SATA: Star Drive SATA SSD
Boot0002* UEFI Shell
Boot0003* debian

Re: Clock gating

Posted: 2022-05-30 09:12
by p.H
Boot0003 was created for Debian and set first in BootOrder but BootCurrent indicates that Boot0001 was used for booting. It means that the firmware may be flawed and boot from the removable media path (EFI/boot) instead of the regular location (EFI/debian).

--force-extra-removable installed a copy of GRUB in EFI/boot but future GRUB package updates won't automatically update it in that location unless you reconfigure grub-efi-amd64 with

Code: Select all

dpkg-reconfigure grub-efi-amd64
and confirm to install GRUB in the removable media path.

Debian is conservative and, unlike other distributions or OS, won't install GRUB in the removable media path by default. It prefers to break Debian boot rather than risking to break an existing system boot by overwriting the removable media path. Unfortunately, the option is offered only in expert install (with a deterrent message).

Re: Clock gating

Posted: 2022-05-30 09:19
by fch
after running the above code it opens a window of configuration of grub-efi-amd64 and asks for a linux command line, I don't know that to type into it, it says it can be empty also.