FPGA Intellectual Property
PCI Express*, Networking and Connectivity, Memory Interfaces, DSP IP, and Video IP
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.
5741 Discussions

Arria 10 can't read from flash via Generic Serial Flash Interface

FZOVK
New Contributor I
231 Views

We have an Arria 10 FPGA connected to a Micron MT25QU256 flash. The FPGA is able to obtain its program from the flash and configure correctly on power-up. We are trying to use the Generic Serial Flash Interface IP to perform an in-system upgrade of the contents of the flash. We have found that we can perform write operations successfully through the GSFI, but read operations do not fully work.

We probed the signals in the bus between the FPGA and the flash and found that the "read device ID" operation is resulting in the flash responding with the correct data on the serial bus (signal DQ1), but when we query the GSFI via the "flash command read data" register, we get all zeroes back. The same is true when we read the status register or the flag status register from the flash device.

Is there some setup we need to do in order to get the GSFI to recognize and properly save the serial data returned from the flash? I can provide more information about our setup and the operations we are performing as needed. Thank you.

0 Kudos
1 Solution
FZOVK
New Contributor I
197 Views

Hi John,

1) We are using the GSFI, but gsfa_asmi_access_granted_reg is a register in the Serial Flash Loader.

2) Yes, that is correct, we wanted to start out by seeing the device ID read work correctly before moving on to reading and writing the flash memory.

We have the baud rate divisor set to 0x10 and we have seen the SPI pins behave as expected.

We were able to get everything to work once we removed the Serial Flash Loader from our design, leaving the GSFI directly connected to the SPI interface. I don't think we will need any further assistance; thank you for your help.

Frank

View solution in original post

7 Replies
JohnT_Intel
Employee
223 Views

Hi,


Could you provide me the step that you used to read the data and what is the setting used in the GSFI CSR Register?


FZOVK
New Contributor I
216 Views

Hi John,

Thanks for your quick response. Our process for attempting to read the flash device ID is as follows:

1) Set bit 0 of the "gsfa_asmi_access_granted_reg" register to 0 in order to give the GSFA module access to the flash.

2) Write 0x0000489F to the Flash Command Setting Register (register offset 0x7).

3) Write 0x00000001 to the Flash Command Control Register (register offset 0x8).

4) Read the Flash Command Read Data 0 Register (register offset 0xC).

We are getting all zeroes from that read operation at the end, even though we can see (by probing the flash data output line) that the flash is responding properly with the device ID. Also, in case this is relevant, we have connected the following pins between the Serial Flash Loader and the GSFI: atom_ports_dataout, atom_ports_dataoe, atom_ports_datain, atom_ports_dclk, atom_ports_ncs, atom_ports_oe.

JohnT_Intel
Employee
206 Views

Hi,


1) Set bit 0 of the "gsfa_asmi_access_granted_reg" register to 0 in order to give the GSFA module access to the flash.

May I know if you are refering to GSFI module? I do not observed any gsfa_asmi_access_granted_reg.


2) Write 0x0000489F to the Flash Command Setting Register (register offset 0x7).

From the setting used, you are reading the ID of the flash.


3) Write 0x00000001 to the Flash Command Control Register (register offset 0x8).

4) Read the Flash Command Read Data 0 Register (register offset 0xC).


May I know what is the Baud rate Divisor used? Have you try to measure the SPI pin?


FZOVK
New Contributor I
198 Views

Hi John,

1) We are using the GSFI, but gsfa_asmi_access_granted_reg is a register in the Serial Flash Loader.

2) Yes, that is correct, we wanted to start out by seeing the device ID read work correctly before moving on to reading and writing the flash memory.

We have the baud rate divisor set to 0x10 and we have seen the SPI pins behave as expected.

We were able to get everything to work once we removed the Serial Flash Loader from our design, leaving the GSFI directly connected to the SPI interface. I don't think we will need any further assistance; thank you for your help.

Frank

View solution in original post

JohnT_Intel
Employee
188 Views

Hi,


Could you try to remove the Serial Flash Loader from your design? I am afraid that this is causing the issue.


FZOVK
New Contributor I
179 Views

Yes, we have removed the Serial Flash Loader and everything is working now. Thank you for your help.

Frank

JohnT_Intel
Employee
170 Views

Glad to be able to help you resolved the issue.


Reply