cpu: imx8_cpu: Print Speed grade if IMX_THERMAL or IMX_TMU
PATCH 1/4 cpu: imx8_cpu: Print Speed grade if IMX_THERMAL or IMX_TMU
Much of the data that is display by imx8_cpu.c is also displayed from arch/arm/mach-imx/cpu.c, except the speed grade and temperature unless the SoC is an i.MX9. Expand this to include checks for IMX_THERMAL or IMX_TMU in the same way it's done for mach-imx/cpu.c.
Before:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz Model: Beacon EmbeddedWorks i.MX8MPlus Development kit
After:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz CPU: Industrial temperature grade (-40C to 105C) at 28C Model: Beacon EmbeddedWorks i.MX8MPlus Development kit
drivers/cpu/imx8_cpu.c +3 -1
@@ -177,7 +177,9 @@ static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) ret =snprintf (buf, size,"NXP i.MX%s Rev%s %s at %u MHz" , plat->type, plat->rev, plat->name, plat->freq_mhz); -if (IS_ENABLED (CONFIG_IMX9 )) { +if (IS_ENABLED (CONFIG_IMX9 ) || +IS_ENABLED (CONFIG_IMX_THERMAL ) || +IS_ENABLED (CONFIG_IMX_TMU )) {switch (get_cpu_temp_grade (&minc, &maxc)) {case TEMP_AUTOMOTIVE : grade ="Automotive temperature grade " ;
Signature · 1 line
2.45.2
PATCH 2/4 arm64: imx: imx8mm-beacon: Enable CPU_IMX
Enable CPU_IMX to register the ARM core and identify the speed and temperature information using the driver model.
configs/imx8mm_beacon_defconfig +2 -0
@@ -84,6 +84,8 @@ CONFIG_SPL_CLK_COMPOSITE_CCF=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y CONFIG_CLK_IMX8MM=y +CONFIG_CPU=y +CONFIG_CPU_IMX=y CONFIG_USB_FUNCTION_FASTBOOT=y CONFIG_FASTBOOT_BUF_ADDR=0x42800000 CONFIG_FASTBOOT_BUF_SIZE=0x20000000
Signature · 1 line
2.45.2
PATCH 3/4 arm64: imx: imx8mn-beacon: Enable CPU_IMX
In reply to Adam FordEnable CPU_IMX to register the ARM core and identify the speed and temperature information using the driver model.
configs/imx8mn_beacon_defconfig +2 -0
@@ -93,6 +93,8 @@ CONFIG_REGMAP=y CONFIG_SYSCON=y CONFIG_SPL_CLK_IMX8MN=y CONFIG_CLK_IMX8MN=y +CONFIG_CPU=y +CONFIG_CPU_IMX=y CONFIG_USB_FUNCTION_FASTBOOT=y CONFIG_FASTBOOT_BUF_ADDR=0x42800000 CONFIG_FASTBOOT_BUF_SIZE=0x40000000
Signature · 1 line
2.45.2
PATCH 4/4 arm64: imx: imx8mp-beacon: Enable CPU_IMX
In reply to Adam FordEnable CPU_IMX to register the ARM core and identify the speed and temperature information using the driver model.
configs/imx8mp_beacon_defconfig +2 -0
@@ -88,6 +88,8 @@ CONFIG_SPL_DM=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MP=y CONFIG_CLK_IMX8MP=y +CONFIG_CPU=y +CONFIG_CPU_IMX=y CONFIG_USB_FUNCTION_FASTBOOT=y CONFIG_FASTBOOT_BUF_ADDR=0x42800000 CONFIG_FASTBOOT_BUF_SIZE=0x20000000
Signature · 1 line
2.45.2
Quoted 22 lines · Adam Ford
Much of the data that is display by
imx8_cpu.cis also displayed fromarch/arm/mach-imx/cpu.c, except the speed grade and temperature unless the SoC is an i.MX9. Expand this to include checks forIMX_THERMALorIMX_TMUin the same way it's done formach-imx/cpu.c.Before:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz Model: Beacon EmbeddedWorks i.MX8MPlus Development kitAfter:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz CPU: Industrial temperature grade (-40C to 105C) at 28C Model: Beacon EmbeddedWorks i.MX8MPlus Development kitSigned-off-by Adam Ford <[email protected]>drivers/cpu/imx8_cpu.c +0
-0
drivers/cpu/imx8_cpu.c static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) · line 182
Quoted 7 lines
drivers/cpu/imx8_cpu.c +3
-1@@ -177,7 +177,9 @@ static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) ret =snprintf (buf, size,"NXP i.MX%s Rev%s %s at %u MHz" , plat->type, plat->rev, plat->name, plat->freq_mhz); -if (IS_ENABLED (CONFIG_IMX9 )) { +if (IS_ENABLED (CONFIG_IMX9 ) || +IS_ENABLED (CONFIG_IMX_THERMAL ) || +IS_ENABLED (CONFIG_IMX_TMU )) {
Can CONFIG_IMX9 instead select CONFIG_IMX_THERMAL or CONFIG_IMX_TMU , so the SoC specific check could be removed from here ?
Quoted 27 lines · Marek Vasut
Quoted 25 lines · Adam Ford
Much of the data that is display by
imx8_cpu.cis also displayed fromarch/arm/mach-imx/cpu.c, except the speed grade and temperature unless the SoC is an i.MX9. Expand this to include checks forIMX_THERMALorIMX_TMUin the same way it's done formach-imx/cpu.c.Before:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz Model: Beacon EmbeddedWorks i.MX8MPlus Development kitAfter:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz CPU: Industrial temperature grade (-40C to 105C) at 28C Model: Beacon EmbeddedWorks i.MX8MPlus Development kitSigned-off-by Adam Ford <[email protected]>drivers/cpu/imx8_cpu.c +0
-0@@ -177,7 +177,9 @@ static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) ret =snprintf (buf, size,"NXP i.MX%s Rev%s %s at %u MHz" , plat->type, plat->rev, plat->name, plat->freq_mhz);
Quoted 7 lines
drivers/cpu/imx8_cpu.c static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) · line 182
Quoted 4 lines
drivers/cpu/imx8_cpu.c +3
-1-if (IS_ENABLED (CONFIG_IMX9 )) { +if (IS_ENABLED (CONFIG_IMX9 ) || +IS_ENABLED (CONFIG_IMX_THERMAL ) || +IS_ENABLED (CONFIG_IMX_TMU )) {Can
CONFIG_IMX9instead selectCONFIG_IMX_THERMALorCONFIG_IMX_TMU, so the SoC specific check could be removed from here ?
Any idea which of IMX_THERMAL or IMX_TMU should be selected or implied? I don't have an IMX9 to test.
adam
Quoted 36 lines · Adam Ford
Quoted 27 lines · Marek Vasut
Quoted 25 lines · Adam Ford
Much of the data that is display by
imx8_cpu.cis also displayed fromarch/arm/mach-imx/cpu.c, except the speed grade and temperature unless the SoC is an i.MX9. Expand this to include checks forIMX_THERMALorIMX_TMUin the same way it's done formach-imx/cpu.c.Before:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz Model: Beacon EmbeddedWorks i.MX8MPlus Development kitAfter:
CPU: NXP i.MX8MP Rev1.1 A53 at 1200 MHz CPU: Industrial temperature grade (-40C to 105C) at 28C Model: Beacon EmbeddedWorks i.MX8MPlus Development kitSigned-off-by Adam Ford <[email protected]>drivers/cpu/imx8_cpu.c +0
-0@@ -177,7 +177,9 @@ static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) ret =snprintf (buf, size,"NXP i.MX%s Rev%s %s at %u MHz" , plat->type, plat->rev, plat->name, plat->freq_mhz);Quoted 7 lines
drivers/cpu/imx8_cpu.c static int cpu_imx_get_desc(const struct udevice *dev, char *buf, int size) · line 182
Quoted 4 lines
drivers/cpu/imx8_cpu.c +3
-1-if (IS_ENABLED (CONFIG_IMX9 )) { +if (IS_ENABLED (CONFIG_IMX9 ) || +IS_ENABLED (CONFIG_IMX_THERMAL ) || +IS_ENABLED (CONFIG_IMX_TMU )) {Can
CONFIG_IMX9instead selectCONFIG_IMX_THERMALorCONFIG_IMX_TMU, so the SoC specific check could be removed from here ?
Quoted 2 lines
Any idea which of
IMX_THERMALorIMX_TMUshould be selected or implied? I don't have an IMX9 to test.
git grep says:
drivers/thermal/imx_tmu.c: { .compatible = "fsl,imx93-tmu", .data = FLAGS_VER4, },