From: Kent Overstreet Date: Tue, 24 Sep 2013 06:17:36 +0000 (-0700) Subject: bcache: Fix flushes in writeback mode X-Git-Tag: v3.12-rc3~34^2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c0f04d88e46d14de51f4baebb6efafb7d59e9f96;p=pandora-kernel.git bcache: Fix flushes in writeback mode In writeback mode, when we get a cache flush we need to make sure we issue a flush to the backing device. The code for sending down an extra flush was wrong - by cloning the bio we were probably getting flags that didn't make sense for a bare flush, and also the old code was firing for FUA bios, for which we don't need to send a flush to the backing device. This was causing data corruption somehow - the mechanism was never determined, but this patch fixes it for the users that were seeing it. Signed-off-by: Kent Overstreet Cc: linux-stable # >= v3.10 Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed