Mikulas Patocka a5d60783df dm log writes: move IO accounting earlier to fix error path
Move log_one_block()'s atomic_inc(&lc->io_blocks) before bio_alloc() to
fix a bug that the target hangs if bio_alloc() fails.  The error path
does put_io_block(lc), so atomic_inc(&lc->io_blocks) must occur before
invoking the error path to avoid underflow of lc->io_blocks.

Signed-off-by: Mikulas Patocka <mpatocka@redhat.com>
Reviewed-by: Josef Bacik <jbacik@fb,com>
Signed-off-by: Mike Snitzer <snitzer@redhat.com>
Cc: stable@vger.kernel.org
2016-08-30 16:16:49 -04:00
..
2016-07-27 14:03:52 -07:00
2016-08-01 18:36:01 -04:00
2016-08-05 09:48:22 -04:00
2016-07-30 21:01:36 -07:00
2016-08-09 18:25:11 +08:00
2016-08-26 17:39:35 -07:00
2016-07-28 15:45:17 -07:00
2016-07-30 21:01:36 -07:00
2016-07-30 21:01:36 -07:00
2016-08-04 09:59:37 -04:00
2016-08-02 17:05:11 -04:00
2016-08-01 18:36:01 -04:00
2016-08-12 12:09:44 -07:00
2016-07-20 23:39:36 -07:00
2016-08-26 18:26:07 -07:00
2016-07-31 21:36:58 -04:00
2016-08-06 00:01:33 -04:00
2016-08-06 00:01:33 -04:00
2016-08-05 09:48:22 -04:00
2016-08-01 18:36:01 -04:00
2016-08-01 18:37:45 -04:00
2016-08-02 19:35:40 -04:00
2016-08-06 09:20:13 -04:00