Skip to contentSkip to conversation

ARM: imx: Enable kaslrseed command on Data Modul i.MX8M Mini/Plus eDM SBC

PATCH Applied Marek Vasut 2 participants 2 messages Jan 22, 2024 – Jan 27, 2024 Arm i.MX and Layerscape

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: imx: Enable kaslrseed command on Data Modul i.MX8M Mini/Plus eDM SBC

Linux 6.6.y with KASLR enabled would print the following message on boot:
"
KASLR disabled due to lack of seed
"
Enable the 'kaslrseed' command so a random number seed can be pulled from CAAM and inserted into the /chosen node 'kaslr-seed' property of Linux kernel DT before boot, thus letting KASLR work properly.

---
Cc: Fabio Estevam <[email protected]>
Cc: Stefano Babic <[email protected]>

---
 configs/imx8mm_data_modul_edm_sbc_defconfig | 2 ++
 configs/imx8mp_data_modul_edm_sbc_defconfig | 2 ++
 2 files changed, 4 insertions(+)
configs/imx8mm_data_modul_edm_sbc_defconfig +2 -0
index f945aea82d7..bbd6ac053ba 100644
@@ -115,6 +115,7 @@ CONFIG_CMD_BOOTCOUNT=y
 CONFIG_CMD_CACHE=y
 CONFIG_CMD_TIME=y
 CONFIG_CMD_GETTIME=y
+CONFIG_CMD_KASLRSEED=y
 CONFIG_CMD_SYSBOOT=y
 CONFIG_CMD_UUID=y
 CONFIG_CMD_PMIC=y
@@ -210,6 +211,7 @@ CONFIG_DM_REGULATOR_BD71837=y
 CONFIG_SPL_DM_REGULATOR_BD71837=y
 CONFIG_DM_REGULATOR_FIXED=y
 CONFIG_DM_REGULATOR_GPIO=y
+CONFIG_DM_RNG=y
 CONFIG_DM_RTC=y
 CONFIG_RTC_M41T62=y
 CONFIG_DM_SERIAL=y
configs/imx8mp_data_modul_edm_sbc_defconfig +2 -0
index d29bc986267..a3e25ea22ab 100644
@@ -122,6 +122,7 @@ CONFIG_CMD_BOOTCOUNT=y
 CONFIG_CMD_CACHE=y
 CONFIG_CMD_TIME=y
 CONFIG_CMD_GETTIME=y
+CONFIG_CMD_KASLRSEED=y
 CONFIG_CMD_SYSBOOT=y
 CONFIG_CMD_UUID=y
 CONFIG_CMD_PMIC=y
@@ -229,6 +230,7 @@ CONFIG_DM_REGULATOR_PCA9450=y
 CONFIG_SPL_DM_REGULATOR_PCA9450=y
 CONFIG_DM_REGULATOR_FIXED=y
 CONFIG_DM_REGULATOR_GPIO=y
+CONFIG_DM_RNG=y
 CONFIG_DM_RTC=y
 CONFIG_RTC_M41T62=y
 CONFIG_DM_SERIAL=y
Signature · 1 line
2.43.0
reviewer Applied
#1 lore raw
Quoted 10 lines · Marek Vasut

Linux 6.6.y with KASLR enabled would print the following message on boot:
"
KASLR disabled due to lack of seed
"
Enable the 'kaslrseed' command so a random number seed can be pulled from CAAM and inserted into the /chosen node 'kaslr-seed' property of Linux kernel DT before boot, thus letting KASLR work properly.

Applied, thanks.