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!

cancel
Showing results for 
Search instead for 
Did you mean: 
Contributor
Contributor
298 Views
Registered: ‎10-10-2018

How can I know QSPI address of boot image actually used?

Jump to solution

This is for handling a fallback situation.  I have a MicroZed with Zynq 7000 and using FreeRTOS.  Booting from 16 MByte QSPI flash.  Application working nicely and I can program boot.bin (FSBL, bitstream, application) into arbitrary sectors (observing 32 KByte placements of course). 

I would like every version of my application, once it is running, to check which QSPI flash location BootROM used for successful booting.  If it was not from 0x0, then my system has fallen back to some other version higher up in flash (and the application may want to take certain actions as a result).

What I am having trouble with is how to know the QSPI location where BootROM found and used valid image to launch the software.

I am not really doing multiboot, but can the multiboot register help here?  If not, which register(s) might let me know this after my application (not FSBL) is running?

I have been reading the UG585 and UG821 docs closely but the answer is not clear to me.  I can try experimenting, but hopefully the Community can provide a quicker answer.

Thanks!

 

0 Kudos
1 Solution

Accepted Solutions
Moderator
Moderator
269 Views
Registered: ‎03-19-2014

Re: How can I know QSPI address of boot image actually used?

Jump to solution

The fallback boot address is in the MultiBoot register.  From UG821:

FSBL Fallback Feature
To recover from an error condition, FSBL does a Fallback and enables BootROM to load another bootable image (the golden image that was originally present and in a known good state) if that image is present in the flash memory. FSBL updates a multiboot register and does a soft reset so that BootROM executes and loads the next present, valid image.

From UG585:

FSBL Image Fallback and Multiboot
If the FSBL detects an error or wants to use a different FSBL image, then it writes the boot image
address to the devcfg.MULTIBOOT_ADDR [MULTIBOOT_ADDR] field and performs a software system
reset. This is briefly described in section 6.3.11 MultiBoot. Also refer to UG821, Zynq-7000 SoC
Software Developers Guide for information on how to use both fallback and multiboot.

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post

1 Reply
Moderator
Moderator
270 Views
Registered: ‎03-19-2014

Re: How can I know QSPI address of boot image actually used?

Jump to solution

The fallback boot address is in the MultiBoot register.  From UG821:

FSBL Fallback Feature
To recover from an error condition, FSBL does a Fallback and enables BootROM to load another bootable image (the golden image that was originally present and in a known good state) if that image is present in the flash memory. FSBL updates a multiboot register and does a soft reset so that BootROM executes and loads the next present, valid image.

From UG585:

FSBL Image Fallback and Multiboot
If the FSBL detects an error or wants to use a different FSBL image, then it writes the boot image
address to the devcfg.MULTIBOOT_ADDR [MULTIBOOT_ADDR] field and performs a software system
reset. This is briefly described in section 6.3.11 MultiBoot. Also refer to UG821, Zynq-7000 SoC
Software Developers Guide for information on how to use both fallback and multiboot.

-------------------------------------------------------------------------
Don’t forget to reply, kudo, and accept as solution.
-------------------------------------------------------------------------

View solution in original post