mirror of
https://github.com/linuxboot/heads.git
synced 2025-04-08 11:54:26 +00:00
librem_mini,librem_mini_v2: Enable CMOS layout, update CMOS checksum
Enable the coreboot CMOS option table, which initializes CMOS if the checksum is not valid. There is now a checksum in the CMOS layout since 4.21, update it when updating the Mini v1/v2 EC power-on setting. coreboot 4.21 will reset the CMOS settings during the first boot, since there was no checksum in prior releases. Heads will restore the automatic power-on setting during init based on config.user. Signed-off-by: Jonathon Hall <jonathon.hall@puri.sm>
This commit is contained in:
parent
bde945ea57
commit
eed8adeb49
@ -7,10 +7,16 @@
|
||||
BRAMADDR=0x360
|
||||
BRAMDATA=0x361
|
||||
|
||||
outb "$BRAMADDR" 0x29 # Select byte at offset 29h
|
||||
if [ "$1" = "y" ]; then
|
||||
outb "$BRAMDATA" 0x00 # 0 -> automatic power-on
|
||||
BRAM_VALUE="0x00" # 0 -> automatic power-on
|
||||
else
|
||||
outb "$BRAMDATA" 0x01 # 1 -> stay off
|
||||
BRAM_VALUE="0x01" # 1 -> stay off
|
||||
fi
|
||||
|
||||
outb "$BRAMADDR" 0x29 # Select byte at offset 29h
|
||||
outb "$BRAMDATA" "$BRAM_VALUE"
|
||||
# There's also a 16-bit checksum at offset 3eh in bank 1. The only byte
|
||||
# included in the checksum is the automatic power-on setting, so the value is
|
||||
# the same, and the upper 8 bits remain 0.
|
||||
outb "$BRAMADDR" 0x3e
|
||||
outb "$BRAMDATA" "$BRAM_VALUE"
|
||||
|
@ -7,10 +7,16 @@
|
||||
BRAMADDR=0x360
|
||||
BRAMDATA=0x361
|
||||
|
||||
outb "$BRAMADDR" 0x29 # Select byte at offset 29h
|
||||
if [ "$1" = "y" ]; then
|
||||
outb "$BRAMDATA" 0x00 # 0 -> automatic power-on
|
||||
BRAM_VALUE="0x00" # 0 -> automatic power-on
|
||||
else
|
||||
outb "$BRAMDATA" 0x01 # 1 -> stay off
|
||||
BRAM_VALUE="0x01" # 1 -> stay off
|
||||
fi
|
||||
|
||||
outb "$BRAMADDR" 0x29 # Select byte at offset 29h
|
||||
outb "$BRAMDATA" "$BRAM_VALUE"
|
||||
# There's also a 16-bit checksum at offset 3eh in bank 1. The only byte
|
||||
# included in the checksum is the automatic power-on setting, so the value is
|
||||
# the same, and the upper 8 bits remain 0.
|
||||
outb "$BRAMADDR" 0x3e
|
||||
outb "$BRAMDATA" "$BRAM_VALUE"
|
||||
|
@ -1,10 +1,12 @@
|
||||
CONFIG_CBFS_SIZE=0xC00000
|
||||
CONFIG_USE_OPTION_TABLE=y
|
||||
CONFIG_VENDOR_PURISM=y
|
||||
CONFIG_CBFS_SIZE=0xC00000
|
||||
CONFIG_INTEL_GMA_VBT_FILE="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini/vbt.bin"
|
||||
CONFIG_IFD_BIN_PATH="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini/flashdescriptor.bin"
|
||||
CONFIG_ME_BIN_PATH="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini/me.bin"
|
||||
CONFIG_HAVE_IFD_BIN=y
|
||||
CONFIG_BOARD_PURISM_LIBREM_MINI=y
|
||||
CONFIG_LINUX_COMMAND_LINE="intel_iommu=igfx_off quiet loglevel=2 drm_kms_helper.drm_leak_fbdev_smem=1 i915.enable_fbc=0"
|
||||
CONFIG_CPU_MICROCODE_CBFS_EXTERNAL_BINS=y
|
||||
CONFIG_CPU_UCODE_BINARIES="3rdparty/purism-blobs/mainboard/purism/librem_cnl/cpu_microcode_blob.bin"
|
||||
CONFIG_HAVE_ME_BIN=y
|
||||
@ -12,4 +14,3 @@ CONFIG_NO_GFX_INIT=y
|
||||
CONFIG_PAYLOAD_LINUX=y
|
||||
CONFIG_PAYLOAD_FILE="@BOARD_BUILD_DIR@/bzImage"
|
||||
CONFIG_LINUX_INITRD="@BOARD_BUILD_DIR@/initrd.cpio.xz"
|
||||
CONFIG_LINUX_COMMAND_LINE="intel_iommu=igfx_off quiet loglevel=2 drm_kms_helper.drm_leak_fbdev_smem=1 i915.enable_fbc=0"
|
||||
|
@ -1,9 +1,12 @@
|
||||
CONFIG_USE_OPTION_TABLE=y
|
||||
CONFIG_VENDOR_PURISM=y
|
||||
CONFIG_CBFS_SIZE=0xC00000
|
||||
CONFIG_INTEL_GMA_VBT_FILE="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini/vbt.bin"
|
||||
CONFIG_IFD_BIN_PATH="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini_v2/flashdescriptor.bin"
|
||||
CONFIG_ME_BIN_PATH="3rdparty/purism-blobs/mainboard/purism/librem_cnl/mini_v2/me.bin"
|
||||
CONFIG_HAVE_IFD_BIN=y
|
||||
CONFIG_BOARD_PURISM_LIBREM_MINI_V2=y
|
||||
CONFIG_LINUX_COMMAND_LINE="intel_iommu=igfx_off quiet loglevel=2 drm_kms_helper.drm_leak_fbdev_smem=1 i915.enable_fbc=0"
|
||||
CONFIG_CPU_MICROCODE_CBFS_EXTERNAL_BINS=y
|
||||
CONFIG_CPU_UCODE_BINARIES="3rdparty/purism-blobs/mainboard/purism/librem_cnl/cpu_microcode_blob.bin"
|
||||
CONFIG_HAVE_ME_BIN=y
|
||||
@ -11,5 +14,3 @@ CONFIG_NO_GFX_INIT=y
|
||||
CONFIG_PAYLOAD_LINUX=y
|
||||
CONFIG_PAYLOAD_FILE="@BOARD_BUILD_DIR@/bzImage"
|
||||
CONFIG_LINUX_INITRD="@BOARD_BUILD_DIR@/initrd.cpio.xz"
|
||||
CONFIG_LINUX_COMMAND_LINE="intel_iommu=igfx_off quiet loglevel=2 drm_kms_helper.drm_leak_fbdev_smem=1 i915.enable_fbc=0"
|
||||
CONFIG_CBFS_SIZE=0xC00000
|
||||
|
Loading…
x
Reference in New Issue
Block a user