mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00: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 <axboe@fb.com>
This commit is contained in:
parent
4246a0b63b
commit
b7c44ed9d2
11 changed files with 33 additions and 20 deletions
|
@ -2961,7 +2961,7 @@ static void end_bio_bh_io_sync(struct bio *bio)
|
|||
{
|
||||
struct buffer_head *bh = bio->bi_private;
|
||||
|
||||
if (unlikely (test_bit(BIO_QUIET,&bio->bi_flags)))
|
||||
if (unlikely(bio_flagged(bio, BIO_QUIET)))
|
||||
set_bit(BH_Quiet, &bh->b_state);
|
||||
|
||||
bh->b_end_io(bh, !bio->bi_error);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue