Displaying 11 results from an estimated 11 matches for "btrfs_chunk".
2015 Dec 24
4
[PATCH] btrfs: Fix logical to physical block address mapping
...-------------
core/fs/btrfs/btrfs.h | 2 ++
2 files changed, 36 insertions(+), 16 deletions(-)
diff --git a/core/fs/btrfs/btrfs.c b/core/fs/btrfs/btrfs.c
index 53e1105..a06607e 100644
--- a/core/fs/btrfs/btrfs.c
+++ b/core/fs/btrfs/btrfs.c
@@ -81,7 +81,8 @@ static int btrfs_comp_chunk_map(struct btrfs_chunk_map_item *m1,
}
/* insert a new chunk mapping item */
-static void insert_map(struct fs_info *fs, struct btrfs_chunk_map_item *item)
+static void insert_chunk_item(struct fs_info *fs,
+ struct btrfs_chunk_map_item *item)
{
struct btrfs_info * const bfs = fs->fs_info;
struct btrf...
2015 Dec 24
0
[PATCH v2] btrfs: Fix logical to physical block address mapping
...-------------
core/fs/btrfs/btrfs.h | 2 ++
2 files changed, 38 insertions(+), 16 deletions(-)
diff --git a/core/fs/btrfs/btrfs.c b/core/fs/btrfs/btrfs.c
index 53e1105..ca611db 100644
--- a/core/fs/btrfs/btrfs.c
+++ b/core/fs/btrfs/btrfs.c
@@ -81,7 +81,8 @@ static int btrfs_comp_chunk_map(struct btrfs_chunk_map_item *m1,
}
/* insert a new chunk mapping item */
-static void insert_map(struct fs_info *fs, struct btrfs_chunk_map_item *item)
+static void insert_chunk_item(struct fs_info *fs,
+ struct btrfs_chunk_map_item *item)
{
struct btrfs_info * const bfs = fs->fs_info;
struct btrf...
2015 Dec 27
0
[PATCH v3] btrfs: Fix logical to physical block address mapping
...-------------
core/fs/btrfs/btrfs.h | 2 ++
2 files changed, 35 insertions(+), 16 deletions(-)
diff --git a/core/fs/btrfs/btrfs.c b/core/fs/btrfs/btrfs.c
index 53e1105..58e1fe6 100644
--- a/core/fs/btrfs/btrfs.c
+++ b/core/fs/btrfs/btrfs.c
@@ -81,7 +81,8 @@ static int btrfs_comp_chunk_map(struct btrfs_chunk_map_item *m1,
}
/* insert a new chunk mapping item */
-static void insert_map(struct fs_info *fs, struct btrfs_chunk_map_item *item)
+static void insert_chunk_item(struct fs_info *fs,
+ struct btrfs_chunk_map_item *item)
{
struct btrfs_info * const bfs = fs->fs_info;
struct btrf...
2012 Mar 20
13
[PATCH 0 of 3 v2] PV-GRUB: add support for ext4 and btrfs
Hi,
The following patches add support for ext4 and btrfs to
PV-GRUB. These patches are taken nearly verbatim from those provided
by Fedora and Gentoo.
We''ve been using these patches for the PV-GRUB images available in EC2
for some time now with no problems.
Changes from v1:
- Makefile has been changed to check the exit code from patch
- The btrfs patch has been rebased to apply
2015 Dec 27
1
[PATCH v2] btrfs: Fix logical to physical block address mapping
..._type(&search_key,
> - &path.item.key))
> + &path.item.key))
> break;
> +
> chunk = (struct btrfs_chunk *)(path.data);
> - /* insert to mapping table, ignore stripes */
> - item.logical = path.item.key.offset;
> - item.length = chunk->length;
> - item.devid = chunk-&g...
2014 Mar 05
0
[PATCH] Btrfs-progs: remove unused variable and update btrfs-image man page
...array_size;
u32 cur = 0;
- u32 new_cur = 0;
u8 *ptr, *write_ptr;
int old_num_stripes;
@@ -1390,7 +1389,6 @@ static int update_super(u8 *buffer)
write_ptr += sizeof(*disk_key);
ptr += sizeof(*disk_key);
cur += sizeof(*disk_key);
- new_cur += sizeof(*disk_key);
if (key.type == BTRFS_CHUNK_ITEM_KEY) {
chunk = (struct btrfs_chunk *)ptr;
@@ -1406,7 +1404,6 @@ static int update_super(u8 *buffer)
memcpy(chunk->stripe.dev_uuid, super->dev_item.uuid,
BTRFS_UUID_SIZE);
new_array_size += sizeof(*chunk);
- new_cur += sizeof(*chunk);
} else {
fprintf(stder...
2011 Aug 23
40
[PATCH 00/21] [RFC] Btrfs: restriper
Hello,
This patch series adds an initial implementation of restriper (it''s a
clever name for relocation framework that allows to do selective profile
changing and selective balancing with some goodies like pausing/resuming
and reporting progress to the user.
Profile changing is global (per-FS) so far, per-subvolume profiles
require some discussion and can be implemented in future.
2011 Dec 28
13
fstrim on BTRFS
Hi!
With 3.2-rc4 (probably earlier), Ext4 seems to remember what areas it
trimmed:
merkaba:~> fstrim -v /boot
/boot: 224657408 bytes were trimmed
merkaba:~> fstrim -v /boot
/boot: 0 bytes were trimmed
But BTRFS does not:
merkaba:~> fstrim -v /
/: 4431613952 bytes were trimmed
merkaba:~> fstrim -v /
/: 4341846016 bytes were trimmed
Is it planned to add this feature to BTRFS
2012 Jan 11
12
[PATCH 00/11] Btrfs: some patches for 3.3
The biggest one is a fix for fstrim, and there''s a fix for on-disk
free space cache. Others are small fixes and cleanups.
The last three have been sent weeks ago.
The patchset is also available in this repo:
git://repo.or.cz/linux-btrfs-devel.git for-chris
Note there''s a small confict with Al Viro''s vfs changes.
Li Zefan (11):
Btrfs: add pinned extents to
2013 Apr 03
0
[PATCH] Btrfs-progs: add a free space cache checker to fsck
...tree.h b/ctree.h
index 702de2c..67fa650 100644
--- a/ctree.h
+++ b/ctree.h
@@ -28,6 +28,7 @@
struct btrfs_root;
struct btrfs_trans_handle;
+struct btrfs_free_space_ctl;
#define BTRFS_MAGIC 0x4D5F53665248425F /* ascii _BHRfS_M, no null */
#define BTRFS_MAX_LEVEL 8
@@ -268,6 +269,15 @@ struct btrfs_chunk {
/* additional stripes go here */
} __attribute__ ((__packed__));
+#define BTRFS_FREE_SPACE_EXTENT 1
+#define BTRFS_FREE_SPACE_BITMAP 2
+
+struct btrfs_free_space_entry {
+ __le64 offset;
+ __le64 bytes;
+ u8 type;
+} __attribute__ ((__packed__));
+
struct btrfs_free_space_header {
struct...
2009 May 12
0
[PATCH 1/2] btrfs-progs: mixed back ref support
...rfs_mark_buffer_dirty(leaf);
free_extent_buffer(leaf);
diff -urp btrfs-progs-unstable/ctree.h btrfs-progs-2/ctree.h
--- btrfs-progs-unstable/ctree.h 2009-01-08 08:30:09.754081530 +0800
+++ btrfs-progs-2/ctree.h 2009-05-11 17:06:21.000000000 +0800
@@ -250,6 +250,7 @@ static inline unsigned long btrfs_chunk_
#define BTRFS_FSID_SIZE 16
#define BTRFS_HEADER_FLAG_WRITTEN (1 << 0)
+#define BTRFS_HEADER_FLAG_RELOC (1 << 1)
/*
* every tree block (leaf or node) starts with this header.
@@ -387,34 +388,64 @@ struct btrfs_node {
* The slots array records the index of the item or block...