From patchwork Tue Oct 4 23:34:27 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Mentz X-Patchwork-Id: 678270 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2001:1868:205::9]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3spb0K6qPXz9s5g for ; Wed, 5 Oct 2016 10:36:33 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=google.com header.i=@google.com header.b=b+3VKbxL; dkim-atps=neutral Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.85_2 #1 (Red Hat Linux)) id 1brZGA-0003Ei-9H; Tue, 04 Oct 2016 23:36:30 +0000 Received: from mail-pf0-x22e.google.com ([2607:f8b0:400e:c00::22e]) by bombadil.infradead.org with esmtps (Exim 4.85_2 #1 (Red Hat Linux)) id 1brZG8-0003DY-6z for linux-snps-arc@lists.infradead.org; Tue, 04 Oct 2016 23:36:29 +0000 Received: by mail-pf0-x22e.google.com with SMTP id 190so33804853pfv.0 for ; Tue, 04 Oct 2016 16:36:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id; bh=djggCR05SyBYnlSHtap3t+A8PBWLMUdhj0ruDdhhcio=; b=b+3VKbxLe7Lg3xktO7zQ3EJIql5lhn4770p3l8twftWdiJreA8rv6d3GjW7O4Jsb02 oRiEi0l4ZCXTZkjlimpYsGrV0mpoFRtyEZ3XT3p6q9Md3BxH3fqQW+YppAwU5NqfDdrB d2fFYPogymgmh5T8VxTz5ykEpW3/jeuxDQSBjdGbifWKZPfJ6AHP32ayo3ArjCPGsxO8 0B86R03B+JrrbJTt5sx5VZfPMwTwIkLNsGCN0zClsN+mTeROCt+Vv4XconncwZmQbEBn u8Ide/HjIWAKT3wv486Yvtit/f2UceUPPjuVBhKtHmV/2p7gcJ6jm/rzEPZY6fgLt6VS jeBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=djggCR05SyBYnlSHtap3t+A8PBWLMUdhj0ruDdhhcio=; b=Bo5AMYbXJOSnqQCDJu9GDT/GxCxkneUna7Wgwtcgl7AUs6HHM7H1zAYjknXmL5YHXF LBvAFMXnLTd2TjyVsBa3yTxUYNgOPh27ueRDKvVU2rj7sVXn1B9GLN+qB0bFJjgmDlpB aGd9Lm4Q56OlHDWtjmlkeDPTpO+cx8G1C8BYDAAgMUMc9vm7xxkTEqe3gB+oDM/IGWFy 2S2GhYE5Gg7dPhtZcxkVnxPBzZKYYUMO09ppUoA3N3c0MS+SpALmpJB9F5gJvSzvJb/U of1AZHn96F2dYAsZd7PwD5dD+KQQPk/aMrC0uIyUV4bQ/d78x2YTZGJPUiEFAhi1W9wV R1kg== X-Gm-Message-State: AA6/9RnPa1lkt0rek85JSSJQ6clPRgxMfrRssHukR+nOeU5+llP5wbXYiJLtLVELx4qOGX4t X-Received: by 10.98.217.7 with SMTP id s7mr1744153pfg.72.1475624164870; Tue, 04 Oct 2016 16:36:04 -0700 (PDT) Received: from danielmentz.mtv.corp.google.com ([100.96.234.43]) by smtp.gmail.com with ESMTPSA id d75sm1577106pfl.81.2016.10.04.16.36.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 04 Oct 2016 16:36:04 -0700 (PDT) From: Daniel Mentz To: linux-snps-arc@lists.infradead.org Subject: [PATCH] ARC: [build] Support gz, lzma compressed uImage Date: Tue, 4 Oct 2016 16:34:27 -0700 Message-Id: <1475624067-17290-1-git-send-email-danielmentz@google.com> X-Mailer: git-send-email 2.8.0.rc3.226.g39d4020 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20161004_163628_347552_7F9EE366 X-CRM114-Status: UNSURE ( 8.97 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -4.1 (----) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-4.1 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [2607:f8b0:400e:c00:0:0:0:22e listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.4 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid X-BeenThere: linux-snps-arc@lists.infradead.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Linux on Synopsys ARC Processors List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Vineet Gupta , linux-kernel@vger.kernel.org, Daniel Mentz MIME-Version: 1.0 Sender: "linux-snps-arc" Errors-To: linux-snps-arc-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Add support for lzma compressed uImage. Support for gzip was already available but could not be enabled because we were missing CONFIG_HAVE_KERNEL_GZIP in arch/arc/Kconfig. Signed-off-by: Daniel Mentz Cc: linux-snps-arc@lists.infradead.org Cc: Vineet Gupta --- arch/arc/Kconfig | 2 ++ arch/arc/boot/Makefile | 16 ++++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/arch/arc/Kconfig b/arch/arc/Kconfig index 25a760b..a538631 100644 --- a/arch/arc/Kconfig +++ b/arch/arc/Kconfig @@ -41,6 +41,8 @@ config ARC select PERF_USE_VMALLOC select HAVE_DEBUG_STACKOVERFLOW select HAVE_GENERIC_DMA_COHERENT + select HAVE_KERNEL_GZIP + select HAVE_KERNEL_LZMA config MIGHT_HAVE_PCI bool diff --git a/arch/arc/boot/Makefile b/arch/arc/boot/Makefile index e597cb34..f94cf15 100644 --- a/arch/arc/boot/Makefile +++ b/arch/arc/boot/Makefile @@ -14,9 +14,15 @@ UIMAGE_ENTRYADDR = $(LINUX_START_TEXT) suffix-y := bin suffix-$(CONFIG_KERNEL_GZIP) := gz +suffix-$(CONFIG_KERNEL_LZMA) := lzma -targets += uImage uImage.bin uImage.gz -extra-y += vmlinux.bin vmlinux.bin.gz +targets += uImage +targets += uImage.bin +targets += uImage.gz +targets += uImage.lzma +extra-y += vmlinux.bin +extra-y += vmlinux.bin.gz +extra-y += vmlinux.bin.lzma $(obj)/vmlinux.bin: vmlinux FORCE $(call if_changed,objcopy) @@ -24,12 +30,18 @@ $(obj)/vmlinux.bin: vmlinux FORCE $(obj)/vmlinux.bin.gz: $(obj)/vmlinux.bin FORCE $(call if_changed,gzip) +$(obj)/vmlinux.bin.lzma: $(obj)/vmlinux.bin FORCE + $(call if_changed,lzma) + $(obj)/uImage.bin: $(obj)/vmlinux.bin FORCE $(call if_changed,uimage,none) $(obj)/uImage.gz: $(obj)/vmlinux.bin.gz FORCE $(call if_changed,uimage,gzip) +$(obj)/uImage.lzma: $(obj)/vmlinux.bin.lzma FORCE + $(call if_changed,uimage,lzma) + $(obj)/uImage: $(obj)/uImage.$(suffix-y) @ln -sf $(notdir $<) $@ @echo ' Image $@ is ready'