Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-17 Thread Dmitry Bogatov
> >> in the kernel?  How much memory did you assign to the
> >> guest?
> > 
> > In kernel. Happens after kernel unpacking. 512mb.
> 
> Please share this kernel image with me, I'll try to take a (brief)
> look.

Sorry, I lost it (rm glob). Sorry for a noise.

> > If it is bug in guest, I propose to reword "internal error".
> For many years these errors were because of one or another emulation
> problem. With time, most of these emulation problems has been fixed,
> and these days, it is much more often a guest bug.  However, the
> message is correct, qemu really can't emulate a guest instruction.
> Bare metal hw usually will be hard-locked in this case.

"Internal error" suggests that there is bug in kvm. If I knew that
bug is in guest, I would not report bug.

-- 
Accept: text/plain, text/x-diff
Accept-Language: eo,en,ru
X-Keep-In-CC: yes
X-Web-Site: nanlnhhunqer4xcy.onion


signature.asc
Description: Digital signature


Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-16 Thread Dmitry Bogatov
* Michael Tokarev  [2015-11-16 13:26:04+0300]
> Control: reassign -1 qemu-system-x86
> Control: severity -1 minor
> 
> 14.11.2015 22:28, Dmitry Bogatov wrote:
> > Package: qemu-kvm
> > Version: 1:2.4+dfsg-4
> > Severity: important
> > 
> > Dear Maintainer,
> > 
> > I installed Gentoo GNU/Linux with `lilo` bootloaded and kernel, built via
> > `genkernel` on virtual machine and on attempt to boot I get qemu
> > internal error, as attached. Script to run qemu is also attached.
> 
> This is a bug in guest.  hers's the disassembly of the code in question:
> 
>  <.data>:
>0: 85 ed   test   %ebp,%ebp
>2: be 4a 2d a8 f2  mov$0xf2a82d4a,%esi
>7: 92  xchg   %eax,%edx
>8: d9 bb 21 7e 85 aa   fnstcw -0x557a81df(%ebx)
>e: 53  push   %ebx
>f: 6b 60 01 6d imul   $0x6d,0x1(%eax),%esp
>   13: 4d  dec%ebp
>   14: da 9d 39 b2 0e 7e   ficompl 0x7e0eb239(%ebp)   <=== here
>   1a: 52  push   %edx
>   1b: 3d 0f d0 29 d5  cmp$0xd529d00f,%eax
>   20: e6 0c   out%al,$0xc
>   22: be f9 76 31 43  mov$0x433176f9,%esi
>   27: 4f  dec%edi
>   28: 86 c2   xchg   %al,%dl
>   2a: 4e  dec%esi
>   2b: be ba c5 34 52  mov$0x5234c5ba,%esi
>   30: 9b  fwait
>   31: c4  .byte 0xc4
> 
> It is a floating-point/integer comparison instruction.
> The instruction sequence smells like your guest code
> jumped to some random junk.
> 
> How far in the boot process it happens?  Is it in lilo or
> in the kernel?  How much memory did you assign to the
> guest?

In kernel. Happens after kernel unpacking. 512mb.

If it is bug in guest, I propose to reword "internal error".

-- 
Accept: text/plain, text/x-diff
Accept-Language: eo,en,ru
X-Keep-In-CC: yes
X-Web-Site: nanlnhhunqer4xcy.onion


signature.asc
Description: Digital signature


Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-16 Thread Michael Tokarev
17.11.2015 08:40, Dmitry Bogatov wrote:

>> How far in the boot process it happens?  Is it in lilo or
>> in the kernel?  How much memory did you assign to the
>> guest?
> 
> In kernel. Happens after kernel unpacking. 512mb.

Please share this kernel image with me, I'll try to take a (brief)
look.

> If it is bug in guest, I propose to reword "internal error".

For many years these errors were because of one or another emulation
problem. With time, most of these emulation problems has been fixed,
and these days, it is much more often a guest bug.  However, the
message is correct, qemu really can't emulate a guest instruction.
Bare metal hw usually will be hard-locked in this case.

Thanks,

/mjt



Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-16 Thread Michael Tokarev
Control: reassign -1 qemu-system-x86
Control: severity -1 minor

14.11.2015 22:28, Dmitry Bogatov wrote:
> Package: qemu-kvm
> Version: 1:2.4+dfsg-4
> Severity: important
> 
> Dear Maintainer,
> 
> I installed Gentoo GNU/Linux with `lilo` bootloaded and kernel, built via
> `genkernel` on virtual machine and on attempt to boot I get qemu
> internal error, as attached. Script to run qemu is also attached.

This is a bug in guest.  hers's the disassembly of the code in question:

 <.data>:
   0:   85 ed   test   %ebp,%ebp
   2:   be 4a 2d a8 f2  mov$0xf2a82d4a,%esi
   7:   92  xchg   %eax,%edx
   8:   d9 bb 21 7e 85 aa   fnstcw -0x557a81df(%ebx)
   e:   53  push   %ebx
   f:   6b 60 01 6d imul   $0x6d,0x1(%eax),%esp
  13:   4d  dec%ebp
  14:   da 9d 39 b2 0e 7e   ficompl 0x7e0eb239(%ebp)   <=== here
  1a:   52  push   %edx
  1b:   3d 0f d0 29 d5  cmp$0xd529d00f,%eax
  20:   e6 0c   out%al,$0xc
  22:   be f9 76 31 43  mov$0x433176f9,%esi
  27:   4f  dec%edi
  28:   86 c2   xchg   %al,%dl
  2a:   4e  dec%esi
  2b:   be ba c5 34 52  mov$0x5234c5ba,%esi
  30:   9b  fwait
  31:   c4  .byte 0xc4

It is a floating-point/integer comparison instruction.
The instruction sequence smells like your guest code
jumped to some random junk.

How far in the boot process it happens?  Is it in lilo or
in the kernel?  How much memory did you assign to the
guest?

Thanks,

/mjt



Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-16 Thread Michael Tokarev
17.11.2015 09:22, Michael Tokarev wrote:
> 17.11.2015 08:40, Dmitry Bogatov wrote:
> 
>>> How far in the boot process it happens?  Is it in lilo or
>>> in the kernel?  How much memory did you assign to the
>>> guest?
>>
>> In kernel. Happens after kernel unpacking. 512mb.
> 
> Please share this kernel image with me, I'll try to take a (brief)
> look.

BTW, can you reproduce this problem by using something like this:

 qemu-system-x86_64 -enable-kvm -m 512 -kernel 

?  That's the way I'd try it if you give me this kernel image.  If
you can't reproduce the prob this way, ofcourse there's something
else missing :)

Thanks,

/mjt



Bug#805107: qemu-kvm: internal error (emulation error)

2015-11-14 Thread Dmitry Bogatov
Package: qemu-kvm
Version: 1:2.4+dfsg-4
Severity: important

Dear Maintainer,

I installed Gentoo GNU/Linux with `lilo` bootloaded and kernel, built via
`genkernel` on virtual machine and on attempt to boot I get qemu
internal error, as attached. Script to run qemu is also attached.

Problem is 100% reproducible -- every time I try to boot virtual
machine, I get this error. Unfortunately, virtual machine is
5G size, but, if needed I can serve it via ssh or http.


-- System Information:
Debian Release: 8.2
  APT prefers stable
  APT policy: (900, 'stable'), (500, 'stable-updates'), (500, 
'buildd-unstable'), (500, 'oldstable')
Architecture: amd64 (x86_64)

Kernel: Linux 3.16.0-4-amd64 (SMP w/8 CPU cores)
Locale: LANG=C.UTF-8, LC_CTYPE=C.UTF-8 (charmap=UTF-8) (ignored: LC_ALL set to 
C.UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages qemu-kvm depends on:
ii  qemu-system-x86  1:2.1+dfsg-12+deb8u4

qemu-kvm recommends no packages.

qemu-kvm suggests no packages.

-- no debconf information
#!/bin/sh
kvm -hda gentoo.qcow \
-boot d \
-net nic \
-net user,hostfwd=tcp::10022-:22 \
-m 512 \
-localtime \
  # -cdrom install-amd64-minimal-*.iso \



gentoo.faillog
Description: application/elc