Re: [Qemu-devel] qemu/hw slavio_intctl.c slavio_timer.c sun4m.c

2008-01-01 Thread Blue Swirl
On 1/1/08, Aurelien Jarno [EMAIL PROTECTED] wrote:
 On Sat, Dec 29, 2007 at 08:09:57PM +, Blue Swirl wrote:
  CVSROOT:  /cvsroot/qemu
  Module name:  qemu
  Changes by:   Blue Swirl blueswir1  07/12/29 20:09:57
 
  Modified files:
hw : slavio_intctl.c slavio_timer.c sun4m.c
 
  Log message:
 Fix CPU timer interrupts
 
  CVSWeb URLs:
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_intctl.c?cvsroot=qemur1=1.26r2=1.27
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_timer.c?cvsroot=qemur1=1.26r2=1.27
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/sun4m.c?cvsroot=qemur1=1.76r2=1.77
 

 Unfortunately this commit has broken SS-5 running Linux:

Thanks for the report, I can reproduce the bug. What a strange error!

The following patch hides the problem, but it also un-fixes the CPU
timer. I have to think of a better solution.

diff -u -r1.28 slavio_intctl.c
--- hw/slavio_intctl.c  1 Jan 2008 17:06:38 -   1.28
+++ hw/slavio_intctl.c  1 Jan 2008 19:52:22 -
@@ -257,7 +257,7 @@
 if (pending  (1  j))
 pil_pending |= 1  s-intbit_to_level[j];
 }
-pil_pending |= s-intreg_pending[i]  CPU_HARDIRQ_MASK;
+//pil_pending |= s-intreg_pending[i]  CPU_HARDIRQ_MASK;
 }
 pil_pending |= (s-intreg_pending[i]  CPU_SOFTIRQ_MASK)  16;




Re: [Qemu-devel] qemu/hw slavio_intctl.c slavio_timer.c sun4m.c

2008-01-01 Thread Andreas Färber


Am 01.01.2008 um 20:25 schrieb Aurelien Jarno:


On Sat, Dec 29, 2007 at 08:09:57PM +, Blue Swirl wrote:

CVSROOT:/cvsroot/qemu
Module name:qemu
Changes by: Blue Swirl blueswir107/12/29 20:09:57

Modified files:
hw : slavio_intctl.c slavio_timer.c sun4m.c

Log message:
 Fix CPU timer interrupts

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_intctl.c?cvsroot=qemur1=1.26r2=1.27
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_timer.c?cvsroot=qemur1=1.26r2=1.27
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/sun4m.c?cvsroot=qemur1=1.76r2=1.77



Unfortunately this commit has broken SS-5 running Linux:


[sparc] Booting file 'disk' with parameters ''
Not a bootable ELF image
Not a Linux kernel image
Loading a.out image...
Loaded 7680 bytes
entry point is 0x4000
Jumping to entry point...
SILO Version 1.4.13
boot:
Uncompressing image...
Loaded kernel version 2.6.18
Loading initial ramdisk (3205804 bytes at 0x300 phys, 0x6000  
virt)...

PROMLIB: obio_ranges 1
Booting Linux...
PROMLIB: Sun Boot Prom Version 3 Revision 2
Linux version 2.6.18-5-sparc32 (Debian 2.6.18.dfsg.1-13etch3) ([EMAIL PROTECTED] 
) (gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)) #1 Wed  
Sep 26 17:37:21 UTC 2007

ARCH: SUN4M
TYPE: SPARCstation 5
Ethernet address: 0:16:3e:0:11:12
Boot time fixup v1.6. 4/Mar/98 Jakub Jelinek ([EMAIL PROTECTED]).  
Patching kernel for srmmu[Fujitsu TurboSparc]/iommu

63MB HIGHMEM available.
PROM: Built device tree with 21328 bytes of memory.
Power off control detected.
Built 1 zonelists.  Total pages: 63944
Kernel command line: root=/dev/sda4 ro
PID hash table entries: 1024 (order: 10, 4096 bytes)
start_kernel(): bug: interrupts were enabled early
Console: colour dummy device 80x25
Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
Memory: 250220k/261292k available (1640k kernel code, 10876k  
reserved, 404k data, 136k init, 64684k highmem)

Mount-cache hash table entries: 512
checking if image is initramfs... it is
Freeing initrd memory: 3130k freed
NET: Registered protocol family 16
IOMMU: impl 0 vers 5 table 0xf07c[262144 B] map [65536 b]
sbus0: Clock 21.1250 MHz
dma0: Revision 2
dma1: Revision 0
NET: Registered protocol family 2
IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
TCP established hash table entries: 8192 (order: 3, 32768 bytes)
TCP bind hash table entries: 4096 (order: 2, 16384 bytes)
TCP: Hash tables configured (established 8192 bind 4096)
TCP reno registered
ioremap: done with statics, switching to malloc
apc: power management initialized
highmem bounce pool size: 64 pages
VFS: Disk quotas dquot_6.5.1
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
Initializing Cryptographic API
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered (default)
Console: switching to colour frame buffer device 128x48
/[EMAIL PROTECTED],1000/[EMAIL PROTECTED],10001000/SUNW,[EMAIL PROTECTED],80: TCX at  
0:5080, 8-bit only

ffd57454: ttyS0 at MMIO 0x7110 (irq = 44) is a zs
Console: ttyS0 (SunZilog zs0)
qemu: fatal: Trap 0x29 while interrupts disabled, Error state
pc: f0011c98  npc: f0011c9c
General Registers:
%g0:    %g1: f01d2400   %g2: f022d070   %g3: f0229c68
%g4: f001aea0   %g5: 05327f80   %g6: f332   %g7: 
Current Register Window:
%o0: 0032   %o1:    %o2: f022d110   %o3: f33200a8
%o4:    %o5:    %o6: f331fff0   %o7: f0030144
%l0: f022d000   %l1:    %l2: f022d938   %l3: 
%l4: f022d538   %l5: 4000   %l6: f332   %l7: 
%i0: f01a6398   %i1: f0012f5c   %i2: f0012f60   %i3: f33201e0
%i4: 0010   %i5:    %i6: f3320060   %i7: f001306c

Floating Point Registers:
%f00: 0.00 0.00 0.00  
0.00
%f04: 0.00 0.00 0.00  
0.00
%f08: 0.00 0.00 0.00  
0.00
%f12: 0.00 0.00 0.00  
0.00
%f16: 0.00 0.00 0.00  
0.00
%f20: 0.00 0.00 0.00  
0.00
%f24: 0.00 0.00 0.00  
0.00
%f28: 0.00 0.00 0.00  
0.00

psr: 0x04001fc3 -  SP- wim: 0x0008
fsr: 0x0008


On Solaris/amd64 it continues until Starting periodic command  
scheduler: crond. and then hangs.
(previously I got a lot of esp0 issues during fsck, this is now fixed,  
thanks)





Re: [Qemu-devel] qemu/hw slavio_intctl.c slavio_timer.c sun4m.c

2008-01-01 Thread Blue Swirl
On 1/1/08, Aurelien Jarno [EMAIL PROTECTED] wrote:
 On Sat, Dec 29, 2007 at 08:09:57PM +, Blue Swirl wrote:
  CVSROOT:  /cvsroot/qemu
  Module name:  qemu
  Changes by:   Blue Swirl blueswir1  07/12/29 20:09:57
 
  Modified files:
hw : slavio_intctl.c slavio_timer.c sun4m.c
 
  Log message:
 Fix CPU timer interrupts
 
  CVSWeb URLs:
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_intctl.c?cvsroot=qemur1=1.26r2=1.27
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_timer.c?cvsroot=qemur1=1.26r2=1.27
  http://cvs.savannah.gnu.org/viewcvs/qemu/hw/sun4m.c?cvsroot=qemur1=1.76r2=1.77
 

 Unfortunately this commit has broken SS-5 running Linux:

The fix is now in CVS, please give it a test.




Re: [Qemu-devel] qemu/hw slavio_intctl.c slavio_timer.c sun4m.c

2008-01-01 Thread Aurelien Jarno
On Tue, Jan 01, 2008 at 11:00:46PM +0200, Blue Swirl wrote:
 On 1/1/08, Aurelien Jarno [EMAIL PROTECTED] wrote:
  On Sat, Dec 29, 2007 at 08:09:57PM +, Blue Swirl wrote:
   CVSROOT:  /cvsroot/qemu
   Module name:  qemu
   Changes by:   Blue Swirl blueswir1  07/12/29 20:09:57
  
   Modified files:
 hw : slavio_intctl.c slavio_timer.c sun4m.c
  
   Log message:
  Fix CPU timer interrupts
  
   CVSWeb URLs:
   http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_intctl.c?cvsroot=qemur1=1.26r2=1.27
   http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_timer.c?cvsroot=qemur1=1.26r2=1.27
   http://cvs.savannah.gnu.org/viewcvs/qemu/hw/sun4m.c?cvsroot=qemur1=1.76r2=1.77
  
 
  Unfortunately this commit has broken SS-5 running Linux:
 
 The fix is now in CVS, please give it a test.
 

I confirm that it works. Thanks a lot for the quick fix.

-- 
  .''`.  Aurelien Jarno | GPG: 1024D/F1BCDB73
 : :' :  Debian developer   | Electrical Engineer
 `. `'   [EMAIL PROTECTED] | [EMAIL PROTECTED]
   `-people.debian.org/~aurel32 | www.aurel32.net




[Qemu-devel] qemu/hw slavio_intctl.c slavio_timer.c sun4m.c

2007-12-29 Thread Blue Swirl
CVSROOT:/cvsroot/qemu
Module name:qemu
Changes by: Blue Swirl blueswir1  07/12/29 20:09:57

Modified files:
hw : slavio_intctl.c slavio_timer.c sun4m.c 

Log message:
 Fix CPU timer interrupts

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_intctl.c?cvsroot=qemur1=1.26r2=1.27
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/slavio_timer.c?cvsroot=qemur1=1.26r2=1.27
http://cvs.savannah.gnu.org/viewcvs/qemu/hw/sun4m.c?cvsroot=qemur1=1.76r2=1.77