Received: by 2002:ab2:1c04:0:b0:1f7:53ba:1ebe with SMTP id f4csp91232lqg; Fri, 26 Apr 2024 09:32:23 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUOvZGvRKglkN0Tzu7PH3C/kFRiRmvdrYzTqY0ZGtFkflFYWWX9fecQ0b3xsZyfN/nsU0T6a68jxtE24vUGwPa7Maq3S0XOgu69fd+UCg== X-Google-Smtp-Source: AGHT+IEsPe7ewhQl8riZFLGAqNjJYpVEh/Mavh+Jz6IBzEamwf6pxtmooP4KQUu6bwx0D7yZqHwp X-Received: by 2002:a05:620a:b99:b0:78f:1583:fde8 with SMTP id k25-20020a05620a0b9900b0078f1583fde8mr3363547qkh.62.1714149143659; Fri, 26 Apr 2024 09:32:23 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714149143; cv=pass; d=google.com; s=arc-20160816; b=0qIMtENRQAc+36LFY8wxLwToVnCd4tHQJK8gXPsbPbE5dv5INFI/kO4ih7xiX6P0sE OKouP6IV7EzJJqdKlSEp0gqeum36dyTj2wPk6s/dTONquZBVyUR6ZJn5VGAnjhx4BdE7 nbcq5lRtt6iBbDley4rxcMp8XX3yvezsIQgBz3m37BMUwsXxAS0viRNpJs498tigweLE GF2ImozXkgFU6EC2Ks3/TqHFe7ZS+S4C0kIGAuM7LGqWfw4xWXHrZ2P719ImjKMZ6jhR 6mcPUSV6+T2noGnZ7rpLHRPmqiiooXvezbx8Pb+L8RmbtDD0ldzWFJAqWVSsvh8lW0ek 4oNA== ARC-Message-Signature: i=2; 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:reply-to:references:in-reply-to :message-id:date:subject:cc:to:dkim-signature:from; bh=cFD0pvg4orrZWH7JCCIWvQcxitlwJBZqeb1sFDYG+1Y=; fh=hj9XKLlYgsePwYNBaqeAki3DNB2hjX+kDd0+M/AHzhg=; b=Buau/vfLHHro0bu003Xvb3izGEKkY47oTFvVLIrOeYZmqZO3XIPwxayJWqlXg/N0Pp WsuoFGw5d+0SnBbWu7QmrhPuwVs2/QuXb0FBZSjY0gs5+56nfpuRX8GPr2Kzlnt9DMVy 8CB/27PGTLts9yiIbZc3tBHkVGRxiGuifnKEZa9DhVvpkQd0d+SaVNBD45pgGIsiC38X 8w2b3fGQfxWf9uZka0Cg43roghErAumu/NsWmVmPHVZstj2P8WRpk6eGgyF+8apua7Xe wrG2ihrhjeWpZqqzHBi/IedO+VCytiOWKcqdP1YWGQXI0ZHJL/iJTTSO8Rp8+yiMwyrI SNhg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@seltendoof.de header.s=2023072701 header.b=U1nKbjcn; arc=pass (i=1 spf=pass spfdomain=seltendoof.de dkim=pass dkdomain=seltendoof.de dmarc=pass fromdomain=seltendoof.de); spf=pass (google.com: domain of linux-kernel+bounces-160378-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-160378-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=seltendoof.de Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id y8-20020a05620a44c800b0078d76c129easi24358663qkp.424.2024.04.26.09.32.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 26 Apr 2024 09:32:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-160378-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@seltendoof.de header.s=2023072701 header.b=U1nKbjcn; arc=pass (i=1 spf=pass spfdomain=seltendoof.de dkim=pass dkdomain=seltendoof.de dmarc=pass fromdomain=seltendoof.de); spf=pass (google.com: domain of linux-kernel+bounces-160378-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-160378-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=seltendoof.de 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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 2DE851C22802 for ; Fri, 26 Apr 2024 16:32:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1A1F01487DC; Fri, 26 Apr 2024 16:32:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=seltendoof.de header.i=@seltendoof.de header.b="U1nKbjcn" Received: from server02.seltendoof.de (server02.seltendoof.de [168.119.48.163]) (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 5534A2B9AF; Fri, 26 Apr 2024 16:32:07 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=168.119.48.163 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714149130; cv=none; b=TlIjW6HirTetfEGaxb8CoEx5tWLBJuJ6lIjqoNGCAHsqmdJjETsQb4TAWuH0zlYti9bpH5wRupvun2SXcCU19wZadFsPBfpZtKySr8XHSsrUC6NGeRf6GFTlgk4HfLT1RYdkcR7o5K+/7UciY1mgTmbZBb2qwWadEn2f8Z+yKbA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714149130; c=relaxed/simple; bh=fGe0JQqXwScJg7nYQvWsn+u/6hpAOG8C2NbPdKgaIgQ=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=XyKD7TsKUnd1pLPzl/yv6wt25uLb8Y3yGITQps9DbNEpNZTrNwNRkhhbOe22tHraTMY1hzZD5WENxUPE7yRYyPE/0BRdo8Do+qQZllJKYm+JDsFxVrj4vDAyqpp6RjLC/jNNIQjrT47xiPtBbaAhIGW/nuNQVYlw8sL9gTCP2dQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=seltendoof.de; spf=pass smtp.mailfrom=seltendoof.de; dkim=pass (2048-bit key) header.d=seltendoof.de header.i=@seltendoof.de header.b=U1nKbjcn; arc=none smtp.client-ip=168.119.48.163 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=seltendoof.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=seltendoof.de From: =?UTF-8?q?Christian=20G=C3=B6ttsche?= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=seltendoof.de; s=2023072701; t=1714148463; h=from:from:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=cFD0pvg4orrZWH7JCCIWvQcxitlwJBZqeb1sFDYG+1Y=; b=U1nKbjcnG/dajzWMm81Rovn1ZBNp4KKwvZKHpnd1e71VjBKWrgmLZsbKnPBzDpCzVlXXi7 hzTrib9bZXcJfBA5DmYzjniFPX6aJ7IOWU+DoaFUNle4H+/ZgBxSVK6n4SLGL6fYLbTC+t ypqv1ZGJm2kVwohG3v34yfEGi6vRrDC9urr/J+/2ckMwXrPaIzVG9mXhlO2p0kkqJRCSA+ IJki4rz0+T7VgPXW4lVEF7p2hiAyW1qtWOWEi1nb5Nfa/dgVXj2zoSLX/7DQETYuIrsyaF z3yvB8IbANBk0Mic2y7iIlx4NBKMEHXmBqQlKWb7UGXSNO1CZPNhGuHTksTaxw== To: cgzones@googlemail.com Cc: Christian Brauner , Alexander Viro , Jan Kara , Jens Axboe , Pavel Begunkov , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, io-uring@vger.kernel.org Subject: [PATCH v3 1/2] fs: rename struct xattr_ctx to kernel_xattr_ctx Date: Fri, 26 Apr 2024 18:20:15 +0200 Message-ID: <20240426162042.191916-2-cgoettsche@seltendoof.de> In-Reply-To: <20240426162042.191916-1-cgoettsche@seltendoof.de> References: <20240426162042.191916-1-cgoettsche@seltendoof.de> Reply-To: cgzones@googlemail.com Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Christian Göttsche Rename the struct xattr_ctx to increase distinction with the about to be added user API struct xattr_args. No functional change. Suggested-by: Christian Brauner Signed-off-by: Christian Göttsche --- v3: added based on feedback --- fs/internal.h | 8 ++++---- fs/xattr.c | 10 +++++----- io_uring/xattr.c | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/fs/internal.h b/fs/internal.h index 7ca738904e34..1caa6a8f666f 100644 --- a/fs/internal.h +++ b/fs/internal.h @@ -260,7 +260,7 @@ struct xattr_name { char name[XATTR_NAME_MAX + 1]; }; -struct xattr_ctx { +struct kernel_xattr_ctx { /* Value of attribute */ union { const void __user *cvalue; @@ -276,11 +276,11 @@ struct xattr_ctx { ssize_t do_getxattr(struct mnt_idmap *idmap, struct dentry *d, - struct xattr_ctx *ctx); + struct kernel_xattr_ctx *ctx); -int setxattr_copy(const char __user *name, struct xattr_ctx *ctx); +int setxattr_copy(const char __user *name, struct kernel_xattr_ctx *ctx); int do_setxattr(struct mnt_idmap *idmap, struct dentry *dentry, - struct xattr_ctx *ctx); + struct kernel_xattr_ctx *ctx); int may_write_xattr(struct mnt_idmap *idmap, struct inode *inode); #ifdef CONFIG_FS_POSIX_ACL diff --git a/fs/xattr.c b/fs/xattr.c index f8b643f91a98..941aab719da0 100644 --- a/fs/xattr.c +++ b/fs/xattr.c @@ -590,7 +590,7 @@ EXPORT_SYMBOL_GPL(vfs_removexattr); * Extended attribute SET operations */ -int setxattr_copy(const char __user *name, struct xattr_ctx *ctx) +int setxattr_copy(const char __user *name, struct kernel_xattr_ctx *ctx) { int error; @@ -620,7 +620,7 @@ int setxattr_copy(const char __user *name, struct xattr_ctx *ctx) } int do_setxattr(struct mnt_idmap *idmap, struct dentry *dentry, - struct xattr_ctx *ctx) + struct kernel_xattr_ctx *ctx) { if (is_posix_acl_xattr(ctx->kname->name)) return do_set_acl(idmap, dentry, ctx->kname->name, @@ -636,7 +636,7 @@ setxattr(struct mnt_idmap *idmap, struct dentry *d, int flags) { struct xattr_name kname; - struct xattr_ctx ctx = { + struct kernel_xattr_ctx ctx = { .cvalue = value, .kvalue = NULL, .size = size, @@ -719,7 +719,7 @@ SYSCALL_DEFINE5(fsetxattr, int, fd, const char __user *, name, */ ssize_t do_getxattr(struct mnt_idmap *idmap, struct dentry *d, - struct xattr_ctx *ctx) + struct kernel_xattr_ctx *ctx) { ssize_t error; char *kname = ctx->kname->name; @@ -754,7 +754,7 @@ getxattr(struct mnt_idmap *idmap, struct dentry *d, { ssize_t error; struct xattr_name kname; - struct xattr_ctx ctx = { + struct kernel_xattr_ctx ctx = { .value = value, .kvalue = NULL, .size = size, diff --git a/io_uring/xattr.c b/io_uring/xattr.c index 44905b82eea8..28b8f7b1af7c 100644 --- a/io_uring/xattr.c +++ b/io_uring/xattr.c @@ -18,7 +18,7 @@ struct io_xattr { struct file *file; - struct xattr_ctx ctx; + struct kernel_xattr_ctx ctx; struct filename *filename; }; -- 2.43.0