Skip to contentSkip to conversation

FPGA: Cyclon II: Correctly reset the FPGA before configuration

PATCH New Stefan Roese 2 participants 2 messages Oct 23, 2012 – Oct 29, 2012 FPGA manager framework

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 FPGA: Cyclon II: Correctly reset the FPGA before configuration

From: Stephan Gatzka <[email protected]>

Deassert the CONFIG pin before asserting it again. This assures that the FPGA will be resetted and therefore configuration will be correctly enabled.

This is also already done on other FPGA's, e.g. Stratix.

---
 drivers/fpga/cyclon2.c | 2 ++
 1 file changed, 2 insertions(+)
drivers/fpga/cyclon2.c +2 -0
index 26494a3..0773e73 100644
@@ -144,6 +144,8 @@ static int CYC2_ps_load(Altera_desc *desc, const void *buf, size_t bsize)
 		}
 
 		/* Establish the initial state */
+		(*fn->config) (FALSE, TRUE, cookie);	/* De-assert nCONFIG */
+		udelay(100);
 		(*fn->config) (TRUE, TRUE, cookie);	/* Assert nCONFIG */
 
 		udelay(2);		/* T_cfg > 2us	*/
Signature · 1 line
1.8.0
#1 lore raw

PATCH 1/1 FPGA: Cyclon II: Correctly reset the FPGA before configuration

Quoted 10 lines · Stefan Roese

From: Stephan Gatzka <[email protected]>

Deassert the CONFIG pin before asserting it again. This assures that the FPGA will be resetted and therefore configuration will be correctly enabled.

This is also already done on other FPGA's, e.g. Stratix.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20121029/349a6066/attachment-0001.pgp>