All of lore.kernel.org
 help / color / mirror / Atom feed
From: Otavio Salvador <otavio@ossystems.com.br>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v6 2/6] cgtqmx6eval: Use SPI NOR to store the environment
Date: Thu, 19 Nov 2015 19:02:34 -0200	[thread overview]
Message-ID: <1447966958-5161-2-git-send-email-otavio@ossystems.com.br> (raw)
In-Reply-To: <1447966958-5161-1-git-send-email-otavio@ossystems.com.br>

Congatec boards boot from SPI NOR, so it makes more sense to use
SPI NOR to store the environment variables.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---

Changes in v6: None
Changes in v5: None
Changes in v4: None

 include/configs/cgtqmx6eval.h | 18 ++++++++++++++----
 1 file changed, 14 insertions(+), 4 deletions(-)

diff --git a/include/configs/cgtqmx6eval.h b/include/configs/cgtqmx6eval.h
index 9aa66c7..79183c4 100644
--- a/include/configs/cgtqmx6eval.h
+++ b/include/configs/cgtqmx6eval.h
@@ -245,11 +245,21 @@
 	(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
 
 /* Environment organization */
-#define CONFIG_ENV_SIZE			(8 * 1024)
-
-#define CONFIG_ENV_IS_IN_MMC
-
+#if defined (CONFIG_ENV_IS_IN_MMC)
 #define CONFIG_ENV_OFFSET		(6 * 64 * 1024)
 #define CONFIG_SYS_MMC_ENV_DEV		0
+#endif
+
+#define CONFIG_ENV_SIZE			(8 * 1024)
+
+#define CONFIG_ENV_IS_IN_SPI_FLASH
+#if defined(CONFIG_ENV_IS_IN_SPI_FLASH)
+#define CONFIG_ENV_OFFSET		(768 * 1024)
+#define CONFIG_ENV_SECT_SIZE		(64 * 1024)
+#define CONFIG_ENV_SPI_BUS		CONFIG_SF_DEFAULT_BUS
+#define CONFIG_ENV_SPI_CS		CONFIG_SF_DEFAULT_CS
+#define CONFIG_ENV_SPI_MODE		CONFIG_SF_DEFAULT_MODE
+#define CONFIG_ENV_SPI_MAX_HZ		CONFIG_SF_DEFAULT_SPEED
+#endif
 
 #endif			       /* __CONFIG_CGTQMX6EVAL_H */
-- 
2.6.2

  reply	other threads:[~2015-11-19 21:02 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-19 21:02 [U-Boot] [PATCH v6 1/6] cgtqmx6eval: Add SPI NOR flash support Otavio Salvador
2015-11-19 21:02 ` Otavio Salvador [this message]
2015-11-19 21:09   ` [U-Boot] [PATCH v6 2/6] cgtqmx6eval: Use SPI NOR to store the environment Fabio Estevam
2015-12-04  8:44     ` Jagan Teki
2015-11-19 21:02 ` [U-Boot] [PATCH v6 3/6] cgtqmx6eval: Add fastboot support Otavio Salvador
2015-11-19 21:09   ` Fabio Estevam
2015-11-19 21:02 ` [U-Boot] [PATCH v6 4/6] cgtqmx6eval: Add SPL support Otavio Salvador
2015-11-19 21:10   ` Fabio Estevam
2015-11-25  8:43   ` Stefano Babic
2015-11-19 21:02 ` [U-Boot] [PATCH v6 5/6] iomux-v3: Take MX6D in consideration for imx_iomux_v3_setup_pad() Otavio Salvador
2015-11-19 21:10   ` Fabio Estevam
2015-11-19 21:02 ` [U-Boot] [PATCH v6 6/6] cgtqmx6eval: Add DFU support Otavio Salvador
2015-11-19 21:11   ` Fabio Estevam
2015-11-19 21:08 ` [U-Boot] [PATCH v6 1/6] cgtqmx6eval: Add SPI NOR flash support Fabio Estevam
2015-12-04  8:44   ` Jagan Teki
2015-12-04 11:22     ` Fabio Estevam
2015-12-04 11:25       ` Jagan Teki
2015-12-04 11:56         ` Stefano Babic
2015-12-04 12:00           ` Jagan Teki

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=1447966958-5161-2-git-send-email-otavio@ossystems.com.br \
    --to=otavio@ossystems.com.br \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.