UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

AR# 56044

SDK - Can I run the FSBL without a DDR connected on the Zynq SoC Processing System?

Description

Is it possible to run the FSBL without a DDR connected on the Zynq SoC Processing System?

Solution

Yes, with some minor modifications to the FSBL source code to disable the DDR initialization, you can execute the FSBL on a DDR-less system. 

The steps to do so are as follows:

For SDK 14.5

  1. In SDK, create the FSBL.
  2. Once the FSBL is created, make the following modifications:
  • Remove all references to the DDR initialization by commenting out lines 11973,12072,12094,12102 and 12110 in ps7_init.c in the FSBL src folder in SDK.

For SDK 14.6/14.7

  1. In SDK, create the FSBL. Once the FSBL is created, make the following modifications:
  2. Add the following lines to line 225 in fsbl.h:
    #define XPAR_PS7_DDR_0_S_AXI_BASEADDR 0x00100000 /*dummy base address */
    #define XPAR_PS7_DDR_0_S_AXI_HIGHADDR 0x3FFFFFFF /*dummy high address */
  3. Comment out the call the ps7_ddr_init_data in the ps7_init.c file in the hw_platform folder:
    //DDR init
    //ret = ps7_config (ps7_ddr_init_data);
    //if (ret != PS7_INIT_SUCCESS) return ret;
  4. Comment out the call to the DDRInitCheck on line 264 of main.c:
    //Status = DDRInitCheck();
  5. Comment out the FsblFallback() on lines 332, and 341 of image_mover.c if loading the application outside of the DDR range.
  6. Once all the changes are made, create a simple Test application in SDK.
  7. Place all the sections of the FSBL in ps7_ram_0_S_AXI_BASEADDR:
  8. Place all the sections of the Application in ps7_ram_1_S_AXI_BASEADDR:
  9. Clean the complete Project.
  10. Next, create the boot Image using Bootgen, and program the QSPI, or the SD card.

    When the QSPI/SD Card is programmed, press the POR_B button on the board, and monitor the serial port.

    As a further check, open XMD and try accessing the DDR using the commands below:

    XMD% connect arm hw
    XMD% stop
    XMD% mrd 0x00100000

    This should error out, as the DDR is not connected.

    Attached to this answer record is a workspace from 14.6, targeting the ZC702 with the changes mentioned above.

    Note: if the QSPI is greater than 16MB and if all of the boot code fits into the lower 16MB, then in qspi.c (located in the fsbl application source directory), the following line can be added in the FlashReadID function in qspi.c.

    At the end of the  "Deduce flash size" code block, before "return XST_SUCCESS" add the following line:

    QspiFlashSize = FLASH_SIZE_128M;

    This is necessary because to run with no DDR, the QSPI must be in linear mode.

For SDK 2014.4:

1. Create your design in Vivado, do NOT uncheck the "Enable DDR" box, the DDR will be removed in SDK.
 
2. In SDK edit the ps7_init.c in the hardware definition folder by removing all references to DDR initialization.

This is done by commenting out lines around 13413:
 
// DDR init
//ret = ps7_config (ps7_ddr_init_data);
//if (ret != PS7_INIT_SUCCESS) return ret;
Also comment lines 13380, 13389, and 13396.

3. In SDK create an FSBL.

4. In main.c comment out line 294:

// Status = DDRInitCheck();

5. In image_mover.c comment out the FsblFallBack() calls in the "load address check" section (line 417 and 425).

6. Place all the sections of the FSBL in ps7_ram_0_S_AXI_BASEADDR:





7. Place all the sections of the Application in ps7_ram_1_S_AXI_BASEADDR:





8. Clean the complete Project.

Next, create the boot Image using Bootgen, and program the QSPI, or the SD card.

When the QSPI/SD Card is programmed, press the POR_B button on the board, and monitor the serial port.

Attachments

Associated Attachments

Name File Size File Type
Workspace.zip 3 MB ZIP
AR# 56044
Date Created 05/16/2013
Last Updated 05/28/2015
Status Active
Type General Article
Devices
  • Zynq-7000
  • XA Zynq-7000
Tools
  • EDK - 14.5