]> git.proxmox.com Git - qemu.git/commitdiff
xilinx_axienet: Implement R_IS behaviour
authorPeter Crosthwaite <peter.crosthwaite@xilinx.com>
Wed, 5 Dec 2012 06:53:42 +0000 (16:53 +1000)
committerEdgar E. Iglesias <edgar.iglesias@gmail.com>
Wed, 5 Dec 2012 08:20:36 +0000 (09:20 +0100)
The interrupt status register R_IS is the standard clear-on-write behaviour.
This was unimplemented and defaulting to updating the register to the written
value. Implemented clear-on-write.

Reported-by: Jason Wu <huanyu@xilinx.com>
Signed-off-by: Peter Crosthwaite <peter.crosthwaite@xilinx.com>
Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
hw/xilinx_axienet.c

index baae02bd661902b0168c6738bfa43ae63e7f8de1..f2e3bf1274913e9f116dbeee4228405d79fa1411 100644 (file)
@@ -591,6 +591,10 @@ static void enet_write(void *opaque, hwaddr addr,
             s->maddr[s->fmi & 3][addr & 1] = value;
             break;
 
+        case R_IS:
+            s->regs[addr] &= ~value;
+            break;
+
         case 0x8000 ... 0x83ff:
             s->ext_mtable[addr - 0x8000] = value;
             break;