mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
block: manipulate bio->bi_flags through helpers
Some places use helpers now, others don't. We only have the 'is set' helper, add helpers for setting and clearing flags too. It was a bit of a mess of atomic vs non-atomic access. With BIO_UPTODATE gone, we don't have any risk of concurrent access to the flags. So relax the restriction and don't make any of them atomic. The flags that do have serialization issues (reffed and chained), we already handle those separately. Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
4246a0b63b
commit
b7c44ed9d2
11 changed files with 33 additions and 20 deletions
|
|
@ -186,7 +186,7 @@ static int must_snapshot_stable_pages(struct request_queue *q, struct bio *bio)
|
|||
if (!bdi_cap_stable_pages_required(&q->backing_dev_info))
|
||||
return 0;
|
||||
|
||||
return test_bit(BIO_SNAP_STABLE, &bio->bi_flags);
|
||||
return bio_flagged(bio, BIO_SNAP_STABLE);
|
||||
}
|
||||
#else
|
||||
static int must_snapshot_stable_pages(struct request_queue *q, struct bio *bio)
|
||||
|
|
|
|||
Loading…
Reference in a new issue