games/snes: small hdma fix
This commit is contained in:
parent
d1822db187
commit
77a3391cf3
|
@ -486,7 +486,7 @@ hdmastep(void)
|
||||||
{
|
{
|
||||||
int i, j, cyc;
|
int i, j, cyc;
|
||||||
u8int *p, *q, n, m, b, v, c;
|
u8int *p, *q, n, m, b, v, c;
|
||||||
u32int a;
|
u32int a, br;
|
||||||
|
|
||||||
cyc = 0;
|
cyc = 0;
|
||||||
if(dma != 0)
|
if(dma != 0)
|
||||||
|
@ -502,12 +502,15 @@ hdmastep(void)
|
||||||
if((hdma & (1<<(16+i))) != 0){
|
if((hdma & (1<<(16+i))) != 0){
|
||||||
n = nbytes[c & 7];
|
n = nbytes[c & 7];
|
||||||
m = modes[c & 7];
|
m = modes[c & 7];
|
||||||
if((c & 0x40) != 0)
|
if((c & 0x40) != 0){
|
||||||
q = p + 5;
|
q = p + 5;
|
||||||
else
|
br = p[7] << 16;
|
||||||
|
}else{
|
||||||
q = p + 8;
|
q = p + 8;
|
||||||
|
br = p[4] << 16;
|
||||||
|
}
|
||||||
for(j = 0; j < n; j++){
|
for(j = 0; j < n; j++){
|
||||||
a = q[0] | q[1] << 8 | p[4] << 16;
|
a = q[0] | q[1] << 8 | br;
|
||||||
b = p[1] + (m & 3);
|
b = p[1] + (m & 3);
|
||||||
if((c & 0x80) != 0){
|
if((c & 0x80) != 0){
|
||||||
v = dmavalid(b, 1) ? memread(0x2100 | b) : 0;
|
v = dmavalid(b, 1) ? memread(0x2100 | b) : 0;
|
||||||
|
|
Loading…
Reference in a new issue