From 465375cd7cdcb2ca6fd03861bc22462d41489093 Mon Sep 17 00:00:00 2001 From: OBattler Date: Tue, 7 Nov 2023 20:09:06 +0100 Subject: [PATCH] Disabled register FF on non-PNP Sound Blaster 16 and AWE32, fixes the Windows for Workgroups 3.11 AWE32 driver. --- src/sound/snd_sb.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/sound/snd_sb.c b/src/sound/snd_sb.c index bfd1ca401..14afb2740 100644 --- a/src/sound/snd_sb.c +++ b/src/sound/snd_sb.c @@ -945,7 +945,7 @@ sb_ct1745_mixer_write(uint16_t addr, uint8_t val, void *priv) break; case 0xff: - if (sb->dsp.sb_type >= SB16) { + if (sb->dsp.sb_type > SBAWE32) { /* Bit 5: High DMA channel enabled (0 = yes, 1 = no); Bit 2: ????; @@ -1173,7 +1173,7 @@ sb_ct1745_mixer_read(uint16_t addr, void *priv) - Register FF = FF: Volume playback normal. - Register FF = Not FF: Volume playback low unless bit 6 of 82h is set. */ - if (sb->dsp.sb_type >= SB16) + if (sb->dsp.sb_type > SBAWE32) ret = mixer->regs[mixer->index]; break; @@ -2179,6 +2179,7 @@ sb_16_init(UNUSED(const device_t *info)) sb_dsp_setdma8(&sb->dsp, device_get_config_int("dma")); sb_dsp_setdma16(&sb->dsp, device_get_config_int("dma16")); sb_dsp_setdma16_supported(&sb->dsp, 1); + sb_dsp_setdma16_enabled(&sb->dsp, 1); sb_ct1745_mixer_reset(sb); if (sb->opl_enabled) { @@ -2233,6 +2234,7 @@ sb_16_reply_mca_init(UNUSED(const device_t *info)) sb_dsp_init(&sb->dsp, SB16, SB_SUBTYPE_DEFAULT, sb); sb_dsp_setdma16_supported(&sb->dsp, 1); + sb_dsp_setdma16_enabled(&sb->dsp, 1); sb_ct1745_mixer_reset(sb); sb->mixer_enabled = 1; @@ -2415,6 +2417,7 @@ sb_16_compat_init(const device_t *info) sb_dsp_init(&sb->dsp, SB16, SB_SUBTYPE_DEFAULT, sb); sb_dsp_setdma16_supported(&sb->dsp, 1); + sb_dsp_setdma16_enabled(&sb->dsp, 1); sb_ct1745_mixer_reset(sb); sb->mixer_enabled = 1; @@ -2488,6 +2491,7 @@ sb_awe32_init(UNUSED(const device_t *info)) sb_dsp_setdma8(&sb->dsp, device_get_config_int("dma")); sb_dsp_setdma16(&sb->dsp, device_get_config_int("dma16")); sb_dsp_setdma16_supported(&sb->dsp, 1); + sb_dsp_setdma16_enabled(&sb->dsp, 1); sb_ct1745_mixer_reset(sb); if (sb->opl_enabled) {