Received: by 2002:a05:7412:37c9:b0:e2:908c:2ebd with SMTP id jz9csp2606020rdb; Fri, 22 Sep 2023 03:48:39 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFA2lcL/eh833EoxV3bsD218sLqMaaSTK/YBROOrIXdgq9NhVirzhEMdFtg4JjMgET3mZ0y X-Received: by 2002:a17:902:7d87:b0:1c4:29dd:2519 with SMTP id a7-20020a1709027d8700b001c429dd2519mr6067170plm.67.1695379719218; Fri, 22 Sep 2023 03:48:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695379719; cv=none; d=google.com; s=arc-20160816; b=Z5mxiSD6kcziEYP2g3z9S9uaJBt/ShLYfW07mKazoW6EkoBtI9eiwXuXVK7pX1WH+O Fp5UQoGQA1kC0MHknqMv7TxKtYxrpMurckMICIIdPuQhaBx/wU0mAs7ugIdevPYOiciF kAMRFBrPS/JjEQpLFrclV3QVqnMv6Tulj+w7+ur43HGcpCFYD9/Z8KeBzk+JZ6XelrUg FHC/xHrva15ozdsmrWq5Q+zYOhUtamch1pOILZU6KSJWLKbAdUxEdXk27Uj4Ela2bRl7 6vOg1wa+OXKaxkFSpr0OujKm+w847pXoxobM3yfZQ1a6viEbCobxNkKKAEL+amnv0VCZ wj2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=p0bdSHfuiIf49mS6w4fhFKXDj5/sFmKlLwmZlMl0SWk=; fh=I1YS8ncQkfnMrBuPilHN1U1PzCjw3KdVL2ZRPZSLICA=; b=ITD44/MN3F0EWH7d5MJHP/DRkgHGwuFarcveaOGLpJHMikRGC0YzFEeAs1mhTghtKj 1vkwyP0DtC7HyhJs9UKkoQcwVTjh8qyo0QUBp/UVr/ZvUGdb52v8i3eW9ExA6PrAtexW lpPGslixuMKPvSkvw4Ka5XAq5uS8ZPlZ7mwMnOGfEUymQwscxYImKxr/zjIZKAfN2ZdP kcuwEbCadFjtQI/nxv0xssh6r1WZMC16SrOm9XPukrw+7bpLz1VKDNg19H1bqp/no+Jc uQeqg/yDfNhetRZZshy3RvUanXhgop3YPTd4nP9lCN0J6Erg2ci/h0h/SKIC88Cx8Dah yu6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TXhsDQUf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from agentk.vger.email (agentk.vger.email. [2620:137:e000::3:2]) by mx.google.com with ESMTPS id z14-20020a1709027e8e00b001b864e277e1si3464308pla.494.2023.09.22.03.48.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 22 Sep 2023 03:48:39 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) client-ip=2620:137:e000::3:2; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=TXhsDQUf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:2 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by agentk.vger.email (Postfix) with ESMTP id 41CA181B5D1E; Fri, 22 Sep 2023 03:42:48 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at agentk.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233463AbjIVKmf (ORCPT + 99 others); Fri, 22 Sep 2023 06:42:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38606 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233427AbjIVKmT (ORCPT ); Fri, 22 Sep 2023 06:42:19 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1113AAC; Fri, 22 Sep 2023 03:42:14 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id AFC69C433CB; Fri, 22 Sep 2023 10:42:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1695379333; bh=ORm7kuwlD/Fvo8ESZ1v+JAsTRK52tEMMlKCCDrA0YY8=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=TXhsDQUfnwx6RyV9NNuadjwzrT2EUkn+EwKJevn77xA6Wd7mRdf2ZNwVAjCLB2c8v 9RHXdZLvEOvr84+SkxV/2USZTmYChZiOnyuPSQjPMcsxKIfgULhiMSj1CqUCcG8aHz iO+AK058Ic2GveDrdS12CWQIljFXvSl7FY+18Dg2LB4z7+4zhniLtLnRMv7FjfUlnd GZRZ+FjxXL0xnhMpUbJLdm9bZ6FJ78cK1orQhshDSp8S79bnx4ka8GEkrxtMhL4qo6 mseuLCdeXRUeGw2Cr4WJltzc0jZ4EhrYD1Y9eYF75qlxjmarYl5Ycuy2JMnOjac1Uh KPdbzMdtH7ypw== Received: by mail-oo1-f43.google.com with SMTP id 006d021491bc7-57b2e23de65so993535eaf.1; Fri, 22 Sep 2023 03:42:13 -0700 (PDT) X-Gm-Message-State: AOJu0Yy8qORikjsl5XsKogyUgzCAd38gkQoHhMWkUgaqZmpTb8C/Yz9m z9/lHEy9i07Qges7Jv0whCjtfKjNufyoMW3LiKg= X-Received: by 2002:a05:6870:891a:b0:1bf:1a58:c50 with SMTP id i26-20020a056870891a00b001bf1a580c50mr8773299oao.9.1695379333035; Fri, 22 Sep 2023 03:42:13 -0700 (PDT) MIME-Version: 1.0 References: <3d34a965-ab9c-d549-0c63-c717ab5d2edc@tweek.dk> In-Reply-To: From: Masahiro Yamada Date: Fri, 22 Sep 2023 19:41:36 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] Use CRC32 and a 1MiB dictionary for XZ compressed modules To: Martin Nybo Andersen Cc: Tor Vic , Nathan Chancellor , Nick Desaulniers , Nicolas Schier , Nick Terrell , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, Lucas De Marchi Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, 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 agentk.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 (agentk.vger.email [0.0.0.0]); Fri, 22 Sep 2023 03:42:48 -0700 (PDT) On Fri, Sep 22, 2023 at 5:52=E2=80=AFPM Martin Nybo Andersen wrote: > > On Fri, 22 Sep 2023, Tor Vic wrote: > > >> > >> Hello? > > > > Hello, > > :) > > >> Anyone? > >> > >> Best regards, > >> - Martin > >> > >> On Fri, 15 Sep 2023, Martin Nybo Andersen wrote: > >> > >>> Kmod is now using the kernel decompressor which doesn't handle CRC64 > >>> and dictionaries larger than 1MiB. > >>> > >>> Fixes: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D1050582 > >>> Signed-off-by: Martin Nybo Andersen > >>> --- > >>> scripts/Makefile.modinst | 2 +- > >>> 1 file changed, 1 insertion(+), 1 deletion(-) > >>> > >>> diff --git a/scripts/Makefile.modinst b/scripts/Makefile.modinst > >>> index c59cc57286ba..ffbafbd3aeea 100644 > >>> --- a/scripts/Makefile.modinst > >>> +++ b/scripts/Makefile.modinst > >>> @@ -144,7 +144,7 @@ endif > >>> quiet_cmd_gzip =3D GZIP $@ > >>> cmd_gzip =3D $(KGZIP) -n -f $< > >>> quiet_cmd_xz =3D XZ $@ > >>> - cmd_xz =3D $(XZ) --lzma2=3Ddict=3D2MiB -f $< > >>> + cmd_xz =3D $(XZ) --check=3Dcrc32 --lzma2=3Ddict=3D1MiB -f $< > > > > I wonder whether it should be guarded with > > ifdef CONFIG_MODULE_DECOMPRESS > > > > But on the other hand, the difference between 1M and 2M is likely very = small > > in terms of compression ratio. > > That would work, since kmod decompress the modules in userspace if > CONFIG_MODULE_DECOMPRESS if off. > > What I'm aiming for is just that the kernel should be able to decompress > its own modules, when it advertises it. Hello, sorry for the delay. I am OK with picking the patch to my tree. I think we can use --check=3Dcrc32 --lzma2=3Ddict=3D1MiB unconditionally. (But, if the in-kernel decompressor is improved to understand CRC64 in the future, we can loosen this restriction again.) Just small change requests. Please do not use the Fixes tag to point at the Debian bug tracker. Instead, you can do Link: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D1050582 or Closes: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D1050582 Also, mention that this change happened in kmod commit 09c9f8c5df04 ("libkmod: Use kernel decompression when available= ") in the commit description might be helpful. I added Lukas to CC. He is the author of the change on kmod side. > Cheers, > Martin > > > Cheers, > > Tor Vic > > > >>> quiet_cmd_zstd =3D ZSTD $@ > >>> cmd_zstd =3D $(ZSTD) -T0 --rm -f -q $< > >>> > >>> -- > >>> 2.40.1 > >>> > >>> > >> > > > > --=20 Best Regards Masahiro Yamada