Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp4177240ybl; Mon, 26 Aug 2019 06:41:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqxhygRemacAzGxbEScjTOAiTCbHD3wHSy9hWJ2smQs/j5upQ+gBTGOqL3vKQZKLETyWdrEX X-Received: by 2002:a62:e401:: with SMTP id r1mr20836435pfh.193.1566826910616; Mon, 26 Aug 2019 06:41:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566826910; cv=none; d=google.com; s=arc-20160816; b=Fd5dVLm/jlDc+8aXMw5wN7/jR/3C9goYWSd5LL2bAjBi+IXncQsNYz7LMIIYQwGonq 1hRjDcmQJvZHNCAmZcfjuGu1h6SxzMO0ihfVA2SxZ2OsB6dPNU4TNRJuQk9MWoKmLvOm P9L+0HeXtHPDX2UNY0lQBpDYEflnEdf9+IysNnkJwX7Lo7ZbSMt/ksvpjpj56laTneGI oDW84IMAI9CG0IvHoAIvrhjzhRw6PnRy7xMARRcO6J9DY7qhZqh5BeRikwXdx1E1R1pU Plnxv313SoV7MVToly8qgmiOpGj4ystxch3j6XCKvfJ0wQxq9sbCRWhiEtx6PyOS31Cb 4wVg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=6Pmx/IvDTWpkHHd/Ids6bGyz8bzIy12B5WHtmGogoSI=; b=0dV2iJ8F93Sh9Fmmxrz5nPk4CEpPb7neULaXeJn22H/+qzohiOI0OVSHOxb8k8tKJ/ IqTDMEAQq6a80+q1tKS8iiHoQOMcgPMUpGD1EuTTqv1IHbMeRQwAwkjBbSSdunIWkCcP ZSeoPkY3b4U6P5fnvOcxCKmPnTR9gC4aq/eCdutTeN6oOvVLw7Y8SOx1NuIGJ5YTP/MG GBqdZlQiiqmGZZQFP6VEN64mqiI3OepM12lzDj7ZyhZZWfMGXQYo1HfmRSLmcuRZ9nyn hM1Um74E2aWVo9dHWY/PsqL28PmAjlj4EDyb7110vg+aUIk60jUeuOoLu4wXHDZGCOQy 3fPA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p2si1326417plr.53.2019.08.26.06.41.25; Mon, 26 Aug 2019 06:41:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-nfs-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-nfs-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728922AbfHZNjv (ORCPT + 99 others); Mon, 26 Aug 2019 09:39:51 -0400 Received: from fieldses.org ([173.255.197.46]:46568 "EHLO fieldses.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728862AbfHZNjv (ORCPT ); Mon, 26 Aug 2019 09:39:51 -0400 Received: by fieldses.org (Postfix, from userid 2815) id 112331CB3; Mon, 26 Aug 2019 09:39:51 -0400 (EDT) Date: Mon, 26 Aug 2019 09:39:51 -0400 From: "J. Bruce Fields" To: Alex Lyakas Cc: chuck.lever@oracle.com, linux-nfs@vger.kernel.org, Shyam Kaushik Subject: Re: [RFC-PATCH] nfsd: when unhashing openowners, increment openowner's refcount Message-ID: <20190826133951.GC22759@fieldses.org> References: <1566406146-7887-1-git-send-email-alex@zadara.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org On Sun, Aug 25, 2019 at 01:12:34PM +0300, Alex Lyakas wrote: > You are listed as maintainers of nfsd. Can you please take a look at > the below patch? Thanks! I take it this was found by some kind of code analysis or fuzzing, not use in production? Asking because I've been considering just deprecating it, so: > > After we fixed this, we confirmed that the openowner is not freed > > prematurely. It is freed by release_openowner() final call > > to nfs4_put_stateowner(). > > > > However, we still get (other) random crashes and memory corruptions > > when nfsd_inject_forget_client_openowners() and > > nfsd_inject_forget_openowners(). > > According to our analysis, we don't see any other refcount issues. > > Can anybody from the community review these flows for other potentials issues? I'm wondering how much effort we want to put into tracking all that down. --b.