From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48090) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XCDPG-0003R4-Sp for qemu-devel@nongnu.org; Tue, 29 Jul 2014 15:50:00 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XCDPB-0002qe-Ea for qemu-devel@nongnu.org; Tue, 29 Jul 2014 15:49:54 -0400 Received: from mx1.redhat.com ([209.132.183.28]:19220) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XCDPB-0002qU-78 for qemu-devel@nongnu.org; Tue, 29 Jul 2014 15:49:49 -0400 Received: from int-mx11.intmail.prod.int.phx2.redhat.com (int-mx11.intmail.prod.int.phx2.redhat.com [10.5.11.24]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s6TJnlx7016681 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Tue, 29 Jul 2014 15:49:47 -0400 Received: from localhost (vpn1-5-136.ams2.redhat.com [10.36.5.136]) by int-mx11.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id s6TJnj52017619 for ; Tue, 29 Jul 2014 15:49:46 -0400 Date: Tue, 29 Jul 2014 20:49:45 +0100 From: "Richard W.M. Jones" Message-ID: <20140729194945.GA14001@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Subject: [Qemu-devel] Should qemu -kernel option be able to gunzip kernel? (aarch64) List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org On Fedora/aarch64, the kernel in /boot is a gzip-compressed file: $ file /boot/vmlinuz-* /boot/vmlinuz-0-rescue-520be7dc677d4fab99d3d3ce91f90c84: gzip compressed data, max compression, from Unix /boot/vmlinuz-3.16.0-0.rc6.git3.1.rwmj2.fc22.aarch64: gzip compressed data, max compression, from Unix /boot/vmlinuz-3.16.0-0.rc6.git3.1.rwmj3.fc22.aarch64: gzip compressed data, max compression, from Unix /boot/vmlinuz-3.16.0-0.rc6.git3.1.rwmj4.fc22.aarch64: gzip compressed data, max compression, from Unix [not just for the custom kernels I've been building ...] Apparently UEFI and u-boot can just handle this by uncompressing the kernel on the fly. However qemu-system-aarch64 -kernel option definitely can*not*, with the result that if you do the "obvious": qemu-system-aarch64 -kernel /boot/vmlinuz-xxx it just hangs immediately, because it's trying to execute gzip data. I don't know the rights and wrongs of this. Maybe Fedora is wrong for having a gzip-compressed kernel. But should the -kernel option be able to detect if the file is gzip encoded and uncompress it on the fly? (If so I'll post a patch for this unless someone else jumps in). Mainly I'm asking because I've no idea what is the right thing to do here. There could be another obvious fix. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-top is 'top' for virtual machines. Tiny program with many powerful monitoring features, net stats, disk stats, logging, etc. http://people.redhat.com/~rjones/virt-top