<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/gfs2/dir.c, branch linux-3.14.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.14.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.14.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-01-08T12:14:57Z</updated>
<entry>
<title>GFS2: Add hints to directory leaf blocks</title>
<updated>2014-01-08T12:14:57Z</updated>
<author>
<name>Steven Whitehouse</name>
</author>
<published>2014-01-08T12:14:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=01bcb0dedbcd77a5ebb4f2dfd7d3196e3ad5cea5'/>
<id>urn:sha1:01bcb0dedbcd77a5ebb4f2dfd7d3196e3ad5cea5</id>
<content type='text'>
This patch adds four new fields to directory leaf blocks.
The intent is not to use them in the kernel itself, although
perhaps we may be able to use them as hints at some later date,
but instead to provide more information for debug/fsck use.

One new field adds a pointer to the inode to which the leaf
belongs. This can be useful if the pointer to the leaf block
has become corrupt, as it will allow us to know which inode
this block should be associated with. This field is set when
the leaf is created and never changed over its lifetime.

The second field is a "distance from the hash table" field.
The meaning is as follows:
 0  = An old leaf in which this value has not been set
 1  = This leaf is pointed to directly from the hash table
 2+ = This leaf is part of a chain, pointed to by another leaf
      block, the value gives the position in the chain.

The third and fourth fields combine to give a time stamp of
the most recent directory insertion or deletion from this
leaf block. The time stamp is not updated when a new leaf
block is chained from the current one. The code is currently
written such that the timestamp on the dir inode will match
that of the leaf block for the most recent insertion/deletion.

For backwards compatibility, any of these new fields which is
zero should be considered to be "unknown".

Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
<entry>
<title>GFS2: For exhash conversion, only one block is needed</title>
<updated>2014-01-08T11:05:29Z</updated>
<author>
<name>Steven Whitehouse</name>
</author>
<published>2014-01-08T11:05:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=22b5a6c0c0cd5eb524d31c949d113c6683e37ec9'/>
<id>urn:sha1:22b5a6c0c0cd5eb524d31c949d113c6683e37ec9</id>
<content type='text'>
For most cases, only a single new block is needed when we reach
the point of converting from stuffed to exhash directory. The
exception being when the file name is so long that it will not
fit within the new leaf block.

So this patch adds a simple test for that situation so that we
do not need to request the full reservation size in this case.

Potentially we could calculate more accurately the value to use
in other cases too, but that is much more complicated to do and
it is doubtful that the benefit would outweigh the extra cost
in code complexity.

Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
<entry>
<title>GFS2: Remember directory insert point</title>
<updated>2014-01-06T12:49:43Z</updated>
<author>
<name>Steven Whitehouse</name>
</author>
<published>2014-01-06T12:49:43Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=2b47dad866d04f14c328f888ba5406057b8c7d33'/>
<id>urn:sha1:2b47dad866d04f14c328f888ba5406057b8c7d33</id>
<content type='text'>
When we look to see if there is enough space to add a dir
entry without allocation, we have then been repeating the
same search later when we do the actual insertion. This
patch caches the details of the location in the gfs2_diradd
structure, so that we do not have to repeat the search.

This will provide a performance improvement which will be
greater as the size of the directory increases.

Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
<entry>
<title>GFS2: Add directory addition info structure</title>
<updated>2014-01-06T11:28:41Z</updated>
<author>
<name>Steven Whitehouse</name>
</author>
<published>2014-01-06T11:28:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3c1c0ae1db74b1f3e606f42158b5dadd89105c1f'/>
<id>urn:sha1:3c1c0ae1db74b1f3e606f42158b5dadd89105c1f</id>
<content type='text'>
The intent is that this structure will hold the information
required when adding entries to a directory (linking). To
start with, it will contain only the number of blocks which
are required to link the new entry into the directory. The
current calculation returns either 0 or the maximim number of
blocks that can ever be requested by such a transaction.

The intent is that in a later patch, we can update the dir
code to calculate this value more accurately. In addition
further patches will also add further fields to the new
structure to increase its utility.

In addition this patch fixes a bug where the link used during
inode creation was adding requesting too many blocks in
some cases. This is harmless unless the fs is close to being
full.

Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
<entry>
<title>treewide: Add __GFP_NOWARN to k.alloc calls with v.alloc fallbacks</title>
<updated>2013-08-20T11:06:40Z</updated>
<author>
<name>Joe Perches</name>
</author>
<published>2013-06-19T19:15:53Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8be04b9374e59923fa337766aaa74151b95b7099'/>
<id>urn:sha1:8be04b9374e59923fa337766aaa74151b95b7099</id>
<content type='text'>
Don't emit OOM warnings when k.alloc calls fail when
there there is a v.alloc immediately afterwards.

Converted a kmalloc/vmalloc with memset to kzalloc/vzalloc.

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Acked-by: "Theodore Ts'o" &lt;tytso@mit.edu&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>Merge git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-3.0-nmw</title>
<updated>2013-07-02T16:41:18Z</updated>
<author>
<name>Linus Torvalds</name>
</author>
<published>2013-07-02T16:41:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c4eb1b07303ad9e00aba842aa90d5521293ac857'/>
<id>urn:sha1:c4eb1b07303ad9e00aba842aa90d5521293ac857</id>
<content type='text'>
Pull GFS2 updates from Steven Whitehouse:
 "There are a few bug fixes for various, mostly very minor corner cases,
  plus some interesting new features.

  The new features include atomic_open whose main benefit will be the
  reduction in locking overhead in case of combined lookup/create and
  open operations, sorting the log buffer lists by block number to
  improve the efficiency of AIL writeback, and aggressively issuing
  revokes in gfs2_log_flush to reduce overhead when dropping glocks."

* git://git.kernel.org/pub/scm/linux/kernel/git/steve/gfs2-3.0-nmw:
  GFS2: Reserve journal space for quota change in do_grow
  GFS2: Fix fstrim boundary conditions
  GFS2: fix warning message
  GFS2: aggressively issue revokes in gfs2_log_flush
  GFS2: fix regression in dir_double_exhash
  GFS2: Add atomic_open support
  GFS2: Only do one directory search on create
  GFS2: fix error propagation in init_threads()
  GFS2: Remove no-op wrapper function
  GFS2: Cocci spatch "ptr_ret.spatch"
  GFS2: Eliminate gfs2_rg_lops
  GFS2: Sort buffer lists by inplace block number
</content>
</entry>
<entry>
<title>[readdir] convert gfs2</title>
<updated>2013-06-29T08:56:35Z</updated>
<author>
<name>Al Viro</name>
</author>
<published>2013-05-16T18:14:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d81a8ef59802d2d8908466d631573a3644c313d5'/>
<id>urn:sha1:d81a8ef59802d2d8908466d631573a3644c313d5</id>
<content type='text'>
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>GFS2: fix regression in dir_double_exhash</title>
<updated>2013-06-14T12:27:17Z</updated>
<author>
<name>Bob Peterson</name>
</author>
<published>2013-06-14T12:39:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=512cbf02fde42b747c5752f135afd3f3f6d598e2'/>
<id>urn:sha1:512cbf02fde42b747c5752f135afd3f3f6d598e2</id>
<content type='text'>
Recent commit e8830d8 introduced a bug in function dir_double_exhash;
it was failing to set h in the fall-back case. This patch corrects it.

Signed-off-by: Bob Peterson &lt;rpeterso@redhat.com&gt;
Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;

</content>
</entry>
<entry>
<title>GFS2: Only do one directory search on create</title>
<updated>2013-06-11T12:45:29Z</updated>
<author>
<name>Steven Whitehouse</name>
</author>
<published>2013-06-11T12:45:29Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5a00f3cc978be45b9d2597851bedaa40630bc597'/>
<id>urn:sha1:5a00f3cc978be45b9d2597851bedaa40630bc597</id>
<content type='text'>
Creation of a new inode requires a directory search in order to ensure
that we are not trying to create an inode with the same name as an
existing one. This was hidden away inside the create_ok() function.

In the case that there was an existing inode, and a lookup can be
substituted for a create (which is the case with regular files
when the O_EXCL flag is not in use) then we were doing a second
lookup in order to return the inode.

This patch merges these two lookups into one. This can be done by
passing a flag to gfs2_dir_search() to tell it to just return -EEXIST
in the cases where we don't actually want to look up the inode.

Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
<entry>
<title>GFS2: Fall back to vmalloc if kmalloc fails for dir hash tables</title>
<updated>2013-06-03T15:39:44Z</updated>
<author>
<name>Bob Peterson</name>
</author>
<published>2013-05-30T13:48:56Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e8830d8856e3ad61067dd46c05438b0d75a0441a'/>
<id>urn:sha1:e8830d8856e3ad61067dd46c05438b0d75a0441a</id>
<content type='text'>
This version has one more correction: the vmalloc calls are replaced
by __vmalloc calls to preserve the GFP_NOFS flag.

When GFS2's directory management code allocates buffers for a
directory hash table, if it can't get the memory it needs, it
currently gives a bad return code. Rather than giving an error,
this patch allows it to use virtual memory rather than kernel
memory for the hash table. This should make it possible for
directories to function properly, even when kernel memory becomes
very fragmented.

Signed-off-by: Bob Peterson &lt;rpeterso@redhat.com&gt;
Signed-off-by: Steven Whitehouse &lt;swhiteho@redhat.com&gt;
</content>
</entry>
</feed>
