Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp105365ybk; Fri, 8 May 2020 15:17:16 -0700 (PDT) X-Google-Smtp-Source: APiQypIKEeV1EfQnwQvVHJ5Pcldnf9ZYtAnYfAgoIM1dar27Y7WIEb4jKA5VOXnzE7DsG6r/WHjN X-Received: by 2002:aa7:d455:: with SMTP id q21mr4003110edr.235.1588976236382; Fri, 08 May 2020 15:17:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588976236; cv=none; d=google.com; s=arc-20160816; b=FJ3K2f0Q2vAq+jOU8DuUKc3Srduu5AWMTx7Nv56F+BrXLN53fiQ1hA6FEClDNQXTxa pov3hkhlxL+/4inHFCLoy97YZyjuXN+Jj93k1we73xnUeieS4XL/nhnG8NduzuE9ZQtN LuzPM90SImGHWBhzPX59r2fBSnKlP1QennJoAyUCGO5564IhUDnQYYygWZ1cZbvK1oea RsG4WqinEzUgR/KJt/C2NdKCcP9LvP92A6xVza9PEl1zD2M+htXJxst5CSDHbwNOzIB3 DhTBZo7ZysZVFGQdC/KBd8pqNFngXpFMdLsgkB6wKj+KOn1cVILWVErzPpfOlNhhPMYl 09Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:message-id:date:cc:to:from:subject:dkim-signature; bh=WtlaW23JDJ9HL5V5AbxLYLZIsw33KhJwstUsDfJ8CX0=; b=ynRw3y1a8q9MbWSPY7uxhj8kiwfv8Yo0j4oDjFlliqIRVB44Ek3TcWRZfGskjNcnMI ivZMcorJESUBwRtkKzzb+RpqYuTCr328RhrlbOzun+VyKuC+osSI8uKRLzdh4CasP/CH OS6MXlbrPkWzHd10rT8YiMyHgx4oMh6VmQa3tpDxTJmHjOXbKPMf0hNqPrjKG+EWYAns c4xvdxP8HMTaywKMxZgFBuRAPIDkQeQq6jpBJIYBC7Tz4Jy1rkTKkT19efM2p5jnl21g QPb5ACLyFMvR73Mg8JgSd7BGm8hNm6Me99pJRXl8b76qRW82TtoHInYZEZBUgwk2ljCN HHNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=XrtDG9qy; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dn16si1884819edb.488.2020.05.08.15.16.50; Fri, 08 May 2020 15:17:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=XrtDG9qy; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727838AbgEHWQs (ORCPT + 99 others); Fri, 8 May 2020 18:16:48 -0400 Received: from us-smtp-delivery-1.mimecast.com ([205.139.110.120]:40356 "EHLO us-smtp-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727787AbgEHWQr (ORCPT ); Fri, 8 May 2020 18:16:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1588976207; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=WtlaW23JDJ9HL5V5AbxLYLZIsw33KhJwstUsDfJ8CX0=; b=XrtDG9qyA42aNySEKcseGad5n9RGf7AujvmLKbvsYE0UHm//ZSOe8KWNxk33j5YFof9XNo uztO83mQ7gdE0tCwzbzo1ygABJGdA+MUidgi52Q1Rcnq6cpVlAQ7CzxdQzp9Mbb6/KTWPj qPcrZCd1azi+4r4TAJlEyWjytO+sQMs= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-174--VLbbYq4OZqQqAlSytfzBw-1; Fri, 08 May 2020 18:16:45 -0400 X-MC-Unique: -VLbbYq4OZqQqAlSytfzBw-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 71E9C107ACCD; Fri, 8 May 2020 22:16:44 +0000 (UTC) Received: from warthog.procyon.org.uk (ovpn-118-225.rdu2.redhat.com [10.10.118.225]) by smtp.corp.redhat.com (Postfix) with ESMTP id 928776AD09; Fri, 8 May 2020 22:16:37 +0000 (UTC) Subject: [PATCH 0/5] cachefiles, nfs: Fixes From: David Howells To: torvalds@linux-foundation.org, Trond Myklebust Cc: Lei Xue , Dave Wysochanski , David Wysochanski , Carlos Maiolino , dhowells@redhat.com, Anna Schumaker , linux-nfs@vger.kernel.org, linux-cachefs@redhat.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Date: Fri, 08 May 2020 23:16:36 +0100 Message-ID: <158897619675.1119820.2203023452686054109.stgit@warthog.procyon.org.uk> User-Agent: StGit/0.21 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org Hi Linus, Trond, Anna, Can you pull these fixes for cachefiles and NFS's use of fscache? Should they go through the NFS tree or directly upstream? The things fixed are: (1) The reorganisation of bmap() use accidentally caused the return value of cachefiles_read_or_alloc_pages() to get corrupted. (2) The NFS superblock index key accidentally got changed to include a number of kernel pointers - meaning that the key isn't matchable after a reboot. (3) A redundant check in nfs_fscache_get_super_cookie(). (4) The NFS change_attr sometimes set in the auxiliary data for the caching of an file and sometimes not, which causes the cache to get discarded when it shouldn't. (5) There's a race between cachefiles_read_waiter() and cachefiles_read_copier() that causes an occasional assertion failure. The patches are tagged here: git://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git tag fscache-fixes-20200508-2 Thanks, David --- Dave Wysochanski (3): NFS: Fix fscache super_cookie index_key from changing after umount NFS: Fix fscache super_cookie allocation NFSv4: Fix fscache cookie aux_data to ensure change_attr is included David Howells (1): cachefiles: Fix corruption of the return value in cachefiles_read_or_alloc_pages() Lei Xue (1): cachefiles: Fix race between read_waiter and read_copier involving op->to_do fs/cachefiles/rdwr.c | 12 ++++++------ fs/nfs/fscache.c | 39 ++++++++++++++++++--------------------- fs/nfs/super.c | 1 - 3 files changed, 24 insertions(+), 28 deletions(-)