From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NM3Cw-0006WO-0o for qemu-devel@nongnu.org; Sat, 19 Dec 2009 12:35:10 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NM3Cu-0006W2-Oj for qemu-devel@nongnu.org; Sat, 19 Dec 2009 12:35:09 -0500 Received: from [199.232.76.173] (port=60882 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NM3Cu-0006Vz-HO for qemu-devel@nongnu.org; Sat, 19 Dec 2009 12:35:08 -0500 Received: from hall.aurel32.net ([88.191.82.174]:58990) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1NM3Ct-0007RJ-DV for qemu-devel@nongnu.org; Sat, 19 Dec 2009 12:35:08 -0500 Date: Sat, 19 Dec 2009 18:34:33 +0100 From: Aurelien Jarno Subject: Re: [Qemu-devel] [PATCH] Add SH4 ELF magic into qemu-binfmt-conf.sh. Message-ID: <20091219173433.GU24729@hall.aurel32.net> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: Sender: Aurelien Jarno List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: David Kozub Cc: qemu-devel@nongnu.org On Wed, Dec 16, 2009 at 11:03:42PM +0100, David Kozub wrote: > > Signed-off-by: David Kozub > --- > qemu-binfmt-conf.sh | 9 ++++++++- > 1 files changed, 8 insertions(+), 1 deletions(-) > > diff --git a/qemu-binfmt-conf.sh b/qemu-binfmt-conf.sh > index ba916ac..9c65c9a 100644 > --- a/qemu-binfmt-conf.sh > +++ b/qemu-binfmt-conf.sh > @@ -1,5 +1,5 @@ > #!/bin/sh > -# enable automatic i386/ARM/M68K/MIPS/SPARC/PPC program execution by the kernel > +# enable automatic i386/ARM/M68K/MIPS/SPARC/PPC/SH4 program execution by the kernel > > # load the binfmt_misc module > if [ ! -d /proc/sys/fs/binfmt_misc ]; then > @@ -27,6 +27,9 @@ case "$cpu" in > armv4l) > cpu="arm" > ;; > + sh4) > + cpu="sh4" > + ;; > esac As already pointed, this part is actually useless. > # register the interpreter for each cpu except for the native one > @@ -60,3 +63,7 @@ if [ $cpu != "mips" ] ; then > echo ':mips64:M::\x7fELF\x02\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff:/usr/local/bin/qemu-mips64:' > /proc/sys/fs/binfmt_misc/register > echo ':mips64el:M::\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x08\x00:\xff\xff\xff\xff\xff\xff\xff\x00\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:/usr/local/bin/qemu-mips64el:' > /proc/sys/fs/binfmt_misc/register > fi > +if [ $cpu != "sh4" ] ; then > + echo ':sh4:M::\x7fELF\x01\x01\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x2a\x00:\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff\xff:/usr/local/bin/qemu-sh4:' > /proc/sys/fs/binfmt_misc/register > + echo ':sh4eb:M::\x7fELF\x01\x02\x01\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x00\x2a:\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xff\xfe\xff\xff:/usr/local/bin/qemu-sh4eb:' > /proc/sys/fs/binfmt_misc/register > +fi > -- > 1.6.4.4 > > > -- Aurelien Jarno GPG: 1024D/F1BCDB73 aurelien@aurel32.net http://www.aurel32.net