Pavel Shilovsky 6dfbd84684 CIFS: Fix read after write for files with read caching
When we have a READ lease for a file and have just issued a write
operation to the server we need to purge the cache and set oplock/lease
level to NONE to avoid reading stale data. Currently we do that
only if a write operation succedeed thus not covering cases when
a request was sent to the server but a negative error code was
returned later for some other reasons (e.g. -EIOCBQUEUED or -EINTR).
Fix this by turning off caching regardless of the error code being
returned.

The patches fixes generic tests 075 and 112 from the xfs-tests.

Cc: <stable@vger.kernel.org>
Signed-off-by: Pavel Shilovsky <pshilov@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
2019-03-05 18:10:51 -06:00
..
2018-06-12 16:19:22 -07:00
2018-12-28 10:05:58 -06:00
2018-12-28 10:13:11 -06:00
2019-03-04 20:05:34 -06:00
2018-12-28 10:05:58 -06:00
2018-08-07 14:15:41 -05:00
2019-03-05 18:10:28 -06:00
2012-07-24 10:25:13 -05:00
2018-07-05 13:48:24 -05:00
2019-01-24 09:37:33 -06:00
2013-09-08 14:54:24 -05:00