Hi,
We have created a custom board with the i.MX8QM. Currently, we are evaluating it using an evaluation board (i.MX8QM MEK) until the custom board is ready. We are using BSP version LF6.6.3_1.0.0, so we are using SCFW version 1.15.0.
On the custom board, U-Boot/Linux controls the SPINOR via FlexSPI0.
Therefore, we moved the resource allocated to M4_1 (Partition 4) to U-Boot/Linux (Partition 6) in SCFW. The SCFW changes (Resource, PAD, allocated FlexSPI memory) are as follows:
Are the following changes correct?
diff --git a/platform/board/mx8qm_mek/board.c b/platform/board/mx8qm_mek/board.c
index dfabbdb..edd8ea9 100755
--- a/platform/board/mx8qm_mek/board.c
+++ b/platform/board/mx8qm_mek/board.c
@@ -874,10 +874,9 @@ void board_system_config(sc_bool_t early, sc_rm_pt_t pt_boo
t)
};
/* List of memory regions */
- static const sc_rm_mem_list_t mem_list[2U] =
+ static const sc_rm_mem_list_t mem_list[1U] =
{
- {0x088000000ULL, 0x0887FFFFFULL},
- {0x008081000ULL, 0x008180FFFULL}
+ {0x088000000ULL, 0x0887FFFFFULL}
};
/* Create partition */
@@ -916,7 +915,7 @@ void board_system_config(sc_bool_t early, sc_rm_pt_t pt_boot)
sc_rm_mr_t mr;
/* List of resources */
- static const sc_rsrc_t rsrc_list[9U] =
+ static const sc_rsrc_t rsrc_list[8U] =
{
SC_R_IRQSTR_M4_1,
SC_R_UART_2,
@@ -925,23 +924,20 @@ void board_system_config(sc_bool_t early, sc_rm_pt_t pt_boot)
SC_R_MU_9B,
SC_R_GPT_3,
RM_RANGE(SC_R_CAN_0, SC_R_CAN_2),
- SC_R_FSPI_0
};
/* List of pads */
- static const sc_pad_t pad_list[8U] =
+ static const sc_pad_t pad_list[6U] =
{
RM_RANGE(SC_P_M41_I2C0_SCL, SC_P_M41_GPIO0_01),
RM_RANGE(SC_P_UART0_CTS_B, SC_P_UART0_RTS_B),
RM_RANGE(SC_P_FLEXCAN0_RX, SC_P_FLEXCAN2_TX),
- RM_RANGE(SC_P_QSPI0A_DATA0, SC_P_COMP_CTL_GPIO_1V8_3V3_QSPI0)
};
/* List of memory regions */
- static const sc_rm_mem_list_t mem_list[2U] =
+ static const sc_rm_mem_list_t mem_list[1U] =
{
- {0x088800000ULL, 0x08FFFFFFFULL},
- {0x008181000ULL, 0x008280FFFULL}
+ {0x088800000ULL, 0x08FFFFFFFULL}
};
/* Create partition */
When using flash.bin (flash_linux_m4) which includes the modified scfw_tcm.bin, the device information can be confirmed with the sf probe command in U-Boot as follows:
=> sf probe
SF: Detected mt35xu512aba with page size 256 Bytes, erase size 128 KiB, total 64 MiB
After deleting the following from imx8qm-mek-rpmsg.dts in the kernel, the device information appeared in the kernel boot messages:
diff --git a/arch/arm64/boot/dts/freescale/imx8qm-mek-rpmsg.dts b/arch/arm64/boot/dts/freescale/imx8qm-mek-rpmsg.dts
index 5639b0a84770..f59bf1d71826 100644
--- a/arch/arm64/boot/dts/freescale/imx8qm-mek-rpmsg.dts
+++ b/arch/arm64/boot/dts/freescale/imx8qm-mek-rpmsg.dts
@@ -85,10 +85,6 @@ &flexcan3 {
status = "disabled";
};
-&flexspi0 {
- status = "disabled";
-};
-
&lpuart2 {
status = "disabled";
};
Kernel boot messages:
spi-nor spi0.0: mt35xu512aba (65536 Kbytes)
Both U-Boot and Linux correctly recognize the device information.
Best regards
Hi, AldoG
Thank you for your response.
I would like to proceed with verification using these modifications.