From: Tom Rini Date: Mon, 14 May 2018 18:13:27 -0400 Subject: [U-Boot] [PATCH] block: Have BLOCK_CACHE default to y in some cases Message-ID: <1526336007-31815-1-git-send-email-trini@konsulko.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de When dealing with filesystems that come from block devices we can get a noticeable performance gain in some use cases from having the block cache enabled. Do so by default for btrfs/ext4/FAT. Signed-off-by: Tom Rini --- In general this grows U-Boot itself by ~2KiB and does grow SPL by ~540 bytes when we have it present. This is only seemingly true when we have CONFIG_SPL_BLK and in turn block devices and filesystems. I'm not opposed to introducing CONFIG_SPL_BLOCK_CACHE down the line if needed, but I don't think we need it to start with. --- drivers/block/Kconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/block/Kconfig b/drivers/block/Kconfig index 15fd1bcb2b7e..a7f4bbfb7bb9 100644 --- a/drivers/block/Kconfig +++ b/drivers/block/Kconfig @@ -29,7 +29,8 @@ config SPL_BLK config BLOCK_CACHE bool "Use block device cache" - default n + depends on BLK + default y if FS_BTRFS || FS_EXT4 || FS_FAT help This option enables a disk-block cache for all block devices. This is most useful when accessing filesystems under U-Boot since -- 2.7.4