Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756908Ab3IOJT0 (ORCPT ); Sun, 15 Sep 2013 05:19:26 -0400 Received: from mx1.redhat.com ([209.132.183.28]:15318 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751357Ab3IOJTZ (ORCPT ); Sun, 15 Sep 2013 05:19:25 -0400 Date: Sun, 15 Sep 2013 14:49:05 +0530 (IST) From: P J P X-X-Sender: pjp@dhcp193-39.pnq.redhat.com To: linux-kernel@vger.kernel.org Subject: [PATCH 2/2] Export initial ramdisk compression config Message-ID: MIME-Version: 1.0 Content-Type: MULTIPART/MIXED; BOUNDARY="1091184577-1494639324-1379236756=:7830" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 5448 Lines: 102 This message is in MIME format. The first part should be readable text, while the remaining parts are likely unreadable without MIME-aware tools. --1091184577-1494639324-1379236756=:7830 Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII Hello, While building the 3.11 kernel recently, I bumped into this issue. Menuconfig allows one to choose compression format of an initial ramdisk image. But this selection does not result in creation of a duly compressed initramfs image. Because - $ make install - does not pass on the selected compression option to dracut(8) tool, which generates the initramfs file. This leads to a situation wherein the initramfs file is gzip(1) compressed, but the kernel knows only to decompress the user's chosen compression format. The attached patch herein, attempts to fix this issue by exporting the compression configuration option to an environment variable of a sub-shell spawned by Make(1) with the invocation of installkernel(8) during the installation process. The dracut(8) & new-kernel-pkg(8) tools need to be patched to recognise and read such an environment variable and use the selected compression algorithm while creating the initial ramdisk image files. Could someone please review this one too? Thank you. -- Prasad J Pandit / Red Hat Security Response Team DB7A 84C5 D3F9 7CD1 B5EB C939 D048 7860 3655 602B --1091184577-1494639324-1379236756=:7830 Content-Type: TEXT/PLAIN; charset=US-ASCII; name=0002-Export-initial-ramdisk-compression-config-option.patch Content-Transfer-Encoding: BASE64 Content-ID: Content-Description: Content-Disposition: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iAgKi8NCiBzdGF0aWMgaW50IF9faW5pdA0KIGlkZW50aWZ5X3JhbWRpc2tf aW1hZ2UoaW50IGZkLCBpbnQgc3RhcnRfYmxvY2ssIGRlY29tcHJlc3NfZm4g KmRlY29tcHJlc3NvcikNCi0tIA0KMS44LjMuMQ0KDQo= --1091184577-1494639324-1379236756=:7830-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/