Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
cifs: bugfix for unreclaimed writeback pages in cifs_writev_requeue()
Pages get the PG_writeback flag set before cifs sends its request to SMB server in cifs_writepages(), if the SMB service goes down, cifs may try to recommit the writing requests in cifs_writev_requeue(). However, it does not clean its PG_writeback flag and relaimed the pages even if it fails again in cifs_writev_requeue(), which may lead to the hanging of the processes accessing the cifs directory. This patch just cleans the PG_writeback flags and reclaims the pages under that circumstances. Steps to reproduce the bug(trying serveral times may trigger the issue): 1.Write from cifs client continuously.(e.g dd if=/dev/zero of=<cifs file>) 2.Stop SMB service from server.(e.g service smb stop) 3.Wait for two minutes, and then start SMB service from server.(e.g service smb start) 4.The processes which are accessing cifs directory may hang up. Signed-off-by: Ouyang Maochun <[email protected]> Signed-off-by: Jiang Yong <[email protected]> Tested-by: Zhang Xianwei <[email protected]> Reviewed-by: Wang Liang <[email protected]> Reviewed-by: Cai Qu <[email protected]> Reviewed-by: Jiang Biao <[email protected]> Reviewed-by: Jeff Layton <[email protected]> Reviewed-by: Pavel Shilovsky <[email protected]> Signed-off-by: Steve French <[email protected]>
- Loading branch information