Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp1592749yba; Fri, 17 May 2019 01:46:33 -0700 (PDT) X-Google-Smtp-Source: APXvYqx6RpURvBC9gDYjEuOHCY/WS7rx4L1iuVANZEd14pcVGDIGHW2VykK44WtpzjSH1udIwKfq X-Received: by 2002:a17:902:7883:: with SMTP id q3mr55134761pll.60.1558082793701; Fri, 17 May 2019 01:46:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558082793; cv=none; d=google.com; s=arc-20160816; b=r9nzOtTRGdbb4XLGrK7ORnix+4cPGN9UtaznHvCtRMdsVyuS5volz0gYiO7CAoQjy4 1PhwIWaBRTbF3nsE2aik2VN6YTJa3PvXaT5mD2xLfsIUqEbtqUYiwmiKGcqI9M1+4LRZ uAG9z6HlePv/YMU0sAfEum6qIMD55dYde/AFAH/giuG3XBT6UalHOdOLG5lLU+C4lHGd nLUJ3Rpb/57tgXco9ct1V3wOno5lFR8tSuFpHhbhOdZNSw+QsfTzbY+pcmJwSqdhmLlu lHVvyJLcbjI7yCp/FrB2Jp0uaeVMZgeCgTBUhECpSVPcQcUghfh4YZJMv3f29Cg9HhWR qJlw== 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=GQ8GwssI0ypvQ6PTO5TR2xA6RGJpzBuZ32mGtNqCpuI=; b=VyVEujxVpvXBphNqFRXBpg9KMstheXMJfiPEs/d16gsJ3r5yFChk4ay+NzJvwZImuf oJdVBPxQhUCWgaRp8s897/KStm63zTdICKzHCl1sVXhwilhQyUMeeNCjcWWuf/wPF9E4 Vw8NUBZW5MmeiHIcT9D23yspHP8o/JEORF+yC6YjM4nLQ5VEHMBCtRpmTDcbFlBEvj2Y KeLa8SevsFp/S18fVOOtNoyXnIktQ+l4KXccDiTS8+z2m6x8olOf0VhbB+wpWG37tAtv qq9XKUzBK/oalDhh42VXZbX5C4svxKsKxFs1xKzRcorZQhihaozwZ5MZtZRCrcL1CDBy jq6A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-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 n21si7372300pgv.105.2019.05.17.01.46.18; Fri, 17 May 2019 01:46:33 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728337AbfEQIXe (ORCPT + 99 others); Fri, 17 May 2019 04:23:34 -0400 Received: from verein.lst.de ([213.95.11.211]:36119 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726893AbfEQIXe (ORCPT ); Fri, 17 May 2019 04:23:34 -0400 Received: by newverein.lst.de (Postfix, from userid 2407) id D286D68B02; Fri, 17 May 2019 10:23:12 +0200 (CEST) Date: Fri, 17 May 2019 10:23:12 +0200 From: Christoph Hellwig To: stummala@codeaurora.org Cc: Junxiao Bi , Joel Becker , Christoph Hellwig , Al Viro , linux-kernel@vger.kernel.org Subject: Re: [PATCH v2] configfs: Fix use-after-free when accessing sd->s_dentry Message-ID: <20190517082312.GA13457@lst.de> References: <1546514295-24818-1-git-send-email-stummala@codeaurora.org> <20190131032011.GC7308@codeaurora.org> <0081e5c8083f5ed9f1c1e9b456739728@codeaurora.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <0081e5c8083f5ed9f1c1e9b456739728@codeaurora.org> User-Agent: Mutt/1.5.17 (2007-11-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 16, 2019 at 06:27:53PM +0530, stummala@codeaurora.org wrote: > Hi Christoph, Al, > > Can you please consider this patch for merging? I've been sitting on this for a while, mostly because I can't convince myself it is safe. What protects other threads from using ->s_dentry just when we clear it? Also why would sd->s_dentry == dentry ever be false?