Hi,
I refered to the StartKit 2018.2 FSBL SI5338 code to modify my configuration, and then configure my own registers. My board has no PCIE and IIC switch, so I uncomment these lines.
u32 XFsbl_BoardInit(void)
{
u32 Status;
// TE Mod :
xil_printf("\r\n--------------------------------------------------------------------------------\r\n");
xil_printf("TE0803 Board Initialisation\r\n");
Status = i2c_init(); // Configure I2C Bus 0 driver instance
if (Status != XFSBL_SUCCESS) {
xil_printf("Error:I2C Init\r\n");
goto END;
}
/* Status = i2c_write(0x77, 0x00, 0x10); // Configure I2C Switch
if (Status != XFSBL_SUCCESS) {
xil_printf("Error: Configure I2C Switch\r\n");
goto END;
}
*/
Status = si5338_init(); // Configure clocks
if (Status != XFSBL_SUCCESS) {
xil_printf("Error: Configure SI5338 CLK\r\n");
goto END;
}
// XFsbl_TeReset();
xil_printf("--------------------------------------------------------------------------------\r\n");
// TE Mod finished
#if defined(XPS_BOARD_ZCU102) || defined(XPS_BOARD_ZCU106) \
|| defined(XPS_BOARD_ZCU104) || defined(XPS_BOARD_ZCU111)
/* Program I2C to configure GT lanes */
Status = XFsbl_BoardConfig();
if (Status != XFSBL_SUCCESS) {
goto END;
}
XFsbl_UsbPhyReset();
#if defined(XPS_BOARD_ZCU102)
XFsbl_PcieReset();
#endif
#else
Status = XFSBL_SUCCESS;
goto END;
#endif
END:
return Status;
}
However, the following error XFSBL_ERROR_PH_CHECKSUM_FAILED occurred during the FSBL boot. I wondered if some program segments were out of scope, so I disabled some code configurations, and the code size has been reduced, but the problem is still there.
Xilinx Zynq MP First Stage Boot Loader (TE modified)
Release 2018.2 Sep 1 2019 - 12:52:05
Reset Mode : System Reset
Platform: Silicon (4.0), Cluster ID 0x80000000
Running on A53-0 (64-bit) Processor, Device Name: XCZU3EG
--------------------------------------------------------------------------------
TE0803 Board Initialisation
SI5338 Init Function
Si5338 Rev 1 Initialization Done
--------------------------------------------------------------------------------
Processor Initialization Done
================= In Stage 2 ============
SD1 Boot Mode
SD: rc= 0
File name is 1:/BOOT.BIN
Multiboot Reg : 0x0
Image Header Table Offset 0x8C0
*****Image Header Table Details********
Boot Gen Ver: 0x1020000
No of Partitions: 0x4
Partition Header Address: 0x440
Partition Present Device: 0x0
Initialization Success
======= In Stage 3, Partition No:1 =======
UnEncrypted data Length: 0xC035B
Data word offset: 0xC035B
Total Data word length: 0xC035B
Destination Load Address: 0xFFFFFFFF
Execution Address: 0x0
Data word offset: 0xF980
Partition Attributes: 0x26
Destination Device is PL, changing LoadAddress
Non authenticated Bitstream download to start now
DMA transfer done
PL Configuration done successfully
Partition 1 Load Success
======= In Stage 3, Partition No:2 =======
UnEncrypted data Length: 0x31F4
Data word offset: 0x31F4
Total Data word length: 0x31F4
Destination Load Address: 0xFFFEA000
Execution Address: 0xFFFEA000
Data word offset: 0xCFCE0
Partition Attributes: 0x117
Partition 2 Load Success
======= In Stage 3, Partition No:3 =======
Error: Checksum 0xEFF6A359 != 0
XFSBL_ERROR_PH_CHECKSUM_FAILED
Partition 3 Load Failed, 0x17
================= In Stage Err ============
Fsbl Error Status: 0x0
Any attempt to access the IIC (I use MIO IIC-0 also) will result in an error. Finally I figured out that it would be reproduce the error to execute this line in si5338_init().
Status = XIicPs_MasterSendPolled(&Iic, &test_addr, 1, IIC_ADDR);
Anybody have good ideas?
Thanks.