fixed invalid command test
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@721 c046a42c-6fe2-441c-8c8c-71466251a162
This commit is contained in:
parent
2f0c934ef9
commit
df475d18d8
10
hw/dma.c
10
hw/dma.c
@ -168,9 +168,9 @@ static void write_cont (void *opaque, uint32_t nport, uint32_t data)
|
|||||||
iport = (nport >> d->dshift) & 0x0f;
|
iport = (nport >> d->dshift) & 0x0f;
|
||||||
switch (iport) {
|
switch (iport) {
|
||||||
case 8: /* command */
|
case 8: /* command */
|
||||||
if (data && (data | CMD_NOT_SUPPORTED)) {
|
if ((data != 0) && (data & CMD_NOT_SUPPORTED)) {
|
||||||
log ("command %#x not supported\n", data);
|
log ("command %#x not supported\n", data);
|
||||||
goto error;
|
return;
|
||||||
}
|
}
|
||||||
d->command = data;
|
d->command = data;
|
||||||
break;
|
break;
|
||||||
@ -236,7 +236,7 @@ static void write_cont (void *opaque, uint32_t nport, uint32_t data)
|
|||||||
|
|
||||||
default:
|
default:
|
||||||
log ("dma: unknown iport %#x\n", iport);
|
log ("dma: unknown iport %#x\n", iport);
|
||||||
goto error;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef DEBUG_DMA
|
#ifdef DEBUG_DMA
|
||||||
@ -245,10 +245,6 @@ static void write_cont (void *opaque, uint32_t nport, uint32_t data)
|
|||||||
nport, ichan, data);
|
nport, ichan, data);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
return;
|
|
||||||
|
|
||||||
error:
|
|
||||||
abort ();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static uint32_t read_cont (void *opaque, uint32_t nport)
|
static uint32_t read_cont (void *opaque, uint32_t nport)
|
||||||
|
Loading…
Reference in New Issue
Block a user