linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/9] btrfs-progs: some fixes for bugs spotted by valgrind
@ 2011-06-04  8:19 Sergei Trofimovich
  2011-06-04  8:19 ` [PATCH v2 1/9] btrfs progs: fix extra metadata chunk allocation in --mixed case Sergei Trofimovich
                   ` (8 more replies)
  0 siblings, 9 replies; 10+ messages in thread
From: Sergei Trofimovich @ 2011-06-04  8:19 UTC (permalink / raw)
  To: Chris Mason; +Cc: linux-btrfs, Sergei Trofimovich

tmp branch recently got very nice feature: 'mkfs.btrfs -r /some/directory'.

It's very useful, when you need to creare minimal root: /bin/sh and fs_mark.

But there is another hidden feature! As '-r' can create whole filesystem
we can effectively valgrind a lot of code paths in btrfs and pick bugs.

This patch series is mostly (with one exception) dumb obvous holes plugs
(sometimes they are backports from kernel).

Patchset based on
    git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-progs-unstable.git#tmp

    commit e6bd18d8938986c997c45f0ea95b221d4edec095
    Author: Christoph Hellwig <hch@lst.de>
    Date:   Thu Apr 21 16:24:07 2011 -0400

First off the exception:

In order to make --mixed produce proper filesystems with meta+data only
blocks (and not meta+data/data ones, which confused space_cache and led
to an oops for me) I ask to consider for pulling Arne's patch:
> Subject: [PATCH v2 1/9] btrfs progs: fix extra metadata chunk allocation in --mixed case

The rest of patches should be obvoius. They don't fix all the fair valgrind
compaints, but reduce them severely.

Changes since v1:
  - "[PATCH 8/9] mkfs.btrfs: fix memory leak caused by 'scandir()' calls":
    'free_namelist()' now works correctly if 'count == -1'. It happens
    when 'free_namelist()' is called right after 'scandir()' returning
    an error.

Some stats:

    convert.c     |    2 +-
    extent-tree.c |    7 ++++---
    extent_io.c   |    1 +
    file-item.c   |    1 +
    mkfs.c        |   39 ++++++++++++++++++++++++++++++++++++---
    5 files changed, 43 insertions(+), 7 deletions(-)

Arne Jansen (1):
      btrfs progs: fix extra metadata chunk allocation in --mixed case

Sergei Trofimovich (8):
      btrfs-convert: fix typo: 'all inode' -> 'all inodes'
      mkfs.btrfs: fail on scandir error (-r mode)
      mkfs.btrfs: return some defined value instead of garbage when lookup checksum
      mkfs.btrfs: fix symlink names writing
      mkfs.btrfs: write zeroes instead on uninitialized data.
      mkfs.btrfs: free buffers allocated by pretty_sizes
      mkfs.btrfs: fix memory leak caused by 'scandir()' calls
      mkfs.btrfs: fix error text in '-r' mode

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2011-06-04  8:19 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-04  8:19 [PATCH v2 0/9] btrfs-progs: some fixes for bugs spotted by valgrind Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 1/9] btrfs progs: fix extra metadata chunk allocation in --mixed case Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 2/9] btrfs-convert: fix typo: 'all inode' -> 'all inodes' Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 3/9] mkfs.btrfs: fail on scandir error (-r mode) Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 4/9] mkfs.btrfs: return some defined value instead of garbage when lookup checksum Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 5/9] mkfs.btrfs: fix symlink names writing Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 6/9] mkfs.btrfs: write zeroes instead on uninitialized data Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 7/9] mkfs.btrfs: free buffers allocated by pretty_sizes Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 8/9] mkfs.btrfs: fix memory leak caused by 'scandir()' calls Sergei Trofimovich
2011-06-04  8:19 ` [PATCH v2 9/9] mkfs.btrfs: fix error text in '-r' mode Sergei Trofimovich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).