Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp2073337rwb; Thu, 17 Nov 2022 06:15:34 -0800 (PST) X-Google-Smtp-Source: AA0mqf4veThEUwsOnQ8QqgtT/qYScOSEbCkBgQBT/HAuoPuZuiB7Irrjyq8Kc238fbMbExd2e80Z X-Received: by 2002:a50:fd81:0:b0:461:a09b:aaf2 with SMTP id o1-20020a50fd81000000b00461a09baaf2mr2289296edt.328.1668694534276; Thu, 17 Nov 2022 06:15:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668694534; cv=none; d=google.com; s=arc-20160816; b=eQ9IGkwhZPeOcoXXraj1V/mP2F2I/ys3VL37l4yC+tFYLz6+mgsu8k0lhAYu5BHPep JNE3hZDVrWQ+wNdmiGQZywl2BS6iVstdyAiLxxxbpFY7lbK/0SmP3yH+v7Atq+Orx2f0 3wttm8ZLENnAwvVjbhRAaHpFZ/B6oJec7mSWl7mb+za74U+Z2onCgC8C9mliIXBWUFsn z8NLiXLc027L847AuAEfExvmeI0mQulbAFUAKecYW9FDaft0mDElSuYmCngU5hYzfSSO 8R8iNbfNDq0tWrf4yVxjjmtjPlfUiV1pXQxM+V7hkNUtL4adLiEtlPgnTIwTclTE3Cau PWaw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=wpo0rn1pBCjCV4bU+0IiTD80Tf+UEqnfeMIwfEX23AY=; b=iSJYKbQKw43coVBrqCfJ0TmGdKpLuADClX4C+s6cq/38x85LOzWvc48M/zmRKbHTwi +v2mq4aVy//pJZaRW/ruX48rev23Ft+e9RsLoBLuit4Y/4r78BIfED3tf9KkPu8FzkjM onzvax3XN9wcGYP9QW4b8StHuCvyN10W/QpURlbXMceevYw0Xvx2QUqWndCYofkE+AQL 2Xe14rL+y4Sy/pFA3GhbRyD6D3LyC2325GU57YRrz0VMujd7qtU2C93t6u+mKsmDUf0u lK3e8DmYG+/Z/b9oqVUPTx4plURIFMHUlret8htinfE+fu3ads1W7nGpHwKtWCDb11q9 X8uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ihPb6V73; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id ne25-20020a1709077b9900b007418e87eea8si671045ejc.770.2022.11.17.06.15.00; Thu, 17 Nov 2022 06:15:34 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=ihPb6V73; spf=pass (google.com: domain of linux-nfs-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S234854AbiKQOMi (ORCPT + 99 others); Thu, 17 Nov 2022 09:12:38 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45100 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234421AbiKQOMg (ORCPT ); Thu, 17 Nov 2022 09:12:36 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2696C76164 for ; Thu, 17 Nov 2022 06:11:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1668694296; 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: in-reply-to:in-reply-to:references:references; bh=wpo0rn1pBCjCV4bU+0IiTD80Tf+UEqnfeMIwfEX23AY=; b=ihPb6V73FOF4XIjvvVDz5ox2qGkkFSSsWrzSPvrc3IeR4ZlgzHpHdIVSzWlN9jmrDHhp2v c6j5caJXHdTDStzzBYBl5ThPxdFyQRE3kV37CfG3IavGk+3/OWZFRXGyN7PMpSzzLs5LrV q6RdNvyYjEavQe/T7A2Aa4BfeXpaRaM= Received: from mail-pl1-f197.google.com (mail-pl1-f197.google.com [209.85.214.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-354-ez0yF1WuOIWI2kU2pUt1Bw-1; Thu, 17 Nov 2022 09:11:35 -0500 X-MC-Unique: ez0yF1WuOIWI2kU2pUt1Bw-1 Received: by mail-pl1-f197.google.com with SMTP id x18-20020a170902ec9200b001869f20da7eso1483503plg.10 for ; Thu, 17 Nov 2022 06:11:35 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=wpo0rn1pBCjCV4bU+0IiTD80Tf+UEqnfeMIwfEX23AY=; b=aWvnrJgjkDJPUKCXPtZpxTUcrlTC0jWZIDOC9adcr3dGH2201XsmlkH7XSlNJRkiXE mqaSfDhmomjtSh2XsEszHlQ8MRMnFbiChe/ZOzeDREBBLBw2l2z1dXhq77TWyh9arFZx Dt79E3/+Knuz1nZFxsGB0iqo5fRyE8TlE7pJ4t6XsMK7cuIzKtNy94kKCIv43aBdX8Fv KLVTZ9Fxv1ZEqtXe+ezkDxxmcc7pIxqVmj7+TTL8jEhHFui+mLcVYH1K6mfMcj0Bbb7M CPh66yOCjCZs1DK/zbxiB7eg82YAo2/iXHiqVd6hllo/KDOI+l1VZf+QX0MtNnWJYxMf z46w== X-Gm-Message-State: ANoB5pnaWnWKFAPpnky8GYOuLVoSsrWN1QQ8v15KjCOio6aHz1+i4myA yrXehxy/52ukBwEiNeIzFvCyTiFYb60Bwj1yx1yXAAH3ZDbhweR5XMs/F37i1mRiJQYkcV8IK66 EZz71QFLfd0XhvpxJMtCwaDap4DvgajQEUVOs X-Received: by 2002:a17:903:2448:b0:188:f5c7:4d23 with SMTP id l8-20020a170903244800b00188f5c74d23mr1251321pls.125.1668694293609; Thu, 17 Nov 2022 06:11:33 -0800 (PST) X-Received: by 2002:a17:903:2448:b0:188:f5c7:4d23 with SMTP id l8-20020a170903244800b00188f5c74d23mr1251307pls.125.1668694293360; Thu, 17 Nov 2022 06:11:33 -0800 (PST) MIME-Version: 1.0 References: <20221117115023.1350181-1-dwysocha@redhat.com> <20221117115023.1350181-2-dwysocha@redhat.com> <3716830.1668693167@warthog.procyon.org.uk> In-Reply-To: <3716830.1668693167@warthog.procyon.org.uk> From: David Wysochanski Date: Thu, 17 Nov 2022 09:10:57 -0500 Message-ID: Subject: Re: [PATCH 1/1] fscache: Fix oops due to race with cookie_lru and use_cookie To: David Howells Cc: Daire Byrne , Benjamin Maynard , linux-cachefs@redhat.com, linux-nfs@vger.kernel.org Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Thu, Nov 17, 2022 at 8:52 AM David Howells wrote: > > Dave Wysochanski wrote: > > > + clear_bit(FSCACHE_COOKIE_DO_LRU_DISCARD, &cookie->flags); > > Actually, can you do test_and_clear_bit() and then log a trace point, say: > > fscache_see_cookie(cookie, fscache_cookie_see_lru_discard_cancel); > > if the bit was set. > > David > Ok sure. I will post a v2 with the trace point and the test_and_clear_bit.