Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp2383737rdh; Sun, 29 Oct 2023 13:37:33 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHRvXxyohpZqrCn0sNQBNTZZP7Ht60mMriIEnRsLU8CN3OImf+7KDmdhz9FGbXAzkM4dLrW X-Received: by 2002:a17:903:245:b0:1ca:e05a:93a2 with SMTP id j5-20020a170903024500b001cae05a93a2mr7118834plh.32.1698611853620; Sun, 29 Oct 2023 13:37:33 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698611853; cv=none; d=google.com; s=arc-20160816; b=otoa3rV8p90Gfx/Kj5exRV6CjkZ2+tydh/eH5ktqHnI9tX36RuLZP19Z4ZUIsdMOKj VinP47gcT/8/RuOdG1Z5QHmYrA16HuQ8iVuKbZ2sXPTjFZMoPF6pQ6XmMyCtxCm48Cyd 0W9YPU3pI0XKIqU5bvs9hFF63Avnml54F7WiJ2Vl9RnaUylebZVIll1jgPQlnRrvI9My Rv7Y6z/LFkJeWjSxWpHSQZao5IAVWVAZYo/ghOt1DPc6MntHOZNTu57kDYLzsFp/ybRx tG1qhr67uh94GJuwZTOhUSYTKSsEJqy5mEeGgUaeXxUSlsDWkYRIMub+3CKjKXt3eLPJ B0DA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:subject:user-agent:mime-version:date:message-id; bh=PCiiofxBf+pgpNmqjZDJGywl3gtaInvLxm/S3C5jRxU=; fh=sF7e5jrpwUJaHq2dbS53UbOaVrjpfqAk8DhA5w4GuG0=; b=QZo0GHEb75zWuI2rP6vpoYaHvuh8n6Ry+Zygq8ccIA1nARhBj+m9zw9CvKm88+LAdt 7qkRlx+9BxWGU/IsUSHlRuYN5sQs8Ixx+jNnczhJoqda91qMVFGD8Wf0IldTUbsgpcSB r9XayaHswEte/GWmsUjRN2gqtT+ORnL+KQTTuXTguuaXpATCx5m4eOfiSqA3kr86uwHY BgikfIPULk9qS3jg1xvCzQUfLKgQewLy5Wor6R2zXNmyrfYOccGT465mUl40hHuvrlpB 6Hz4xYvupehvbOJ9b2FhYgQqMtWPsW3cQEr7lVUHtLKztTQaBiHywcHK7bTgkD2sXxyr SFjQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [2620:137:e000::3:3]) by mx.google.com with ESMTPS id d19-20020a170903209300b001cc50c56980si255172plc.411.2023.10.29.13.37.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 29 Oct 2023 13:37:33 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) client-ip=2620:137:e000::3:3; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:3 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 790F2806E3F2; Sun, 29 Oct 2023 13:37:13 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229795AbjJ2UeF (ORCPT + 99 others); Sun, 29 Oct 2023 16:34:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38412 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229512AbjJ2UeE (ORCPT ); Sun, 29 Oct 2023 16:34:04 -0400 Received: from p3plwbeout26-05.prod.phx3.secureserver.net (p3plsmtp26-05-2.prod.phx3.secureserver.net [216.69.139.32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5555DC2 for ; Sun, 29 Oct 2023 13:34:00 -0700 (PDT) Received: from mailex.mailcore.me ([94.136.40.142]) by :WBEOUT: with ESMTP id xCTuqFGaNm1kPxCTvqaQRp; Sun, 29 Oct 2023 13:33:59 -0700 X-CMAE-Analysis: v=2.4 cv=bLPTnNyZ c=1 sm=1 tr=0 ts=653ec1b7 a=s1hRAmXuQnGNrIj+3lWWVA==:117 a=84ok6UeoqCVsigPHarzEiQ==:17 a=ggZhUymU-5wA:10 a=IkcTkHD0fZMA:10 a=bhdUkHdE2iEA:10 a=AUd_NHdVAAAA:8 a=FXvPX3liAAAA:8 a=VwQbUJbxAAAA:8 a=vaoKmyfopMuWMe4x9wgA:9 a=QEXdDO2ut3YA:10 a=UObqyxdv-6Yh2QiB9mM_:22 a=AjGcO6oz07-iQ99wixmX:22 X-SECURESERVER-ACCT: phillip@squashfs.org.uk X-SID: xCTuqFGaNm1kP Received: from 82-69-79-175.dsl.in-addr.zen.co.uk ([82.69.79.175] helo=[192.168.178.90]) by smtp12.mailcore.me with esmtpa (Exim 4.94.2) (envelope-from ) id 1qxCTr-0006on-PN; Sun, 29 Oct 2023 20:33:56 +0000 Message-ID: Date: Sun, 29 Oct 2023 20:33:54 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1 Subject: Re: [PATCH v2] docs: filesystems: document the squashfs specific mount options To: Ariel Miculas , linux-doc@vger.kernel.org, Andrew Morton Cc: serge@hallyn.com, Jonathan Corbet , linux-kernel@vger.kernel.org References: <20231029161924.50648-1-amiculas@cisco.com> From: Phillip Lougher In-Reply-To: <20231029161924.50648-1-amiculas@cisco.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Mailcore-Auth: 439999529 X-Mailcore-Domain: 1394945 X-123-reg-Authenticated: phillip@squashfs.org.uk X-Originating-IP: 82.69.79.175 X-CMAE-Envelope: MS4xfL4x8jLDkzbGkBtVc9zmuJx9uFFd9xvMwlrG/h/PKB8vMyWom8ivbSHcE/5424we7xTRPXYW+UujIFAE7bc5T6WZyTRxMiO1mBtaXwUoNhJ/aGSj5rO9 7InyJdAB4F0LYSShaZpEK8nVC2W79Pp5bIMHjW0flT96wQ0ls2+45syAo5mUTIAYd31CSegRR8/1zQt0SYNpuGq3Z0DY74f3TLqZlVrSedPGiyMXu6JuDtHM dV1OQYkbLdAn+/IBRXNjYg== X-Spam-Status: No, score=-3.7 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Sun, 29 Oct 2023 13:37:13 -0700 (PDT) On 29/10/2023 16:19, Ariel Miculas wrote: > When SQUASHFS_CHOICE_DECOMP_BY_MOUNT is set, the "threads" mount option > can be used to specify the decompression mode: single-threaded, > multi-threaded, percpu or the number of threads used for decompression. > When SQUASHFS_CHOICE_DECOMP_BY_MOUNT is not set and > SQUASHFS_DECOMP_MULTI is set, the "threads" option can also be used to > specify the number of threads used for decompression. This mount option > is only mentioned in fs/squashfs/Kconfig, which makes it difficult to > find. > > Another mount option available is "errors", which can be configured to > panic the kernel when squashfs errors are encountered. > > Add both these options to the squashfs documentation, making them more > noticeable. > > Signed-off-by: Ariel Miculas Looks good to me. Reviewed-by: Phillip Lougher > --- > Documentation/filesystems/squashfs.rst | 59 ++++++++++++++++++++++++++ > 1 file changed, 59 insertions(+) > > diff --git a/Documentation/filesystems/squashfs.rst b/Documentation/filesystems/squashfs.rst > index df42106bae71..0a7fa66b70f8 100644 > --- a/Documentation/filesystems/squashfs.rst > +++ b/Documentation/filesystems/squashfs.rst > @@ -64,6 +64,65 @@ obtained from this site also. > The squashfs-tools development tree is now located on kernel.org > git://git.kernel.org/pub/scm/fs/squashfs/squashfs-tools.git > > +2.1 Mount options > +----------------- > +=================== ========================================================= > +errors=%s Specify whether squashfs errors trigger a kernel panic > + or not > + > + ========== ============================================= > + continue errors don't trigger a panic (default) > + panic trigger a panic when errors are encountered, > + similar to several other filesystems (e.g. > + btrfs, ext4, f2fs, GFS2, jfs, ntfs, ubifs) > + > + This allows a kernel dump to be saved, > + useful for analyzing and debugging the > + corruption. > + ========== ============================================= > +threads=%s Select the decompression mode or the number of threads > + > + If SQUASHFS_CHOICE_DECOMP_BY_MOUNT is set: > + > + ========== ============================================= > + single use single-threaded decompression (default) > + > + Only one block (data or metadata) can be > + decompressed at any one time. This limits > + CPU and memory usage to a minimum, but it > + also gives poor performance on parallel I/O > + workloads when using multiple CPU machines > + due to waiting on decompressor availability. > + multi use up to two parallel decompressors per core > + > + If you have a parallel I/O workload and your > + system has enough memory, using this option > + may improve overall I/O performance. It > + dynamically allocates decompressors on a > + demand basis. > + percpu use a maximum of one decompressor per core > + > + It uses percpu variables to ensure > + decompression is load-balanced across the > + cores. > + 1|2|3|... configure the number of threads used for > + decompression > + > + The upper limit is num_online_cpus() * 2. > + ========== ============================================= > + > + If SQUASHFS_CHOICE_DECOMP_BY_MOUNT is **not** set and > + SQUASHFS_DECOMP_MULTI is set: > + > + ========== ============================================= > + 2|3|... configure the number of threads used for > + decompression > + > + The upper limit is num_online_cpus() * 2. > + ========== ============================================= > + > +=================== ========================================================= > + > 3. Squashfs Filesystem Design > ----------------------------- >