Received: by 2002:a05:7412:a9a2:b0:e2:908c:2ebd with SMTP id o34csp1228905rdh; Fri, 27 Oct 2023 08:09:58 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEoE1vjVagFM+eTpqPd+WthBLxynZkTtyppsvQTx5KwHi8hlmqnAbp/HXRlWetPirKmebM3 X-Received: by 2002:a05:6830:1081:b0:6b9:4d79:e08a with SMTP id y1-20020a056830108100b006b94d79e08amr2534860oto.32.1698419398219; Fri, 27 Oct 2023 08:09:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698419398; cv=none; d=google.com; s=arc-20160816; b=zo0zzIGTpTrMiSWd31bZBn4hzgmFiMqAP07lZi3OnV/Ap7WIfPKBCyt61JPizkWKwi p+RHtV6U8HU5k6ydcoA/tvpDJcNERNpuSnLYWofOuTdSTEv0LQ/9gXP2/xdFTOJZG8wW 7nS5G8v4gwab6kfMIAlofMHRfcWpay2rSwj0CSR++VCVifwx7ZnljFUkv/kFNuOWH0bI wimtYYAv5lIOCDkBsSHce9dawIxaLuVifTGxOlVLGTLwFqqRKzquu9egdFXsOkMxwmnn j4Ub940AMhocZr1oEl1vBGaK8GKE/j+ljHYlaaM0PC0eSBwgReTMmAQGizcWepCiehRk v2fg== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=K+Q8SznD4YEdTNAqWeFh3IR+IKhUM+Cg+mvQX53XToM=; fh=keEatAjqJ8JDfwyuW+GepWNF7G22gfkxxvvY1oYJ80k=; b=D/BRyyZ48MgEE41nvQpXEYXTaKzk3U8sDUkpaqCcwd7qLHzWRoy+WaQkASKgEb3Lde 6Et2nlnouUEfH/kcdiOJTPTcdm/D9nsARz173L12jbK/4GIQ6hyjbTcLW2ZZIyRonrDm gZElYwhBnv5O7E3GDItkgph5Bo+nwNDv2odcnHv4hq3b3auld6QKN8FXxy5hsZU4nLTX tLGMuin1uiXZjhffdC+R/JqUy0FwazPgVrxlnv5m6Swz67sRSg2Fq8VzmCjowDEg/HRN TVXi3lb0qQODKSivMACBFUS6vVha2KquZnCAsYe4HygbDgm46zeLNf22O56rcfaicilj 3Iqw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b="OI/xy8fy"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=cisco.com Return-Path: Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id o14-20020a67e14e000000b00452a281c2b5si263061vsl.163.2023.10.27.08.09.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Oct 2023 08:09:58 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b="OI/xy8fy"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=NONE dis=NONE) header.from=cisco.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id 08E73845650C; Fri, 27 Oct 2023 08:09:47 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345761AbjJ0PJk (ORCPT + 99 others); Fri, 27 Oct 2023 11:09:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37342 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345650AbjJ0PJj (ORCPT ); Fri, 27 Oct 2023 11:09:39 -0400 X-Greylist: delayed 63 seconds by postgrey-1.37 at lindbergh.monkeyblade.net; Fri, 27 Oct 2023 08:09:37 PDT Received: from aer-iport-5.cisco.com (aer-iport-5.cisco.com [173.38.203.67]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 088E0C4; Fri, 27 Oct 2023 08:09:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=4467; q=dns/txt; s=iport; t=1698419377; x=1699628977; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=Z30PGUp2OXocE8topJov5NYF/tsEceZZC+SDL8xdOnU=; b=OI/xy8fyMOjNhb8VPmSXX9JAKPm01kfV1nO1JQSDFqQssv2T8rWQhMk8 m1yByGuyhK62X8WfiyscnN2sY4f5MQYpA7cmiDi5OY0J5LfqoVYo42x4J wQdecWw7QgRlj3GoGB1X/iRwuwe49zXF/mGs9EmdRrawCmm9PaNOnTSC1 c=; X-CSE-ConnectionGUID: Mb9aEPJAQOWVefeqwFY5Vg== X-CSE-MsgGUID: lDbVgR8gTvuMaTrKYVRPQw== X-IronPort-AV: E=Sophos;i="6.03,256,1694736000"; d="scan'208";a="6852703" Received: from aer-iport-nat.cisco.com (HELO aer-core-11.cisco.com) ([173.38.203.22]) by aer-iport-5.cisco.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Oct 2023 15:08:31 +0000 Received: from localhost ([10.61.193.113]) (authenticated bits=0) by aer-core-11.cisco.com (8.15.2/8.15.2) with ESMTPSA id 39RF8Uxw125999 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 27 Oct 2023 15:08:31 GMT From: Ariel Miculas To: linux-doc@vger.kernel.org Cc: serge@hallyn.com, Ariel Miculas , Phillip Lougher , Jonathan Corbet , linux-kernel@vger.kernel.org Subject: [PATCH] docs: filesystems: document the squashfs specific mount options Date: Fri, 27 Oct 2023 18:08:14 +0300 Message-ID: <20231027150814.217689-1-amiculas@cisco.com> X-Mailer: git-send-email 2.42.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Authenticated-User: amiculas@cisco.com X-Outbound-SMTP-Client: 10.61.193.113, [10.61.193.113] X-Outbound-Node: aer-core-11.cisco.com X-Spam-Status: No, score=-8.4 required=5.0 tests=DKIMWL_WL_HIGH,DKIMWL_WL_MED, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_IN_DEF_DKIM_WL autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.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 (pete.vger.email [0.0.0.0]); Fri, 27 Oct 2023 08:09:47 -0700 (PDT) When SQUASHFS_CHOICE_DECOMP_BY_MOUNT is set, the "threads" mount option can be used to specify the decompression mode: single-threaded, multi-threaded or percpu. It can also be used to specify the number of threads used for decompression. This 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 --- Documentation/filesystems/squashfs.rst | 58 ++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/Documentation/filesystems/squashfs.rst b/Documentation/filesystems/squashfs.rst index df42106bae71..f71ac870603b 100644 --- a/Documentation/filesystems/squashfs.rst +++ b/Documentation/filesystems/squashfs.rst @@ -64,6 +64,64 @@ 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: + + ========== ============================================= + 2|3|... configure the number of threads used for + decompression + + The upper limit is num_online_cpus() * 2. + ========== ============================================= + +=================== ========================================================= + 3. Squashfs Filesystem Design ----------------------------- -- 2.42.0