From patchwork Mon Oct 21 16:37:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Andr=C3=A9_Almeida?= X-Patchwork-Id: 13844446 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 63382D15DBB for ; Mon, 21 Oct 2024 16:38:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E6F1A6B009C; Mon, 21 Oct 2024 12:38:27 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id E1F3B6B009D; Mon, 21 Oct 2024 12:38:27 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id CE7A36B009E; Mon, 21 Oct 2024 12:38:27 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id A85AD6B009C for ; Mon, 21 Oct 2024 12:38:27 -0400 (EDT) Received: from smtpin18.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 62DFD12071D for ; Mon, 21 Oct 2024 16:38:13 +0000 (UTC) X-FDA: 82698167160.18.0C0A4DF Received: from fanzine2.igalia.com (fanzine.igalia.com [178.60.130.6]) by imf17.hostedemail.com (Postfix) with ESMTP id 04E5B40004 for ; Mon, 21 Oct 2024 16:38:13 +0000 (UTC) Authentication-Results: imf17.hostedemail.com; dkim=pass header.d=igalia.com header.s=20170329 header.b=V2FlZGvv; dmarc=pass (policy=none) header.from=igalia.com; spf=pass (imf17.hostedemail.com: domain of andrealmeid@igalia.com designates 178.60.130.6 as permitted sender) smtp.mailfrom=andrealmeid@igalia.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1729528583; a=rsa-sha256; cv=none; b=wT1kcjChMJRlKI9cav95pqO4PseloG5HJlOIqIzjypIReHinbfanhnJ5rqR7noV+z4EZat g7Kdit9BSg+wBCrgG4SCA/6kR+kz9C4b3UOlWpzXfm6GIW1ZYIEi+H8+P968GzwiiSjrmW kceTyY/t63663OP3nADFYGHRGfoK17Y= ARC-Authentication-Results: i=1; imf17.hostedemail.com; dkim=pass header.d=igalia.com header.s=20170329 header.b=V2FlZGvv; dmarc=pass (policy=none) header.from=igalia.com; spf=pass (imf17.hostedemail.com: domain of andrealmeid@igalia.com designates 178.60.130.6 as permitted sender) smtp.mailfrom=andrealmeid@igalia.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1729528583; h=from:from:sender: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:dkim-signature; bh=IRWzJ2ihFV+Or6Yh2tTDHkDcDI2/Jt0crAI74pE29VE=; b=Nlkv0VGN0KJrtyO1o3ujWja4pg2Dc6E/NZ499wUQ5Ds4TdEpAJEx6xwBRAL81xdHC6luzK PjrqHCv96sf6CknaU2/aUc/7lQtVizEwZ5znHnOwg/WbrVPbOiea2jIiQVJryIxucKhRT8 KU/VWtfeNLEFTaE69sE37L90yy9VoN4= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Cc:To:In-Reply-To:References:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From:Sender: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=IRWzJ2ihFV+Or6Yh2tTDHkDcDI2/Jt0crAI74pE29VE=; b=V2FlZGvv0GJNi7LqNPWoCYWe6T IkwHBJYGJ+UMuht6t72Uh3VCoWz68gVRWqEbZFagUWe9x7/A0ezMs/UiC/c4DJmOYrRcFZ3Lyxjot 47BDGhrMfAYzpMpD2UVR9+/fldHg+jpxD2KQ5PHkjAcWueBNoH9mq+ZUjG8DvwdhDW6/U3mTkxnVG XNUawWorxooLY1LtJwijslHO5Q3PEh4xE6Ijzu9Hz6byJ4CiNigt+12Fn0h1nxM0EBM0Or8V4CKac pFzUu5ary992udtZ0y2pP0Qp0lvbOhTcP8801kQmPgA6te+sRvFoFyKoDgkhpOTq/rvslEYjRjawC CF8EthZw==; Received: from [191.204.195.205] (helo=[192.168.15.100]) by fanzine2.igalia.com with esmtpsa (Cipher TLS1.3:ECDHE_X25519__RSA_PSS_RSAE_SHA256__AES_256_GCM:256) (Exim) id 1t2vQC-00DECf-1s; Mon, 21 Oct 2024 18:38:20 +0200 From: =?utf-8?q?Andr=C3=A9_Almeida?= Date: Mon, 21 Oct 2024 13:37:25 -0300 Subject: [PATCH v8 9/9] docs: tmpfs: Add casefold options MIME-Version: 1.0 Message-Id: <20241021-tonyk-tmpfs-v8-9-f443d5814194@igalia.com> References: <20241021-tonyk-tmpfs-v8-0-f443d5814194@igalia.com> In-Reply-To: <20241021-tonyk-tmpfs-v8-0-f443d5814194@igalia.com> To: Gabriel Krisman Bertazi , Alexander Viro , Christian Brauner , Jan Kara , Theodore Ts'o , Andreas Dilger , Hugh Dickins , Andrew Morton , Jonathan Corbet , smcv@collabora.com Cc: kernel-dev@igalia.com, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, linux-ext4@vger.kernel.org, linux-mm@kvack.org, linux-doc@vger.kernel.org, Gabriel Krisman Bertazi , Randy Dunlap , =?utf-8?q?Andr=C3=A9_Almeida?= X-Mailer: b4 0.14.2 X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: 04E5B40004 X-Stat-Signature: ieuo4k3ribswswab9kjc55urrpy47r9s X-Rspam-User: X-HE-Tag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+omSq47H7cEWKnbizVO73JFfDBrBRm2JLnghmh1Non3q21/NXCs9j6JHtojCBWn4MVlPxBPbIXY1uOdOlC6DdURDjr+vdEZ/FdL80un1VFvX4FRo1f8kiB25Syi8TQZZydPpKuX1WoyTfBa3AoYsb11lsd6u04wMm0xhl3b3oWk6GKBPxF1z9BYxubMrqLtjiiLktvquI66STlG1X6FDoOiH99Nchid8+S9HbtsoGBNvOVRwdr2tGm9UvlosRUIv2UbhoFr5pumNrVobaujBl8xCZfqNO+ZIGxqwZ9W1FRM9s+MJesIR/MIPNdsPC+GVJirO8gMP6IuTMR2+q63yPiLSI0Sk8HmFg1pxlU1zvq1iUCu X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Document mounting options for casefold support in tmpfs. Reviewed-by: Gabriel Krisman Bertazi Reviewed-by: Randy Dunlap Signed-off-by: André Almeida --- Changes from v3: - Rewrote note about "this doesn't enable casefold by default" (Krisman) --- Documentation/filesystems/tmpfs.rst | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/Documentation/filesystems/tmpfs.rst b/Documentation/filesystems/tmpfs.rst index 56a26c843dbe964086503dda9b4e8066a1242d72..d677e0428c3f68148a3761bb232bbed5b9a41f76 100644 --- a/Documentation/filesystems/tmpfs.rst +++ b/Documentation/filesystems/tmpfs.rst @@ -241,6 +241,28 @@ So 'mount -t tmpfs -o size=10G,nr_inodes=10k,mode=700 tmpfs /mytmpfs' will give you tmpfs instance on /mytmpfs which can allocate 10GB RAM/SWAP in 10240 inodes and it is only accessible by root. +tmpfs has the following mounting options for case-insensitive lookup support: + +================= ============================================================== +casefold Enable casefold support at this mount point using the given + argument as the encoding standard. Currently only UTF-8 + encodings are supported. If no argument is used, it will load + the latest UTF-8 encoding available. +strict_encoding Enable strict encoding at this mount point (disabled by + default). In this mode, the filesystem refuses to create file + and directory with names containing invalid UTF-8 characters. +================= ============================================================== + +This option doesn't render the entire filesystem case-insensitive. One needs to +still set the casefold flag per directory, by flipping the +F attribute in an +empty directory. Nevertheless, new directories will inherit the attribute. The +mountpoint itself cannot be made case-insensitive. + +Example:: + + $ mount -t tmpfs -o casefold=utf8-12.1.0,strict_encoding fs_name /mytmpfs + $ mount -t tmpfs -o casefold fs_name /mytmpfs + :Author: Christoph Rohland , 1.12.01 @@ -250,3 +272,5 @@ RAM/SWAP in 10240 inodes and it is only accessible by root. KOSAKI Motohiro, 16 Mar 2010 :Updated: Chris Down, 13 July 2020 +:Updated: + André Almeida, 23 Aug 2024