Commit Graph

263 Commits

Author SHA1 Message Date
Chris Mason
9a9bdd6047 Pass down the expected generation number when reading tree blocks 2008-05-12 13:51:24 -04:00
Chris Mason
a62332eeb2 Add a readonly flag open_ctree to force RO opens 2008-05-05 09:45:26 -04:00
Chris Mason
8bfbb6b6f8 Update the Ext3 converter
The main changes in this patch are adding chunk handing and data relocation
ability. In the last step of conversion, the converter relocates data in system
chunk and move chunk tree into system chunk. In the rollback process, the
converter remove chunk tree from system chunk and copy data back.

Regards
YZ
---
2008-04-22 14:06:56 -04:00
Chris Mason
358564890a Add a command to show all of the btrfs filesystems on the box (btrfs-show) 2008-04-22 14:06:31 -04:00
Chris Mason
951fd7371c Add chunk uuids and update multi-device back references
Block headers now store the chunk tree uuid

Chunk items records the device uuid for each stripes

Device extent items record better back refs to the chunk tree

Block groups record better back refs to the chunk tree

The chunk tree format has also changed.  The objectid of BTRFS_CHUNK_ITEM_KEY
used to be the logical offset of the chunk.  Now it is a chunk tree id,
with the logical offset being stored in the offset field of the key.

This allows a single chunk tree to record multiple logical address spaces,
upping the number of bytes indexed by a chunk tree from 2^64 to
2^128.
2008-04-15 15:42:08 -04:00
Chris Mason
d1b04c2112 Write all super blocks during commit 2008-04-10 16:22:00 -04:00
Chris Mason
fd2d0af0bf Retry metadata reads in the face of checksum failures 2008-04-09 16:28:12 -04:00
Chris Mason
1b74adf90b Change btrfs_map_block to return a structure with mappings for all stripes 2008-04-09 16:28:12 -04:00
Chris Mason
a37e1e7204 Recow all roots at the end of mkfs
The mkfs code bootstraps the filesystem on a single device.  Once
the raid block groups are setup, it needs to recow all of the blocks so
that each tree is properly allocated.
2008-04-04 15:42:17 -04:00
Chris Mason
a6de0bd778 Add mirroring support across multiple drives 2008-04-03 16:35:48 -04:00
Alex Chiang
857e9a2a63 btrfs-progs: Fix printf format casting errors
We get lots of warnings of the flavor:

utils.c:441: warning: format '%Lu' expects type 'long long unsigned int' but argument 2 has type 'u64'

And thanks to -Werror, the build fails. Clean up these printfs
by properly casting the arg to the format specified.

Signed-off-by: Alex Chiang <achiang@hp.com>
2008-04-01 10:52:22 -04:00
Chris Mason
ad67cd73b7 Update struct btrfs_header flags, and use it to indicate buffers are written 2008-04-01 10:20:06 -04:00
Chris Mason
0dcfa3b827 Walk all block devices looking for btrfs 2008-03-24 15:05:44 -04:00
Chris Mason
1f3ba6a3f9 Btrfsck updates for multi-device filesystems 2008-03-24 15:04:37 -04:00
Chris Mason
d12d4c7203 Dynamic chunk allocation 2008-03-24 15:03:58 -04:00
Chris Mason
510be29677 Add support for multiple devices per filesystem 2008-03-24 15:03:18 -04:00
Chris Mason
80791984f6 Rename the extent_map code to extent_io
This mirrors the changes in the kernel code.
2008-03-04 11:16:54 -05:00
Yan
d1b729ac2b Add rollback support for the converter
This patch adds rollback support for the converter,  the converter can
roll back a conversion if the image file haven't been modified.  In
addition,  I rearrange some codes in convert.c and add a few comments.
2008-01-08 15:56:32 -05:00
Yan
84b99666be Update find_free_extent for the ext3 conversion tool
This patch adds customized find_free_extent support to btrfs-progs,
the conversion program requires this.
2008-01-04 10:41:19 -05:00
Yan
7777e63b42 Update btrfs-progs to match kernel sources 2008-01-04 10:38:22 -05:00
Chris Mason
c4603e35d7 Verify extent back references in btrfsck 2007-12-14 11:00:30 -05:00
Yan
07a4f1b81d Update btrfs-progs to better match the kernel 2007-12-05 10:41:38 -05:00
Chris Mason
1883251686 Add simple stripe size parameter 2007-11-30 11:30:24 -05:00
Chris Mason
678af9b3a4 Remove the last radix tree (block_group_cache) 2007-10-17 09:58:56 -04:00
Chris Mason
167388ab2b Make the crc32c code match what the kernel modules are currently doing 2007-10-15 16:25:43 -04:00
Chris Mason
28de03cb0a Create a slightly more generic extent-caching structure 2007-10-15 16:25:41 -04:00
Chris Mason
38f79f9077 Switch to byte granular allocations 2007-10-15 16:25:14 -04:00
Chris Mason
08c66b7738 Stop using radix trees to record pending allocations 2007-10-15 16:25:04 -04:00
Chris Mason
f12d799856 Allow large blocks 2007-10-15 16:24:39 -04:00
Josef Bacik
4623a01bdc calculate checksums during IO 2007-06-28 16:20:29 -04:00
Chris Mason
d9f1317c7d add GPLv2 2007-06-12 09:07:11 -04:00
Chris Mason
b53a236c3e remove device tree 2007-06-09 09:22:37 -04:00
Chris Mason
5856b7e124 start of block group code 2007-04-26 16:46:06 -04:00
Chris Mason
d7260c060c faster btrfsck 2007-04-23 15:56:27 -04:00
Chris Mason
2f2264fc2d add owner and type fields to the extents aand block headers 2007-04-20 20:23:29 -04:00
Chris Mason
3eaaf935e5 add some support for multiple devices to progs 2007-04-12 12:14:47 -04:00
Chris Mason
d23ea8706c early support for multiple devices 2007-04-11 13:57:55 -04:00
Chris Mason
1b4ca380ed drop the inode map tree 2007-04-10 12:13:29 -04:00
Chris Mason
43f6ab83bf btrfsctl 2007-04-10 09:27:30 -04:00
Chris Mason
d785b7d058 uuids 2007-04-05 14:29:12 -04:00
Chris Mason
8a2c8123c5 create a root dir in mkfs 2007-03-21 11:13:29 -04:00
Chris Mason
b55672a2a1 Better block record keeping, real mkfs 2007-03-20 20:35:03 -04:00
Chris Mason
ab61081c6c change dir-test to insert inode_items 2007-03-20 15:57:25 -04:00
Chris Mason
099f1ae6e4 Add inode map, and the start of file extent items 2007-03-20 14:38:32 -04:00
Chris Mason
f247156e4f transaction handles everywhere 2007-03-16 16:20:31 -04:00
Chris Mason
7a0a809b4c variable block size support 2007-03-14 14:14:43 -04:00
Chris Mason
d9c9960f8d Change the super to point to a tree of trees to enable persistent snapshots 2007-03-13 16:47:54 -04:00
Chris Mason
aa60202f13 rename funcs and structs to btrfs 2007-03-13 10:46:10 -04:00
Chris Mason
8e17fab249 get/set for struct header fields 2007-03-12 12:01:18 -04:00
Chris Mason
2db1ff3570 fix leak in btrfs_drop_snapshot 2007-03-12 09:03:27 -04:00
Chris Mason
2adfc44778 Fixup last found extent caching 2007-03-07 16:15:30 -05:00
Chris Mason
79b90e3fdf Fixup reference counting on cows 2007-03-06 20:08:01 -05:00
Chris Mason
7da449a2f6 early reference counting 2007-03-02 16:08:05 -05:00
Chris Mason
bd530a2cff period commit during initial fill in the random tester 2007-03-02 10:06:43 -05:00
Chris Mason
11bc1cd2a5 Fix extent code to use merge during delete
Remove implicit commit in del_item and insert_item
Add implicit commit to close()
Add commit op in random-test
2007-03-02 09:47:58 -05:00
Chris Mason
a71a25da69 pretend page cache & commit code 2007-03-01 18:59:40 -05:00
Chris Mason
67a8d4bbac fixup dbfile perms 2007-02-26 10:46:55 -05:00
Chris Mason
74556aa757 Break up ctree.c a little
Extent fixes
2007-02-24 06:24:44 -05:00
Chris Mason
c6c63c3e74 Block sized tree extents and extent deletion 2007-02-23 08:38:36 -05:00
Chris Mason
e0bafb2999 switch to early splits 2007-02-22 11:39:13 -05:00
Chris Mason
72777fbe29 extent fixes 2007-02-21 17:04:57 -05:00
Chris Mason
c12e4863d2 early extent mapping support 2007-02-20 16:40:44 -05:00
Chris Mason
215ad20a9b Add backing store, memory management 2007-02-02 09:18:22 -05:00