Re: send/receive and bedup

2014-05-20 Thread Mark Fasheh
data sets is the type of work I want to be doing on it in the future. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: send/receive and bedup

2014-05-19 Thread Mark Fasheh
finding code as it got messy and could be a bit faster. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: send/receive and bedup

2014-05-19 Thread Mark Fasheh
how much time I've had :) 2) can it be included in btrfs-progs so that it becomes a standard feature of btrfs? I have to think about this one personally as it implies some tradeoffs in my development on duperemove that I'm not sure I want to make yet. --Mark -- Mark Fasheh

Re: send/receive and bedup

2014-05-19 Thread Mark Fasheh
disagree that it might not be as good an idea as it sounds. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH 1/3] btrfs-progs: print qgroup excl as unsigned

2014-05-07 Thread Mark Fasheh
It's unsigned in the structure definition. Reviewed-by: Mark Fasheh mfas...@suse.de --- print-tree.c | 12 ++-- qgroup.c | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/print-tree.c b/print-tree.c index 7263b09..adef94a 100644 --- a/print-tree.c +++ b/print

[PATCH 0/3] btrfs-progs: add quota group verify to btrfsck

2014-05-07 Thread Mark Fasheh
Hi, The following 3 patches add support to btrfsck to check the counts in subvolume quota groups. With these patches a user can run btrfsck against a volume and if quota is enabled, qgroup data will be checked against the actual space used on disk. I also added a --qgroup-report option

[PATCH 2/3] btrfs-progs: import ulist

2014-05-07 Thread Mark Fasheh
qgroup-verify.c wants this for walking root refs. Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile | 3 +- kerncompat.h | 2 +- ulist.c | 253 +++ ulist.h | 66 4 files changed, 322 insertions

[PATCH 3/3] btrfs-progs: add quota group verify code

2014-05-07 Thread Mark Fasheh
yet. Adding the code to verify compressed counts shouldn't be hard at all though once kernel can do this. - It is only concerned with subvolume quota groups (like most of btrfs-progs). Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile|2 +- cmds-check.c| 24

Re: [PATCH 1/4] Btrfs: send, bump stream version

2014-04-15 Thread Mark Fasheh
snapshotting tools that are using send/recieve and it would be bad to change the ABI in incompatible ways underneath them. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info

Re: [PATCH 1/4] Btrfs: send, bump stream version

2014-04-15 Thread Mark Fasheh
or not (this is easiest) I would generally avoid breaking compatibility inside of btrfs-progs too so just forcing the new flag seems the most 'breaking' option. Thanks, --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord

Re: Build failures due to commit 416161db (btrfs: offline dedupe)

2013-09-18 Thread Mark Fasheh
On Wed, Sep 18, 2013 at 11:40:07AM -0700, Guenter Roeck wrote: On Tue, Sep 17, 2013 at 03:43:54PM -0700, Mark Fasheh wrote: On Fri, Sep 13, 2013 at 03:33:34PM -0400, Chris Mason wrote: Mark, could you please send a patch for the whole-struct option until the unaligned put is upstreamed

Re: Build failures due to commit 416161db (btrfs: offline dedupe)

2013-09-13 Thread Mark Fasheh
of the patch were putting the whole struct but during review I was asked to change it. This should be very straight forward to fix so long as we all stay calm ;) --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord

Re: [PATCH][RESEND] vfs: allow /proc/PID/maps to get device from stat

2013-09-10 Thread Mark Fasheh
that is described above? Sincerely, someone who would like to fix this ABI breakage that has been going on for years. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: [PROGS PATCH] Import btrfs-extent-same

2013-09-03 Thread Mark Fasheh
-user perspective. For example, I had to include a note in the files subcommand that it does not require online dedupe to be turned on. Again I think most new end users are going to look at this and be confused. --Mark -- Mark Fasheh From 8285eacdffa9fad783efca0ce0b7979f607e9e24 Mon Sep 17

Re: [PROGS PATCH] Import btrfs-extent-same

2013-08-13 Thread Mark Fasheh
... Sound reasonable? --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH][RESEND] vfs: allow /proc/PID/maps to get device from stat

2013-08-07 Thread Mark Fasheh
-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/super.c| 1 + fs/proc/generic.c | 15 +++ fs/proc/internal.h | 1 + fs/proc/nommu.c | 2 +- fs/proc/task_mmu.c | 2 +- fs/proc/task_nommu.c| 2 +- include/uapi/linux/fs.h | 1 + 7 files changed, 21

[PATCH 2/4] btrfs_ioctl_clone: Move clone code into it's own function

2013-08-06 Thread Mark Fasheh
There's some 250+ lines here that are easily encapsulated into their own function. I don't change how anything works here, just create and document the new btrfs_clone() function from btrfs_ioctl_clone() code. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 232

[PATCH 0/4] btrfs: out-of-band (aka offline) dedupe v4

2013-08-06 Thread Mark Fasheh
Hi, The following series of patches implements in btrfs an ioctl to do out-of-band deduplication of file extents. To be clear, this means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software initiates a

[PATCH 1/4] btrfs: abtract out range locking in clone ioctl()

2013-08-06 Thread Mark Fasheh
The range locking in btrfs_ioctl_clone is trivially broken out into it's own function. This reduces the complexity of btrfs_ioctl_clone() by a small bit and makes that locking code available to future functions in fs/btrfs/ioctl.c Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c

[PATCH 3/4] btrfs: Introduce extent_read_full_page_nolock()

2013-08-06 Thread Mark Fasheh
for extent_read_full_page() to indicate that we are already locked. Partial credit for this patch goes to Gabriel de Perthuis g2p.c...@gmail.com as I have included a fix from him to the original patch which avoids a deadlock on compressed extents. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs

[PATCH 4/4] btrfs: offline dedupe

2013-08-06 Thread Mark Fasheh
along with a length argument. The ioctl will then (for each dedupe) do a byte-by-byte comparison of the user data before deduping the extent. Status and number of bytes deduped are returned for each operation. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 278

Re: [PATCH] Btrfs-progs: add dedup subcommand

2013-08-01 Thread Mark Fasheh
of a subcommand of the btrfs binary. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[PATCH 2/4] btrfs_ioctl_clone: Move clone code into it's own function

2013-07-26 Thread Mark Fasheh
There's some 250+ lines here that are easily encapsulated into their own function. I don't change how anything works here, just create and document the new btrfs_clone() function from btrfs_ioctl_clone() code. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 232

[PATCH 1/4] btrfs: abtract out range locking in clone ioctl()

2013-07-26 Thread Mark Fasheh
The range locking in btrfs_ioctl_clone is trivially broken out into it's own function. This reduces the complexity of btrfs_ioctl_clone() by a small bit and makes that locking code available to future functions in fs/btrfs/ioctl.c Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c

[PATCH 0/4] btrfs: offline dedupe v3

2013-07-26 Thread Mark Fasheh
Hi, The following series of patches implements in btrfs an ioctl to do offline deduplication of file extents. To be clear, offline in this sense means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software

[PATCH 4/4] btrfs: offline dedupe

2013-07-26 Thread Mark Fasheh
along with a length argument. The ioctl will then (for each dedupe) do a byte-by-byte comparison of the user data before deduping the extent. Status and number of bytes deduped are returned for each operation. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 283

[PATCH 3/4] btrfs: Introduce extent_read_full_page_nolock()

2013-07-26 Thread Mark Fasheh
for extent_read_full_page() to indicate that we are already locked. Partial credit for this patch goes to Gabriel de Perthuis g2p.c...@gmail.com as I have included a fix from him to the original patch which avoids a deadlock on compressed extents. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs

[PATCH] vfs: allow /proc/PID/maps to get device from stat

2013-07-22 Thread Mark Fasheh
: http://thr3ads.net/btrfs-devel/2011/05/2346176-RFC-PATCH-0-2-btrfs-vfs-Return-same-device-in-stat-2-and-proc-pid-maps Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/super.c| 1 + fs/proc/generic.c | 15 +++ fs/proc/internal.h | 1 + fs/proc/nommu.c

Re: btrfs: stat(2) and /proc/pid/maps returns different devices

2013-07-19 Thread Mark Fasheh
On Thu, Jul 11, 2013 at 12:26:50AM +0200, David Sterba wrote: On Wed, Jul 10, 2013 at 10:45:45AM -0700, Mark Fasheh wrote: Well, what do I get when I pretend I don't care any more? The little voice in my head says keep plugging away. Here's another attempt at fixing this problem in a sane

Re: btrfs: stat(2) and /proc/pid/maps returns different devices

2013-07-10 Thread Mark Fasheh
://bugzilla.openvz.org/show_bug.cgi?id=2653 And about 2 years ago Mark Fasheh tried to fix this problem: http://thr3ads.net/btrfs-devel/2011/05/2346176-RFC-PATCH-0-2-btrfs-vfs-Return-same-device-in-stat-2-and-proc-pid-maps And basically nobody cared :/ Eric Biederman sugested to not create a new

Re: btrfs: stat(2) and /proc/pid/maps returns different devices

2013-07-10 Thread Mark Fasheh
On Wed, Jul 10, 2013 at 09:31:05AM -0700, Mark Fasheh wrote: As far as I can tell we'll be carrying this patch until a better solution is possible. When that will happen, I don't know. --Mark Well, what do I get when I pretend I don't care any more? The little voice in my head says

Re: [PATCH 0/4] btrfs: offline dedupe v2

2013-06-17 Thread Mark Fasheh
On Wed, Jun 12, 2013 at 02:10:37PM -0400, Josef Bacik wrote: On Tue, Jun 11, 2013 at 02:31:34PM -0600, Mark Fasheh wrote: Hi, The following series of patches implements in btrfs an ioctl to do offline deduplication of file extents. Ok I'm relatively happy with this set, I just want

[PATCH 2/4] btrfs_ioctl_clone: Move clone code into it's own function

2013-06-11 Thread Mark Fasheh
There's some 250+ lines here that are easily encapsulated into their own function. I don't change how anything works here, just create and document the new btrfs_clone() function from btrfs_ioctl_clone() code. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 232

[PATCH 4/4] btrfs: offline dedupe

2013-06-11 Thread Mark Fasheh
along with a length argument. The ioctl will then (for each dedupe) do a byte-by-byte comparison of the user data before deduping the extent. Status and number of bytes deduped are returned for each operation. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 329

[PATCH 1/4] btrfs: abtract out range locking in clone ioctl()

2013-06-11 Thread Mark Fasheh
The range locking in btrfs_ioctl_clone is trivially broken out into it's own function. This reduces the complexity of btrfs_ioctl_clone() by a small bit and makes that locking code available to future functions in fs/btrfs/ioctl.c Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c

[PATCH 0/4] btrfs: offline dedupe v2

2013-06-11 Thread Mark Fasheh
Hi, The following series of patches implements in btrfs an ioctl to do offline deduplication of file extents. To be clear, offline in this sense means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software

[PATCH 3/4] btrfs: Introduce extent_read_full_page_nolock()

2013-06-11 Thread Mark Fasheh
for extent_read_full_page() to indicate that we are already locked. Partial credit for this patch goes to Gabriel de Perthuis g2p.c...@gmail.com as I have included a fix from him to the original patch which avoids a deadlock on compressed extents. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs

Re: [PATCH 0/4] btrfs: offline dedupe v2

2013-06-11 Thread Mark Fasheh
? Thanks for the quick reply :) --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 0/4] btrfs: offline dedupe v2

2013-06-11 Thread Mark Fasheh
On Tue, Jun 11, 2013 at 11:31:41PM +0200, Gabriel de Perthuis wrote: Le 11/06/2013 23:04, Mark Fasheh a écrit : On Tue, Jun 11, 2013 at 10:56:59PM +0200, Gabriel de Perthuis wrote: What I found however is that neither of these is a great idea ;) - We want to require that the inode be open

Re: [PATCH 4/4] btrfs: offline dedupe

2013-05-24 Thread Mark Fasheh
Hey David, thanks again for the review! Comments are inline below. On Fri, May 24, 2013 at 04:05:36PM +0200, David Sterba wrote: On Tue, May 21, 2013 at 11:28:28AM -0700, Mark Fasheh wrote: +static noinline int fill_data(struct inode *inode, u64 off, u64 len, + char

Re: [PATCH 4/4] btrfs: offline dedupe

2013-05-24 Thread Mark Fasheh
for read, they can check their contents and dedupe them. Letting users dedupe files in say, /etc seems kind of weird to me but I'm struggling to come up with a good explanation of why that should mean we limit this ioctl to root. --Mark -- Mark Fasheh -- To unsubscribe from this list: send

[PATCH 0/4] btrfs: offline dedupe v1

2013-05-21 Thread Mark Fasheh
Hi, The following series of patches implements in btrfs an ioctl to do offline deduplication of file extents. To be clear, offline in this sense means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software

[PATCH 1/4] btrfs: abtract out range locking in clone ioctl()

2013-05-21 Thread Mark Fasheh
The range locking in btrfs_ioctl_clone is trivially broken out into it's own function. This reduces the complexity of btrfs_ioctl_clone() by a small bit and makes that locking code available to future functions in fs/btrfs/ioctl.c Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c

[PATCH 2/4] btrfs_ioctl_clone: Move clone code into it's own function

2013-05-21 Thread Mark Fasheh
There's some 250+ lines here that are easily encapsulated into their own function. I don't change how anything works here, just create and document the new btrfs_clone() function from btrfs_ioctl_clone() code. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 232

[PATCH 3/4] btrfs: Introduce extent_read_full_page_nolock()

2013-05-21 Thread Mark Fasheh
for extent_read_full_page() to indicate that we are already locked. Partial credit for this patch goes to Gabriel de Perthuis g2p.c...@gmail.com as I have included a fix from him to the original patch which avoids a deadlock on compressed extents. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs

[PATCH 4/4] btrfs: offline dedupe

2013-05-21 Thread Mark Fasheh
along with a length argument. The ioctl will then (for each dedupe) do a byte-by-byte comparison of the user data before deduping the extent. Status and number of bytes deduped are returned for each operation. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 290

Re: [PATCH 0/4] [RFC] btrfs: offline dedupe

2013-04-21 Thread Mark Fasheh
objections I'll add you as CC to this series when I send new versions to the list from now on. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org

[PATCH 0/4] [RFC] btrfs: offline dedupe

2013-04-16 Thread Mark Fasheh
Hi, The following series of patches implements in btrfs an ioctl to do offline deduplication of file extents. To be clear, offline in this sense means that the file system is mounted and running, but the dedupe is not done during file writes, but after the fact when some userspace software

[PATCH 1/4] btrfs: abtract out range locking in clone ioctl()

2013-04-16 Thread Mark Fasheh
The range locking in btrfs_ioctl_clone is trivially broken out into it's own function. This reduces the complexity of btrfs_ioctl_clone() by a small bit and makes that locking code available to future functions in fs/btrfs/ioctl.c Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c

[PATCH 2/4] btrfs_ioctl_clone: Move clone code into it's own function

2013-04-16 Thread Mark Fasheh
There's some 250+ lines here that are easily encapsulated into their own function. I don't change how anything works here, just create and document the new btrfs_clone() function from btrfs_ioctl_clone() code. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 232

[PATCH 3/4] btrfs: Introduce extent_read_full_page_nolock()

2013-04-16 Thread Mark Fasheh
for extent_read_full_page() to indicate that we are already locked. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/extent_io.c | 44 fs/btrfs/extent_io.h |2 ++ 2 files changed, 34 insertions(+), 12 deletions(-) diff --git a/fs/btrfs/extent_io.c b/fs

[PATCH 4/4] btrfs: offline dedupe

2013-04-16 Thread Mark Fasheh
along with a length argument. The ioctl will then (for each dedupe) do a byte-by-byte comparison of the user data before deduping the extent. Status and number of bytes deduped are returned for each operation. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/ioctl.c | 272

Re: [PATCH 0/4] [RFC] btrfs: offline dedupe

2013-04-16 Thread Mark Fasheh
a look. My patches don't actually add any custom code for the actual let's de-dupe this extent as I re-use the code from btrfs_ioctl_clone(). --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org

Re: [PATCH 2/2] Btrfs: introduce noextiref mount option

2013-04-15 Thread Mark Fasheh
that would fit in a standard btrfs hard link). Tunefs can already turn the flag on, I don't see why we don't add the reverse functionality. Also making it optional on mkfs time is easy enough... --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs

btrfs-progs: Fix pointer math in __ino_to_path_fd

2013-02-14 Thread Mark Fasheh
We are casting an array of u64 values into a char ** array so when we dereference this array (as a char **) on a 32 bit system we're then re-casting that back to a 32 bit value. This causes problems when we try to print those strings. Signed-off-by: Mark Fasheh mfas...@suse.de --- cmds-inspect.c

Re: Integration branch of btrfs-progs 2013-02

2013-02-13 Thread Mark Fasheh
is required. We could even add that now (if you have an idea of what would change) despite your patch not being upstream. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info

[PATCH 17/21] btrfs-progs: libify some parts of btrfs-progs

2013-02-12 Thread Mark Fasheh
just send-stream.c and send-utils.c we have to pull in some other parts of the progs package. This patch adds code to the Makefile and headers to create a library, libbtrfs which the btrfs command now links to. Signed-off-by: Mark Fasheh mfas...@suse.de Signed-off-by: David Sterba dste...@suse.cz

Re: [RESEND][PATCH] btrfs: add no file data flag to btrfs send ioctl

2013-02-04 Thread Mark Fasheh
On Mon, Feb 04, 2013 at 04:48:56PM +0100, David Sterba wrote: On Wed, Jan 30, 2013 at 02:43:41PM -0800, Mark Fasheh wrote: @@ -4570,6 +4605,11 @@ long btrfs_ioctl_send(struct file *mnt_file, void __user *arg_) INIT_RADIX_TREE(sctx-name_cache, GFP_NOFS); INIT_LIST_HEAD(sctx

[PATCH 0/5] btrfs-progs: better support for external users of send, V3

2013-01-30 Thread Mark Fasheh
to libuuid and libm (Reported by Arvin) - library symlinks are now properly installed (Reported by Arvin) From: Mark Fasheh mfas...@suse.de btrfs: add no file data flag to btrfs send ioctl This patch adds the flag, BTRFS_SEND_FLAG_NO_FILE_DATA to the btrfs send ioctl code. When this flag is set

[PATCH 1/5] btrfs-progs: Add support for BTRFS_SEND_FLAG_NO_FILE_DATA

2013-01-30 Thread Mark Fasheh
definition to cmds-receive.c as that code never uses BTRFS_SEND_FLAG_NO_FILE_DATA. Signed-off-by: Mark Fasheh mfas...@suse.de --- ioctl.h |7 +++ send-stream.c |6 ++ send-stream.h |1 + send.h|1 + 4 files changed, 15 insertions(+) diff --git a/ioctl.h b/ioctl.h

[PATCH 2/5] btrfs-progs: libify some parts of btrfs-progs

2013-01-30 Thread Mark Fasheh
just send-stream.c and send-utils.c we have to pull in some other parts of the progs package. This patch adds code to the Makefile and headers to create a library, libbtrfs which the btrfs command now links to. Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile | 83

[PATCH 3/5] btrfs-progs: add send-test

2013-01-30 Thread Mark Fasheh
send-test.c links against libbtrfs and uses the send functionality provided to decode and print a send stream to the console. Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile|5 +- send-test.c | 458 +++ 2 files changed, 462

[PATCH 4/5] btrfs-progs: make libbtrfs usable from C++

2013-01-30 Thread Mark Fasheh
From: Arvin Schnell aschn...@suse.de Please find attached a patch to make the new libbtrfs usable from C++ (at least for the parts snapper will likely need). Signed-off-by: Arvin Schnell aschn...@suse.de Signed-off-by: Mark Fasheh mfas...@suse.de --- extent_io.c |6 +++--- extent_io.h

[PATCH 5/5] btrfs-progs: use autotools for building

2013-01-30 Thread Mark Fasheh
From: Jeff Mahoney je...@suse.com Since we're building shared libraries now, let's not reinvent the wheel. This also makes packaging libbtrfs much easier. The following (empty) files are added to satisfy autoconf: AUTHORS ChangeLog NEWS INSTALL. Changes by Mark Fasheh: - Fixes to make this patch

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-16 Thread Mark Fasheh
On Tue, Jan 15, 2013 at 04:06:42PM +0800, Anand Jain wrote: better if its there (man libbtrfs). pls create if you could. Hmm, I'm confused though - what exactly goes into a file system library man page? Could you point me to an example one? --Mark -- Mark Fasheh -- To unsubscribe from

[PATCH 1/4] btrfs-progs: Add support for BTRFS_SEND_FLAG_NO_FILE_DATA

2013-01-16 Thread Mark Fasheh
definition to cmds-receive.c as that code never uses BTRFS_SEND_FLAG_NO_FILE_DATA. Signed-off-by: Mark Fasheh mfas...@suse.de --- ioctl.h |7 +++ send-stream.c |6 ++ send-stream.h |1 + send.h|1 + 4 files changed, 15 insertions(+) diff --git a/ioctl.h b/ioctl.h

[PATCH 2/4] btrfs-progs: libify some parts of btrfs-progs

2013-01-16 Thread Mark Fasheh
just send-stream.c and send-utils.c we have to pull in some other parts of the progs package. This patch adds code to the Makefile and headers to create a library, libbtrfs which the btrfs command now links to. Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile | 85

[PATCH 4/4] btrfs-progs: make libbtrfs usable from C++

2013-01-16 Thread Mark Fasheh
From: Arvin Schnell aschn...@suse.de Please find attached a patch to make the new libbtrfs usable from C++ (at least for the parts snapper will likely need). Signed-off-by: Arvin Schnell aschn...@suse.de Signed-off-by: Mark Fasheh mfas...@suse.de --- extent_io.c |6 +++--- extent_io.h

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-14 Thread Mark Fasheh
have to look at other libfs manpages first to get an idea of what goes in there. At any rate, thanks :) --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-14 Thread Mark Fasheh
set. Can I put: Signed-off-by: Arvin Schnell aschn...@suse.de at the bottom of the patch to indicate that started with you? Thanks, --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-14 Thread Mark Fasheh
to a test case! --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-14 Thread Mark Fasheh
) and Arvin's patch can be found at: https://github.com/markfasheh/btrfs-progs-patches/tree/no-data-and-libify If nothing else comes up, I will send them out tommorrow. Thanks again to you all for looking at this. --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line

Re: [PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-11 Thread Mark Fasheh
than that would be why it won't install. Thanks again for testing this Anand! --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo

Re: [PATCH 3/3] btrfs-progs: add send-test

2013-01-11 Thread Mark Fasheh
On Fri, Jan 11, 2013 at 05:28:22PM +0800, Anand Jain wrote: Thanks for libbtrfs. comments below. No problem, thanks for looking over and testing this out. I'll correct the whitespace error below for my next send of the patches. --Mark -- Mark Fasheh -- To unsubscribe from this list

[PATCH 2/3] btrfs-progs: libify some parts of btrfs-progs

2013-01-08 Thread Mark Fasheh
just send-stream.c and send-utils.c we have to pull in some other parts of the progs package. This patch adds code to the Makefile and headers to create a library, libbtrfs which the btrfs command now links to. Signed-off-by: Mark Fasheh mfas...@suse.de --- Makefile | 38

[PATCH] btrfs: add no file data flag to btrfs send ioctl

2013-01-07 Thread Mark Fasheh
of BTRFS_SEND_C_WRITE) with an offset, length pair indicating the extent in question. This patch does not affect the operation of BTRFS_SEND_C_CLONE commands - they will continue to be sent when a search finds an appropriate extent to clone from. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs

Re: [PATCH] btrfs: add no file data flag to btrfs send ioctl

2013-01-07 Thread Mark Fasheh
On Mon, Jan 07, 2013 at 11:01:17PM +0100, David Sterba wrote: On Mon, Jan 07, 2013 at 01:51:19PM -0800, Mark Fasheh wrote: +#define BTRFS_SEND_FLAG_NO_FILE_DATA 0x1 + + sctx-flags = arg-flags; + For compatibility reasons, you should mask the user input value and only allow

Re: [RFC] btrfs send without data updates?

2013-01-02 Thread Mark Fasheh
! --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

[RFC] btrfs send without data updates?

2012-12-31 Thread Mark Fasheh
be replicating most of the send code _anyway_ (well, it could just be a wrapper ioctl()). Thanks in advance for looking at this. --Mark -- Mark Fasheh From: Mark Fasheh mfas...@suse.de btrfs: add no file data flag to btrfs send ioctl This patch adds the flag, BTRFS_SEND_FLAG_NO_FILE_DATA

Re: [PATCH v2] Btrfs: extended inode refs support for send mechanism

2012-10-16 Thread Mark Fasheh
+--- 3 files changed, 94 insertions(+), 58 deletions(-) --- Changes for v2: - Re-understood how btrfs_search_slot_for_read works (3 places, reported by Alex Lyakas) - Fixed extref handling in get_first_ref (reported by Mark Fasheh) Looks good to my eyes

Re: [PATCH] Btrfs: extended inode refs support for send mechanism

2012-10-11 Thread Mark Fasheh
line in get_first_ref() which I believe was missed: *dir = found_key.offset; that will have to account for an extended ref. The rest of the patch looks pretty good to me. Thanks for writing this up! --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line

Re: [PATCH v4 3/4] btrfs: extended inode refs

2012-10-09 Thread Mark Fasheh
, 2012 at 22:29 (+0200), Mark Fasheh wrote: Teach tree-log.c about extended inode refs. In particular, we have to adjust the behavior of inode ref replay as well as log tree recovery to account for the existence of extended refs. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs

Re: [PATCH v4 0/4] btrfs: extended inode refs

2012-09-27 Thread Mark Fasheh
On Tue, Sep 25, 2012 at 04:04:46PM -0400, Chris Mason wrote: On Mon, Aug 20, 2012 at 02:29:17PM -0600, Mark Fasheh wrote: Testing wise, the basic namespace operations work well (link, unlink, etc). The rest has gotten less debugging (and I really don't have a great way of testing

[PATCH v4 0/4] btrfs: extended inode refs

2012-08-20 Thread Mark Fasheh
for extended refs, I fixed up iterate_irefs_t arguments to take the raw information from whatever ref version we're coming from. This removed a bunch of duplicated code. - I am actually including a patch to btrfs-progs with this drop. :) From: Mark Fasheh mfas...@suse.com [PATCH] btrfs-progs

[PATCH v4 3/4] btrfs: extended inode refs

2012-08-20 Thread Mark Fasheh
Teach tree-log.c about extended inode refs. In particular, we have to adjust the behavior of inode ref replay as well as log tree recovery to account for the existence of extended refs. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/backref.c | 68 +++ fs/btrfs/backref.h

[PATCH v4 1/4] btrfs: extended inode refs

2012-08-20 Thread Mark Fasheh
This patch adds basic support for extended inode refs. This includes support for link and unlink of the refs, which basically gets us support for rename as well. Inode creation does not need changing - extended refs are only added after the ref array is full. Signed-off-by: Mark Fasheh mfas

[PATCH v4 2/4] btrfs: improved readablity for add_inode_ref

2012-08-20 Thread Mark Fasheh
From: Jan Schmidt list.bt...@jan-o-sch.net Moved part of the code into a sub function and replaced most of the gotos by ifs, hoping that it will be easier to read now. Signed-off-by: Jan Schmidt list.bt...@jan-o-sch.net Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/tree-log.c | 178

[PATCH v4 4/4] btrfs: extended inode refs

2012-08-20 Thread Mark Fasheh
. Reviewed-by: Jan Schmidt list.bt...@jan-o-sch.net Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/backref.c | 134 +++- fs/btrfs/backref.h |2 - 2 files changed, 112 insertions(+), 24 deletions(-) diff --git a/fs/btrfs/backref.c b/fs/btrfs

Re: [PATCH 2/3] btrfs: extended inode refs

2012-08-15 Thread Mark Fasheh
On Wed, Aug 15, 2012 at 05:04:48PM +0200, Jan Schmidt wrote: When applying this patch I get: warning: 2 lines add whitespace errors. Oop, I'll fix that up. More comments inline. On Wed, August 08, 2012 at 20:55 (+0200), Mark Fasheh wrote: Teach tree-log.c about extended inode refs

Re: [PATCH 1/3] btrfs: extended inode refs

2012-08-14 Thread Mark Fasheh
On Tue, Aug 14, 2012 at 11:32:43AM +0200, Jan Schmidt wrote: On Wed, August 08, 2012 at 20:55 (+0200), Mark Fasheh wrote: +/* + * btrfs_insert_inode_extref() - Inserts an extended inode ref into a tree. + * + * The caller must have checked against BTRFS_LINK_MAX already. + */ +static

[PATCH 0/3] btrfs: extended inode refs

2012-08-08 Thread Mark Fasheh
the raw information from whatever ref version we're coming from. This removed a bunch of duplicated code. - I am actually including a patch to btrfs-progs with this drop. :) From: Mark Fasheh mfas...@suse.com [PATCH] btrfs-progs: basic support for extended inode refs This patch adds enough

[PATCH 1/3] btrfs: extended inode refs

2012-08-08 Thread Mark Fasheh
This patch adds basic support for extended inode refs. This includes support for link and unlink of the refs, which basically gets us support for rename as well. Inode creation does not need changing - extended refs are only added after the ref array is full. Signed-off-by: Mark Fasheh mfas

[PATCH 3/3] btrfs: extended inode refs

2012-08-08 Thread Mark Fasheh
-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/backref.c | 134 +++- fs/btrfs/backref.h |2 - 2 files changed, 112 insertions(+), 24 deletions(-) diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c index 658e09c..4a01f7c 100644 --- a/fs/btrfs

[PATCH 2/3] btrfs: extended inode refs

2012-08-08 Thread Mark Fasheh
Teach tree-log.c about extended inode refs. In particular, we have to adjust the behavior of inode ref replay as well as log tree recovery to account for the existence of extended refs. Signed-off-by: Mark Fasheh mfas...@suse.de --- fs/btrfs/backref.c | 68 fs/btrfs/backref.h

Re: [PATCH 2/3] btrfs: extended inode refs

2012-08-06 Thread Mark Fasheh
On Fri, Jul 06, 2012 at 04:57:15PM +0200, Jan Schmidt wrote: Thought about this search_done once again, I'd like to repeat our May's conversation: On Fri, May 04, 2012 at 01:12 (+0200), Mark Fasheh wrote: You moved this comment and assignment out of the if (ret == 0) case. I'm not sure

Re: [PATCH 1/3] btrfs: extended inode refs

2012-07-09 Thread Mark Fasheh
patch (don't think I need to reply individually to those). On Mon, May 21, 2012 at 23:46 (+0200), Mark Fasheh wrote: @@ -189,6 +435,19 @@ int btrfs_insert_inode_ref(struct btrfs_trans_handle *trans, out: btrfs_free_path(path); + + if (ret == -EMLINK) { + struct

Re: [PATCH 1/3] btrfs: extended inode refs

2012-07-09 Thread Mark Fasheh
, however I don't think prefixing it is a big deal so I'll go ahead and make _that_ change unless you feel otherwise. Thanks, --Mark -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info

[PATCH 0/3] btrfs-progs: Support for extended inode refs

2012-06-07 Thread Mark Fasheh
with the same key in an array just like the dir item code. This means we have to search an array on rare occasion. -- Mark Fasheh -- To unsubscribe from this list: send the line unsubscribe linux-btrfs in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org

[PATCH 1/3] [PATCH] btrfs-progs: Basic support for extended inode refs

2012-06-07 Thread Mark Fasheh
From: Mark Fasheh mfas...@suse.com This patch syncs the extended inode ref definitions from kernels ctree.h and adds support in btrfs-debug-tree for visualizing the state of extended refs on disk. Signed-off-by: Mark Fasheh mfas...@suse.de --- ctree.h | 27

[PATCH 2/3] [PATCH] btrfs-progs: add extended inode ref support to btrfsck

2012-06-07 Thread Mark Fasheh
From: Mark Fasheh mfas...@suse.com Add a function, process_inode_extref() to be called from process_one_leaf() when an item type of BTRFS_INODE_EXTREF_KEY is encountered. Similarly to process_inode_ref(), process_inode_extref() walks an extref and adds an inode_backref structure for each

<    1   2   3   4   5   >