Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp7222837ybf; Fri, 6 Mar 2020 12:52:47 -0800 (PST) X-Google-Smtp-Source: ADFU+vunETCedfmX/DAM/F7nfV8TrvtQmjZqPUrbOc34nJSM8pSShso3ohlBq78wSlhxkOqJx1Uf X-Received: by 2002:aca:230f:: with SMTP id e15mr4042644oie.54.1583527967415; Fri, 06 Mar 2020 12:52:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583527967; cv=none; d=google.com; s=arc-20160816; b=VaA0hIzS4JpuO0NsAhvRJfPiXHXKP55UUVOk1LJfCypNEsctjRAKULxk2iSFH+Irby 9zGN5nnbQ2WagV1LWAZ3GI5qfrz60q9x+CRMulr99tZk5iD8YFO8xDPK1H/JRM0P341l FPvZWByAU6YHjb2CSY3QGymgwrGQ4i3Mi78OnAFLm5fS//I4wzhV0cAMK5Tza8qrJmZv ApiaNrdZoqtSHAbtc5uthic01A4oXNOfiL4YhC7T78QJ85LhH+ber6YmOyxx3a3ujL9B vGj6tKvYHxoitipW0zLjn39mnz24Bk27IyTopjikoItYQBwDV2xkjbyo34hOqfUZTlTT LDTQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=DvYR/A6sU6MOP83SOcaM6fuuOQnX/X3paiURCZQZ5zg=; b=PgvldPuQwHJyxJphcoJWXIUg/jsd+EC7pcfMI4k5EFM40C9BqmqSF/TGB4jeaFud7b RsVaEHTLfH5AQP38AnNVDCjS983Gq2g/xvnbIBfC/51LY9OEJt/xhWYSR6oYsvlwiG+N bKfx4eLOnAI8LsrygKiOGUOJahecbE+2EigX+ezFuYevmzeVqSCwS1J27V2izyHlLBkS w88cwVsTsAFnu4R7ruXBkLAQ+LOcUFObTMhwJIgyGx681acXWgqa6vB/1g5++RPjqYQG IhP5bdM0+Nvby69qugVCThro+e5ls5TembpccINajQHK1WnEzMgX+kDiV4oGjDs7dGb1 v/CQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=temperror (no key for signature) header.i=@szeredi.hu header.s=google header.b=gdosk36N; 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 b12si277013oic.260.2020.03.06.12.52.36; Fri, 06 Mar 2020 12:52:47 -0800 (PST) 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; dkim=temperror (no key for signature) header.i=@szeredi.hu header.s=google header.b=gdosk36N; 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 S1726382AbgCFUwD (ORCPT + 99 others); Fri, 6 Mar 2020 15:52:03 -0500 Received: from mail-il1-f194.google.com ([209.85.166.194]:46659 "EHLO mail-il1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726178AbgCFUwC (ORCPT ); Fri, 6 Mar 2020 15:52:02 -0500 Received: by mail-il1-f194.google.com with SMTP id e8so3251139ilc.13 for ; Fri, 06 Mar 2020 12:52:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=szeredi.hu; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=DvYR/A6sU6MOP83SOcaM6fuuOQnX/X3paiURCZQZ5zg=; b=gdosk36NodqB1hwovjpQiyfVrBcCT18ZZbADF2DKWw0ltWEDy6wxV7OtCiUiXRbhi8 wApryLv+o7MA3xTBwKCecpyYXsypPV4llqkjt9QKK3gqFry2pXG6z/9rB5H+p8YONVWw ILjY9/lDsSbwbv0gahQM4JqMzI/cQAi2PGmHw= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=DvYR/A6sU6MOP83SOcaM6fuuOQnX/X3paiURCZQZ5zg=; b=JQHRlD75WNahskQOqXhqTkw+J/N8to0snhty92GPYZOapdZRH1GounOvBRi8sLLUJg btBXHeCWFmiBodkVzqIuBAG5L/rXAaSEPKYPG+OWdun5ORnrq0jI0pnOjCnR3rI72I+I OEpWXoUnVQUTnLsQAFQrNb+ZgwAmA3QAFXZdjVpKfbydZ+yP+EkCJnAYsUi/Dv6XuZd+ e2ei6rPolRYUAq5A3gnj0NB/uZN2b/1fjhUMeNR95qxdWHkXvs6JI08ei5lAuMdJgjKr BNnB2buV6B+2leo4hU3D9wKAdAX5IgmHd1QM8Wc734l5jprJYMzdi5NfVCcjdIFh1J5w 98zQ== X-Gm-Message-State: ANhLgQ0YmVMTNHDuyf2liEggD3pzJ0twDPpCB8YVvVTUkhPGe8Xba85E 7vzho+1EXvb5UypHr5oZZ4pLWdOM3Wy/4oORPPFiRA== X-Received: by 2002:a92:8d41:: with SMTP id s62mr4596013ild.63.1583527922077; Fri, 06 Mar 2020 12:52:02 -0800 (PST) MIME-Version: 1.0 References: <0403cda7345e34c800eec8e2870a1917a8c07e5c.camel@themaw.net> <20200306162549.GA28467@miu.piliscsaba.redhat.com> <20200306194322.GY23230@ZenIV.linux.org.uk> <20200306195823.GZ23230@ZenIV.linux.org.uk> <20200306200522.GA23230@ZenIV.linux.org.uk> <20200306203705.GB23230@ZenIV.linux.org.uk> <20200306203844.GC23230@ZenIV.linux.org.uk> <20200306204523.GD23230@ZenIV.linux.org.uk> <20200306204926.GE23230@ZenIV.linux.org.uk> In-Reply-To: <20200306204926.GE23230@ZenIV.linux.org.uk> From: Miklos Szeredi Date: Fri, 6 Mar 2020 21:51:50 +0100 Message-ID: Subject: Re: [PATCH 00/17] VFS: Filesystem information and notifications [ver #17] To: Al Viro Cc: Ian Kent , David Howells , Christian Brauner , James Bottomley , Steven Whitehouse , Miklos Szeredi , Christian Brauner , Jann Horn , "Darrick J. Wong" , Linux API , linux-fsdevel , lkml , Greg Kroah-Hartman Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Mar 6, 2020 at 9:49 PM Al Viro wrote: > > On Fri, Mar 06, 2020 at 08:45:23PM +0000, Al Viro wrote: > > On Fri, Mar 06, 2020 at 08:38:44PM +0000, Al Viro wrote: > > > On Fri, Mar 06, 2020 at 08:37:05PM +0000, Al Viro wrote: > > > > > > > You are misreading mntput_no_expire(), BTW - your get_mount() can > > > > bloody well race with umount(2), hitting the moment when we are done > > > > figuring out whether it's busy but hadn't cleaned ->mnt_ns (let alone > > > > set MNT_DOOMED) yet. If somebody calls umount(2) on a filesystem that > > > > is not mounted anywhere else, they are not supposed to see the sucker > > > > return 0 until the filesystem is shut down. You break that. > > > > > > While we are at it, d_alloc_parallel() requires i_rwsem on parent held > > > at least shared. > > > > Egads... Let me see if I got it right - you are providing procfs symlinks > > to objects on the internal mount of that thing. And those objects happen > > to be directories, so one can get to their parent that way. Or am I misreading > > that thing? > > IDGI. You have (in your lookup) kstrtoul, followed by snprintf, followed > by strcmp and WARN_ON() in case of mismatch? Is there any point in having > stat(2) on "00" spew into syslog? Confused... The WARN_ON() is for the buffer overrun, not for the strcmp mismatch. Thanks, Miklos