summaryrefslogtreecommitdiff
path: root/common/env_sf.c
diff options
context:
space:
mode:
authorJean-Jacques Hiblot <jjhiblot@ti.com>2017-02-01 13:51:47 (GMT)
committerTom Rini <trini@konsulko.com>2017-02-08 21:24:26 (GMT)
commit2e4e5ad4c8b83ffbe5c5f345d4f4723911bfb645 (patch)
tree7cd4e53c76e74914a032e74da59e2f178c359b13 /common/env_sf.c
parentdb74cbfc090f05bbfe31ea05ca7e04bd8f364c9f (diff)
downloadu-boot-2e4e5ad4c8b83ffbe5c5f345d4f4723911bfb645.tar.xz
common: env_sf: Use CONFIG_SF_DEFAULT_xxx as the default value for CONFIG_ENV_SPI_xxx
The default values for the configuration defines CONFIG_ENV_SPI_xxx are arbitrary values. It makes more sense to set them to the values used by the sf command. Signed-off-by: Jean-Jacques Hiblot <jjhiblot@ti.com> Reviewed-by: Tom Rini <trini@konsulko.com>
Diffstat (limited to 'common/env_sf.c')
-rw-r--r--common/env_sf.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/common/env_sf.c b/common/env_sf.c
index c53200f..27b4d12 100644
--- a/common/env_sf.c
+++ b/common/env_sf.c
@@ -19,16 +19,16 @@
#include <dm/device-internal.h>
#ifndef CONFIG_ENV_SPI_BUS
-# define CONFIG_ENV_SPI_BUS 0
+# define CONFIG_ENV_SPI_BUS CONFIG_SF_DEFAULT_BUS
#endif
#ifndef CONFIG_ENV_SPI_CS
-# define CONFIG_ENV_SPI_CS 0
+# define CONFIG_ENV_SPI_CS CONFIG_SF_DEFAULT_CS
#endif
#ifndef CONFIG_ENV_SPI_MAX_HZ
-# define CONFIG_ENV_SPI_MAX_HZ 1000000
+# define CONFIG_ENV_SPI_MAX_HZ CONFIG_SF_DEFAULT_SPEED
#endif
#ifndef CONFIG_ENV_SPI_MODE
-# define CONFIG_ENV_SPI_MODE SPI_MODE_3
+# define CONFIG_ENV_SPI_MODE CONFIG_SF_DEFAULT_MODE
#endif
#ifdef CONFIG_ENV_OFFSET_REDUND