• David Howells's avatar
    netfs: Don't use certain unnecessary folio_*() functions · 202bc57b
    David Howells authored
    Filesystems should use folio->index and folio->mapping, instead of
    folio_index(folio), folio_mapping() and folio_file_mapping() since
    they know that it's in the pagecache.
    
    Change this automagically with:
    
    perl -p -i -e 's/folio_mapping[(]([^)]*)[)]/\1->mapping/g' fs/netfs/*.c
    perl -p -i -e 's/folio_file_mapping[(]([^)]*)[)]/\1->mapping/g' fs/netfs/*.c
    perl -p -i -e 's/folio_index[(]([^)]*)[)]/\1->index/g' fs/netfs/*.c
    Reported-by: default avatarMatthew Wilcox <willy@infradead.org>
    Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
    cc: Jeff Layton <jlayton@kernel.org>
    cc: linux-afs@lists.infradead.org
    cc: linux-cachefs@redhat.com
    cc: linux-cifs@vger.kernel.org
    cc: linux-erofs@lists.ozlabs.org
    cc: linux-fsdevel@vger.kernel.org
    202bc57b
misc.c 6.84 KB