dma: don't wait on unbinds in SH3

This can freeze for reasons I didn't completely root cause. The MWE
leading to this was made by @Calamari, is very dependent on factors I
haven't completely characterized, but includes having the DMA driver,
doing a world switch; and seems to require some timers (via gray engine)
and stack usage, but I'm not clear on the role of that.
This commit is contained in:
Lephe 2025-06-01 21:30:52 +02:00
parent df9ecba326
commit 36f37b9200
No known key found for this signature in database
GPG key ID: 1BBA026E13FC0495

View file

@ -298,6 +298,8 @@ static void configure(void)
static void funbind(void)
{
if(isSH3()) return;
/* Wait for all OS transfers to finish before taking over */
for(int channel = 0; channel < 6; channel++)
dma_channel_wait(channel, true);
@ -305,6 +307,8 @@ static void funbind(void)
static void unbind(void)
{
if(isSH3()) return;
/* Make sure all DMA transfers are finished before leaving gint */
for(int channel = 0; channel < 6; channel++)
dma_channel_wait(channel, false);