CIFS: Fix wrong restart readdir for SMB1
Subsystems (2)
PATCH v2 1/1 CIFS: Fix wrong restart readdir for SMB1
The existing code calls server->ops->close() that is not right. This causes XFS test generic/310 to fail. Fix this by using server->ops->closedir() function.
Cc <[email protected]> # v3.7+
Signed-off-by Dan Carpenter <[email protected]>
Signed-off-by Pavel Shilovsky <[email protected]>
--- fs/cifs/readdir.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/cifs/readdir.c +2 -2
@@ -596,8 +596,8 @@ find_cifs_entry(const unsigned int xid, struct cifs_tcon *tcon, loff_t pos,if (server->ops->dir_needs_close (cfile)) { cfile->invalidHandle = true;spin_unlock (&cifs_file_list_lock); -if (server->ops->close) - server->ops->close (xid, tcon, &cfile->fid); +if (server->ops->close_dir) + server->ops->close_dir (xid, tcon, &cfile->fid); }else spin_unlock (&cifs_file_list_lock);if (cfile->srch_inf.ntwrk_buf_start) {
Signature · 1 line
1.9.1
Steve French
Appliedmerged into cifs-2.6.git for-next
Quoted 33 lines · Pavel Shilovsky
The existing code calls
server->ops->close()that is not right. This causes XFS test generic/310 to fail. Fix this by usingserver->ops->closedir()function.Cc <[email protected]> # v3.7+Signed-off-by Dan Carpenter <[email protected]>Signed-off-by Pavel Shilovsky <[email protected]>--- fs/cifs/readdir.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)fs/cifs/readdir.c +2
-3@@ -596,8 +596,8 @@ find_cifs_entry(const unsigned int xid, struct cifs_tcon *tcon, loff_t pos,if (server->ops->dir_needs_close (cfile)) { cfile->invalidHandle = true;spin_unlock (&cifs_file_list_lock); -if (server->ops->close) - server->ops->close (xid, tcon, &cfile->fid); +if (server->ops->close_dir) + server->ops->close_dir (xid, tcon, &cfile->fid); }else spin_unlock (&cifs_file_list_lock);if (cfile->srch_inf.ntwrk_buf_start) { --1.9.1
--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 3 lines
Thanks, Steve