From: Marek Vasut <marex@denx.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] arm: socfpga: Question about FPGA/HPS SDRAM Bridge
Date: Tue, 1 Sep 2015 14:03:22 +0200 [thread overview]
Message-ID: <201509011403.22313.marex@denx.de> (raw)
In-Reply-To: <55E590D7.7010103@boschrexroth.de>
On Tuesday, September 01, 2015 at 01:49:43 PM, Jian Luo wrote:
> **
> Hi Marek,
Hi!
> On 01.09.2015 11:03, Marek Vasut wrote:
> > On Tuesday, September 01, 2015 at 10:41:31 AM, Jian Luo wrote:
> >> Hi!
> >
> > Hi,
> >
> >> I've read about an implementation requirement regarding the usage of
> >> FPGA/HPS SDRAM bridge.
> >> (Link and Text attached at the end.)
> >>
> >> The 3. step involves writing the APPLYCFG bit in the STATICCFG register
> >> while the SDRAM interface is completely IDLE.
> >> IMHO, it's only possible in SPL stage where everything runs in SRAM.
> >> FPGA however can not be configured until U-Boot is ready (step 2).
> >> So warm reset should be performed after FPGA configuration.
> >>
> >> My idea is to patch sdram.c to dynamically write FPGAPORTRST and
> >> APPLYCFG based on information in sysmgr_regs->romcodegrp_bootromswstate.
> >>
> >> Is any one working on this?
> >
> > We do this sort of stuff by running code from cache, see
> > socfpga_sdram_apply_static_cfg() in arch/arm/mach-socfpga/misc.c .
>
> Thanks. It's way better than run bootloader twice!
Yeah :)
> > You want to use the "bridge enable" and "bridge disable" commands
> > to enable/disable the bridges between FPGA and HPS in U-Boot.
>
> What about calling socfpga_sdram_apply_static_cfg() direct in
> socfpga_load() in drivers/fpga/socfpga.c to make it generic?
Which code exactly do you refer to ?
> socfpga_load() already did step 1 and 2.
> Is there any side effect when fpga2sdram bridge is not used?
The idea is to keep the FPGA programming code and the code which controls
the bridges separate. The reason for that is that you can have content in
the FPGA which is running completely independent of the HPS software. You
don't always need to enable the bridges.
The FPGA2SDRAM bridge (or, more like fpga2hps bridge) is used for stuff
like framebuffers implemented in the FPGA, so that the FPGA can fetch
data from the SDRAM.
Best regards,
Marek Vasut
next prev parent reply other threads:[~2015-09-01 12:03 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-01 8:41 [U-Boot] arm: socfpga: Question about FPGA/HPS SDRAM Bridge Jian Luo
2015-09-01 9:03 ` Marek Vasut
2015-09-01 11:49 ` Jian Luo
2015-09-01 12:03 ` Marek Vasut [this message]
2015-09-01 12:32 ` Jian Luo
2015-09-02 10:27 ` Marek Vasut
2015-09-02 11:29 ` Jian Luo
2015-09-02 12:49 ` Marek Vasut
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201509011403.22313.marex@denx.de \
--to=marex@denx.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox