]> git.baikalelectronics.ru Git - kernel.git/commit
bcache: avoid unncessary cache prefetch bch_btree_node_get()
authorColy Li <colyli@suse.de>
Thu, 9 Aug 2018 07:48:44 +0000 (15:48 +0800)
committerJens Axboe <axboe@kernel.dk>
Thu, 9 Aug 2018 14:21:05 +0000 (08:21 -0600)
commit35fb1d4efff9aaa060a304ee3a74cfe7f4b9c76d
tree76e7706cf9a9be055724727375fd452930a284ba
parent58f0acf6c7588b35769e2a7ceb97aaaf54be1df4
bcache: avoid unncessary cache prefetch bch_btree_node_get()

In bch_btree_node_get() the read-in btree node will be partially
prefetched into L1 cache for following bset iteration (if there is).
But if the btree node read is failed, the perfetch operations will
waste L1 cache space. This patch checkes whether read operation and
only does cache prefetch when read I/O succeeded.

Signed-off-by: Coly Li <colyli@suse.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/md/bcache/btree.c