Re: [PATCH v13 2/6] powerpc: Move arch independent ima kexec functions to drivers/of/kexec.c

From: Lakshmi Ramasubramanian
Date: Tue Dec 22 2020 - 23:58:17 EST


On 12/22/20 4:48 PM, Thiago Jung Bauermann wrote:

Actually, I have one more comment on this patch:

Lakshmi Ramasubramanian <nramas@xxxxxxxxxxxxxxxxxxx> writes:

diff --git a/arch/powerpc/kexec/file_load.c b/arch/powerpc/kexec/file_load.c
index 956bcb2d1ec2..9f3ec0b239ef 100644
--- a/arch/powerpc/kexec/file_load.c
+++ b/arch/powerpc/kexec/file_load.c
@@ -20,7 +20,6 @@
#include <linux/of_fdt.h>
#include <linux/libfdt.h>
#include <asm/setup.h>
-#include <asm/ima.h>
#define SLAVE_CODE_SIZE 256 /* First 0x100 bytes */
@@ -163,12 +162,6 @@ int setup_new_fdt(const struct kimage *image, void *fdt,
if (ret)
goto err;
- ret = setup_ima_buffer(image, fdt, fdt_path_offset(fdt, "/chosen"));
- if (ret) {
- pr_err("Error setting up the new device tree.\n");
- return ret;
- }
-
return 0;
err:

With this change, setup_new_fdt() is nothing more than a call to
of_kexec_setup_new_fdt(). It should be removed, and its caller should
call of_kexec_setup_new_fdt() directly.

This change could be done in patch 4 of this series, to keep this patch
simpler.


Sure Thiago - I will make that change.

thanks,
-lakshmi