diff options
author | Vikas Manocha <vikas.manocha@st.com> | 2015-07-02 18:29:44 -0700 |
---|---|---|
committer | Jagan Teki <jteki@openedev.com> | 2015-07-03 13:50:53 +0530 |
commit | 90a2f7171182f3b96c28b2dcff67b02a3164cdb1 (patch) | |
tree | dfd0eb215dab5e1c4ea8c8d1a7eeb0d977013c84 /drivers/spi/cadence_qspi.c | |
parent | c0535c0ef0b7e7a3e4c1011266bf26baf94fd4a3 (diff) | |
download | u-boot-imx-90a2f7171182f3b96c28b2dcff67b02a3164cdb1.zip u-boot-imx-90a2f7171182f3b96c28b2dcff67b02a3164cdb1.tar.gz u-boot-imx-90a2f7171182f3b96c28b2dcff67b02a3164cdb1.tar.bz2 |
spi: cadence_qspi: get sram size from device tree
sram size could be different on different socs, e.g. on stv0991 it is 256 while
on altera platform it is 128. It is better to receive it from device tree.
Signed-off-by: Vikas Manocha <vikas.manocha@st.com>
Tested-by: Stefan Roese <sr@denx.de>
Reviewed-by: Jagannadh Teki <jteki@openedev.com>
Diffstat (limited to 'drivers/spi/cadence_qspi.c')
-rw-r--r-- | drivers/spi/cadence_qspi.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/spi/cadence_qspi.c b/drivers/spi/cadence_qspi.c index a75fc46..34a0f46 100644 --- a/drivers/spi/cadence_qspi.c +++ b/drivers/spi/cadence_qspi.c @@ -309,6 +309,7 @@ static int cadence_spi_ofdata_to_platdata(struct udevice *bus) plat->tsd2d_ns = fdtdec_get_int(blob, subnode, "tsd2d-ns", 255); plat->tchsh_ns = fdtdec_get_int(blob, subnode, "tchsh-ns", 20); plat->tslch_ns = fdtdec_get_int(blob, subnode, "tslch-ns", 20); + plat->sram_size = fdtdec_get_int(blob, node, "sram-size", 128); debug("%s: regbase=%p ahbbase=%p max-frequency=%d page-size=%d\n", __func__, plat->regbase, plat->ahbbase, plat->max_hz, |