search for: btrfs_ioctl_search_header

Displaying 8 results from an estimated 8 matches for "btrfs_ioctl_search_header".

2010 Dec 11
1
[RFC] Improve btrfs subvolume find-new command
...* given root id and spit out the latest generation we can find */ -static u64 find_root_gen(int fd) +u64 find_root_gen(int fd) { struct btrfs_ioctl_ino_lookup_args ino_args; int ret; @@ -657,11 +657,43 @@ int list_subvols(int fd) return ret; } -static int print_one_extent(int fd, struct btrfs_ioctl_search_header *sh, +static u64 cache_get_full_path_dirid = 0; +static u64 cache_get_full_path_ino = 0; +static char *cache_get_full_path_dir_name = NULL; +static char *cache_get_full_path_full_name = NULL; + +static void init_cache_get_full_path(void) +{ + cache_get_full_path_dirid = 0; + cache_get_full_path_ino...
2011 Jul 12
0
[PATCH]: Use a general way to get the default subvolume for btrfs
...+ __u32 min_type; + __u32 max_type; + + /* + * how many items did userland ask for, and how many are we + * returning + */ + __u32 nr_items; + + /* align to 64 bits */ + __u32 unused; + + /* some extra for later */ + __u64 unused1; + __u64 unused2; + __u64 unused3; + __u64 unused4; +}; + +struct btrfs_ioctl_search_header { + __u64 transid; + __u64 objectid; + __u64 offset; + __u32 type; + __u32 len; +} __attribute__((may_alias)); + +#define BTRFS_SEARCH_ARGS_BUFSIZE (4096 - sizeof(struct btrfs_ioctl_search_key)) +/* + * the buf is an array of search headers where + * each header is followed by the actual item + * t...
2015 Sep 09
1
[PATCH v1 1/1] extlinux: fix file descriptors leak
..._file(const char *path, int devfd, struct stat *rst) goto bail; } + close(fd); free(file); free(oldfile); free(c32file); @@ -778,7 +779,7 @@ static char * get_default_subvol(char * rootdir, char * subvol) struct btrfs_ioctl_search_key *sk = &args.key; struct btrfs_ioctl_search_header *sh; int ret, i; - int fd; + int fd = -1; struct btrfs_root_ref *ref; struct btrfs_dir_item *dir_item; unsigned long off = 0; @@ -797,6 +798,8 @@ static char * get_default_subvol(char * rootdir, char * subvol) } if (ret <= 0) { subvol[0] = '\0'...
2012 Aug 01
17
[PATCH] add crtime to the snapshot list
From: Anand <anand.jain@oracle.com> This patch adds creation-time to the snapshot list display, which would help user to better manage the snapshots when number of snapshots grow substantially. This patch is developed and on top of the send/receive btrfs and btrfs-progs repo at git://github.com/ablock84/linux-btrfs.git (send-v2) git://github.com/ablock84/btrfs-progs.git (send-v2)
2010 Jun 28
1
[PATCH] Btrgs-progs: Define _GNU_SOURCE for strndup
This fixes: btrfs-list.c: Dans la fonction «ino_resolve» : btrfs-list.c:511: attention : déclaration implicite de la fonction « «strndup» » btrfs-list.c:511: attention : incompatible implicit declaration of built-in function «strndup» make: *** [btrfs-list.o] Erreur 1 and: btrfs.c: Dans la fonction «split_command» : btrfs.c:168: attention : déclaration implicite de la fonction « «strndup» »
2015 Sep 09
0
[PATCH v1 1/1] extlinux: fix memory leak
...tions(+), 17 deletions(-) diff --git a/extlinux/main.c b/extlinux/main.c index bc7ded3..74f8d1f 100644 --- a/extlinux/main.c +++ b/extlinux/main.c @@ -779,7 +779,7 @@ static char * get_default_subvol(char * rootdir, char * subvol) struct btrfs_ioctl_search_key *sk = &args.key; struct btrfs_ioctl_search_header *sh; int ret, i; - int fd; + int fd = -1; struct btrfs_root_ref *ref; struct btrfs_dir_item *dir_item; unsigned long off = 0; @@ -1044,12 +1044,12 @@ err: } #ifndef __KLIBC__ -static const char *find_device(const char *mtab_file, dev_t dev) +static char *find_device(co...
2013 Aug 14
23
[RFC] btrfs-progs: fix sparse checking and warnings
Hi gang, I was a little surprised to see that patch go by recently which fixed an endian bug. I went to see how sparse checking looked and it was.. broken. I got it going again in my Fedora environment. Most of the patches are just cleanups, but there *were* three real bugs lurking in all that sparse warning spam. So I maintain that it''s worth our time to keep it going and fix
2012 Feb 29
15
[RFC] [PATCH] Add btrfs autosnap feature
From: anand jain <anand.jain@oracle.com> Anand Jain (1): [RFC] Add btrfs autosnap feature Makefile | 6 +- autosnap.c | 1553 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ autosnap.h | 81 +++ btrfs-list.c | 140 +++++- btrfs.c | 46 ++- btrfs_cmds.c | 186 +++++++- btrfs_cmds.h | 3 +- scrub.c | 1 + 8 files changed, 1982 insertions(+), 34