From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758781Ab2CSSeY (ORCPT ); Mon, 19 Mar 2012 14:34:24 -0400 Received: from mailfw02.zoner.fi ([84.34.147.249]:52744 "EHLO mailfw02.zoner.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755502Ab2CSSeX (ORCPT ); Mon, 19 Mar 2012 14:34:23 -0400 Date: Mon, 19 Mar 2012 20:34:08 +0200 From: Lasse Collin To: Linus Torvalds Cc: Jan Beulich , linux-kernel@vger.kernel.org Subject: [PATCH] xz: Enable BCJ filters on SPARC and 32-bit x86 Message-ID: <20120319203408.6d5b2b76@tukaani.org> X-Mailer: Claws Mail 3.8.0 (GTK+ 2.24.10; x86_64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Antivirus-Scanner: Clean mail though you should still use an Antivirus Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lasse Collin The BCJ filters were meant to be enabled already on these archs, but the xz_wrap.sh script was buggy. Enabling the filters should give smaller kernel images. xz_wrap.sh will now use $SRCARCH instead of $ARCH to detect the architecture. That way it doesn't need to care about the subarchs (like i386 vs. x86_64) since the BCJ filters don't care either. Signed-off-by: Lasse Collin Acked-by: Jan Beulich --- I'm not sure if this should be fixed in stable kernels. It's not a critical bug so maybe it is better to not touch the stable kernels. diff -uprN linux-3.3.orig/scripts/xz_wrap.sh linux-3.3/scripts/xz_wrap.sh --- linux-3.3.orig/scripts/xz_wrap.sh 2012-03-19 01:15:34.000000000 +0200 +++ linux-3.3/scripts/xz_wrap.sh 2012-03-19 11:20:55.289074991 +0200 @@ -12,8 +12,8 @@ BCJ= LZMA2OPTS= -case $ARCH in - x86|x86_64) BCJ=--x86 ;; +case $SRCARCH in + x86) BCJ=--x86 ;; powerpc) BCJ=--powerpc ;; ia64) BCJ=--ia64; LZMA2OPTS=pb=4 ;; arm) BCJ=--arm ;;