lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180518123415.28181-5-jlayton@kernel.org>
Date:   Fri, 18 May 2018 08:34:08 -0400
From:   Jeff Layton <jlayton@...nel.org>
To:     linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Cc:     viro@...IV.linux.org.uk, willy@...radead.org, andres@...razel.de
Subject: [RFC PATCH 04/11] vfs: add errseq_t pointer to __sync_filesystem

From: Jeff Layton <jlayton@...hat.com>

...and pass that to the sync_fs operation. Also, have __sync_filesystem
return the error from sync_fs (if there is one).

Signed-off-by: Jeff Layton <jlayton@...hat.com>
---
 fs/sync.c | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/fs/sync.c b/fs/sync.c
index fc0b7bd51ae6..c876fa414cae 100644
--- a/fs/sync.c
+++ b/fs/sync.c
@@ -28,14 +28,16 @@
  * wait == 1 case since in that case write_inode() functions do
  * sync_dirty_buffer() and thus effectively write one block at a time.
  */
-static int __sync_filesystem(struct super_block *sb, int wait)
+static int __sync_filesystem(struct super_block *sb, int wait, errseq_t *since)
 {
+	int ret = 0;
+
 	if (wait)
 		sync_inodes_sb(sb);
 	else
 		writeback_inodes_sb(sb, WB_REASON_SYNC);
 
-	return call_sync_fs(sb, wait, NULL);
+	return call_sync_fs(sb, wait, since);
 }
 
 /*
@@ -59,10 +61,10 @@ int sync_filesystem(struct super_block *sb, errseq_t *since)
 	if (sb_rdonly(sb))
 		return 0;
 
-	ret = __sync_filesystem(sb, 0);
+	ret = __sync_filesystem(sb, 0, since);
 	if (ret < 0)
 		return ret;
-	return __sync_filesystem(sb, 1);
+	return __sync_filesystem(sb, 1, since);
 }
 EXPORT_SYMBOL(sync_filesystem);
 
-- 
2.17.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ