Message ID | 20240105152129.196824-4-aleksandr.mikhalitsyn@canonical.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7301:6f82:b0:100:9c79:88ff with SMTP id tb2csp6287793dyb; Fri, 5 Jan 2024 07:23:06 -0800 (PST) X-Google-Smtp-Source: AGHT+IFBydBpvpReUd6utDp3yhF82nHcgAOFu3j7ynKRxTqaEyczgbIkelBKA1RTuho23+iIXiGI X-Received: by 2002:a17:907:924e:b0:a28:ac85:385b with SMTP id kb14-20020a170907924e00b00a28ac85385bmr742361ejb.110.1704468186352; Fri, 05 Jan 2024 07:23:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704468186; cv=none; d=google.com; s=arc-20160816; b=AKXGr76Tayy+cmOuo12Il78itlZVBFqQ5du5Xoh6C6JIrfhgsQMb9NSwj17KW5SzPp wjLlapzxYfthOgUJJe54QEU77lMbt17AbonlB8uYcPfmau96Sm66i40cBkMk15DMJGR0 Rw58JtKAKcTY3ZiiZp1qXSUFc8693/IxARXzcJ/2JCg4fbjrHcIbashpHWOkz569msVF yxPempweFYJKX6V3Y64UXN74Kz177ZzQbDdTbVRtKq6bkCYwJcBlOXvPvJ6vvfYtciij xM2tk0bW+s/J78yLcE0SOjuzoSUtOgJvbXsKPurtZVJBzY3yn6Up32vgkD2TY/TPuIs0 munw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=3ehRu/Zuzjv9SF1nMloRA0oZhzJAyfoaCoaYcJRfDMg=; fh=HYreRiIpRdi/Sn9y2jRKR/GOkeohfolaSlTMugsUjQY=; b=GtMSiO5MltRJLEAeIZrAaaOPPtzAx0kZZuLeURBbmTRy79RefZVaMRfml73Gwx9mqU HNUKzzmhausIWtByYc/rYuXneE8Sv/cR3rhZOrssm6pzE5IuQCrrjsMFsnENMSxbPpBg +che9bqXzv4zabpJng/n3NgNb2XZQIyCOdKRM8e4JrH4SmfGx9tOmCCTUvMa93EQFZiG 1d2KRxFPpQ1GKv2Y8EqvQceg8kZZgY3KXPERtFtyB2Cc8dArd5cZKlBB2HiEVXmSQbsH yeyn5PlCYF2gJGIDkBECKqQJEF6xKHwjdvu+ib04mlFushyry78Wm9+rSnH/MpFTOrLU No6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@canonical.com header.s=20210705 header.b=UE8vaO1I; spf=pass (google.com: domain of linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id t3-20020a17090605c300b00a27a2a029b3si652302ejt.419.2024.01.05.07.23.06 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jan 2024 07:23:06 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@canonical.com header.s=20210705 header.b=UE8vaO1I; spf=pass (google.com: domain of linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-17991-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id DFC8C1F22E1C for <ouuuleilei@gmail.com>; Fri, 5 Jan 2024 15:23:05 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A8D3B321B8; Fri, 5 Jan 2024 15:22:06 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=canonical.com header.i=@canonical.com header.b="UE8vaO1I" X-Original-To: linux-kernel@vger.kernel.org Received: from smtp-relay-internal-1.canonical.com (smtp-relay-internal-1.canonical.com [185.125.188.123]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A85083173E for <linux-kernel@vger.kernel.org>; Fri, 5 Jan 2024 15:22:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=canonical.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=canonical.com Received: from mail-ed1-f71.google.com (mail-ed1-f71.google.com [209.85.208.71]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id F32EF3F468 for <linux-kernel@vger.kernel.org>; Fri, 5 Jan 2024 15:22:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1704468121; bh=3ehRu/Zuzjv9SF1nMloRA0oZhzJAyfoaCoaYcJRfDMg=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=UE8vaO1Ix0h0HypNFxX3xnrcJENd2rJTrb8XVFzVrxiuDQKZqr/t6KO/eCv/49seL gD2zmqSJXsRDDZU5dbx9zVJRMD6mK6eNFBa5pUO5Q7Sx45Zle0TeF1RYRo3APFRe1P zXa2cX2I5tSw09U7ZSzhYj7xrUtYhxMT3l07dpcYBGTJIpU8xsqcScIp4OIDUr3+Tt lKKZf8OC2oWvw67tQsakjKfZwhBRC3Tq5HgOiKKMTZtsvQPLM9R5oCdCA/DlbhA0nQ knrq4Gn1MJSz6OeuagpPjszITc3XAJx1Xg7aDWr/UkAOwBT5tnWRFbbINfXLWwwXSD 51u4bgTrRtHCg== Received: by mail-ed1-f71.google.com with SMTP id 4fb4d7f45d1cf-556415459d2so983322a12.0 for <linux-kernel@vger.kernel.org>; Fri, 05 Jan 2024 07:22:00 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704468120; x=1705072920; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=3ehRu/Zuzjv9SF1nMloRA0oZhzJAyfoaCoaYcJRfDMg=; b=d+VQYJlbbB2RJwOjLsUhFMQuVnb1SbX2yCc3QJcOkKJPHvqRaewlDLKRkCqyXosqKx LtzaiZijK9xm1T3qBP+s5zXUnM0iDvm/flD1Bci2ZS/G4KbOZn0oYag58xgWvrnfK6Y6 751pMxBLYT8axQjLRHFCXcP29y2npbDhPIb/+1LM28kWu4G6PueZNK8coLAK+Lh/0fXL p2rEoZF8areEeh/4DcxOaF27zkgy2eSltQ7VTjX+TjdwkyDIQ1mWTYFlSBMVMF/5S4Ku Onx4FWT0wUUGzMtMN9yen1RwBJhWJvRinAQvfiNWG4xHpfDDo+u5yTKO5i1lSVG6oGbM gu4Q== X-Gm-Message-State: AOJu0YwYyPNzaAf66U+e37KtXvq0UebwdfYvQ6FTuj1J27s8ONOSgIVG ZNhg1Y2wIiTo1RD628+TunA3gTn7DaY5IEXEwYpHPDMUmQUMNPBT2GeMCrnr1jS2Of3hNMgStw6 h1HuRKxkNv6/j515D2jz7oR1Wh9NC6XWPA5HEgA/jsz48nTxcR3x1Mpgy X-Received: by 2002:a17:906:e0d8:b0:a27:6e73:a248 with SMTP id gl24-20020a170906e0d800b00a276e73a248mr773799ejb.68.1704468120505; Fri, 05 Jan 2024 07:22:00 -0800 (PST) X-Received: by 2002:a17:906:e0d8:b0:a27:6e73:a248 with SMTP id gl24-20020a170906e0d800b00a276e73a248mr773791ejb.68.1704468120298; Fri, 05 Jan 2024 07:22:00 -0800 (PST) Received: from amikhalitsyn.lan ([91.64.72.41]) by smtp.gmail.com with ESMTPSA id i23-20020a170906115700b00a298adde5a1sm345630eja.189.2024.01.05.07.21.59 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 05 Jan 2024 07:21:59 -0800 (PST) From: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com> To: mszeredi@redhat.com Cc: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>, Christian Brauner <brauner@kernel.org>, Miklos Szeredi <miklos@szeredi.hu>, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v1 3/3] fuse: __kuid_val/__kgid_val helpers in fuse_fill_attr_from_inode() Date: Fri, 5 Jan 2024 16:21:29 +0100 Message-Id: <20240105152129.196824-4-aleksandr.mikhalitsyn@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240105152129.196824-1-aleksandr.mikhalitsyn@canonical.com> References: <20240105152129.196824-1-aleksandr.mikhalitsyn@canonical.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1787264433023592844 X-GMAIL-MSGID: 1787264433023592844 |
Series |
fuse: a few small fixes
|
|
Commit Message
Aleksandr Mikhalitsyn
Jan. 5, 2024, 3:21 p.m. UTC
For the sake of consistency, let's use these helpers to extract
{u,g}id_t values from k{u,g}id_t ones.
There are no functional changes, just to make code cleaner.
Cc: Christian Brauner <brauner@kernel.org>
Cc: Miklos Szeredi <miklos@szeredi.hu>
Cc: <linux-fsdevel@vger.kernel.org>
Cc: <linux-kernel@vger.kernel.org>
Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com>
---
fs/fuse/inode.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Comments
On Fri, Jan 05, 2024 at 04:21:29PM +0100, Alexander Mikhalitsyn wrote: > For the sake of consistency, let's use these helpers to extract > {u,g}id_t values from k{u,g}id_t ones. > > There are no functional changes, just to make code cleaner. > > Cc: Christian Brauner <brauner@kernel.org> > Cc: Miklos Szeredi <miklos@szeredi.hu> > Cc: <linux-fsdevel@vger.kernel.org> > Cc: <linux-kernel@vger.kernel.org> > Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com> > --- Looks good to me, Reviewed-by: Christian Brauner <brauner@kernel.org>
On Mon, 8 Jan 2024 12:37:07 +0100 Christian Brauner <brauner@kernel.org> wrote: > On Fri, Jan 05, 2024 at 04:21:29PM +0100, Alexander Mikhalitsyn wrote: > > For the sake of consistency, let's use these helpers to extract > > {u,g}id_t values from k{u,g}id_t ones. > > > > There are no functional changes, just to make code cleaner. > > > > Cc: Christian Brauner <brauner@kernel.org> > > Cc: Miklos Szeredi <miklos@szeredi.hu> > > Cc: <linux-fsdevel@vger.kernel.org> > > Cc: <linux-kernel@vger.kernel.org> > > Signed-off-by: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com> > > --- > > Looks good to me, > Reviewed-by: Christian Brauner <brauner@kernel.org> Thanks! Kind regards, Alex
diff --git a/fs/fuse/inode.c b/fs/fuse/inode.c index b8636b5e79dc..ab824a8908b7 100644 --- a/fs/fuse/inode.c +++ b/fs/fuse/inode.c @@ -1489,8 +1489,8 @@ static void fuse_fill_attr_from_inode(struct fuse_attr *attr, .ctimensec = ctime.tv_nsec, .mode = fi->inode.i_mode, .nlink = fi->inode.i_nlink, - .uid = fi->inode.i_uid.val, - .gid = fi->inode.i_gid.val, + .uid = __kuid_val(fi->inode.i_uid), + .gid = __kgid_val(fi->inode.i_gid), .rdev = fi->inode.i_rdev, .blksize = 1u << fi->inode.i_blkbits, };