aboutsummaryrefslogtreecommitdiff
path: root/drivers/block
diff options
context:
space:
mode:
authorAdam Ford2018-06-11 17:17:48 -0500
committerTom Rini2018-06-18 14:43:13 -0400
commit6fef62cc47a0ad2a1ef6b58fda18f1e333869003 (patch)
tree65f137aee05eb41d7fab18473a22883ea53ce346 /drivers/block
parenta1b73c18724eb8cb75f7a60d851578d933c78095 (diff)
block: Add SPL_BLOCK_CACHE and default n
When enabling BLOCK_CACHE on devices with limited RAM during SPL, some devices may not boot. This creates an option to enable block caching in SPL by defaults off. It is dependent on SPL_BLK Fixes: 46960ad6d09b ("block: Have BLOCK_CACHE default to y in some cases") Signed-off-by: Adam Ford <aford173@gmail.com>
Diffstat (limited to 'drivers/block')
-rw-r--r--drivers/block/Kconfig7
-rw-r--r--drivers/block/Makefile2
2 files changed, 8 insertions, 1 deletions
diff --git a/drivers/block/Kconfig b/drivers/block/Kconfig
index 0792373cfc4..f9502b36bac 100644
--- a/drivers/block/Kconfig
+++ b/drivers/block/Kconfig
@@ -37,6 +37,13 @@ config BLOCK_CACHE
it will prevent repeated reads from directory structures and other
filesystem data structures.
+config SPL_BLOCK_CACHE
+ bool "Use block device cache in SPL"
+ depends on SPL_BLK
+ default n
+ help
+ This option enables the disk-block cache in SPL
+
config IDE
bool "Support IDE controllers"
select HAVE_BLOCK_DEVICE
diff --git a/drivers/block/Makefile b/drivers/block/Makefile
index 5fcafb193ee..0e80ce94058 100644
--- a/drivers/block/Makefile
+++ b/drivers/block/Makefile
@@ -11,4 +11,4 @@ endif
obj-$(CONFIG_IDE) += ide.o
obj-$(CONFIG_SANDBOX) += sandbox.o
-obj-$(CONFIG_BLOCK_CACHE) += blkcache.o
+obj-$(CONFIG_$(SPL_)BLOCK_CACHE) += blkcache.o