Received: by 2002:a05:7412:d002:b0:f9:9049:d2ea with SMTP id bd2csp16925rdb; Wed, 20 Dec 2023 02:35:32 -0800 (PST) X-Google-Smtp-Source: AGHT+IGywqVHVclIgJvxMMxKdyBt9hPChjiDhZLJNPJvMC9XFFpob4Lp5wARRh4CK33DxcKKnNo6 X-Received: by 2002:a05:6358:6f9e:b0:170:4ac0:f9ef with SMTP id s30-20020a0563586f9e00b001704ac0f9efmr24908914rwn.15.1703068532400; Wed, 20 Dec 2023 02:35:32 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703068532; cv=none; d=google.com; s=arc-20160816; b=WC1CAm9OTGYcOWIUmPeK0OJaiuleGKf0aq9XVvoXkX2W4S6mA8KB3PAysv3WaBpu1u luNzQ7LHsXZTzvkbBqe4/43mc3lBLxHdn52rqZiM8xguGLsCDnBVoAw++jyxSjPr20DO KBFfB/bkzT0QS7fPHYkKE8vn/MwZL7C0gh+XRapU9PnnuIklwmaKhQzv2yCbzKIojPDo w8TY4uFfEjEMAFD2uFtkZ8ABy+rFjs2s61+0FNEaa97w8KQ7jCb564vMu6fZUmTQtcks SgZm0vgVFqjRYlBzyD7bLjkPxyrO8TqkvtROpQ+2IfWi/C4Og4zgxJEjG9phSGdZ5MQn 6hDA== ARC-Message-Signature: i=1; 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:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=8G9gIUzWq3S9DwN1F69m6K2FJSCQp0rMkcWT18Ovi08=; fh=uzDb1Y547P40bxrN7fs7dk1uFTaKu1NGvAn108bYGEI=; b=SrCfH0YToL7zAi/jlW2hSRNn9uNNSHQBRq6JrWBNUPIjyGN0SJW1XkOoYmv7K8Qg6F HHn10O+uTKjTBlk8g0x1c6wLGdJvch1lv9UMAci+eh++Y9EQQ8zKNo+ylohyY9cGLKvM VTrMKxTUtcxvM/qSFxOMC3N5evDhk0JCslcsUjaz1RcGXGz8WJXb7sXyi67aahkitQon HeUsqUH6iboi8ccDZcovr50/+SzWbzHSITfJi2DfrViV4ybC0xtLxZAH2aUnozN6pA2L 31bSDXAf6zx/Fl6BoLWqCm2UyqwAFf/iZ05PvghMjOiPxJV0ocyzqh4TWQHbNXUZgam8 /LsQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=eNQmNImu; spf=pass (google.com: domain of linux-kernel+bounces-6740-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-6740-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id r19-20020a17090aa09300b0028bc752bbc9si547951pjp.110.2023.12.20.02.35.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Dec 2023 02:35:32 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-6740-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=eNQmNImu; spf=pass (google.com: domain of linux-kernel+bounces-6740-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-6740-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com 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 sy.mirrors.kernel.org (Postfix) with ESMTPS id BEBA0B243F4 for ; Wed, 20 Dec 2023 10:27:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 5183220322; Wed, 20 Dec 2023 10:26:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="eNQmNImu" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-yw1-f174.google.com (mail-yw1-f174.google.com [209.85.128.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 490D22031F; Wed, 20 Dec 2023 10:26:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-yw1-f174.google.com with SMTP id 00721157ae682-5e76948cda7so19978727b3.3; Wed, 20 Dec 2023 02:26:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703068015; x=1703672815; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=8G9gIUzWq3S9DwN1F69m6K2FJSCQp0rMkcWT18Ovi08=; b=eNQmNImu26BPPuBy/6X19L7Xisfn+azCSQHpzTUjJXh07vZMx38bF4uEYCiUuNBbKl Ga0YSuptMrTKMNbiCdIVZp2cWQj+vWX54UxXNIcXchUlraQNC45R4J9FHa7h/POa3QhE Vls2SAvJzlecr9SdmF8HGwczSP4ScUHDm6SS76yWZmslIVU0I8UHKeplrouz4m+/bekh 5Aaaj13FcnSBIam9h2/etYD7H+a1EkPBZZRH3d9UUoxlVjyxd7F1aLl/+oiFw8lZtA3C f/CcYpjldIl5/DfIo6axfGbWAKBeN4TjG7AeIjcZqbsi6ffqEvT2pAPx9xQTyFyJPf6K YFMg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703068015; x=1703672815; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=8G9gIUzWq3S9DwN1F69m6K2FJSCQp0rMkcWT18Ovi08=; b=AcCMQoQA7catzKdwoKn4i0KJqAwyDt+51twcjPWNfJMrsZWHVH1YKhfYueFYz7O9o5 KA9qjkYRruxQjaSvnlHY2QJnOZ+qxRt/ogA1hdbIjIxxZhOXRVdHA27pS0DqQYE2QI4v TxFOu+TjeJJ/cIU2JV/HDqrCkpogLz7pXzOg27Yi/HGNZxqroPLz29h7g+/fmxsV/VPH BbQz/HkXpepRSbsisjf6DgEFqIJYJvoGALnTAm5ehOQi+eoU//wXcryrQRucZzwhCctR /3LIfYDheWh5LjJfr4fESRgi5xsTiMVsyY8vTlZ+CrDKfPWYZ5boHSPWdI8BGCgc7x8b sm0A== X-Gm-Message-State: AOJu0YxwnnbGISeRbe/l9LdG9u4PNUAtDJ7XYqNtAa3g6hMe+DWP/uAO /DFVuS/PQ1Z0pVjgigCN+pY= X-Received: by 2002:a05:6902:534:b0:db7:dacf:ed96 with SMTP id y20-20020a056902053400b00db7dacfed96mr11216655ybs.119.1703068014962; Wed, 20 Dec 2023 02:26:54 -0800 (PST) Received: from localhost ([185.215.181.26]) by smtp.gmail.com with ESMTPSA id w6-20020a25ef46000000b00db5380fc1absm1322769ybm.19.2023.12.20.02.26.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Dec 2023 02:26:54 -0800 (PST) From: Kevin Martin To: joeyzerocrash@protonmail.com, Masahiro Yamada , Nathan Chancellor , Nick Desaulniers , Nicolas Schier , linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Kevin Martin Subject: [PATCH 1/2] kbuild: Enable decompression for use by EXTRA_FIRMWARE The build system can currently only compress files. This patch adds the functionality to decompress files. Decompression is needed for building firmware files into the kernel if those files are compressed on the filesystem. Compressed firmware files are in use by Gentoo, Fedora, Arch, and others. Date: Wed, 20 Dec 2023 05:22:50 -0500 Message-ID: <941a566eb114701685dc44f708f81891b3bd085b.1703042082.git.kevinmbecause@gmail.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Signed-off-by: Kevin Martin --- scripts/Makefile.lib | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 1a965fe68..d043be3dc 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -523,6 +523,9 @@ quiet_cmd_xzkern_with_size = XZKERN $@ quiet_cmd_xzmisc = XZMISC $@ cmd_xzmisc = cat $(real-prereqs) | $(XZ) --check=crc32 --lzma2=dict=1MiB > $@ +quiet_cmd_xzdec = XZDEC $@ + cmd_xzdec = cat $(real-prereqs) | $(XZ) --decompress > $@ + # ZSTD # --------------------------------------------------------------------------- # Appends the uncompressed size of the data using size_append. The .zst @@ -548,6 +551,9 @@ quiet_cmd_zstd22 = ZSTD22 $@ quiet_cmd_zstd22_with_size = ZSTD22 $@ cmd_zstd22_with_size = { cat $(real-prereqs) | $(ZSTD) -22 --ultra; $(size_append); } > $@ +quiet_cmd_zstddec = ZSTDDEC $@ + cmd_zstddec = cat $(real-prereqs) | $(ZSTD) --decompress > $@ + # ASM offsets # --------------------------------------------------------------------------- -- 2.41.0