Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 77638
b: refs/heads/master
c: 5d84070
h: refs/heads/master
v: v3
  • Loading branch information
Jens Axboe committed Jan 28, 2008
1 parent b75c918 commit d77bbe4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 482eb689169948e9f4966fbae6be4d6bc0bfa818
refs/heads/master: 5d84070ee0a433620c57e85dac7f82faaec5fbb3
8 changes: 4 additions & 4 deletions trunk/fs/bio.c
Original file line number Diff line number Diff line change
Expand Up @@ -248,20 +248,20 @@ inline int bio_hw_segments(struct request_queue *q, struct bio *bio)
*/
void __bio_clone(struct bio *bio, struct bio *bio_src)
{
struct request_queue *q = bdev_get_queue(bio_src->bi_bdev);

memcpy(bio->bi_io_vec, bio_src->bi_io_vec,
bio_src->bi_max_vecs * sizeof(struct bio_vec));

/*
* most users will be overriding ->bi_bdev with a new target,
* so we don't set nor calculate new physical/hw segment counts here
*/
bio->bi_sector = bio_src->bi_sector;
bio->bi_bdev = bio_src->bi_bdev;
bio->bi_flags |= 1 << BIO_CLONED;
bio->bi_rw = bio_src->bi_rw;
bio->bi_vcnt = bio_src->bi_vcnt;
bio->bi_size = bio_src->bi_size;
bio->bi_idx = bio_src->bi_idx;
bio_phys_segments(q, bio);
bio_hw_segments(q, bio);
}

/**
Expand Down

0 comments on commit d77bbe4

Please sign in to comment.