Re: [PATCH v21 2/7] crash: add generic infrastructure for crash hotplug support

2023-04-18 Thread Baoquan He
On 04/18/23 at 08:55am, Eric DeVolder wrote: .. > > > > Seems we passed in the cpu number just for printing here. Wondering why > > > > we don't print out hot added/removed memory ranges. Is the cpu number > > > > printing necessary? > > > > > > > Baoquan, > > > > > > Ah, actually until

Re: [PATCH v9 4/4] tpm/kexec: Duplicate TPM measurement log in of-tree for kexec

2023-04-18 Thread kernel test robot
Hi Stefan, kernel test robot noticed the following build warnings: [auto build test WARNING on 6a8f57ae2eb07ab39a6f0ccad60c760743051026] url: https://github.com/intel-lab-lkp/linux/commits/Stefan-Berger/drivers-of-kexec-ima-Support-32-bit-platforms/20230418-214600 base

Re: [PATCH v9 4/4] tpm/kexec: Duplicate TPM measurement log in of-tree for kexec

2023-04-18 Thread Simon Horman
On Tue, Apr 18, 2023 at 09:44:09AM -0400, Stefan Berger wrote: > The memory area of the TPM measurement log is currently not properly > duplicated for carrying it across kexec when an Open Firmware > Devicetree is used. Therefore, the contents of the log get corrupted. > Fix this for the

Re: [PATCH v9 4/4] tpm/kexec: Duplicate TPM measurement log in of-tree for kexec

2023-04-18 Thread kernel test robot
Hi Stefan, kernel test robot noticed the following build warnings: [auto build test WARNING on 6a8f57ae2eb07ab39a6f0ccad60c760743051026] url: https://github.com/intel-lab-lkp/linux/commits/Stefan-Berger/drivers-of-kexec-ima-Support-32-bit-platforms/20230418-214600 base

Re: [PATCH v5 2/2] x86/purgatory: Add linker script

2023-04-18 Thread Nick Desaulniers
On Tue, Apr 11, 2023 at 2:46 PM Ricardo Ribalda wrote: > > Hi Nick > > On Sat, 8 Apr 2023 at 01:22, Nick Desaulniers wrote: > > > > Hi Ricardo, > > Thanks for the patch! Please make sure to cc our mailing list > > for llvm specific issues. > > scripts/get_maintainer.pl should recommend it, or

Re: [PATCH v21 2/7] crash: add generic infrastructure for crash hotplug support

2023-04-18 Thread Eric DeVolder
On 4/6/23 18:58, Baoquan He wrote: On 04/06/23 at 11:10am, Eric DeVolder wrote: On 4/6/23 06:04, Baoquan He wrote: On 04/04/23 at 02:03pm, Eric DeVolder wrote: .. +static void crash_handle_hotplug_event(unsigned int hp_action, unsigned int cpu) +{ + struct kimage *image; + +

[PATCH v9 4/4] tpm/kexec: Duplicate TPM measurement log in of-tree for kexec

2023-04-18 Thread Stefan Berger
The memory area of the TPM measurement log is currently not properly duplicated for carrying it across kexec when an Open Firmware Devicetree is used. Therefore, the contents of the log get corrupted. Fix this for the kexec_file_load() syscall by allocating a buffer and copying the contents of the

[PATCH v9 3/4] of: kexec: Refactor IMA buffer related functions to make them reusable

2023-04-18 Thread Stefan Berger
Refactor IMA buffer related functions to make them reusable for carrying TPM logs across kexec. Signed-off-by: Stefan Berger Cc: Rob Herring Cc: Frank Rowand Cc: Mimi Zohar Reviewed-by: Mimi Zohar Reviewed-by: Rob Herring Tested-by: Nageswara R Sastry Tested-by: Coiby Xu --- v6: - Add

[PATCH v9 1/4] drivers: of: kexec ima: Support 32-bit platforms

2023-04-18 Thread Stefan Berger
From: Palmer Dabbelt RISC-V recently added kexec_file() support, which uses enables kexec IMA. We're the first 32-bit platform to support this, so we found a build bug. Acked-by: Rob Herring Signed-off-by: Palmer Dabbelt Reviewed-by: Mimi Zohar --- drivers/of/kexec.c | 4 ++-- 1 file

[PATCH v9 2/4] tpm: of: Make of-tree specific function commonly available

2023-04-18 Thread Stefan Berger
Simplify tpm_read_log_of() by moving reusable parts of the code into an inline function that makes it commonly available so it can be used also for kexec support. Call the new of_tpm_get_sml_parameters() function from the TPM Open Firmware driver. Signed-off-by: Stefan Berger Cc: Jarkko Sakkinen

[PATCH v9 0/4] tpm: Preserve TPM measurement log across kexec (ppc64)

2023-04-18 Thread Stefan Berger
The of-tree subsystem does not currently preserve the IBM vTPM 1.2 and vTPM 2.0 measurement logs across a kexec on PowerVM and PowerKVM. This series fixes this for the kexec_file_load() syscall using the flattened device tree (fdt) to carry the TPM measurement log's buffer across kexec. Stefan

[PATCH 6.2 092/139] asymmetric_keys: log on fatal failures in PE/pkcs7

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 3584c1dbfffdabf8e3dc1dd25748bb38dd01cd43 ] These particular errors can be encountered while trying to kexec when secureboot lockdown is in place. Without this change, even with a signed debug build, one still needs to reboot the machine to add the

[PATCH 6.2 091/139] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 6.1 086/134] asymmetric_keys: log on fatal failures in PE/pkcs7

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 3584c1dbfffdabf8e3dc1dd25748bb38dd01cd43 ] These particular errors can be encountered while trying to kexec when secureboot lockdown is in place. Without this change, even with a signed debug build, one still needs to reboot the machine to add the

[PATCH 6.1 085/134] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 5.15 45/91] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 5.15 46/91] asymmetric_keys: log on fatal failures in PE/pkcs7

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 3584c1dbfffdabf8e3dc1dd25748bb38dd01cd43 ] These particular errors can be encountered while trying to kexec when secureboot lockdown is in place. Without this change, even with a signed debug build, one still needs to reboot the machine to add the

[PATCH 5.10 092/124] asymmetric_keys: log on fatal failures in PE/pkcs7

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 3584c1dbfffdabf8e3dc1dd25748bb38dd01cd43 ] These particular errors can be encountered while trying to kexec when secureboot lockdown is in place. Without this change, even with a signed debug build, one still needs to reboot the machine to add the

[PATCH 5.10 091/124] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 5.4 68/92] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 5.4 69/92] asymmetric_keys: log on fatal failures in PE/pkcs7

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 3584c1dbfffdabf8e3dc1dd25748bb38dd01cd43 ] These particular errors can be encountered while trying to kexec when secureboot lockdown is in place. Without this change, even with a signed debug build, one still needs to reboot the machine to add the

[PATCH 4.19 45/57] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH 4.14 30/37] verify_pefile: relax wrapper length check

2023-04-18 Thread Greg Kroah-Hartman
From: Robbie Harwood [ Upstream commit 4fc5c74dde69a7eda172514aaeb5a7df3600adb3 ] The PE Format Specification (section "The Attribute Certificate Table (Image Only)") states that `dwLength` is to be rounded up to 8-byte alignment when used for traversal. Therefore, the field is not required to

[PATCH] arm64: kexec: include reboot.h

2023-04-18 Thread Simon Horman
Include reboot.h in machine_kexec.c for declaration of machine_crash_shutdown. gcc-12 with W=1 reports: arch/arm64/kernel/machine_kexec.c:257:6: warning: no previous prototype for 'machine_crash_shutdown' [-Wmissing-prototypes] 257 | void machine_crash_shutdown(struct pt_regs *regs) No