Implement byte wise write handling for DSA register instead of using the macro, as NetBSD driver accesses it byte by byte
Signed-off-by: Soumyajyotii Ssarkar<[email protected]> --- hw/scsi/ncr53c710.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/hw/scsi/ncr53c710.c b/hw/scsi/ncr53c710.c index dd453991e0..0ea1fc43a3 100644 --- a/hw/scsi/ncr53c710.c +++ b/hw/scsi/ncr53c710.c @@ -2078,7 +2078,21 @@ static void ncr710_reg_writeb(NCR710State *s, int offset, uint8_t val) /* Linux writes to these readonly registers on startup */ return; - CASE_SET_REG32(dsa, NCR710_DSA_REG) + case NCR710_DSA_REG: + s->dsa &= 0xffffff00; + s->dsa |= val; + break; + case NCR710_DSA_REG + 1: + s->dsa &= 0xffff00ff; + s->dsa |= val << 8; + break; + case NCR710_DSA_REG + 2: + s->dsa &= 0xff00ffff; + s->dsa |= val << 16; + break; + case NCR710_DSA_REG + 3: + s->dsa &= 0x00ffffff; + s->dsa |= val << 24; break; case NCR710_CTEST0_REG: /* CTEST0 */ -- 2.49.0
