notaz.gp2x.de
/
pcsx_rearmed.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #7 from tobiasjakobi/fixes
[pcsx_rearmed.git]
/
plugins
/
dfsound
/
dma.c
diff --git
a/plugins/dfsound/dma.c
b/plugins/dfsound/dma.c
index
f92d066
..
7c164ac
100644
(file)
--- a/
plugins/dfsound/dma.c
+++ b/
plugins/dfsound/dma.c
@@
-31,8
+31,6
@@
unsigned short CALLBACK SPUreadDMA(void)
spuAddr+=2;
\r
if(spuAddr>0x7ffff) spuAddr=0;
\r
\r
spuAddr+=2;
\r
if(spuAddr>0x7ffff) spuAddr=0;
\r
\r
- iSpuAsyncWait=0;
\r
-
\r
return s;
\r
}
\r
\r
return s;
\r
}
\r
\r
@@
-50,8
+48,6
@@
void CALLBACK SPUreadDMAMem(unsigned short * pusPSXMem,int iSize)
spuAddr+=2; // inc spu addr
\r
if(spuAddr>0x7ffff) spuAddr=0; // wrap
\r
}
\r
spuAddr+=2; // inc spu addr
\r
if(spuAddr>0x7ffff) spuAddr=0; // wrap
\r
}
\r
-
\r
- iSpuAsyncWait=0;
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r
@@
-72,8
+68,6
@@
void CALLBACK SPUwriteDMA(unsigned short val)
\r
spuAddr+=2; // inc spu addr
\r
if(spuAddr>0x7ffff) spuAddr=0; // wrap
\r
\r
spuAddr+=2; // inc spu addr
\r
if(spuAddr>0x7ffff) spuAddr=0; // wrap
\r
-
\r
- iSpuAsyncWait=0;
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r
@@
-83,15
+77,22
@@
void CALLBACK SPUwriteDMA(unsigned short val)
void CALLBACK SPUwriteDMAMem(unsigned short * pusPSXMem,int iSize)
\r
{
\r
int i;
\r
void CALLBACK SPUwriteDMAMem(unsigned short * pusPSXMem,int iSize)
\r
{
\r
int i;
\r
+
\r
+ had_dma = 1;
\r
+
\r
+ if(spuAddr + iSize*2 < 0x80000)
\r
+ {
\r
+ memcpy(&spuMem[spuAddr>>1], pusPSXMem, iSize*2);
\r
+ spuAddr += iSize*2;
\r
+ return;
\r
+ }
\r
\r
for(i=0;i<iSize;i++)
\r
{
\r
spuMem[spuAddr>>1] = *pusPSXMem++; // spu addr got by writeregister
\r
spuAddr+=2; // inc spu addr
\r
\r
for(i=0;i<iSize;i++)
\r
{
\r
spuMem[spuAddr>>1] = *pusPSXMem++; // spu addr got by writeregister
\r
spuAddr+=2; // inc spu addr
\r
-
if(spuAddr>0x7ffff) spuAddr=0;
// wrap
\r
+
spuAddr&=0x7ffff;
// wrap
\r
}
\r
}
\r
-
\r
- iSpuAsyncWait=0;
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r
}
\r
\r
////////////////////////////////////////////////////////////////////////
\r