Hi Greg,
On Sat, Jan 13, 2024 at 10:50:39AM +0100, Greg Kroah-Hartman wrote:
6.1-stable review patch. If anyone has any objections, please let me know.
filemap_get_folio works differenty in 6.1 vs. later kernels (returning NULL in 6.1 instead of an error). Add this minor correction which addresses the regression in the patch: cifs: Fix flushing, invalidation and file size with copy_file_range()
Suggested-by: David Howells dhowells@redhat.com Reported-by: Salvatore Bonaccorso carnil@debian.org Signed-off-by: Steve French stfrench@microsoft.com Tested-by: Salvatore Bonaccorso carnil@debian.org Signed-off-by: Greg Kroah-Hartman gregkh@linuxfoundation.org
fs/smb/client/cifsfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/smb/client/cifsfs.c +++ b/fs/smb/client/cifsfs.c @@ -1240,7 +1240,7 @@ static int cifs_flush_folio(struct inode int rc = 0; folio = filemap_get_folio(inode->i_mapping, index);
- if (IS_ERR(folio))
- if ((!folio) || (IS_ERR(folio))) return 0;
size = folio_size(folio);
Note, this one needs to be revisited:
https://lore.kernel.org/stable/ZaLNlyo8cDCpATPm@casper.infradead.org/T/#md6a...
Regards, Salvatore