From: Sebastian Herbszt <herbszt@gmx.de>
To: qemu-devel@nongnu.org
Cc: herbszt@gmx.de
Subject: [Qemu-devel] [PATCH 3/3] lsi53c895a: Implement write access to DMA Byte Counter
Date: Sat, 13 Jun 2009 23:03:29 +0200 [thread overview]
Message-ID: <1244927008$1980@local> (raw)
In-Reply-To: <1244927006$1157@local>
Adds CASE_SET_REG24 and fixes the following errors:
lsi_scsi: error: Unhandled writeb 0x24 = 0x0
lsi_scsi: error: Unhandled writeb 0x25 = 0x0
Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
Index: qemu-1172f6536247c8f5a382e6f9062034b1e9bec631/hw/lsi53c895a.c
===================================================================
--- qemu-1172f6536247c8f5a382e6f9062034b1e9bec631.orig/hw/lsi53c895a.c
+++ qemu-1172f6536247c8f5a382e6f9062034b1e9bec631/hw/lsi53c895a.c
@@ -1492,6 +1492,11 @@ static uint8_t lsi_reg_readb(LSIState *s
static void lsi_reg_writeb(LSIState *s, int offset, uint8_t val)
{
+#define CASE_SET_REG24(name, addr) \
+ case addr : s->name &= 0xffffff00; s->name |= val; break; \
+ case addr + 1: s->name &= 0xffff00ff; s->name |= val << 8; break; \
+ case addr + 2: s->name &= 0xff00ffff; s->name |= val << 16; break;
+
#define CASE_SET_REG32(name, addr) \
case addr : s->name &= 0xffffff00; s->name |= val; break; \
case addr + 1: s->name &= 0xffff00ff; s->name |= val << 8; break; \
@@ -1596,6 +1601,7 @@ static void lsi_reg_writeb(LSIState *s,
}
s->ctest5 = val;
break;
+ CASE_SET_REG24(dbc, 0x24)
CASE_SET_REG32(dnad, 0x28)
case 0x2c: /* DSP[0:7] */
s->dsp &= 0xffffff00;
@@ -1710,6 +1716,7 @@ static void lsi_reg_writeb(LSIState *s,
BADF("Unhandled writeb 0x%x = 0x%x\n", offset, val);
}
}
+#undef CASE_SET_REG24
#undef CASE_SET_REG32
}
prev parent reply other threads:[~2009-06-13 21:04 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-13 21:03 [Qemu-devel] [PATCH 1/3] lsi53c895a: Implement Scratch Byte Register Sebastian Herbszt
2009-06-13 21:03 ` [Qemu-devel] [PATCH 2/3] lsi53c895a: Implement read and write access to DMA Next Address Sebastian Herbszt
2009-06-13 21:03 ` Sebastian Herbszt [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='1244927008$1980@local' \
--to=herbszt@gmx.de \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.