Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp160639imm; Thu, 12 Jul 2018 16:22:28 -0700 (PDT) X-Google-Smtp-Source: AAOMgpft195OluAmkWpdfSYd7DB2HZsfkVH0WtLcqm1awcvu6Xj7VHIKOK6Ec2tFSKYsZLqUmuD7 X-Received: by 2002:a63:c00b:: with SMTP id h11-v6mr3734270pgg.279.1531437748028; Thu, 12 Jul 2018 16:22:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531437747; cv=none; d=google.com; s=arc-20160816; b=LY2eS9B1pVe1sGiX7AE27dgYeSopjF78w5DxrnFQ/8BtW13cMpJa/qfWds50cg7SFZ YgBkpybPUX+Znoth1pGAWQQXm26GdW1xwGVXMIfru7/wEsdk7kQnqClTwKqUA1/UQSS0 7DG3UAVYcKGR/iwPgDBgL4j0NKhvsEs2jksV2rFDb0WcaEJXIZVj3YDNDVN7Uc58svl4 CUsHcN9slj5tSreIJ2CXt1tj4QCUVU8UeowoKA+5wtMX48N3qVH9QM27yIq7AeIVn9wM gcjBu7T8Y9/T1vbVUAW7A3rfRyjjVdnv0rgj4yIkgqkPawYV7LnQOpqFQnZ58SPI9sTv U/wA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version:dkim-signature:arc-authentication-results; bh=E59WpRPCjmtFx5KXXD35289bbHUJ8DPuvAaEKu2ztBA=; b=I9Tg927FDZzoJi5Rjer6OcWiOAirnry50EDEKySV0qh+Q1+Pba+mUNs8o1nZjC7Vxw SU192GAyVK+Po48JR/8p/flhOO8xfGZIxMpT7mQYzA7lGzwjgdedJgXFRrYA6FLMP9Zw 4rWMLSOxqb7375KNGBiKvtOvGcWOaaxK4EVSX0l3/I5tL63lsQZitrtWfPD39E7nCiz6 wLxR7VsGUc3Di323FgSO274val6bWuRiGj1xNeWmXCxNHFLyis2HconcsEToE3k1nu76 xG4PGEOd7cBonIb+U0EsC4Eo4RqxPdsjz8854eUce72reQ1hW9YquqCTUqBCqkgYwYzJ Cn0w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b="2HZSO/pH"; 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 c14-v6si24986599pfl.319.2018.07.12.16.22.13; Thu, 12 Jul 2018 16:22:27 -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; dkim=pass header.i=@amacapital-net.20150623.gappssmtp.com header.s=20150623 header.b="2HZSO/pH"; 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 S1733160AbeGLXd1 (ORCPT + 99 others); Thu, 12 Jul 2018 19:33:27 -0400 Received: from mail-pl0-f67.google.com ([209.85.160.67]:46929 "EHLO mail-pl0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732243AbeGLXd1 (ORCPT ); Thu, 12 Jul 2018 19:33:27 -0400 Received: by mail-pl0-f67.google.com with SMTP id 30-v6so11309107pld.13 for ; Thu, 12 Jul 2018 16:21:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amacapital-net.20150623.gappssmtp.com; s=20150623; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=E59WpRPCjmtFx5KXXD35289bbHUJ8DPuvAaEKu2ztBA=; b=2HZSO/pHC2CLSf3beAjygTAjeXsmduUwOa4MT4Zs4mYzi6g/RDcsRTAIPYAczzkyzz 2dK/6U+xbFuCLjF16xvVzHB+rx8ztmwJ+7AJNe2XyYA3a1zD2I6q/skCUxIyDtOjBRDi eWTQ/3IrJklEVYMbpC5VR8PqWzKJBqW5geIu3s2Jsprl/TjPQXB/yuGBSgkQ+Irp1WbV eZh7Ci+h1PfAeeeNiuqrVqI6LTPVgocaWKoIidYMBkHasU6ir970xdnUlB9lhYG6kveB FSoPc+lHD65XgF+Jr54ch0XY1UWfgFaD83Q9in/YNbXPbtciL9otg/XUDpnfiZWSZmn3 qffQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=E59WpRPCjmtFx5KXXD35289bbHUJ8DPuvAaEKu2ztBA=; b=pn6rwtbJ0xU63MKdRLJK/2r0k7awzopQL2I7YBXPKxCPdvxeqMcKLr6/XcdDDRypP6 GgD3vnZgohhVBJXOQcrTtLl7okp1b+ibSWvQ18wy78M6k4MpgKmW+cXqL90rrEkbK2eh YeRgN6Re8jbDpTAJ714L60maLyRN64ydQvbbl1hB/3JfnmFIAqi4/uR92ff9xygGLTz+ m9h+cEBtW66XJjYHZU7cm+r/QXdhqWWs4C+dDU1Z5XcehPSbjtfRl70gKywisuiNTsln dOl0urU2vzFkeTYCYsG3v5iIf4c+spSI8iE5jyzrta9OiuF/ntyezMDcdaYZUlgPTTZE gZjQ== X-Gm-Message-State: AOUpUlGqlMejfNqCAXmZSoWpts0ZSxtfhdIPdJwrXD64ybuo5wZq79RW dzddyQVbKy6nGp946DbwspWZZA== X-Received: by 2002:a17:902:bc8c:: with SMTP id bb12-v6mr4038339plb.84.1531437699188; Thu, 12 Jul 2018 16:21:39 -0700 (PDT) Received: from [100.125.106.90] (24.sub-174-237-8.myvzw.com. [174.237.8.24]) by smtp.gmail.com with ESMTPSA id s20-v6sm34661548pga.37.2018.07.12.16.21.37 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 12 Jul 2018 16:21:38 -0700 (PDT) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (1.0) Subject: Re: [PATCH 24/32] vfs: syscall: Add fsopen() to prepare for superblock creation [ver #9] From: Andy Lutomirski X-Mailer: iPhone Mail (15F79) In-Reply-To: <22105.1531436081@warthog.procyon.org.uk> Date: Thu, 12 Jul 2018 16:21:35 -0700 Cc: "Theodore Y. Ts'o" , Linus Torvalds , Andrew Lutomirski , Al Viro , Linux API , linux-fsdevel , Linux Kernel Mailing List , Jann Horn Content-Transfer-Encoding: quoted-printable Message-Id: <611054C7-D6E8-4C89-958E-3128C9305E1E@amacapital.net> References: <20180712223223.GA28610@thunk.org> <153126248868.14533.9751473662727327569.stgit@warthog.procyon.org.uk> <153126264966.14533.3388004240803696769.stgit@warthog.procyon.org.uk> <686E805C-81F3-43D0-A096-50C644C57EE3@amacapital.net> <22370.1531293761@warthog.procyon.org.uk> <7002.1531407244@warthog.procyon.org.uk> <16699.1531426991@warthog.procyon.org.uk> <18233.1531430797@warthog.procyon.org.uk> <22105.1531436081@warthog.procyon.org.uk> To: David Howells Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > On Jul 12, 2018, at 3:54 PM, David Howells wrote: >=20 > Theodore Y. Ts'o wrote: >=20 >> So maybe the answer is that you open /dev/sda1 and /dev/sda2 and then >> pass the file descriptors to the fsopen object? We can require that >> the fd's be opened with O_RDWR and O_EXCL, which has the benefit where >> if you have multiple block devices, you know *which* block device had >> a problem with being grabbed for an exclusive open. >=20 > Would that mean then that doing: >=20 > mount /dev/sda3 /a > mount /dev/sda3 /b >=20 > would then fail on the second command because /dev/sda3 is already open > exclusively? >=20 I tend to think that this *should* fail using the new API. The semantics of= the second mount request are bizarre at best.=