|
From: kosmirror <kos...@us...> - 2025-11-18 20:02:24
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "A pseudo Operating System for the Dreamcast.".
The branch, master has been updated
via 6216f5e6795f6aec3578b4387a05976e6d804327 (commit)
from 7ffb61cf845bf2e470f1baa47531937f1a447c95 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 6216f5e6795f6aec3578b4387a05976e6d804327
Author: DC-SWAT <sw...@21...>
Date: Sun Nov 16 23:23:51 2025 +0700
g1ata: Do not switch the bus to Master on NAOMI.
There is no need to switch to the master device (no syscalls for GD-ROM) on NAOMI, and by some reason this causes issues in the operation of the slave device.
-----------------------------------------------------------------------
Summary of changes:
kernel/arch/dreamcast/hardware/g1ata.c | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
diff --git a/kernel/arch/dreamcast/hardware/g1ata.c b/kernel/arch/dreamcast/hardware/g1ata.c
index b6716b80..977d84a4 100644
--- a/kernel/arch/dreamcast/hardware/g1ata.c
+++ b/kernel/arch/dreamcast/hardware/g1ata.c
@@ -18,6 +18,7 @@
#include <kos/thread.h>
#include <kos/timer.h>
+#include <arch/arch.h>
#include <arch/cache.h>
#include <arch/irq.h>
#include <arch/memory.h>
@@ -218,7 +219,9 @@ inline int g1_ata_mutex_lock(void) {
inline int g1_ata_mutex_unlock(void) {
/* Make sure to select the GD-ROM drive back. */
- g1_ata_select_device(G1_ATA_MASTER);
+ if(hardware_sys_mode(NULL) == HW_TYPE_RETAIL) {
+ g1_ata_select_device(G1_ATA_MASTER);
+ }
return mutex_unlock(&_g1_ata_mutex);
}
@@ -250,7 +253,9 @@ static void g1_dma_done(void) {
dma_in_progress = 0;
/* Make sure to select the GD-ROM drive back. */
- g1_ata_select_device(G1_ATA_MASTER);
+ if(hardware_sys_mode(NULL) == HW_TYPE_RETAIL) {
+ g1_ata_select_device(G1_ATA_MASTER);
+ }
mutex_unlock_as_thread(&_g1_ata_mutex, dma_thd);
}
hooks/post-receive
--
A pseudo Operating System for the Dreamcast.
|