Page MenuHomeFreeBSD

D32150.diff
No OneTemporary

D32150.diff

diff --git a/sys/ufs/ffs/ffs_snapshot.c b/sys/ufs/ffs/ffs_snapshot.c
--- a/sys/ufs/ffs/ffs_snapshot.c
+++ b/sys/ufs/ffs/ffs_snapshot.c
@@ -63,6 +63,7 @@
#include <vm/vm_extern.h>
#include <geom/geom.h>
+#include <geom/geom_vfs.h>
#include <ufs/ufs/extattr.h>
#include <ufs/ufs/quota.h>
@@ -2554,22 +2555,16 @@
ufs2_daddr_t lbn;
{
struct inode *ip;
- struct bio *bip;
struct fs *fs;
ip = VTOI(vp);
fs = ITOFS(ip);
- bip = g_alloc_bio();
- bip->bio_cmd = BIO_READ;
- bip->bio_offset = dbtob(fsbtodb(fs, blkstofrags(fs, lbn)));
- bip->bio_data = bp->b_data;
- bip->bio_length = bp->b_bcount;
- bip->bio_done = NULL;
-
- g_io_request(bip, ITODEVVP(ip)->v_bufobj.bo_private);
- bp->b_error = biowait(bip, "snaprdb");
- g_destroy_bio(bip);
+ bp->b_iocmd = BIO_READ;
+ bp->b_iooffset = dbtob(fsbtodb(fs, blkstofrags(fs, lbn)));
+ bp->b_iodone = bdone;
+ g_vfs_strategy(&ITODEVVP(ip)->v_bufobj, bp);
+ bufwait(bp);
return (bp->b_error);
}

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 9, 12:46 PM (22 h, 13 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
14560663
Default Alt Text
D32150.diff (960 B)

Event Timeline