mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
block: Relocate bio integrity flags
Move flags affecting the integrity code out of the bio bi_flags and into the block integrity payload. Signed-off-by: Martin K. Petersen <[email protected]> Reviewed-by: Sagi Grimberg <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
This commit is contained in:
parent
3aec2f41a8
commit
b1f0138857
4 changed files with 14 additions and 9 deletions
|
|
@ -100,7 +100,7 @@ void bio_integrity_free(struct bio *bio)
|
|||
struct bio_integrity_payload *bip = bio_integrity(bio);
|
||||
struct bio_set *bs = bio->bi_pool;
|
||||
|
||||
if (bip->bip_owns_buf)
|
||||
if (bip->bip_flags & BIP_BLOCK_INTEGRITY)
|
||||
kfree(page_address(bip->bip_vec->bv_page) +
|
||||
bip->bip_vec->bv_offset);
|
||||
|
||||
|
|
@ -293,7 +293,7 @@ int bio_integrity_prep(struct bio *bio)
|
|||
return -EIO;
|
||||
}
|
||||
|
||||
bip->bip_owns_buf = 1;
|
||||
bip->bip_flags |= BIP_BLOCK_INTEGRITY;
|
||||
bip->bip_iter.bi_size = len;
|
||||
bip_set_seed(bip, bio->bi_iter.bi_sector);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue