Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp4417534pxy; Tue, 27 Apr 2021 04:45:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxLiZD5R24ooe58kbKHbK+ehNPHK7IHBqcuABq9yOntp59mE/dCfwv0fNoKTn3qAk0g+aQS X-Received: by 2002:a17:902:9a84:b029:ea:e627:f7c2 with SMTP id w4-20020a1709029a84b02900eae627f7c2mr23819532plp.57.1619523937166; Tue, 27 Apr 2021 04:45:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619523937; cv=none; d=google.com; s=arc-20160816; b=FAZxrErRKxplLFAQDXMjTj4bL8Y+i8Vkasis9F2G0u4/hXAykJ37PddLLqnEeJ5t36 pHhk0tdx4d3ptykIW/ELb51tXWY37GfciDimKJgAIOo+sIzWqquXB3tvNFCzFrZ1tPVv U6wre3pkb2X1cJZtfyqDKsky58PxP7Y2q9ptEXQaBkOcJxm0xIGvEwEkogBpM5h6Jq/S H27EyCxYmSauUHmFPAWfuuY4Gv64jYiN97Wp5ijuwRGOVhCfBWgXsXAv1rzOWEOlMi87 y10yzR8CKcMhQJ+7oTe5RTprU6DQVSBWYJQVrD2xGFUPLiIOPCEEHTk0KLbELLRhLSGw uF7g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=fSIglWh61xZJ/xsSpFVgO2FLNYI4MWOlXZbNtRRxdJQ=; b=gAxsnib+7g7gdjxWiLkHk1wUgvY09l/Yybb2uljIio0fOaTX4LnmVVGJgDoYhOz3ji w4f4bQkaBEFD2YBfXleKwivHUX9ZoGJLzTWcqsFo0LY8rqSanTw2ELgtfhi8u0OXTm72 0cGIS/qP6BopRG2/VClIcnbqMttf6YySAXwDH8nP7+YjzL0cKSi3EV6aSdvy7DU/JaMo qIR/RFihKjOUIWsTk5Vk8W2MO/TjMHltj4dJto+xmRwTImie91qDDTb01WYi7DAuK/ln n9F3bBZmpq6mUjP6GuSTay1i/Futd5LulDczf/RA+y/ZryIt7PKq2WGZ/8S8T2kbQlQP mifg== ARC-Authentication-Results: i=1; mx.google.com; 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 b11si21654119pgs.399.2021.04.27.04.45.24; Tue, 27 Apr 2021 04:45:37 -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; 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 S235929AbhD0LoZ (ORCPT + 99 others); Tue, 27 Apr 2021 07:44:25 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:60776 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230365AbhD0LoZ (ORCPT ); Tue, 27 Apr 2021 07:44:25 -0400 Received: from ip5f5bf209.dynamic.kabel-deutschland.de ([95.91.242.9] helo=wittgenstein.fritz.box) by youngberry.canonical.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1lbM7w-0001JU-VF; Tue, 27 Apr 2021 11:43:41 +0000 From: Christian Brauner To: Linus Torvalds Cc: linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [GIT PULL] fs mapping helpers update Date: Tue, 27 Apr 2021 13:43:32 +0200 Message-Id: <20210427114332.1713512-1-christian.brauner@ubuntu.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20210427113845.1712549-1-christian.brauner@ubuntu.com> References: <20210427113845.1712549-1-christian.brauner@ubuntu.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Linus, /* Summary */ This adds kernel-doc to all new idmapping helpers and improves their naming which was triggered by a discussion with some fs developers. Some of the names are based on suggestions by Vivek and Al. We also remove the open-coded permission checking in a few places with simple helpers. Overall this should lead to more clarity make it easier to maintain. The following changes since commit 0d02ec6b3136c73c09e7859f0d0e4e2c4c07b49b: Linux 5.12-rc4 (2021-03-21 14:56:43 -0700) are available in the Git repository at: git@gitolite.kernel.org:pub/scm/linux/kernel/git/brauner/linux tags/fs.idmapped.helpers.v5.13 for you to fetch changes up to db998553cf11dd697485ac6142adbb35d21fff10: fs: introduce two inode i_{u,g}id initialization helpers (2021-03-23 11:15:26 +0100) /* Testing */ All patches are based on v5.12-rc4 and have been sitting in linux-next. No build failures or warnings were observed. All old and new tests are passing. ubuntu@f2-vm:~/src/git/xfstests$ sudo ./check -g idmapped FSTYP -- xfs (debug) PLATFORM -- Linux/x86_64 f2-vm 5.12.0-rc6-idmapped-cfebad8730dd #387 SMP PREEMPT Tue Apr 27 10:39:29 UTC 2021 MKFS_OPTIONS -- -f -bsize=4096 /dev/loop1 MOUNT_OPTIONS -- /dev/loop1 /mnt/scratch generic/633 files ... 27s xfs/152 files ... 68s xfs/153 files ... 36s Ran: generic/633 xfs/152 xfs/153 Passed all 3 tests /* Conflicts */ At the time of creating this PR no merge conflicts were reported from linux-next and no merge conflicts showed up doing a test-merge with current mainline. (Note, in case you care about this at all I changed my tag naming pattern simply because I ran into limitations with branch naming in git using "/" separators and I like to have a 1:1 correspondence between the branch and the tag name.) Please consider pulling these changes from the signed fs.idmapped.helpers.v5.13 tag. ---------------------------------------------------------------- fs.idmapped.helpers.v5.13 ---------------------------------------------------------------- Christian Brauner (4): fs: document mapping helpers fs: document and rename fsid helpers fs: introduce fsuidgid_has_mapping() helper fs: introduce two inode i_{u,g}id initialization helpers fs/ext4/ialloc.c | 2 +- fs/inode.c | 4 +- fs/namei.c | 11 ++--- fs/xfs/xfs_inode.c | 10 ++--- fs/xfs/xfs_symlink.c | 4 +- include/linux/fs.h | 124 ++++++++++++++++++++++++++++++++++++++++++++++++++- 6 files changed, 135 insertions(+), 20 deletions(-)