search for: total_byt

Displaying 20 results from an estimated 62 matches for "total_byt".

Did you mean: total_bytes
2013 Sep 05
3
[PATCH v2 0/3] btrfs-progs: prevent mkfs from aborting with small volume
Here are 3 patches to avoid undesired aborts of mkfs.btrfs. These are based on top of Chris''s btrfs-progs.git: git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-progs.git Thanks, H.Seto Hidetoshi Seto (3): btrfs-progs: error if device for mkfs is too small btrfs-progs: error if device have no space to make primary chunks btrfs-progs: calculate available
2013 Oct 08
3
[PATCH] Btrfs: limit delalloc pages outside of find_delalloc_range
...(-) diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index b48942f..2bf6f46 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -1491,10 +1491,8 @@ static noinline u64 find_delalloc_range(struct extent_io_tree *tree, cur_start = state->end + 1; node = rb_next(node); total_bytes += state->end - state->start + 1; - if (total_bytes >= max_bytes) { - *end = *start + max_bytes - 1; + if (total_bytes >= max_bytes) break; - } if (!node) break; } @@ -1636,10 +1634,9 @@ again: /* * make sure to limit the number of pages we try to lock down -...
2010 Apr 03
1
[PATCH] btrfs support
...erent from the btrfs_header from here own down */ + __le64 magic; + __le64 generation; + __le64 root; + __le64 chunk_root; + __le64 log_root; + + /* this will help find the new super based on the log root */ + __le64 log_root_transid; + __le64 total_bytes; + __le64 bytes_used; + __le64 root_dir_objectid; + __le64 num_devices; + __le32 sectorsize; + __le32 nodesize; + __le32 leafsize; + __le32 stripesize; + __le32 sys_chunk_array_size; + __le64 chunk_root_generation; + __le64 com...
2008 Jan 07
1
[PATCH]Add rollback support for the converter
...*name, - int namelen, ext2_filsys ext2_fs) +static int create_ext2_image(struct btrfs_root *root, ext2_filsys ext2_fs, + const char *name) { int ret; struct btrfs_key key; @@ -837,7 +853,8 @@ static int create_ext2_image(struct btrf btrfs_set_stack_inode_size(&btrfs_inode, total_bytes); btrfs_set_stack_inode_nlink(&btrfs_inode, 1); btrfs_set_stack_inode_nblocks(&btrfs_inode, 0); - btrfs_set_stack_inode_mode(&btrfs_inode, S_IFREG | 0444); + btrfs_set_stack_inode_mode(&btrfs_inode, S_IFREG | 0400); + btrfs_set_stack_inode_flags(&btrfs_inode, BTRFS_INODE_N...
2011 Jul 26
0
[PATCH] Btrfs: use bytes_may_use for all ENOSPC reservations
...inode *inode, u64 bytes) { @@ -3154,6 +3170,7 @@ static int should_alloc_chunk(struct btrfs_root *root, struct btrfs_space_info *sinfo, u64 alloc_bytes, int force) { + struct btrfs_block_rsv *global_rsv = &root->fs_info->global_block_rsv; u64 num_bytes = sinfo->total_bytes - sinfo->bytes_readonly; u64 num_allocated = sinfo->bytes_used + sinfo->bytes_reserved; u64 thresh; @@ -3162,6 +3179,14 @@ static int should_alloc_chunk(struct btrfs_root *root, return 1; /* + * We need to take into account the global rsv because for all intents + * and purp...
2011 Jul 27
0
[PATCH] Btrfs: use bytes_may_use for all ENOSPC reservations V2
...inode *inode, u64 bytes) { @@ -3154,6 +3170,7 @@ static int should_alloc_chunk(struct btrfs_root *root, struct btrfs_space_info *sinfo, u64 alloc_bytes, int force) { + struct btrfs_block_rsv *global_rsv = &root->fs_info->global_block_rsv; u64 num_bytes = sinfo->total_bytes - sinfo->bytes_readonly; u64 num_allocated = sinfo->bytes_used + sinfo->bytes_reserved; u64 thresh; @@ -3162,6 +3179,13 @@ static int should_alloc_chunk(struct btrfs_root *root, return 1; /* + * We need to take into account the global rsv because for all intents + * and purp...
2010 Apr 19
0
[PATCH 08/12] Btrfs: Introduce global metadata reservation
...ta_sinfo->bytes_readonly + data_sinfo->bytes_may_use + - data_sinfo->bytes_super; + used = data_sinfo->bytes_used + data_sinfo->bytes_reserved + + data_sinfo->bytes_pinned + data_sinfo->bytes_readonly + + data_sinfo->bytes_may_use; if (used + bytes > data_sinfo->total_bytes) { struct btrfs_trans_handle *trans; @@ -2814,7 +2813,7 @@ alloc: bytes + 2 * 1024 * 1024, alloc_target, 0); btrfs_end_transaction(trans, root); - if (ret) + if (ret < 0) return ret; if (!data_sinfo) { @@ -2837,11 +2836,10 @@ alloc: goto again;...
2006 Apr 14
0
Quota again
...; } --- quota-maildir.c.old 2006-04-14 22:46:17.000000000 +0200 +++ quota-maildir.c 2006-04-14 13:56:02.000000000 +0200 @@ -597,7 +597,7 @@ if (strcmp(name, QUOTA_NAME_STORAGE) == 0) { *limit_r = root->message_bytes_limit / 1024; - *value_r = root->total_bytes / 1024; + *value_r = root->total_bytes / 10; } else if (strcmp(name, QUOTA_NAME_MESSAGES) == 0) { *limit_r = root->message_count_limit; *value_r = root->total_count;
2020 Feb 07
2
Dovecot/doveadm quota
...- if (p != NULL) { + if (0 && p != NULL) { /* ,S=nnnn[:,] */ p += 3; for (num = 0; *p >= '0' && *p <= '9'; p++) @@ -104,7 +104,7 @@ str_truncate(path, len); str_append(path, dp->d_name); if (stat(str_c(path), &st) == 0) { - *total_bytes += st.st_size; + *total_bytes += st.st_blocks * 512; *total_count += 1; } else if (errno != ENOENT && errno != ESTALE) { *error_r = t_strdup_printf( Thank you! -- Best regards, Martynas Bendorius
2019 Jun 29
0
[libnbd PATCH 6/6] examples: New example for strict read validations
...e MAX_BUF (2 * 1024 * 1024) +static char buf[MAX_BUF]; + +/* Various statistics */ +static int total_data_chunks; +static int total_data_bytes; +static int total_hole_chunks; +static int total_hole_bytes; +static int total_chunks; +static int total_df_reads; +static int total_reads; +static int64_t total_bytes; +static int total_success; + +static int +read_chunk (void *opaque, const void *bufv, size_t count, uint64_t offset, + int *error, int status) +{ + struct data *data = opaque; + struct range *r, **prev; + + /* libnbd guarantees this: */ + assert (offset >= data->offset); +...
2017 Feb 28
0
[PATCH 3/3] gpu: drm: drivers: Convert printk(KERN_<LEVEL> to pr_<level>
...--git a/drivers/gpu/drm/omapdrm/dss/dsi.c b/drivers/gpu/drm/omapdrm/dss/dsi.c index f74615d005a8..5e51a5649efb 100644 --- a/drivers/gpu/drm/omapdrm/dss/dsi.c +++ b/drivers/gpu/drm/omapdrm/dss/dsi.c @@ -582,15 +582,14 @@ static void dsi_perf_show(struct platform_device *dsidev, const char *name) total_bytes = dsi->update_bytes; - printk(KERN_INFO "DSI(%s): %u us + %u us = %u us (%uHz), " - "%u bytes, %u kbytes/sec\n", - name, - setup_us, - trans_us, - total_us, - 1000*1000 / total_us, - total_bytes, - total_bytes * 1000 / total_us); + pr_info("DSI(%s): %...
2011 Jul 21
10
[PATCH v5 0/8] Btrfs scrub: print path to corrupted files and trigger nodatasum fixup
While testing raid-auto-repair patches I''m going to send out later, I just found the very last bug in my current scrub patch series: Changelog v4->v5: - fixed a deadlock when fixup is taking longer while scrub is about to end Original message follows: ------------------------ This patch set introduces two new features for scrub. They share the backref iteration code which is the
2008 Oct 10
1
[PATCH] fix enospc when there is plenty of space
...7 @@ static int update_space_info(struct btrfs_fs_info *info, u64 flags, list_add(&found->list, &info->space_info); INIT_LIST_HEAD(&found->block_groups); + init_rwsem(&found->groups_sem); spin_lock_init(&found->lock); found->flags = flags; found->total_bytes = total_bytes; @@ -2208,19 +2165,22 @@ static int noinline find_free_extent(struct btrfs_trans_handle *trans, u64 exclude_start, u64 exclude_nr, int data) { - int ret; - u64 orig_search_start; + int ret = 0; struct btrfs_root * root = orig_root->fs_info->extent_root;...
2009 Aug 24
0
[PATCH] Btrfs: proper metadata -ENOSPC handling
...target, thresh, used, total; /* get the space info for where the metadata will live */ alloc_target = btrfs_get_alloc_profile(root, 0); meta_sinfo = __find_space_info(info, alloc_target); -again: spin_lock(&meta_sinfo->lock); - if (!meta_sinfo->full) - thresh = meta_sinfo->total_bytes * 80; - else - thresh = meta_sinfo->total_bytes * 95; - - do_div(thresh, 100); + total = meta_sinfo->total_bytes; + used = meta_sinfo->bytes_used + meta_sinfo->bytes_reserved + + meta_sinfo->bytes_pinned + meta_sinfo->bytes_readonly + + meta_sinfo->bytes_super; - if (met...
2017 Feb 28
8
[PATCH 2/2] gpu: drm: Convert printk(KERN_<LEVEL> to pr_<level>
...m/dss/dsi.c b/drivers/gpu/drm/omapdrm/dss/dsi.c > index f74615d005a8..5e51a5649efb 100644 > --- a/drivers/gpu/drm/omapdrm/dss/dsi.c > +++ b/drivers/gpu/drm/omapdrm/dss/dsi.c > @@ -582,15 +582,14 @@ static void dsi_perf_show(struct platform_device *dsidev, const char *name) > > total_bytes = dsi->update_bytes; > > - printk(KERN_INFO "DSI(%s): %u us + %u us = %u us (%uHz), " > - "%u bytes, %u kbytes/sec\n", > - name, > - setup_us, > - trans_us, > - total_us, > - 1000*1000 / total_us, > - total_bytes, > - total_by...
2012 Oct 04
8
[PATCH][BTRFS-PROGS][V3] btrfs filesystem df
Hi Chris, this serie of patches updated the command "btrfs filesystem df". I update this command because it is not so easy to get the information about the disk usage from the command "fi df" and "fi show". This patch was the result of some discussions on the btrfs mailing list. Many thanks to all the contributors. From the man page (see 2nd patch): [...] The
2012 Apr 08
4
[PATCH] Revert "Btrfs: increase the global block reserve estimates"
This reverts commit 5500cdbe14d7435e04f66ff3cfb8ecd8b8e44ebf. We had numerous reports of premature ENOSPC that were bisected to this patch. Reverting will not break things but a warning in ''use_block_rsv'' may show up in the syslog. There''s no alternative fix in sight and the ENOSPC problem affects all 3.3 btrfs users during normal filesystem use. CC:
2013 Feb 23
4
Changing node & leaf size on live partition.
Hi, Question is pretty simple: "How to change node size and leaf size on previously created partition?" Now, I know what most people will say: "you should''ve be smarter while typing mkfs.btrfs". Well, I''m intending to convert in place ext4 partition but there seems to be no option for leaf and node size in this tool. If it''s not possible I guess
2011 May 02
5
[PATCH v3 0/3] btrfs: quasi-round-robin for chunk allocation
In a multi device setup, the chunk allocator currently always allocates chunks on the devices in the same order. This leads to a very uneven distribution, especially with RAID1 or RAID10 and an uneven number of devices. This patch always sorts the devices before allocating, and allocates the stripes on the devices with the most available space, as long as there is enough space available. In a low
2019 Aug 14
1
Re: [PATCH libnbd 2/4] api: Add free function and remove valid_flag parameter.
...nks > 0); > + if (data->flags & LIBNBD_CMD_FLAG_DF) { > + total_df_reads++; > + if (data->chunks > 1) { > + fprintf (stderr, "buggy server: too many chunks for DF flag\n"); > *error = EPROTO; > goto cleanup; > } > - total_bytes += data->count; > - total_success++; > - ret = 0; > - > - cleanup: > - while (data->remaining) { > - struct range *r = data->remaining; > - data->remaining = r->next; > - free (r); > - } I half wonder if this cleanup: label sh...