<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/xfs/xfs_alloc.c, branch linux-3.2.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.2.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.2.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-08-06T17:07:40Z</updated>
<entry>
<title>xfs: really fix the cursor leak in xfs_alloc_ag_vextent_near</title>
<updated>2014-08-06T17:07:40Z</updated>
<author>
<name>Dave Chinner</name>
</author>
<published>2012-07-11T21:40:42Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d9892580a2f3aa0d369fcec9bd50fd75ecc57dcc'/>
<id>urn:sha1:d9892580a2f3aa0d369fcec9bd50fd75ecc57dcc</id>
<content type='text'>
commit e3a746f5aab71f2dd0a83116772922fb37ae29d6 upstream.

The current cursor is reallocated when retrying the allocation, so
the existing cursor needs to be destroyed in both the restart and
the failure cases.

Signed-off-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Tested-by: Mike Snitzer &lt;snitzer@redhat.com&gt;
Signed-off-by: Ben Myers &lt;bpm@sgi.com&gt;
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</content>
</entry>
<entry>
<title>xfs: fix allocbt cursor leak in xfs_alloc_ag_vextent_near</title>
<updated>2014-08-06T17:07:40Z</updated>
<author>
<name>Dave Chinner</name>
</author>
<published>2012-06-12T04:20:26Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=381687bd230ca824df7a70aa1f8fa3a4345ee6e2'/>
<id>urn:sha1:381687bd230ca824df7a70aa1f8fa3a4345ee6e2</id>
<content type='text'>
commit 76d095388b040229ea1aad7dea45be0cfa20f589 upstream.

When we fail to find an matching extent near the requested extent
specification during a left-right distance search in
xfs_alloc_ag_vextent_near, we fail to free the original cursor that
we used to look up the XFS_BTNUM_CNT tree and hence leak it.

Reported-by: Chris J Arges &lt;chris.j.arges@canonical.com&gt;
Signed-off-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Ben Myers &lt;bpm@sgi.com&gt;
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</content>
</entry>
<entry>
<title>xfs: remove XFS_BUF_SET_VTYPE and XFS_BUF_SET_VTYPE_REF</title>
<updated>2011-10-12T02:15:09Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2011-10-10T16:52:45Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=38f23232449c9d2c0bc8e9541cb8ab08b7c2b9ce'/>
<id>urn:sha1:38f23232449c9d2c0bc8e9541cb8ab08b7c2b9ce</id>
<content type='text'>
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;


</content>
</entry>
<entry>
<title>xfs: Remove the macro XFS_BUF_ERROR and family</title>
<updated>2011-07-25T19:57:46Z</updated>
<author>
<name>Chandra Seetharaman</name>
</author>
<published>2011-07-22T23:39:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5a52c2a581cddcb676a54a95d99cd39f5577c33b'/>
<id>urn:sha1:5a52c2a581cddcb676a54a95d99cd39f5577c33b</id>
<content type='text'>
Remove the definitions and usage of the macros XFS_BUF_ERROR,
XFS_BUF_GETERROR and XFS_BUF_ISERROR.

Signed-off-by: Chandra Seetharaman &lt;sekharan@us.ibm.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
<entry>
<title>xfs: remove variables that serve no purpose in xfs_alloc_ag_vextent_exact()</title>
<updated>2011-07-08T16:32:51Z</updated>
<author>
<name>Chandra Seetharaman</name>
</author>
<published>2011-06-09T16:47:49Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=81463b1ca8dbd2f4f180feac3f49c7640e2b5f79'/>
<id>urn:sha1:81463b1ca8dbd2f4f180feac3f49c7640e2b5f79</id>
<content type='text'>
Remove two variables that serve no purpose in
xfs_alloc_ag_vextent_exact().

Signed-off-by: Chandra Seetharaman &lt;sekharan@us.ibm.com&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
<entry>
<title>xfs: byteswap constants instead of variables</title>
<updated>2011-07-08T12:36:05Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2011-07-08T12:36:05Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=69ef921b55cc3788d1d2a27b33b27d04acd0090a'/>
<id>urn:sha1:69ef921b55cc3788d1d2a27b33b27d04acd0090a</id>
<content type='text'>
Micro-optimize various comparisms by always byteswapping the constant
instead of the variable, which allows to do the swap at compile instead
of runtime.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Reviewed-by: Alex Elder &lt;aelder@sgi.com&gt;
Reviewed-by: Dave Chinner &lt;dchinner@redhat.com&gt;
</content>
</entry>
<entry>
<title>xfs: do not discard alloc btree blocks</title>
<updated>2011-05-24T16:17:22Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2011-05-04T18:55:15Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=55a7bc5a30ff2d30d8a34fea2af9fc601b32e61a'/>
<id>urn:sha1:55a7bc5a30ff2d30d8a34fea2af9fc601b32e61a</id>
<content type='text'>
Blocks for the allocation btree are allocated from and released to
the AGFL, and thus frequently reused.  Even worse we do not have an
easy way to avoid using an AGFL block when it is discarded due to
the simple FILO list of free blocks, and thus can frequently stall
on blocks that are currently undergoing a discard.

Add a flag to the busy extent tracking structure to skip the discard
for allocation btree blocks.  In normal operation these blocks are
reused frequently enough that there is no need to discard them
anyway, but if they spill over to the allocation btree as part of a
balance we "leak" blocks that we would otherwise discard.  We could
fix this by adding another flag and keeping these block in the
rbtree even after they aren't busy any more so that we could discard
them when they migrate out of the AGFL.  Given that this would cause
significant overhead I don't think it's worthwile for now.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
<entry>
<title>xfs: add online discard support</title>
<updated>2011-05-24T16:17:13Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2011-05-20T13:45:32Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e84661aa84e2e003738563f65155d4f12dc474e7'/>
<id>urn:sha1:e84661aa84e2e003738563f65155d4f12dc474e7</id>
<content type='text'>
Now that we have reliably tracking of deleted extents in a
transaction we can easily implement "online" discard support
which calls blkdev_issue_discard once a transaction commits.

The actual discard is a two stage operation as we first have
to mark the busy extent as not available for reuse before we
can start the actual discard.  Note that we don't bother
supporting discard for the non-delaylog mode.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
<entry>
<title>xfs: obey minleft values during extent allocation correctly</title>
<updated>2011-05-19T17:03:48Z</updated>
<author>
<name>Dave Chinner</name>
</author>
<published>2011-04-21T09:34:28Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188'/>
<id>urn:sha1:bf59170a66bc3eaf3ee513aa6ce9774aa2ab5188</id>
<content type='text'>
When allocating an extent that is long enough to consume the
remaining free space in an AG, we need to ensure that the allocation
leaves enough space in the AG for any subsequent bmap btree blocks
that are needed to track the new extent. These have to be allocated
in the same AG as we only reserve enough blocks in an allocation
transaction for modification of the freespace trees in a single AG.

xfs_alloc_fix_minleft() has been considering blocks on the AGFL as
free blocks available for extent and bmbt block allocation, which is
not correct - blocks on the AGFL are there exclusively for the use
of the free space btrees. As a result, when minleft is less than the
number of blocks on the AGFL, xfs_alloc_fix_minleft() does not trim
the given extent to leave minleft blocks available for bmbt
allocation, and hence we can fail allocation during bmbt record
insertion.

Signed-off-by: Dave Chinner &lt;dchinner@redhat.com&gt;
Reviewed-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
<entry>
<title>xfs: reduce the number of pagb_lock roundtrips in xfs_alloc_clear_busy</title>
<updated>2011-04-28T18:18:09Z</updated>
<author>
<name>Christoph Hellwig</name>
</author>
<published>2011-04-24T19:06:17Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=8a072a4d4c6a5b6ec32836c467d2996393c76c6f'/>
<id>urn:sha1:8a072a4d4c6a5b6ec32836c467d2996393c76c6f</id>
<content type='text'>
Instead of finding the per-ag and then taking and releasing the pagb_lock
for every single busy extent completed sort the list of busy extents and
only switch betweens AGs where nessecary.  This becomes especially important
with the online discard support which will hit this lock more often.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Alex Elder &lt;aelder@sgi.com&gt;
</content>
</entry>
</feed>
