All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexey Kardashevskiy <aik@ozlabs.ru>
To: Alexander Graf <agraf@suse.de>
Cc: Julio Guerra <guerr@julio.in>,
	qemu-ppc@nongnu.org, qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2] e600 core for MPC86xx processors
Date: Mon, 24 Jun 2013 14:14:29 +1000	[thread overview]
Message-ID: <51C7C7A5.7090300@ozlabs.ru> (raw)
In-Reply-To: <FE4DCC62-2059-439B-8059-592B0E038D96@suse.de>

On 06/21/2013 10:03 PM, Alexander Graf wrote:
> 
> On 21.06.2013, at 14:01, Julio Guerra wrote:
> 
>> 2013/6/21 Alexander Graf <agraf@suse.de>:
>>>
>>> On 26.05.2013, at 19:41, Julio Guerra wrote:
>>>
>>>> MPC86xx processors are based on the e600 core, which is not the case
>>>> in qemu where it is based on the 7400 processor.
>>>>
>>>> This patch creates the e600 core and instantiates the MPC86xx
>>>> processors based on it. Therefore, adding the high BATs and the SPRG
>>>> 4..7 registers, which are e600-specific [1].
>>>>
>>>> This allows to define the MPC8610 processor too and my program running
>>>> on a real MPC8610 target is now able to run on qemu :)
>>>>
>>>> [1] http://cache.freescale.com/files/32bit/doc/ref_manual/E600CORERM.pdf
>>>>
>>>> Signed-off-by: Julio Guerra <guerr@julio.in>
>>>
>>> Thanks, applied to ppc-next.
>>>
>>
>> I just retested this patch and I noticed the `handle_mmu_fault`
>> default value introduced by recent A. Farber patches on the CPU
>> definitions is wrong with the selected memory model. Thus qemu
>> complains about the MMU model.
>>
>> The following is missing in e600 CPU definition:
>>> #if defined(CONFIG_SOFTMMU)
>>>    ppc->handle_mmu_fault = ppc_hash32_handle_mmu_fault;
>>> #endif
>>
>> Can you correct it or should I resend a patch (v3 or just the previous
>> three lines) ?
> 
> Just send a patch on top of the current one.


I do not really understand what this patch actually does but it breaks my
pseries/power7 setup. Please, help.


Starting program: /home/aik/qemu-system-ppc64 -L qemu-ppc64-bios/ -trace
events=qemu_trace_events -net nic,model=e1000,addr=0:0:0 -net
user,hostfwd=tcp::5000-:22 -m 1024 -machine pseries -nographic -vga none
-enable-kvm -kernel guest.vmlinux.n -initrd 1.cpio
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
**
ERROR:/home/alexey/pcipassthru/qemu-impreza/qom/object.c:152:type_get_parent:
assertion failed: (type->parent_type != NULL)

Breakpoint 4, 0x00000080c6eefb8c in .abort () from /lib64/libc.so.6
Missing separate debuginfos, use: debuginfo-install SDL-1.2.15-8.fc19.ppc64
bluez-libs-4.101-6.fc19.ppc64 boost-system-1.53.0-6.fc19.ppc64
boost-thread-1.53.0-6.fc19.ppc64 brlapi-0.6.0-5.fc19.ppc64
ceph-devel-0.56.4-1.fc19.ppc64 ceph-libs-0.56.4-1.fc19.ppc64
cryptopp-5.6.2-2.fc19.ppc64 cyrus-sasl-lib-2.1.26-8.fc19.ppc64p7
glib2-2.36.2-1.fc19.ppc64 glibc-2.17-4.fc19.ppc64p7
glusterfs-3.4.0-0.5.beta2.fc19.ppc64
glusterfs-api-3.4.0-0.5.beta2.fc19.ppc64 gmp-5.1.1-2.fc19.ppc64
gnutls-3.1.11-1.fc19.ppc64 keyutils-libs-1.5.5-4.fc19.ppc64
krb5-libs-1.11.2-10.fc19.ppc64 leveldb-1.9.0-1.fc19.ppc64
libX11-1.5.99.902-1.fc19.ppc64 libXau-1.0.6-7.fc19.ppc64
libcom_err-1.42.7-2.fc19.ppc64 libcurl-7.29.0-6.fc19.ppc64
libfdt-1.3.0-6.fc19.ppc64 libgcc-4.8.0-8.fc19.ppc64
libgcrypt-1.5.2-1.fc19.ppc64 libgpg-error-1.11-1.fc19.ppc64
libidn-1.26-2.fc19.ppc64 libjpeg-turbo-1.2.90-2.fc19.ppc64
libselinux-2.1.13-15.fc19.ppc64 libssh2-1.4.3-4.fc19.ppc64
libstdc++-4.8.0-8.fc19.ppc64 libtasn1-3.3-1.fc19.ppc64
libuuid-2.23.1-2.fc19.ppc64 libxcb-1.9-3.fc19.ppc64
ncurses-libs-5.9-11.20130511.fc19.ppc64 nettle-2.6-2.fc19.ppc64
nspr-4.9.6-1.fc19.ppc64 nss-3.14.3-13.0.fc19.ppc64
nss-softokn-freebl-3.14.3-1.fc19.ppc64 nss-util-3.14.3-1.fc19.ppc64
openldap-2.4.35-4.fc19.ppc64 openssl-libs-1.0.1e-4.fc19.ppc64p7
p11-kit-0.18.3-1.fc19.ppc64 pcre-8.32-6.fc19.ppc64p7
pixman-0.30.0-1.fc19.ppc64 snappy-1.1.0-1.fc19.ppc64 zlib-1.2.7-10.fc19.ppc64p7
(gdb) up
#1  0x00000080c742d54c in .g_assertion_message () from /lib64/libglib-2.0.so.0
(gdb)
#2  0x00000080c742d5f4 in .g_assertion_message_expr () from
/lib64/libglib-2.0.so.0
(gdb) bt
#0  0x00000080c6eefb8c in .abort () from /lib64/libc.so.6
#1  0x00000080c742d54c in .g_assertion_message () from /lib64/libglib-2.0.so.0
#2  0x00000080c742d5f4 in .g_assertion_message_expr () from
/lib64/libglib-2.0.so.0
#3  0x0000000010260058 in type_get_parent (type=0x10f7b260)
    at /home/alexey/pcipassthru/qemu-impreza/qom/object.c:152
#4  0x0000000010260120 in type_class_get_size (ti=0x10f7b260)
    at /home/alexey/pcipassthru/qemu-impreza/qom/object.c:170
#5  0x00000000102603d8 in type_initialize (ti=0x10f7b260)
    at /home/alexey/pcipassthru/qemu-impreza/qom/object.c:236
#6  0x000000001026175c in object_class_foreach_tramp (key=0x10f7b3e0,
value=0x10f7b260,
    opaque=0x3fffffffe5e0) at
/home/alexey/pcipassthru/qemu-impreza/qom/object.c:626
#7  0x00000080c73e0ab0 in .g_hash_table_foreach () from /lib64/libglib-2.0.so.0
#8  0x000000001026188c in object_class_foreach (fn=
    @0x10681290: 0x10261988 <object_class_get_list_tramp>,
    implements_type=0x105c7188 "powerpc64-cpu", include_abstract=0x0,
opaque=0x3fffffffe680)
    at /home/alexey/pcipassthru/qemu-impreza/qom/object.c:647
#9  0x0000000010261a3c in object_class_get_list (implements_type=0x105c7188
"powerpc64-cpu",
    include_abstract=0x0) at
/home/alexey/pcipassthru/qemu-impreza/qom/object.c:679
#10 0x0000000010459dec in ppc_cpu_class_by_pvr (pvr=0x3f0201)
    at /home/alexey/pcipassthru/qemu-impreza/target-ppc/translate_init.c:7908
#11 0x00000000103ca368 in kvm_ppc_register_host_cpu_type ()
    at /home/alexey/pcipassthru/qemu-impreza/target-ppc/kvm.c:1781
#12 0x00000000103c4fcc in kvm_arch_init (s=0x10fb8ab0)
    at /home/alexey/pcipassthru/qemu-impreza/target-ppc/kvm.c:110
#13 0x0000000010376138 in kvm_init () at
/home/alexey/pcipassthru/qemu-impreza/kvm-all.c:1461
#14 0x00000000102c1b08 in configure_accelerator ()
    at /home/alexey/pcipassthru/qemu-impreza/vl.c:2673
#15 0x00000000102c5e28 in main (argc=0x15, argv=0x3ffffffff218,
envp=0x3ffffffff2c8)
    at /home/alexey/pcipassthru/qemu-impreza/vl.c:4062
(gdb) up
#3  0x0000000010260058 in type_get_parent (type=0x10f7b260)
    at /home/alexey/pcipassthru/qemu-impreza/qom/object.c:152
152	        g_assert(type->parent_type != NULL);
(gdb) p *type
$5 = {name = 0x10f7b3e0 "MPC8641-powerpc64-cpu", class_size = 0x0,
instance_size = 0x0,
  class_init = @0x1069ac10: 0x103a287c
<CPU_POWERPC_e600_POWERPC_SVR_8641_e600_cpu_class_init>,
  class_base_init = 0x0, class_finalize = 0x0, class_data = 0x0,
instance_init = 0x0,
  instance_finalize = 0x0, abstract = 0x0, parent = 0x10f7b400
"e600-family-powerpc64-cpu",
  parent_type = 0x0, class = 0x0, num_interfaces = 0x0, interfaces = {{
      typename = 0x0} <repeats 32 times>}}
(gdb)




-- 
Alexey

  reply	other threads:[~2013-06-24  4:14 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-26 17:41 [Qemu-devel] [PATCH v2] e600 core for MPC86xx processors Julio Guerra
2013-06-06  6:20 ` Julio Guerra
2013-06-06 11:44 ` Andreas Färber
2013-06-06 16:31   ` Scott Wood
2013-06-07 13:44     ` Julio Guerra
2013-06-13  6:32       ` Julio Guerra
2013-06-20 23:16 ` Alexander Graf
2013-06-21 12:01   ` Julio Guerra
2013-06-21 12:03     ` Alexander Graf
2013-06-24  4:14       ` Alexey Kardashevskiy [this message]
2013-06-24  6:13         ` Julio Guerra
2013-06-24  6:41           ` Alexander Graf
2013-06-22  0:50   ` [Qemu-devel] [Qemu-ppc] " Alexander Graf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51C7C7A5.7090300@ozlabs.ru \
    --to=aik@ozlabs.ru \
    --cc=agraf@suse.de \
    --cc=guerr@julio.in \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.