Fix mipsnet device ID, noticed by Vijay Kumar.

git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@4119 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
aurel32 2008-03-28 22:29:33 +00:00
parent 15a5115690
commit 9b5953952a
1 changed files with 2 additions and 4 deletions

View File

@ -11,7 +11,6 @@
/* MIPSnet register offsets */
#define MIPSNET_DEV_ID 0x00
# define MIPSNET_DEV_ID_STRING "MIPSNET0"
#define MIPSNET_BUSY 0x08
#define MIPSNET_RX_DATA_COUNT 0x0c
#define MIPSNET_TX_DATA_COUNT 0x10
@ -105,15 +104,14 @@ static uint32_t mipsnet_ioport_read(void *opaque, uint32_t addr)
{
MIPSnetState *s = opaque;
int ret = 0;
const char *devid = MIPSNET_DEV_ID_STRING;
addr &= 0x3f;
switch (addr) {
case MIPSNET_DEV_ID:
ret = *((uint32_t *)&devid);
ret = be32_to_cpu(0x4d495053); /* MIPS */
break;
case MIPSNET_DEV_ID + 4:
ret = *((uint32_t *)(&devid + 4));
ret = be32_to_cpu(0x4e455430); /* NET0 */
break;
case MIPSNET_BUSY:
ret = s->busy;