Re: [Qemu-devel] Regression bug
Blue Swirl [EMAIL PROTECTED] wrote: On 5/29/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On Tue, May 29, 2007 at 09:44:39PM +0300, Blue Swirl wrote: Hi, I found a bug in the subpage checking code. Could you try if the attached patch fixes the problem? thats a negative. the exact same behavior as before. Thanks. The bug was actually that on PC, the very last addresses are mapped, and the current code failed when the start_addr + size wrapped back to 0. That didn't happen on amd64, where I first tried to reproduce the bug. The attached patch fixes the problem for me, I'll commit it if there are no objections. Works for me, too. Ben
Re: [Qemu-devel] Regression bug
Hi, I do reproduce that trying to boot a kubuntu i386 on an i368. Now we have to bisect... Xavier. I've been keeping up with CVS patches for qemu about once a week. I just updated tonight after the big round of patches that have been commited and am seeing a consistent failure with my existing ubuntu-7.04 32-bit guest on Solaris 10/x86 32-bit host. The last time I tested the CVS code would have been 5/21/07, so something recently changed has broken the i386-softmmu qemu: fatal: Trying to execute code outside RAM or ROM at 0xfff0 EAX= EBX= ECX= EDX=0600 ESI= EDI= EBP= ESP= EIP=fff0 EFL=0002 [---] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES = CS =f000 SS = DS = FS = GS = LDT= 8000 TR = 8000 GDT= IDT= CR0=6010 CR2= CR3= CR4= CCS= CCD= CCO=EFLAGS FCW=037f FSW= [ST=0] FTW=00 MXCSR=1f80 FPR0= FPR1= FPR2= FPR3= FPR4= FPR5= FPR6= FPR7= XMM00= XMM01= XMM02= XMM03= XMM04= XMM05= XMM06= XMM07= Anyone seen this? Ben -- Xavier Gnata CRAL - Observatoire de Lyon 9, avenue Charles André 69561 Saint Genis Laval cedex Phone: +33 4 78 86 85 28 Fax: +33 4 78 86 83 86 E-mail: [EMAIL PROTECTED]
Re: [Qemu-devel] Regression bug
On Tue, May 29, 2007 at 01:10:02AM -0400, Ben Taylor wrote: I've been keeping up with CVS patches for qemu about once a week. I just updated tonight after the big round of patches that have been commited and am seeing a consistent failure with my existing ubuntu-7.04 32-bit guest on Solaris 10/x86 32-bit host. The last time I tested the CVS code would have been 5/21/07, so something recently changed has broken the i386-softmmu qemu: fatal: Trying to execute code outside RAM or ROM at 0xfff0 EAX= EBX= ECX= EDX=0600 ESI= EDI= EBP= ESP= EIP=fff0 EFL=0002 [---] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES = CS =f000 SS = DS = FS = GS = LDT= 8000 TR = 8000 GDT= IDT= CR0=6010 CR2= CR3= CR4= CCS= CCD= CCO=EFLAGS FCW=037f FSW= [ST=0] FTW=00 MXCSR=1f80 FPR0= FPR1= FPR2= FPR3= FPR4= FPR5= FPR6= FPR7= XMM00= XMM01= XMM02= XMM03= XMM04= XMM05= XMM06= XMM07= Anyone seen this? Ben Ben: i've been monitoring this, and reporting on irc since the bug was comitted. i've tracked it down to somewhere between CVS version 2007-05-26 15:00 and 2007-05-26 17:40. as in, 15:00 works, 17:40 dosent, and if i try to check out the version between.. it fails to compile. I'm quite new here, so i didn't feel like yelling the sky is falling on a mailing list. hope this helps, Julia Longtin [EMAIL PROTECTED]
Re: [Qemu-devel] Regression bug
Hi Julia, [EMAIL PROTECTED] wrote: On Tue, May 29, 2007 at 01:10:02AM -0400, Ben Taylor wrote: I've been keeping up with CVS patches for qemu about once a week. I just updated tonight after the big round of patches that have been commited and am seeing a consistent failure with my existing ubuntu-7.04 32-bit guest on Solaris 10/x86 32-bit host. The last time I tested the CVS code would have been 5/21/07, so something recently changed has broken the i386-softmmu qemu: fatal: Trying to execute code outside RAM or ROM at 0xfff0 Anyone seen this? Ben Ben: i've been monitoring this, and reporting on irc since the bug was comitted. i've tracked it down to somewhere between CVS version 2007-05-26 15:00 and 2007-05-26 17:40. as in, 15:00 works, 17:40 dosent, and if i try to check out the version between.. it fails to compile. Great spot. I reverted the patch to exec.c from 05/26/07 at 17:36 and QEMU again booted my ubuntu 7.04 image. Looks like the patch from http://cvs.savannah.gnu.org/viewcvs/qemu/exec.c?cvsroot=qemur1=1.96r2=1.97 needs to be reverted and reworked before being recommitted. I'm quite new here, so i didn't feel like yelling the sky is falling on a mailing list. What you did was perfect. Thanks. hope this helps, Julia Longtin [EMAIL PROTECTED] Regards, Ben
Re: [Qemu-devel] Regression bug
On 5/29/07, Ben Taylor [EMAIL PROTECTED] wrote: Looks like the patch from http://cvs.savannah.gnu.org/viewcvs/qemu/exec.c?cvsroot=qemur1=1.96r2=1.97 needs to be reverted and reworked before being recommitted. Thank you for the reports. I still can't reproduce the bug, but it seems that on PC, the area between 0xa and 0x10 is registered multiple times and this could confuse the subpage code. Adding printf to cpu_register_physical memory reveals: cpu_register_physical_memory: start_addr 000a size 1000 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 1000 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 1000 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 1000 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 1000 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 2 phys_offset 70 cpu_register_physical_memory: start_addr 000a size 2 phys_offset a The subpage part in cpu_register_physical_memory could be disabled just for i386. A better fix would be to fix the PC/VGA/PIIX memory registrations and also make the subpage code handle this case.
Re: [Qemu-devel] Regression bug
Hi, I found a bug in the subpage checking code. Could you try if the attached patch fixes the problem? Index: qemu/exec.c === --- qemu.orig/exec.c 2007-05-29 18:39:35.0 + +++ qemu/exec.c 2007-05-29 18:39:54.0 + @@ -1922,7 +1922,7 @@ need_subpage = 1; \ } \ \ -if (end_addr - addr TARGET_PAGE_SIZE) \ +if (end_addr - addr = TARGET_PAGE_SIZE)\ end_addr2 = TARGET_PAGE_SIZE - 1; \ else { \ end_addr2 = (start_addr + orig_size - 1) ~TARGET_PAGE_MASK; \
Re: [Qemu-devel] Regression bug
On Tue, May 29, 2007 at 09:44:39PM +0300, Blue Swirl wrote: Hi, I found a bug in the subpage checking code. Could you try if the attached patch fixes the problem? thats a negative. the exact same behavior as before. qemu: fatal: Trying to execute code outside RAM or ROM at 0xfff0 EAX= EBX= ECX= EDX=0600 ESI= EDI= EBP= ESP= EIP=fff0 EFL=0002 [---] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES = CS =f000 SS = DS = FS = GS = LDT= 8000 TR = 8000 GDT= IDT= CR0=6010 CR2= CR3= CR4= CCS= CCD= CCO=EFLAGS FCW=037f FSW= [ST=0] FTW=00 MXCSR=1f80 FPR0= FPR1= FPR2= FPR3= FPR4= FPR5= FPR6= FPR7= XMM00= XMM01= XMM02= XMM03= XMM04= XMM05= XMM06= XMM07= ./start.sh: line 4: 14065 Aborted qemu -hda ide0.img ouch. Julia Longtin [EMAIL PROTECTED]
Re: [Qemu-devel] Regression bug
On 5/29/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On Tue, May 29, 2007 at 09:44:39PM +0300, Blue Swirl wrote: Hi, I found a bug in the subpage checking code. Could you try if the attached patch fixes the problem? thats a negative. the exact same behavior as before. Thanks. The bug was actually that on PC, the very last addresses are mapped, and the current code failed when the start_addr + size wrapped back to 0. That didn't happen on amd64, where I first tried to reproduce the bug. The attached patch fixes the problem for me, I'll commit it if there are no objections. Index: qemu/exec.c === --- qemu.orig/exec.c 2007-05-29 19:31:15.0 + +++ qemu/exec.c 2007-05-29 19:31:24.0 + @@ -1922,7 +1922,7 @@ need_subpage = 1; \ } \ \ -if (end_addr - addr TARGET_PAGE_SIZE) \ +if ((start_addr + orig_size) - addr = TARGET_PAGE_SIZE)\ end_addr2 = TARGET_PAGE_SIZE - 1; \ else { \ end_addr2 = (start_addr + orig_size - 1) ~TARGET_PAGE_MASK; \ @@ -1944,9 +1944,9 @@ unsigned long orig_size = size; void *subpage; -end_addr = start_addr + (target_phys_addr_t)size; size = (size + TARGET_PAGE_SIZE - 1) TARGET_PAGE_MASK; -for(addr = start_addr; addr end_addr; addr += TARGET_PAGE_SIZE) { +end_addr = start_addr + (target_phys_addr_t)size; +for(addr = start_addr; addr != end_addr; addr += TARGET_PAGE_SIZE) { p = phys_page_find(addr TARGET_PAGE_BITS); if (p p-phys_offset != IO_MEM_UNASSIGNED) { unsigned long orig_memory = p-phys_offset;
Re: [Qemu-devel] Regression bug
On Tue, May 29, 2007 at 10:33:37PM +0300, Blue Swirl wrote: On 5/29/07, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: On Tue, May 29, 2007 at 09:44:39PM +0300, Blue Swirl wrote: Hi, I found a bug in the subpage checking code. Could you try if the attached patch fixes the problem? thats a negative. the exact same behavior as before. Thanks. The bug was actually that on PC, the very last addresses are mapped, and the current code failed when the start_addr + size wrapped back to 0. That didn't happen on amd64, where I first tried to reproduce the bug. The attached patch fixes the problem for me, I'll commit it if there are no objections. this patch works. thanks. :) Julia Longtin [EMAIL PROTECTED]
[Qemu-devel] Regression bug
I've been keeping up with CVS patches for qemu about once a week. I just updated tonight after the big round of patches that have been commited and am seeing a consistent failure with my existing ubuntu-7.04 32-bit guest on Solaris 10/x86 32-bit host. The last time I tested the CVS code would have been 5/21/07, so something recently changed has broken the i386-softmmu qemu: fatal: Trying to execute code outside RAM or ROM at 0xfff0 EAX= EBX= ECX= EDX=0600 ESI= EDI= EBP= ESP= EIP=fff0 EFL=0002 [---] CPL=0 II=0 A20=1 SMM=0 HLT=0 ES = CS =f000 SS = DS = FS = GS = LDT= 8000 TR = 8000 GDT= IDT= CR0=6010 CR2= CR3= CR4= CCS= CCD= CCO=EFLAGS FCW=037f FSW= [ST=0] FTW=00 MXCSR=1f80 FPR0= FPR1= FPR2= FPR3= FPR4= FPR5= FPR6= FPR7= XMM00= XMM01= XMM02= XMM03= XMM04= XMM05= XMM06= XMM07= Anyone seen this? Ben