mirror of
https://github.com/linuxboot/heads.git
synced 2024-12-20 13:33:10 +00:00
Better vboot-rwa.fmd for KGPE-D16.
Bring patches/coreboot-4.11 on par with master Removed patches/coreboot-4.11/0020-kgpe-d16-vboot.patch Removed Vboot options from KGPE-D16 coreboot configs Enabled TPM in kgpe-d16 board configs Enabled measured boot in kgpe-d16 coreboot configs. Added support for video cards that require nouveau, radeon and amdgpu drivers in linux-kgpe-d16_workstation.config `nouveau.config=NvForcePost=1` to be added to kexec'd kernels for better Nvidia card support.
This commit is contained in:
parent
bac1d54bde
commit
6bd3f815e4
@ -43,7 +43,7 @@ CONFIG_LINUX_USB=y
|
|||||||
CONFIG_LINUX_E1000E=y
|
CONFIG_LINUX_E1000E=y
|
||||||
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
||||||
|
|
||||||
export CONFIG_TPM=n
|
export CONFIG_TPM=y
|
||||||
#BOOT SCRIPT SELECTION
|
#BOOT SCRIPT SELECTION
|
||||||
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
||||||
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
||||||
|
@ -36,7 +36,7 @@ CONFIG_LINUX_USB=y
|
|||||||
CONFIG_LINUX_E1000E=y
|
CONFIG_LINUX_E1000E=y
|
||||||
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
||||||
|
|
||||||
export CONFIG_TPM=n
|
export CONFIG_TPM=y
|
||||||
#BOOT SCRIPT SELECTION
|
#BOOT SCRIPT SELECTION
|
||||||
export CONFIG_BOOTSCRIPT=/bin/generic-init
|
export CONFIG_BOOTSCRIPT=/bin/generic-init
|
||||||
#export CONFIG_BOOTSCRIPT_NETWORK=/bin/network-init-recovery
|
#export CONFIG_BOOTSCRIPT_NETWORK=/bin/network-init-recovery
|
||||||
|
@ -34,7 +34,7 @@ export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
|||||||
#Enable USB Keyboard support
|
#Enable USB Keyboard support
|
||||||
export CONFIG_USB_KEYBOARD=y
|
export CONFIG_USB_KEYBOARD=y
|
||||||
#No TPM support for the moment
|
#No TPM support for the moment
|
||||||
export CONFIG_TPM=n
|
export CONFIG_TPM=y
|
||||||
#BOOT SCRIPT SELECTION
|
#BOOT SCRIPT SELECTION
|
||||||
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
||||||
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
||||||
@ -49,7 +49,7 @@ export CONFIG_ERROR_BG_COLOR="--background-gradient 0 0 0 150 0 0"
|
|||||||
#Dual output to local console (tty0) and OpenBmc (ttyS1)
|
#Dual output to local console (tty0) and OpenBmc (ttyS1)
|
||||||
#export CONFIG_BOOT_KERNEL_ADD="nohz=on console=ttyS1,115200n8 console=tty0"
|
#export CONFIG_BOOT_KERNEL_ADD="nohz=on console=ttyS1,115200n8 console=tty0"
|
||||||
#Single output to tty0
|
#Single output to tty0
|
||||||
export CONFIG_BOOT_KERNEL_ADD="nohz=on console=tty0"
|
export CONFIG_BOOT_KERNEL_ADD="nohz=on console=tty0 nouveau.config=NvForcePost=1"
|
||||||
#export CONFIG_BOOT_RECOVERY_SERIAL="/dev/ttyS0"
|
#export CONFIG_BOOT_RECOVERY_SERIAL="/dev/ttyS0"
|
||||||
#export CONFIG_BOOT_STATIC_IP=192.168.2.3
|
#export CONFIG_BOOT_STATIC_IP=192.168.2.3
|
||||||
|
|
||||||
|
@ -31,7 +31,7 @@ CONFIG_LINUX_USB=y
|
|||||||
CONFIG_LINUX_E1000E=y
|
CONFIG_LINUX_E1000E=y
|
||||||
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
export CONFIG_LINUX_USB_COMPANION_CONTROLLER=y
|
||||||
|
|
||||||
export CONFIG_TPM=n
|
export CONFIG_TPM=y
|
||||||
#BOOT SCRIPT SELECTION
|
#BOOT SCRIPT SELECTION
|
||||||
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
#export CONFIG_BOOTSCRIPT=/bin/generic-init
|
||||||
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
export CONFIG_BOOTSCRIPT=/bin/gui-init
|
||||||
@ -46,7 +46,7 @@ export CONFIG_ERROR_BG_COLOR="--background-gradient 0 0 0 150 0 0"
|
|||||||
#Dual output to local console (tty0) and OpenBmc (ttyS1)
|
#Dual output to local console (tty0) and OpenBmc (ttyS1)
|
||||||
#export CONFIG_BOOT_KERNEL_ADD="nohz=on console=ttyS1,115200n8 console=tty0"
|
#export CONFIG_BOOT_KERNEL_ADD="nohz=on console=ttyS1,115200n8 console=tty0"
|
||||||
#Single output to tty0
|
#Single output to tty0
|
||||||
export CONFIG_BOOT_KERNEL_ADD="nohz=on console=tty0"
|
export CONFIG_BOOT_KERNEL_ADD="nohz=on console=tty0 nouveau.config=NvForcePost=1"
|
||||||
#export CONFIG_BOOT_RECOVERY_SERIAL="/dev/ttyS0"
|
#export CONFIG_BOOT_RECOVERY_SERIAL="/dev/ttyS0"
|
||||||
#export CONFIG_BOOT_STATIC_IP=192.168.2.3
|
#export CONFIG_BOOT_STATIC_IP=192.168.2.3
|
||||||
|
|
||||||
|
@ -5,14 +5,13 @@ CONFIG_USE_OPTION_TABLE=y
|
|||||||
CONFIG_VENDOR_ASUS=y
|
CONFIG_VENDOR_ASUS=y
|
||||||
CONFIG_UART_FOR_CONSOLE=1
|
CONFIG_UART_FOR_CONSOLE=1
|
||||||
CONFIG_BOARD_ASUS_KGPE_D16=y
|
CONFIG_BOARD_ASUS_KGPE_D16=y
|
||||||
CONFIG_VBOOT=y
|
|
||||||
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
||||||
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
||||||
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
||||||
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
||||||
CONFIG_VBOOT_MEASURED_BOOT=y
|
CONFIG_MEASURED_BOOT=y
|
||||||
CONFIG_VBOOT_MEASURED_BOOT_RUNTIME_DATA="S3NV"
|
|
||||||
CONFIG_USER_TPM1=y
|
CONFIG_USER_TPM1=y
|
||||||
|
CONFIG_TPM_RDRESP_NEED_DELAY=y
|
||||||
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
||||||
CONFIG_PAYLOAD_LINUX=y
|
CONFIG_PAYLOAD_LINUX=y
|
||||||
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_server-whiptail/bzImage"
|
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_server-whiptail/bzImage"
|
||||||
|
@ -5,14 +5,13 @@ CONFIG_USE_OPTION_TABLE=y
|
|||||||
CONFIG_VENDOR_ASUS=y
|
CONFIG_VENDOR_ASUS=y
|
||||||
CONFIG_UART_FOR_CONSOLE=1
|
CONFIG_UART_FOR_CONSOLE=1
|
||||||
CONFIG_BOARD_ASUS_KGPE_D16=y
|
CONFIG_BOARD_ASUS_KGPE_D16=y
|
||||||
CONFIG_VBOOT=y
|
|
||||||
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
||||||
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
||||||
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
||||||
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
||||||
CONFIG_VBOOT_MEASURED_BOOT=y
|
CONFIG_MEASURED_BOOT=y
|
||||||
CONFIG_VBOOT_MEASURED_BOOT_RUNTIME_DATA="S3NV"
|
|
||||||
CONFIG_USER_TPM1=y
|
CONFIG_USER_TPM1=y
|
||||||
|
CONFIG_TPM_RDRESP_NEED_DELAY=y
|
||||||
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
||||||
CONFIG_PAYLOAD_LINUX=y
|
CONFIG_PAYLOAD_LINUX=y
|
||||||
CONFIG_LINUX_COMMAND_LINE="nohz=on console=ttyS1,115200n8 earlyprintk=ttyS1,115200"
|
CONFIG_LINUX_COMMAND_LINE="nohz=on console=ttyS1,115200n8 earlyprintk=ttyS1,115200"
|
||||||
|
@ -5,14 +5,13 @@ CONFIG_USE_OPTION_TABLE=y
|
|||||||
CONFIG_VENDOR_ASUS=y
|
CONFIG_VENDOR_ASUS=y
|
||||||
CONFIG_UART_FOR_CONSOLE=1
|
CONFIG_UART_FOR_CONSOLE=1
|
||||||
CONFIG_BOARD_ASUS_KGPE_D16=y
|
CONFIG_BOARD_ASUS_KGPE_D16=y
|
||||||
CONFIG_VBOOT=y
|
|
||||||
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
||||||
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
||||||
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
||||||
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
||||||
CONFIG_VBOOT_MEASURED_BOOT=y
|
CONFIG_MEASURED_BOOT=y
|
||||||
CONFIG_VBOOT_MEASURED_BOOT_RUNTIME_DATA="S3NV"
|
|
||||||
CONFIG_USER_TPM1=y
|
CONFIG_USER_TPM1=y
|
||||||
|
CONFIG_TPM_RDRESP_NEED_DELAY=y
|
||||||
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
||||||
CONFIG_PAYLOAD_LINUX=y
|
CONFIG_PAYLOAD_LINUX=y
|
||||||
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_workstation-usb_keyboard/bzImage"
|
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_workstation-usb_keyboard/bzImage"
|
||||||
|
@ -5,14 +5,13 @@ CONFIG_USE_OPTION_TABLE=y
|
|||||||
CONFIG_VENDOR_ASUS=y
|
CONFIG_VENDOR_ASUS=y
|
||||||
CONFIG_UART_FOR_CONSOLE=1
|
CONFIG_UART_FOR_CONSOLE=1
|
||||||
CONFIG_BOARD_ASUS_KGPE_D16=y
|
CONFIG_BOARD_ASUS_KGPE_D16=y
|
||||||
CONFIG_VBOOT=y
|
|
||||||
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
CONFIG_DRIVERS_PS2_KEYBOARD=y
|
||||||
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
CONFIG_COREBOOT_ROMSIZE_KB_16384=y
|
||||||
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
CONFIG_SOUTHBRIDGE_AMD_SB700_33MHZ_SPI=y
|
||||||
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
# CONFIG_DRIVERS_INTEL_WIFI is not set
|
||||||
CONFIG_VBOOT_MEASURED_BOOT=y
|
CONFIG_MEASURED_BOOT=y
|
||||||
CONFIG_VBOOT_MEASURED_BOOT_RUNTIME_DATA="S3NV"
|
|
||||||
CONFIG_USER_TPM1=y
|
CONFIG_USER_TPM1=y
|
||||||
|
CONFIG_TPM_RDRESP_NEED_DELAY=y
|
||||||
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
CONFIG_DEFAULT_CONSOLE_LOGLEVEL_8=y
|
||||||
CONFIG_PAYLOAD_LINUX=y
|
CONFIG_PAYLOAD_LINUX=y
|
||||||
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_workstation/bzImage"
|
CONFIG_PAYLOAD_FILE="../../build/kgpe-d16_workstation/bzImage"
|
||||||
|
@ -324,3 +324,6 @@ CONFIG_CRC8=m
|
|||||||
CONFIG_XZ_DEC_TEST=m
|
CONFIG_XZ_DEC_TEST=m
|
||||||
CONFIG_CORDIC=m
|
CONFIG_CORDIC=m
|
||||||
CONFIG_IRQ_POLL=y
|
CONFIG_IRQ_POLL=y
|
||||||
|
CONFIG_DRM_NOUVEAU=y
|
||||||
|
CONFIG_DRM_RADEON=y
|
||||||
|
CONFIG_DRM_AMDGPU=y
|
||||||
|
@ -1,6 +1,8 @@
|
|||||||
--- clean/coreboot-4.8.1/Makefile 2018-05-16 21:00:17.000000000 +0200
|
diff --git a/Makefile b/Makefile
|
||||||
+++ coreboot-4.8.1/Makefile 2020-01-08 17:01:32.998287979 +0100
|
index f3f9592649..cb37557c81 100644
|
||||||
@@ -152,6 +152,24 @@
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -164,6 +164,24 @@ $(if $(wildcard .xcompile)$(NOCOMPILE),,$(eval $(shell util/xcompile/xcompile $(
|
||||||
|
|
||||||
-include .xcompile
|
-include .xcompile
|
||||||
|
|
||||||
@ -25,3 +27,6 @@
|
|||||||
ifneq ($(XCOMPILE_COMPLETE),1)
|
ifneq ($(XCOMPILE_COMPLETE),1)
|
||||||
$(shell rm -f .xcompile)
|
$(shell rm -f .xcompile)
|
||||||
$(error .xcompile deleted because it's invalid. \
|
$(error .xcompile deleted because it's invalid. \
|
||||||
|
--
|
||||||
|
2.20.1
|
||||||
|
|
||||||
|
@ -1,129 +0,0 @@
|
|||||||
diff --git a/src/mainboard/asus/kgpe-d16/Kconfig b/src/mainboard/asus/kgpe-d16/Kconfig
|
|
||||||
index ffbfd53169..45e1a55b88 100644
|
|
||||||
--- a/src/mainboard/asus/kgpe-d16/Kconfig
|
|
||||||
+++ b/src/mainboard/asus/kgpe-d16/Kconfig
|
|
||||||
@@ -34,6 +34,31 @@ config BOARD_SPECIFIC_OPTIONS
|
|
||||||
select POWER_STATE_DEFAULT_ON_AFTER_FAILURE
|
|
||||||
select IPMI_KCS
|
|
||||||
|
|
||||||
+ select TPM1
|
|
||||||
+
|
|
||||||
+ select VBOOT
|
|
||||||
+ select VBOOT_VBNV_CMOS
|
|
||||||
+ select VBOOT_NO_BOARD_SUPPORT
|
|
||||||
+ #select GBB_FLAG_DISABLE_LID_SHUTDOWN
|
|
||||||
+ #select GBB_FLAG_DISABLE_PD_SOFTWARE_SYNC
|
|
||||||
+ #select GBB_FLAG_DISABLE_EC_SOFTWARE_SYNC
|
|
||||||
+ #select GBB_FLAG_DISABLE_FWMP
|
|
||||||
+ select RTC
|
|
||||||
+ select VBOOT_STARTS_IN_ROMSTAGE
|
|
||||||
+ select VBOOT_MEASURED_BOOT
|
|
||||||
+
|
|
||||||
+config VBOOT_VBNV_OFFSET
|
|
||||||
+ hex
|
|
||||||
+ default 0x2f
|
|
||||||
+
|
|
||||||
+config FMDFILE
|
|
||||||
+ string
|
|
||||||
+ default "src/mainboard/$(CONFIG_MAINBOARD_DIR)/vboot-rwa.fmd" if VBOOT
|
|
||||||
+
|
|
||||||
+config VBOOT_MEASURED_BOOT_RUNTIME_DATA
|
|
||||||
+ string
|
|
||||||
+ default "S3NV"
|
|
||||||
+
|
|
||||||
config MAINBOARD_DIR
|
|
||||||
string
|
|
||||||
default "asus/kgpe-d16"
|
|
||||||
diff --git a/src/mainboard/asus/kgpe-d16/cmos.layout b/src/mainboard/asus/kgpe-d16/cmos.layout
|
|
||||||
index 1c8d4662c3..2a2f11c574 100644
|
|
||||||
--- a/src/mainboard/asus/kgpe-d16/cmos.layout
|
|
||||||
+++ b/src/mainboard/asus/kgpe-d16/cmos.layout
|
|
||||||
@@ -54,6 +54,13 @@ entries
|
|
||||||
481 1 e 1 experimental_memory_speed_boost
|
|
||||||
482 1 r 0 allow_spd_nvram_cache_restore
|
|
||||||
483 4 h 0 maximum_p_state_limit
|
|
||||||
+
|
|
||||||
+
|
|
||||||
+# VBOOT
|
|
||||||
+488 128 r 0 vbnv
|
|
||||||
+
|
|
||||||
+
|
|
||||||
+
|
|
||||||
728 256 h 0 user_data
|
|
||||||
984 16 h 0 check_sum
|
|
||||||
# Reserve the extended AMD configuration registers
|
|
||||||
diff --git a/src/mainboard/asus/kgpe-d16/vboot-rwa.fmd b/src/mainboard/asus/kgpe-d16/vboot-rwa.fmd
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000000..1b666000cf
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/src/mainboard/asus/kgpe-d16/vboot-rwa.fmd
|
|
||||||
@@ -0,0 +1,24 @@
|
|
||||||
+FLASH@0xff800000 0x800000 {
|
|
||||||
+ SI_ALL@0x0 0x500000 {
|
|
||||||
+ SI_DESC@0x0 0x1000
|
|
||||||
+ SI_GBE@0x1000 0x2000
|
|
||||||
+ SI_ME@0x3000 0x4ed000
|
|
||||||
+ }
|
|
||||||
+ SI_BIOS@0x500000 0x300000 {
|
|
||||||
+ UNIFIED_MRC_CACHE@0x180000 0x20000 {
|
|
||||||
+ RECOVERY_MRC_CACHE@0x0 0x10000
|
|
||||||
+ RW_MRC_CACHE@0x10000 0x10000
|
|
||||||
+ }
|
|
||||||
+ RW_VPD(PRESERVE)@0x1a0000 0x1000
|
|
||||||
+ SMMSTORE(PRESERVE)@0x1a1000 0x40000
|
|
||||||
+
|
|
||||||
+ WP_RO@0x1e1000 0x11f000 {
|
|
||||||
+ FMAP@0x0 0x800
|
|
||||||
+ RO_FRID@0x800 0x40
|
|
||||||
+ RO_PADDING@0x840 0x7c0
|
|
||||||
+ RO_VPD(PRESERVE)@0x1000 0x1000
|
|
||||||
+ GBB@0x2000 0x1e000
|
|
||||||
+ COREBOOT(CBFS)@0x20000 0xff000
|
|
||||||
+ }
|
|
||||||
+ }
|
|
||||||
+}
|
|
||||||
diff --git a/src/southbridge/amd/sb700/Makefile.inc b/src/southbridge/amd/sb700/Makefile.inc
|
|
||||||
index 0a20a8c8b3..c1cd41678a 100644
|
|
||||||
--- a/src/southbridge/amd/sb700/Makefile.inc
|
|
||||||
+++ b/src/southbridge/amd/sb700/Makefile.inc
|
|
||||||
@@ -24,4 +24,8 @@ romstage-y += smbus.c
|
|
||||||
romstage-y += ramtop.c
|
|
||||||
ramstage-y += ramtop.c
|
|
||||||
|
|
||||||
+romstage-y += pmutil.c
|
|
||||||
+verstage-y += pmutil.c
|
|
||||||
+ramstage-y += pmutil.c
|
|
||||||
+
|
|
||||||
endif
|
|
||||||
diff --git a/src/southbridge/amd/sb700/pmutil.c b/src/southbridge/amd/sb700/pmutil.c
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000000..2c2db3df43
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/src/southbridge/amd/sb700/pmutil.c
|
|
||||||
@@ -0,0 +1,25 @@
|
|
||||||
+/*
|
|
||||||
+ * This file is part of the coreboot project.
|
|
||||||
+ *
|
|
||||||
+ * Copyright 2017 Google Inc.
|
|
||||||
+ *
|
|
||||||
+ * This program is free software; you can redistribute it and/or modify
|
|
||||||
+ * it under the terms of the GNU General Public License as published by
|
|
||||||
+ * the Free Software Foundation; version 2 of the License.
|
|
||||||
+ *
|
|
||||||
+ * This program is distributed in the hope that it will be useful,
|
|
||||||
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
||||||
+ * GNU General Public License for more details.
|
|
||||||
+ */
|
|
||||||
+
|
|
||||||
+#include <arch/acpi.h>
|
|
||||||
+#include <security/vboot/vboot_common.h>
|
|
||||||
+#include <security/vboot/vbnv.h>
|
|
||||||
+#include <pc80/mc146818rtc.h>
|
|
||||||
+
|
|
||||||
+int vbnv_cmos_failed(void)
|
|
||||||
+{
|
|
||||||
+ /* If CMOS power has failed, the century will be set to 0xff */
|
|
||||||
+ return cmos_read(RTC_CLK_ALTCENTURY) == 0xff;
|
|
||||||
+}
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user