[PATCH][TRIVIAL] ceph: Add comments for ENOENT which returned from osd.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The error ENOENT from osd has special meaning.It means the data of
read-area are all-zero.In order to reduce the flow between client and
osd, it used this method.

Signed-off-by: Jianpeng Ma <majianpeng@xxxxxxxxx>
---
 fs/ceph/file.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/fs/ceph/file.c b/fs/ceph/file.c
index 2ddf061..81a9dfc 100644
--- a/fs/ceph/file.c
+++ b/fs/ceph/file.c
@@ -342,6 +342,11 @@ more:
 				  ci->i_truncate_seq,
 				  ci->i_truncate_size,
 				  page_pos, pages_left, page_align);
+	/*
+	 * This error is return from osd.It means the read-area is allzero.
+	 * So in order to reduce the flow,it return this value the reciver
+	 * should fill zero.
+	 */
 	if (ret == -ENOENT)
 		ret = 0;
 	hit_stripe = this_len < left;
-- 
1.8.1.2

Thanks!
Jianpeng Ma?韬{.n?????%??檩??w?{.n????u朕?Ф?塄}?财??j:+v??????2??璀??摺?囤??z夸z罐?+?????w棹f





[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux