summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorasami <asami@FreeBSD.org>1996-11-13 02:00:17 +0000
committerasami <asami@FreeBSD.org>1996-11-13 02:00:17 +0000
commitf530bd2c71777c0f554b94d405627688497be35e (patch)
tree6f88d1661c87ffa287555ab2bbb68a29259ee9ea /sys
parent3781f2dcb04f4f320bf7b51a32450154bf7d7030 (diff)
downloadFreeBSD-src-f530bd2c71777c0f554b94d405627688497be35e.zip
FreeBSD-src-f530bd2c71777c0f554b94d405627688497be35e.tar.gz
Another round of resync and some added sound support.
sys/pc98/i386/machdep.c: sync with i386/i386/machdep.c sys/pc98/conf/options.pc98: sync with i386/conf/options.i386 sys/i386/isa/sound: DMA auto initialize mode support for PC98. contributed by: Akio Morita <amorita@bird.scphys.kyoto-u.ac.jp> Definite 2.2 material, I believe. Submitted by: The FreeBSD (98) Development Team
Diffstat (limited to 'sys')
-rw-r--r--sys/conf/options.pc983
-rw-r--r--sys/i386/isa/sound/ad1848.c4
-rw-r--r--sys/i386/isa/sound/local.h5
-rw-r--r--sys/i386/isa/sound/pas2_pcm.c4
-rw-r--r--sys/i386/isa/sound/sb16_dsp.c4
-rw-r--r--sys/pc98/conf/options.pc983
-rw-r--r--sys/pc98/i386/machdep.c20
-rw-r--r--sys/pc98/pc98/machdep.c20
8 files changed, 23 insertions, 40 deletions
diff --git a/sys/conf/options.pc98 b/sys/conf/options.pc98
index e9cca8e..0d622c9 100644
--- a/sys/conf/options.pc98
+++ b/sys/conf/options.pc98
@@ -1,4 +1,4 @@
-# $Id: options.pc98,v 1.8 1996/10/30 22:39:32 asami Exp $
+# $Id: options.pc98,v 1.9 1996/11/02 10:38:48 asami Exp $
BOUNCEPAGES opt_bounce.h
USER_LDT
MATH_EMULATE opt_math_emulate.h
@@ -42,7 +42,6 @@ I486_CPU opt_cpu.h
I586_CPU opt_cpu.h
I686_CPU opt_cpu.h
-I586_FAST_BCOPY opt_temporary.h
I586_OPTIMIZED_BCOPY opt_temporary.h
I586_OPTIMIZED_BZERO opt_temporary.h
diff --git a/sys/i386/isa/sound/ad1848.c b/sys/i386/isa/sound/ad1848.c
index 0dc5464..73e0edc 100644
--- a/sys/i386/isa/sound/ad1848.c
+++ b/sys/i386/isa/sound/ad1848.c
@@ -480,11 +480,7 @@ static struct audio_operations ad1848_pcm_operations[MAX_AUDIO_DEV] =
{
{
"Generic AD1848 codec",
-#ifdef PC98
- NEEDS_RESTART,
-#else
DMA_AUTOMODE,
-#endif
AFMT_U8, /* Will be set later */
NULL,
ad1848_open,
diff --git a/sys/i386/isa/sound/local.h b/sys/i386/isa/sound/local.h
index c243e4b..c500366 100644
--- a/sys/i386/isa/sound/local.h
+++ b/sys/i386/isa/sound/local.h
@@ -3,7 +3,12 @@
* $Id: local.h,v 1.11 1994/11/01 17:26:50 ache Exp
*/
+#ifdef PC98
+/* If a soundcard uses DMA AUTO mode, DPS_BUFFSIZE must be < 64KB. */
+#define DSP_BUFFSIZE 61440
+#else
#define DSP_BUFFSIZE 65536
+#endif
#define SELECTED_SOUND_OPTIONS 0xffffffff
#define SOUND_CONFIG_DATE "Sun Feb 5 14:38:12 EST 1995"
#define SOUND_CONFIG_BY "freebsd-hackers"
diff --git a/sys/i386/isa/sound/pas2_pcm.c b/sys/i386/isa/sound/pas2_pcm.c
index db91165..97ae76c 100644
--- a/sys/i386/isa/sound/pas2_pcm.c
+++ b/sys/i386/isa/sound/pas2_pcm.c
@@ -377,11 +377,7 @@ pas_pcm_prepare_for_output (int dev, int bsize, int bcount)
static struct audio_operations pas_pcm_operations =
{
"Pro Audio Spectrum",
-#ifdef PC98
- NEEDS_RESTART,
-#else
DMA_AUTOMODE,
-#endif
AFMT_U8 | AFMT_S16_LE,
NULL,
pas_pcm_open,
diff --git a/sys/i386/isa/sound/sb16_dsp.c b/sys/i386/isa/sound/sb16_dsp.c
index 5e84e67..4057774 100644
--- a/sys/i386/isa/sound/sb16_dsp.c
+++ b/sys/i386/isa/sound/sb16_dsp.c
@@ -84,11 +84,7 @@ static void dsp_cleanup (void);
static struct audio_operations sb16_dsp_operations =
{
"SoundBlaster 16",
-#ifdef PC98
- NEEDS_RESTART,
-#else
DMA_AUTOMODE,
-#endif
AFMT_U8 | AFMT_S16_LE,
NULL,
sb16_dsp_open,
diff --git a/sys/pc98/conf/options.pc98 b/sys/pc98/conf/options.pc98
index e9cca8e..0d622c9 100644
--- a/sys/pc98/conf/options.pc98
+++ b/sys/pc98/conf/options.pc98
@@ -1,4 +1,4 @@
-# $Id: options.pc98,v 1.8 1996/10/30 22:39:32 asami Exp $
+# $Id: options.pc98,v 1.9 1996/11/02 10:38:48 asami Exp $
BOUNCEPAGES opt_bounce.h
USER_LDT
MATH_EMULATE opt_math_emulate.h
@@ -42,7 +42,6 @@ I486_CPU opt_cpu.h
I586_CPU opt_cpu.h
I686_CPU opt_cpu.h
-I586_FAST_BCOPY opt_temporary.h
I586_OPTIMIZED_BCOPY opt_temporary.h
I586_OPTIMIZED_BZERO opt_temporary.h
diff --git a/sys/pc98/i386/machdep.c b/sys/pc98/i386/machdep.c
index c6539d9..23e1d67 100644
--- a/sys/pc98/i386/machdep.c
+++ b/sys/pc98/i386/machdep.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
- * $Id: machdep.c,v 1.11 1996/10/29 08:36:16 asami Exp $
+ * $Id: machdep.c,v 1.12 1996/11/02 10:38:57 asami Exp $
*/
#include "npx.h"
@@ -210,17 +210,6 @@ cpu_startup(dummy)
bootverbose++;
/*
- * Initialize error message buffer (at end of core).
- */
-
- /* avail_end was pre-decremented in init386() to compensate */
- for (i = 0; i < btoc(sizeof (struct msgbuf)); i++)
- pmap_enter(pmap_kernel(), (vm_offset_t)msgbufp,
- avail_end + i * PAGE_SIZE,
- VM_PROT_ALL, TRUE);
- msgbufmapped = 1;
-
- /*
* Good {morning,afternoon,evening,night}.
*/
printf(version);
@@ -994,6 +983,7 @@ init386(first)
struct region_descriptor r_gdt, r_idt;
int pagesinbase, pagesinext;
int target_page, pa_indx;
+ int off;
proc0.p_addr = proc0paddr;
@@ -1340,6 +1330,12 @@ init386(first)
/* now running on new page tables, configured,and u/iom is accessible */
+ /* Map the message buffer. */
+ for (off = 0; off < round_page(sizeof(struct msgbuf)); off += PAGE_SIZE)
+ pmap_enter(kernel_pmap, (vm_offset_t)msgbufp + off,
+ avail_end + off, VM_PROT_ALL, TRUE);
+ msgbufmapped = 1;
+
/* make a initial tss so microp can get interrupt stack on syscall! */
proc0.p_addr->u_pcb.pcb_tss.tss_esp0 = (int) kstack + UPAGES*PAGE_SIZE;
proc0.p_addr->u_pcb.pcb_tss.tss_ss0 = GSEL(GDATA_SEL, SEL_KPL) ;
diff --git a/sys/pc98/pc98/machdep.c b/sys/pc98/pc98/machdep.c
index c6539d9..23e1d67 100644
--- a/sys/pc98/pc98/machdep.c
+++ b/sys/pc98/pc98/machdep.c
@@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
- * $Id: machdep.c,v 1.11 1996/10/29 08:36:16 asami Exp $
+ * $Id: machdep.c,v 1.12 1996/11/02 10:38:57 asami Exp $
*/
#include "npx.h"
@@ -210,17 +210,6 @@ cpu_startup(dummy)
bootverbose++;
/*
- * Initialize error message buffer (at end of core).
- */
-
- /* avail_end was pre-decremented in init386() to compensate */
- for (i = 0; i < btoc(sizeof (struct msgbuf)); i++)
- pmap_enter(pmap_kernel(), (vm_offset_t)msgbufp,
- avail_end + i * PAGE_SIZE,
- VM_PROT_ALL, TRUE);
- msgbufmapped = 1;
-
- /*
* Good {morning,afternoon,evening,night}.
*/
printf(version);
@@ -994,6 +983,7 @@ init386(first)
struct region_descriptor r_gdt, r_idt;
int pagesinbase, pagesinext;
int target_page, pa_indx;
+ int off;
proc0.p_addr = proc0paddr;
@@ -1340,6 +1330,12 @@ init386(first)
/* now running on new page tables, configured,and u/iom is accessible */
+ /* Map the message buffer. */
+ for (off = 0; off < round_page(sizeof(struct msgbuf)); off += PAGE_SIZE)
+ pmap_enter(kernel_pmap, (vm_offset_t)msgbufp + off,
+ avail_end + off, VM_PROT_ALL, TRUE);
+ msgbufmapped = 1;
+
/* make a initial tss so microp can get interrupt stack on syscall! */
proc0.p_addr->u_pcb.pcb_tss.tss_esp0 = (int) kstack + UPAGES*PAGE_SIZE;
proc0.p_addr->u_pcb.pcb_tss.tss_ss0 = GSEL(GDATA_SEL, SEL_KPL) ;
OpenPOWER on IntegriCloud