<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BMC/Intel-BMC/linux.git/fs/ceph/caps.c, branch dev-4.17</title>
<subtitle>Intel OpenBMC Linux kernel source tree (mirror)</subtitle>
<id>https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.17</id>
<link rel='self' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.17'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/'/>
<updated>2018-04-02T09:17:53+00:00</updated>
<entry>
<title>ceph: quota: cache inode pointer in ceph_snap_realm</title>
<updated>2018-04-02T09:17:53+00:00</updated>
<author>
<name>Luis Henriques</name>
<email>lhenriques@suse.com</email>
</author>
<published>2018-01-12T17:19:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=e3161f17d92699ce6ca3b7988131b10ad4035cf9'/>
<id>urn:sha1:e3161f17d92699ce6ca3b7988131b10ad4035cf9</id>
<content type='text'>
Keep a pointer to the inode in struct ceph_snap_realm.  This allows to
optimize functions that walk the realms hierarchy (e.g. in quotas).

Signed-off-by: Luis Henriques &lt;lhenriques@suse.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: optimizing cap reservation</title>
<updated>2018-04-02T08:12:47+00:00</updated>
<author>
<name>Chengguang Xu</name>
<email>cgxu519@icloud.com</email>
</author>
<published>2018-02-24T10:36:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=79cd674aed7363a043222af3c8f97d0ea0a078cf'/>
<id>urn:sha1:79cd674aed7363a043222af3c8f97d0ea0a078cf</id>
<content type='text'>
When caps_avail_count is in a low level, most newly
trimmed caps will probably go into -&gt;caps_list and
caps_avail_count will be increased. Hence after trimming,
should recheck caps_avail_count to effectly reuse
newly trimmed caps. Also, when releasing unnecessary
caps follow the same rule of ceph_put_cap.

Signed-off-by: Chengguang Xu &lt;cgxu519@icloud.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: release unreserved caps if having enough available caps</title>
<updated>2018-04-02T08:12:47+00:00</updated>
<author>
<name>Chengguang Xu</name>
<email>cgxu519@icloud.com</email>
</author>
<published>2018-02-25T05:39:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=b517c1d87faafba0c33a38ffdd551e8b399f0a31'/>
<id>urn:sha1:b517c1d87faafba0c33a38ffdd551e8b399f0a31</id>
<content type='text'>
When unreserving caps check if there is too mamy available caps
in the -&gt;caps_list, if so release unreserved caps.

Signed-off-by: Chengguang Xu &lt;cgxu519@icloud.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: optimizing cap allocation</title>
<updated>2018-04-02T08:12:46+00:00</updated>
<author>
<name>Chengguang Xu</name>
<email>cgxu519@icloud.com</email>
</author>
<published>2018-02-24T10:35:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=e327ce068518e38c0182739e879b9dce477c8d85'/>
<id>urn:sha1:e327ce068518e38c0182739e879b9dce477c8d85</id>
<content type='text'>
When setting high volume of caps_min_count or having many
unreserved caps, unused caps may always keep in the -&gt;caps_list
even can't get new cap from kmem_cache_alloc because lack of
maximum limitation of caps_avail_count. Hence reuse caps in
-&gt;caps_list if available, it's maybe better than setting max
limitation of caps_avail_count and releasing unused caps when
reaching the limit.

Signed-off-by: Chengguang Xu &lt;cgxu519@icloud.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: adding protection for showing cap reservation info</title>
<updated>2018-04-02T08:12:46+00:00</updated>
<author>
<name>Chengguang Xu</name>
<email>cgxu519@icloud.com</email>
</author>
<published>2018-02-23T09:09:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=b884014a91a49ed0e7198d276b28887cc48363bd'/>
<id>urn:sha1:b884014a91a49ed0e7198d276b28887cc48363bd</id>
<content type='text'>
Adding spinlock protection during getting cap reservation
ralated fields so that the numbers match below BUG_ON condition
in the code.

BUG_ON(mdsc-&gt;caps_total_count != mdsc-&gt;caps_use_count +
				 mdsc-&gt;caps_reserve_count +
				 mdsc-&gt;caps_avail_count);

Signed-off-by: Chengguang Xu &lt;cgxu519@icloud.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: flush dirty caps of unlinked inode ASAP</title>
<updated>2018-02-26T15:19:16+00:00</updated>
<author>
<name>Zhi Zhang</name>
<email>zhang.david2011@gmail.com</email>
</author>
<published>2018-01-24T13:24:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=6ef0bc6ddee1f62310877a1d53b1ea1d0d8e51a2'/>
<id>urn:sha1:6ef0bc6ddee1f62310877a1d53b1ea1d0d8e51a2</id>
<content type='text'>
Client should release unlinked inode from its cache ASAP. But client
can't release inode with dirty caps.

Link: http://tracker.ceph.com/issues/22886
Signed-off-by: Zhi Zhang &lt;zhang.david2011@gmail.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: improving efficiency of syncfs</title>
<updated>2018-01-30T20:10:15+00:00</updated>
<author>
<name>Chengguang Xu</name>
<email>cgxu519@icloud.com</email>
</author>
<published>2018-01-30T02:02:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=16515a6d54183349b858b9c05e483afc55fa7948'/>
<id>urn:sha1:16515a6d54183349b858b9c05e483afc55fa7948</id>
<content type='text'>
write_inode() could be called variety of reasons, in the case of syncfs(2)
there is no need to wait for flush getting completed in write_inode(),
-&gt;sync_fs is for guaranteeing flush completion for all inodes at that point.

Signed-off-by: Chengguang Xu &lt;cgxu519@icloud.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: try to allocate enough memory for reserved caps</title>
<updated>2018-01-29T17:36:12+00:00</updated>
<author>
<name>Zhi Zhang</name>
<email>zhang.david2011@gmail.com</email>
</author>
<published>2018-01-24T13:24:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=e30ee58121e34831b9665934d70dbc72ab0fe2fb'/>
<id>urn:sha1:e30ee58121e34831b9665934d70dbc72ab0fe2fb</id>
<content type='text'>
ceph_reserve_caps() may not reserve enough caps under high memory
pressure, but it saved the needed caps number that expected to
be reserved. When getting caps, crash would happen due to number
mismatch.

Now we will try to trim more caps when failing to allocate memory
for caps need to be reserved, then try again. If still failing to
allocate memory, return -ENOMEM.

Signed-off-by: Zhi Zhang &lt;zhang.david2011@gmail.com&gt;
Reviewed-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: fix race of queuing delayed caps</title>
<updated>2018-01-29T17:36:11+00:00</updated>
<author>
<name>Yan, Zheng</name>
<email>zyan@redhat.com</email>
</author>
<published>2018-01-08T06:44:10+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=0f439c746c8cb370ce3ae1668182b18a5cb12b14'/>
<id>urn:sha1:0f439c746c8cb370ce3ae1668182b18a5cb12b14</id>
<content type='text'>
When called with CHECK_CAPS_AUTHONLY flag, ceph_check_caps() only
processes auth caps. In that case, it's unsafe to remove inode
from mdsc-&gt;cap_delay_list, because there can be delayed non-auth
caps.

Besides, ceph_check_caps() may lock/unlock i_ceph_lock several
times, when multiple threads call ceph_check_caps() at the same
time. It's possible that one thread calls __cap_delay_requeue(),
another thread calls __cap_delay_cancel(). __cap_delay_cancel()
should be called at very beginning of ceph_check_caps(), so that
it does not race with __cap_delay_requeue().

Signed-off-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
<entry>
<title>ceph: delete unreachable code in ceph_check_caps()</title>
<updated>2018-01-29T17:36:11+00:00</updated>
<author>
<name>Yan, Zheng</name>
<email>zyan@redhat.com</email>
</author>
<published>2018-01-08T06:36:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=ee612d954fe96612afaa966d8a67b736ba0c571e'/>
<id>urn:sha1:ee612d954fe96612afaa966d8a67b736ba0c571e</id>
<content type='text'>
"revoking &amp; (CEPH_CAP_FILE_CACHE|CEPH_CAP_FILE_LAZYIO)" has already
been tested before calling try_nonblocking_invalidate()

Signed-off-by: "Yan, Zheng" &lt;zyan@redhat.com&gt;
Signed-off-by: Ilya Dryomov &lt;idryomov@gmail.com&gt;
</content>
</entry>
</feed>
