<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/ocfs2/localalloc.c, branch linux-4.5.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.5.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-4.5.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2016-01-22T23:04:28Z</updated>
<entry>
<title>wrappers for -&gt;i_mutex access</title>
<updated>2016-01-22T23:04:28Z</updated>
<author>
<name>Al Viro</name>
</author>
<published>2016-01-22T20:40:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5955102c9984fa081b2d570cfac75c97eecf8f3b'/>
<id>urn:sha1:5955102c9984fa081b2d570cfac75c97eecf8f3b</id>
<content type='text'>
parallel to mutex_{lock,unlock,trylock,is_locked,lock_nested},
inode_foo(inode) being mutex_foo(&amp;inode-&gt;i_mutex).

Please, use those for access to -&gt;i_mutex; over the coming cycle
-&gt;i_mutex will become rwsem, with -&gt;lookup() done with it held
only shared.

Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>ocfs2: clean up redundant NULL check before iput</title>
<updated>2016-01-15T00:00:49Z</updated>
<author>
<name>Joseph Qi</name>
</author>
<published>2016-01-14T23:17:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=72865d92300a6ad20a8851887aeac4f41fd2c579'/>
<id>urn:sha1:72865d92300a6ad20a8851887aeac4f41fd2c579</id>
<content type='text'>
Since iput will take care the NULL check itself, NULL check before
calling it is redundant.  So clean them up.

Signed-off-by: Joseph Qi &lt;joseph.qi@huawei.com&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.de&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: neaten do_error, ocfs2_error and ocfs2_abort</title>
<updated>2015-09-04T23:54:41Z</updated>
<author>
<name>Joe Perches</name>
</author>
<published>2015-09-04T22:44:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7ecef14ab1db961545354fa443749aeda2ea1b75'/>
<id>urn:sha1:7ecef14ab1db961545354fa443749aeda2ea1b75</id>
<content type='text'>
These uses sometimes do and sometimes don't have '\n' terminations.  Make
the uses consistently use '\n' terminations and remove the newline from
the functions.

Miscellanea:

o Coalesce formats
o Realign arguments

Signed-off-by: Joe Perches &lt;joe@perches.com&gt;
Reviewed-by: Mark Fasheh &lt;mfasheh@suse.de&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: fix possible uninitialized variable access</title>
<updated>2015-04-14T23:48:58Z</updated>
<author>
<name>Joseph Qi</name>
</author>
<published>2015-04-14T22:43:33Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=023d4ea358494ccfeb37abfe5b0fd01b45a6051c'/>
<id>urn:sha1:023d4ea358494ccfeb37abfe5b0fd01b45a6051c</id>
<content type='text'>
In ocfs2_local_alloc_find_clear_bits and ocfs2_get_dentry, variable
numfound and set may be uninitialized and then used in tracepoint.  In
ocfs2_xattr_block_get and ocfs2_delete_xattr_in_bucket, variable block_off
and xv may be uninitialized and then used in the following logic due to
unchecked return value.

This patch fixes these possible issues.

Signed-off-by: Joseph Qi &lt;joseph.qi@huawei.com&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: fix typo in ocfs2_reserve_local_alloc_bits</title>
<updated>2015-04-14T23:48:57Z</updated>
<author>
<name>Joseph Qi</name>
</author>
<published>2015-04-14T22:43:16Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d0ba25b905ba1246d04578cd59df83014e9b9152'/>
<id>urn:sha1:d0ba25b905ba1246d04578cd59df83014e9b9152</id>
<content type='text'>
In ocfs2_reserve_local_alloc_bits, it calls ocfs2_error if local alloc
inode bitmap used bits mismatch, but the log mistakes it as free bits.

Signed-off-by: Joseph Qi &lt;joseph.qi@huawei.com&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: free allocated clusters if error occurs after ocfs2_claim_clusters</title>
<updated>2014-02-06T21:48:51Z</updated>
<author>
<name>Zongxun Wang</name>
</author>
<published>2014-02-06T20:04:20Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=fb951eb5e167de9f07973ce0dfff674a2019bfab'/>
<id>urn:sha1:fb951eb5e167de9f07973ce0dfff674a2019bfab</id>
<content type='text'>
Even if using the same jbd2 handle, we cannot rollback a transaction.
So once some error occurs after successfully allocating clusters, the
allocated clusters will never be used and it means they are lost.  For
example, call ocfs2_claim_clusters successfully when expanding a file,
but failed in ocfs2_insert_extent.  So we need free the allocated
clusters if they are not used indeed.

Signed-off-by: Zongxun Wang &lt;wangzongxun@huawei.com&gt;
Signed-off-by: Joseph Qi &lt;joseph.qi@huawei.com&gt;
Acked-by: Joel Becker &lt;jlbec@evilplan.org&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Cc: Li Zefan &lt;lizefan@huawei.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: ac_bits_wanted should be local_alloc_bits when returns -ENOSPC</title>
<updated>2013-09-11T22:56:31Z</updated>
<author>
<name>Younger Liu</name>
</author>
<published>2013-09-11T21:19:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7e9b79370733945b25c24e09d663b07c3936d10c'/>
<id>urn:sha1:7e9b79370733945b25c24e09d663b07c3936d10c</id>
<content type='text'>
There is an issue in reserving and claiming space for localalloc, When
localalloc space is not enough, it would claim space from global_bitmap.
And if there is not enough free space in global_bitmap, the size of
claiming space would set to half of orignal size and retry.

The issue is as follows: osb-&gt;local_alloc_bits is set to half of orignal
size in ocfs2_recalc_la_window(), but ac-&gt;ac_bits_wanted is set to
osb-&gt;local_alloc_default_bits which is not changed.  localalloc always
reserves and claims local_alloc_default_bits space and returns ENOSPC.

So, ac-&gt;ac_bits_wanted should be osb-&gt;local_alloc_bits which would be
changed.

Signed-off-by: Younger Liu &lt;younger.liu@huawei.com&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Cc: Jeff Liu &lt;jeff.liu@oracle.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: remove kfree() redundant null checks</title>
<updated>2013-02-22T01:22:19Z</updated>
<author>
<name>Tim Gardner</name>
</author>
<published>2013-02-22T00:42:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d787ab0977c58e2c421b8d0ab49e363893ddb814'/>
<id>urn:sha1:d787ab0977c58e2c421b8d0ab49e363893ddb814</id>
<content type='text'>
smatch analysis indicates a number of redundant NULL checks before
calling kfree(), eg:

  fs/ocfs2/alloc.c:6138 ocfs2_begin_truncate_log_recovery() info:
   redundant null check on *tl_copy calling kfree()

  fs/ocfs2/alloc.c:6755 ocfs2_zero_range_for_truncate() info:
   redundant null check on pages calling kfree()

etc....

[akpm@linux-foundation.org: revert dubious change in ocfs2_begin_truncate_log_recovery()]
Signed-off-by: Tim Gardner &lt;tim.gardner@canonical.com&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Acked-by: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: use memweight()</title>
<updated>2012-07-31T00:25:16Z</updated>
<author>
<name>Akinobu Mita</name>
</author>
<published>2012-07-30T21:41:03Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a75613ec73ec87726a81fe421385a13c25fdcfc4'/>
<id>urn:sha1:a75613ec73ec87726a81fe421385a13c25fdcfc4</id>
<content type='text'>
Use memweight to count the total number of bits set in memory area.

Signed-off-by: Akinobu Mita &lt;akinobu.mita@gmail.com&gt;
Cc: Mark Fasheh &lt;mfasheh@suse.com&gt;
Cc: Joel Becker &lt;jlbec@evilplan.org&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>ocfs2: Remove DISK_ALLOC from masklog.</title>
<updated>2011-02-22T00:01:27Z</updated>
<author>
<name>Tao Ma</name>
</author>
<published>2011-02-22T00:01:27Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=81bad69749623062fae2f94e2d98dd43d95a36f4'/>
<id>urn:sha1:81bad69749623062fae2f94e2d98dd43d95a36f4</id>
<content type='text'>
Since all 4 files, localalloc.c, suballoc.c, alloc.c and
resize.c, which use DISK_ALLOC are changed to trace events,
Remove masklog DISK_ALLOC totally.

Signed-off-by: Tao Ma &lt;boyu.mt@taobao.com&gt;
</content>
</entry>
</feed>
