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-next>] [day] [month] [year] [list]
Date:   Sat,  1 Feb 2020 15:12:58 +0800
From:   qiwuchen55@...il.com
To:     mark@...heh.com, jlbec@...lplan.org, joseph.qi@...ux.alibaba.com,
        trivial@...nel.org
Cc:     ocfs2-devel@....oracle.com, linux-kernel@...r.kernel.org,
        chenqiwu <chenqiwu@...omi.com>
Subject: [PATCH] ocfs2: remove trivial nowait check for buffered read/write

From: chenqiwu <chenqiwu@...omi.com>

Remove trivial nowait check for buffered read/write, since
buffered read is checked in generic_file_read_iter()->
generic_file_buffered_read(), buffered write is checked in
generic_write_checks().

Signed-off-by: chenqiwu <chenqiwu@...omi.com>
---
 fs/ocfs2/file.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c
index 9876db5..6a5e3b0 100644
--- a/fs/ocfs2/file.c
+++ b/fs/ocfs2/file.c
@@ -2298,9 +2298,6 @@ static ssize_t ocfs2_file_write_iter(struct kiocb *iocb,
 		file->f_path.dentry->d_name.name,
 		(unsigned int)from->nr_segs);	/* GRRRRR */
 
-	if (!direct_io && nowait)
-		return -EOPNOTSUPP;
-
 	if (count == 0)
 		return 0;
 
@@ -2453,9 +2450,6 @@ static ssize_t ocfs2_file_read_iter(struct kiocb *iocb,
 		goto bail;
 	}
 
-	if (!direct_io && nowait)
-		return -EOPNOTSUPP;
-
 	/*
 	 * buffered reads protect themselves in ->readpage().  O_DIRECT reads
 	 * need locks to protect pending reads from racing with truncate.
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ