linux/drivers/md/bcache
Kent Overstreet 5794351146 bcache: Refactor btree io
The most significant change is that btree reads are now done
synchronously, instead of asynchronously and doing the post read stuff
from a workqueue.

This was originally done because we can't block on IO under
generic_make_request(). But - we already have a mechanism to punt cache
lookups to workqueue if needed, so if we just use that we don't have to
deal with the complexity of doing things asynchronously.

The main benefit is this makes the locking situation saner; we can hold
our write lock on the btree node until we're finished reading it, and we
don't need that btree_node_read_done() flag anymore.

Also, for writes, btree_write() was broken out into btree_node_write()
and btree_leaf_dirty() - the old code with the boolean argument was dumb
and confusing.

The prio_blocked mechanism was improved a bit too, now the only counter
is in struct btree_write, we don't mess with transfering a count from
struct btree anymore.

This required changing garbage collection to block prios at the start
and unblock when it finishes, which is cleaner than what it was doing
anyways (the old code had mostly the same effect, but was doing it in a
convoluted way)

And the btree iter btree_node_read_done() uses was converted to a real
mempool.

Signed-off-by: Kent Overstreet <koverstreet@google.com>
2013-06-26 17:09:14 -07:00
..
alloc.c bcache: Convert allocator thread to kthread 2013-06-26 17:09:13 -07:00
bcache.h bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
bset.c bcache: Use WARN_ONCE() instead of __WARN() 2013-04-08 13:33:48 -07:00
bset.h
btree.c bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
btree.h bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
closure.c bcache: Fix for the build fixes 2013-03-25 19:36:39 -06:00
closure.h
debug.c bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
debug.h
io.c md: bcache: io.c: fix a potential NULL pointer dereference 2013-06-26 17:06:19 -07:00
journal.c bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
journal.h
Kconfig bcache: drop "select CLOSURES" 2013-05-15 00:42:51 -07:00
Makefile
movinggc.c bcache: Don't export utility code, prefix with bch_ 2013-03-28 12:50:55 -06:00
request.c bcache: Take data offset from the bdev superblock. 2013-04-20 17:56:12 -07:00
request.h
stats.c bcache: Fix error handling in init code 2013-05-15 00:48:14 -07:00
stats.h
super.c bcache: Refactor btree io 2013-06-26 17:09:14 -07:00
sysfs.c bcache: fix a spurious gcc complaint, use scnprintf 2013-06-26 17:06:33 -07:00
sysfs.h bcache: Don't export utility code, prefix with bch_ 2013-03-28 12:50:55 -06:00
trace.c
util.c bcache: Fix a format string overflow 2013-04-08 13:33:49 -07:00
util.h bcache: Don't export utility code, prefix with bch_ 2013-03-28 12:50:55 -06:00
writeback.c bcache: Fix error handling in init code 2013-05-15 00:48:14 -07:00