add TPCM support with ipmi channel
Signed-off-by: Qiumiao Zhang <zhangqiumiao1@huawei.com> (cherry picked from commit 1e52014b39673718830070eb7dfe450646954074)
This commit is contained in:
parent
e2073a0c9f
commit
acc6d8a204
@ -13,7 +13,6 @@ fix firmwarehash length and uiCmdLength error
|
|||||||
clean code
|
clean code
|
||||||
|
|
||||||
zhangqiumiao(4):
|
zhangqiumiao(4):
|
||||||
skip verification when just opening the grub.cfg without loading it
|
|
||||||
support control switch
|
support control switch
|
||||||
modify GRUB_IPMI_TIMEOUT_MS from 7000 to 2000
|
modify GRUB_IPMI_TIMEOUT_MS from 7000 to 2000
|
||||||
|
|
||||||
@ -68,10 +67,10 @@ index 0000000..57a4cea
|
|||||||
+ ((value >> 8 ) & 0x0000FF00) | \
|
+ ((value >> 8 ) & 0x0000FF00) | \
|
||||||
+ ((value >> 24 ) & 0x000000FF))
|
+ ((value >> 24 ) & 0x000000FF))
|
||||||
+
|
+
|
||||||
+static grub_efi_guid_t gIpmiInterfaceProtocolGuid = EFI_TPCM_GUID;
|
+static grub_guid_t gIpmiInterfaceProtocolGuid = EFI_TPCM_GUID;
|
||||||
+static grub_efi_guid_t hash2_service_binding_guid = GRUB_EFI_HASH2_SERVICE_BINDING_PROTOCOL_GUID;
|
+static grub_guid_t hash2_service_binding_guid = GRUB_EFI_HASH2_SERVICE_BINDING_PROTOCOL_GUID;
|
||||||
+static grub_efi_guid_t hash2_guid = GRUB_EFI_HASH2_PROTOCOL_GUID;
|
+static grub_guid_t hash2_guid = GRUB_EFI_HASH2_PROTOCOL_GUID;
|
||||||
+static grub_efi_guid_t sm3_guid = GRUB_HASH_ALGORITHM_SM3_GUID;
|
+static grub_guid_t sm3_guid = GRUB_HASH_ALGORITHM_SM3_GUID;
|
||||||
+
|
+
|
||||||
+static grub_efi_ipmi_interface_protocol_t *tpcm_ipmi;
|
+static grub_efi_ipmi_interface_protocol_t *tpcm_ipmi;
|
||||||
+static grub_efi_uint16_t grub_tcpm_file_type = GRUB_FILE_TYPE_NONE;
|
+static grub_efi_uint16_t grub_tcpm_file_type = GRUB_FILE_TYPE_NONE;
|
||||||
@ -80,7 +79,7 @@ index 0000000..57a4cea
|
|||||||
+static grub_efi_uint8_t permissive = 0;
|
+static grub_efi_uint8_t permissive = 0;
|
||||||
+
|
+
|
||||||
+static grub_efi_handle_t
|
+static grub_efi_handle_t
|
||||||
+grub_efi_service_binding (grub_efi_guid_t *service_binding_guid)
|
+grub_efi_service_binding (grub_guid_t *service_binding_guid)
|
||||||
+{
|
+{
|
||||||
+ grub_efi_service_binding_t *service;
|
+ grub_efi_service_binding_t *service;
|
||||||
+ grub_efi_status_t status;
|
+ grub_efi_status_t status;
|
||||||
@ -102,7 +101,7 @@ index 0000000..57a4cea
|
|||||||
+ return NULL;
|
+ return NULL;
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
+ status = efi_call_2 (service->create_child, service, &child_dev);
|
+ status = service->create_child (service, &child_dev);
|
||||||
+ if (status != GRUB_EFI_SUCCESS)
|
+ if (status != GRUB_EFI_SUCCESS)
|
||||||
+ {
|
+ {
|
||||||
+ grub_printf ("Failed to create child device of efi service %x\n", status);
|
+ grub_printf ("Failed to create child device of efi service %x\n", status);
|
||||||
@ -718,19 +717,19 @@ index 0000000..d4cf93b
|
|||||||
+struct grub_efi_hash2_protocol {
|
+struct grub_efi_hash2_protocol {
|
||||||
+ grub_efi_status_t
|
+ grub_efi_status_t
|
||||||
+ (*get_hash_size) (struct grub_efi_hash2_protocol *this,
|
+ (*get_hash_size) (struct grub_efi_hash2_protocol *this,
|
||||||
+ grub_efi_guid_t *hash_algorithm,
|
+ grub_guid_t *hash_algorithm,
|
||||||
+ grub_efi_uintn_t hash_size);
|
+ grub_efi_uintn_t hash_size);
|
||||||
+
|
+
|
||||||
+ grub_efi_status_t
|
+ grub_efi_status_t
|
||||||
+ (*hash) (struct grub_efi_hash2_protocol *this,
|
+ (*hash) (struct grub_efi_hash2_protocol *this,
|
||||||
+ grub_efi_guid_t *hash_algorithm,
|
+ grub_guid_t *hash_algorithm,
|
||||||
+ grub_efi_uint8_t *message,
|
+ grub_efi_uint8_t *message,
|
||||||
+ grub_efi_uintn_t message_size,
|
+ grub_efi_uintn_t message_size,
|
||||||
+ grub_efi_hash2_output *hash);
|
+ grub_efi_hash2_output *hash);
|
||||||
+
|
+
|
||||||
+ grub_efi_status_t
|
+ grub_efi_status_t
|
||||||
+ (*hash_init) (struct grub_efi_hash2_protocol *this,
|
+ (*hash_init) (struct grub_efi_hash2_protocol *this,
|
||||||
+ grub_efi_guid_t *hash_algorithm);
|
+ grub_guid_t *hash_algorithm);
|
||||||
+
|
+
|
||||||
+ grub_efi_status_t
|
+ grub_efi_status_t
|
||||||
+ (*hash_update) (struct grub_efi_hash2_protocol *this,
|
+ (*hash_update) (struct grub_efi_hash2_protocol *this,
|
||||||
|
|||||||
@ -118,7 +118,7 @@
|
|||||||
|
|
||||||
### fixme
|
### fixme
|
||||||
%ifarch aarch64 %{arm} riscv64 loongarch64
|
%ifarch aarch64 %{arm} riscv64 loongarch64
|
||||||
%global efi_modules " tpm "
|
%global efi_modules " tpm tpcm_kunpeng "
|
||||||
%else
|
%else
|
||||||
%global efi_modules " backtrace chain tpm usb usbserial_common usbserial_pl2303 usbserial_ftdi usbserial_usbdebug keylayouts at_keyboard "
|
%global efi_modules " backtrace chain tpm usb usbserial_common usbserial_pl2303 usbserial_ftdi usbserial_usbdebug keylayouts at_keyboard "
|
||||||
%endif
|
%endif
|
||||||
|
|||||||
@ -216,5 +216,5 @@ Patch215: 0032-Try-prefix-if-fw_path-doesn-t-work.patch
|
|||||||
Patch216: 0034-Make-grub2-mkconfig-construct-titles-that-look-like-.patch
|
Patch216: 0034-Make-grub2-mkconfig-construct-titles-that-look-like-.patch
|
||||||
Patch217: 0035-Add-friendly-grub2-password-config-tool-985962.patch
|
Patch217: 0035-Add-friendly-grub2-password-config-tool-985962.patch
|
||||||
Patch218: grub2-set-password-prompts-to-enter-the-current-pass.patch
|
Patch218: grub2-set-password-prompts-to-enter-the-current-pass.patch
|
||||||
#Patch208: add-TPCM-support-with-ipmi-channel.patch
|
Patch219: add-TPCM-support-with-ipmi-channel.patch
|
||||||
#Patch209: skip-verification-when-not-loading-grub.cfg.patch
|
Patch220: skip-verification-when-not-loading-grub.cfg.patch
|
||||||
|
|||||||
@ -14,7 +14,7 @@
|
|||||||
Name: grub2
|
Name: grub2
|
||||||
Epoch: 1
|
Epoch: 1
|
||||||
Version: 2.12
|
Version: 2.12
|
||||||
Release: 4
|
Release: 5
|
||||||
Summary: Bootloader with support for Linux, Multiboot and more
|
Summary: Bootloader with support for Linux, Multiboot and more
|
||||||
License: GPLv3+
|
License: GPLv3+
|
||||||
URL: http://www.gnu.org/software/grub/
|
URL: http://www.gnu.org/software/grub/
|
||||||
@ -449,6 +449,12 @@ fi
|
|||||||
%{_datadir}/man/man*
|
%{_datadir}/man/man*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Mar 21 2024 zhangqiumiao <zhangqiumiao1@huawei.com> - 1:2.12-5
|
||||||
|
- Type:requirement
|
||||||
|
- CVE:NA
|
||||||
|
- SUG:NA
|
||||||
|
- DESC:add TPCM support with ipmi channel
|
||||||
|
|
||||||
* Mon Mar 11 2024 zhangqiumiao <zhangqiumiao1@huawei.com> - 1:2.12-4
|
* Mon Mar 11 2024 zhangqiumiao <zhangqiumiao1@huawei.com> - 1:2.12-4
|
||||||
- Type:bugfix
|
- Type:bugfix
|
||||||
- CVE:NA
|
- CVE:NA
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user