Received: by 2002:a05:6a10:a852:0:0:0:0 with SMTP id d18csp599285pxy; Fri, 30 Apr 2021 12:00:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyyvJsp8c69yzdo2gmKazerPl62z5XPVmSlNuYK1b3lmQq0FyJgWakhBd9DuOepwj7wq/pi X-Received: by 2002:a17:902:ee94:b029:ed:4204:5e44 with SMTP id a20-20020a170902ee94b02900ed42045e44mr6624345pld.60.1619809223137; Fri, 30 Apr 2021 12:00:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619809223; cv=none; d=google.com; s=arc-20160816; b=wPJ36qXcQykxp3EACyIq6614ziXegXEhBymO1soBrZBp+U3+J3FaRknYthahA7vD6H IdwNx14EYFGQB9itJKXhBqbNPljHq3oGPKIYurgQpMLSm1LSeF7dPLEsH9ho4zlas214 boak90DdaqKyZWa7GlVAoCNkUfFnRP2fHi2JyxiqFDAdos5FKpohTvImK5+jD0RCCT0o XjfStoOgD8nDnE0x2kcQH3UI3yjATEJcFJ45RRViUmy0fYl5rKALYKWh2luaB05kSDJa 5ImKnWsP9YpHZxHW42Q/RTG1UFowlShf1kyahpsoOCjX0HtS3Le07Bkp9HMwPmKQmYbm P5IA== 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=HR9HIh5t6ChKf4G2M+/v8UEXBtBcvCoA8Ko3upSQGEE=; b=Mc55UNS7ZSDyWOG/pm6V8wXjfrJ7cWgavMDG4LMUUFWOS2uNvSowEJZOSvPaV5aT7O UGnw1J65sAxNG0kQyP3cMInW+PW9qbzT6hshhz3doG8zqN6G/CX7/ISaSlNbUmMd1xO0 K39XZHcQMgYY9Z2f5PNt56OO/9UtlvQUDJutxVi3xDQdtgCLh7StyfV5jMGlUnJ+0U/5 D8lapw/KZbEPWu/ZiAAthtpkDRb1KS52NkNw/RtJ3U0qdQ4G4HBoga6MZCck1JYNRRzg OyTrD1veLRCD/in3LcAvXB5Q0brOcIlqEXK1YDlTEQvh+igKa5naVlLibu3rLvyNyyvj B84g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=Gthh0M42; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e4si50000pld.407.2021.04.30.12.00.09; Fri, 30 Apr 2021 12:00:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-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=@linux-foundation.org header.s=google header.b=Gthh0M42; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231631AbhD3S7m (ORCPT + 99 others); Fri, 30 Apr 2021 14:59:42 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50610 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231136AbhD3S7l (ORCPT ); Fri, 30 Apr 2021 14:59:41 -0400 Received: from mail-lj1-x22a.google.com (mail-lj1-x22a.google.com [IPv6:2a00:1450:4864:20::22a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 301DFC06174A for ; Fri, 30 Apr 2021 11:58:52 -0700 (PDT) Received: by mail-lj1-x22a.google.com with SMTP id s9so24119567ljj.6 for ; Fri, 30 Apr 2021 11:58:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=HR9HIh5t6ChKf4G2M+/v8UEXBtBcvCoA8Ko3upSQGEE=; b=Gthh0M42pJvYCWBy3e13blM8tVYPzsKl3dsjSJfC6WPQE14dl0aGEMfGT9jr9z9r0w zsppuIHNQXNvQnegVvGlCd5YB/6sVcBPAQvlzcTZcq9WavaVu35v8QiWsut/Uf2cZiRi SROr1sstiMDfAGbtJG7YiUrELWg4w1bLfBT9o= 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=HR9HIh5t6ChKf4G2M+/v8UEXBtBcvCoA8Ko3upSQGEE=; b=SZH3BgWaEizT8cX6T5tExxLvUUD/o6K0/I8QOqFVBilZ92N2pJnqUdf7sYWR3Uc19v nsPZu/BgrfUcAclXuTzuBjmAsmqdLsxjP8vgtgnKDQCL7P27Qpq9FGrnBHXXa0OXtlil uCYSlUG4+4qg7mhmurg5z5XJulkH4klWdzvRpKj7NaFx4UbRuCNYKFIiu/VI9SC3wuI2 1O8P02ns6sDBGwRR33QHjCxiylraTRXcRH916845dCRNaDM29nxAhqQ5UBJ6Op4CHXA9 9Bkj3DCaZMtBCSj9iNnVFU9QYhbQKFcgKn4aztFMeTZd2mC+IW1ny6AlSuQrgLOkNcy7 o7JA== X-Gm-Message-State: AOAM531KyO+pTNeiDUlI4REgZkZLy2b2zZPWGj062RiYIeI57D587+tW 6EGchMxbA18mf2GRAamnhHO7fWCAwkmYFpMj X-Received: by 2002:a05:651c:2c8:: with SMTP id f8mr4898418ljo.409.1619809130432; Fri, 30 Apr 2021 11:58:50 -0700 (PDT) Received: from mail-lf1-f42.google.com (mail-lf1-f42.google.com. [209.85.167.42]) by smtp.gmail.com with ESMTPSA id j14sm343275ljh.0.2021.04.30.11.58.49 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 30 Apr 2021 11:58:49 -0700 (PDT) Received: by mail-lf1-f42.google.com with SMTP id j10so18466397lfb.12 for ; Fri, 30 Apr 2021 11:58:49 -0700 (PDT) X-Received: by 2002:a05:6512:3763:: with SMTP id z3mr4084391lft.487.1619809128928; Fri, 30 Apr 2021 11:58:48 -0700 (PDT) MIME-Version: 1.0 References: <20210428061706.GC5084@lst.de> <20210428064110.GA5883@lst.de> <1de23de2-12a9-2b13-3b86-9fe4102fdc0c@rasmusvillemoes.dk> <26d06c27-4778-bf75-e39a-3b02cd22d0e3@rasmusvillemoes.dk> In-Reply-To: From: Linus Torvalds Date: Fri, 30 Apr 2021 11:58:32 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [GIT PULL] iomap: new code for 5.13-rc1 To: Al Viro Cc: Justin He , Rasmus Villemoes , Christoph Hellwig , "Darrick J. Wong" , linux-fsdevel , linux-xfs , Dave Chinner , Linux Kernel Mailing List , Eric Sandeen , Andy Shevchenko Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 29, 2021 at 8:21 PM Al Viro wrote: > > Just what does vfsmount have to do with rename_lock? And what's the point > of the entire mess, anyway? Currently "%pD" doesn't actually show a truly valid pathname. So we have three cases: (a) __d_path and friends get the name right, but are being overly careful about it, and take mount_lock and rename_lock in prepend_path (b) dentry_path() doesn't get the actual path name right (only the in-filesystem one), and takes rename_lock in __dentry_path (c) for the vsnprintf case, dentry_name() is the nice lockless "good for debugging and printk" that doesn't take any locks at all, and optimistically gives a valid end result, even if it's perhaps not *THE* valid end result Basically, the vsnprintf case does the right thing for dentries, and the whole "you can use this for debugging messages even when you hold the rename lock" etc. So (c) is the "debug messages version of (b)". But there is no "debug messages version of (a)", which is what would be good for %pD. You can see it in how the s390 hmcdriv thing does that pr_debug("open file '/dev/%pD' with return code %d\n", fp, rc); which is really just garbage: the "/dev/" part is just a guess, but yes, if /dev is devtmpfs - like it usually is - then '%pD' simply doesn't do the right thing (even if it had '%pD2') Linus