Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-9]: src/sys/dev/audio Pull up following revision(s) (requested by...
details: https://anonhg.NetBSD.org/src/rev/db2fd112a83a
branches: netbsd-9
changeset: 963555:db2fd112a83a
user: martin <martin%NetBSD.org@localhost>
date: Mon Jan 27 07:06:02 2020 +0000
description:
Pull up following revision(s) (requested by nia in ticket #657):
sys/dev/files.audio: revision 1.13
sys/dev/files.audio: revision 1.14
sys/arch/amd64/conf/GENERIC: revision 1.559
sys/arch/evbarm/conf/GENERIC: revision 1.71
sys/arch/evbarm/conf/GENERIC64: revision 1.134
sys/dev/audio/audiodef.h: revision 1.8
Set AUDIO_BLK_MS=4 - unlikely to cause significant overhead on non-m68k.
Several of us have been setting this in /etc/sysctl.conf for months, to
get better performance from applications that require synced audio, etc.
It's also mentioned as a good value with low overhead on most archs here:
href="https://mail-index.netbsd.org/tech-kern/2019/12/07/msg025830.html
We could probably go lower, but this is low enough to make most/all
software run well, removing frame drops. It's also low enough to get
emulators/mednafen to stop complaining in the console.
defopt AUDIO_BLK_MS
Follow amd64 and set AUDIO_BLK_MS=4 by default
defopt -> defparam (oops)
diffstat:
sys/arch/amd64/conf/GENERIC | 7 +++++--
sys/arch/evbarm/conf/GENERIC | 3 ++-
sys/arch/evbarm/conf/GENERIC64 | 3 ++-
sys/dev/audio/audiodef.h | 6 +++++-
sys/dev/files.audio | 4 +++-
5 files changed, 17 insertions(+), 6 deletions(-)
diffs (95 lines):
diff -r 1c413f3ca02e -r db2fd112a83a sys/arch/amd64/conf/GENERIC
--- a/sys/arch/amd64/conf/GENERIC Sun Jan 26 11:29:39 2020 +0000
+++ b/sys/arch/amd64/conf/GENERIC Mon Jan 27 07:06:02 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: GENERIC,v 1.531.2.7 2020/01/21 11:55:57 martin Exp $
+# $NetBSD: GENERIC,v 1.531.2.8 2020/01/27 07:06:02 martin Exp $
#
# GENERIC machine description file
#
@@ -22,7 +22,7 @@
options INCLUDE_CONFIG_FILE # embed config file in kernel binary
-#ident "GENERIC-$Revision: 1.531.2.7 $"
+#ident "GENERIC-$Revision: 1.531.2.8 $"
maxusers 64 # estimated number of users
@@ -55,6 +55,9 @@
options INSECURE # disable kernel security levels - X needs this
+options AUDIO_BLK_MS=4 # make software with low latency needs performant
+ # no substantial CPU overhead on this platform
+
options RTC_OFFSET=0 # hardware clock is this many mins. west of GMT
options NTP # NTP phase/frequency locked loop
diff -r 1c413f3ca02e -r db2fd112a83a sys/arch/evbarm/conf/GENERIC
--- a/sys/arch/evbarm/conf/GENERIC Sun Jan 26 11:29:39 2020 +0000
+++ b/sys/arch/evbarm/conf/GENERIC Mon Jan 27 07:06:02 2020 +0000
@@ -1,5 +1,5 @@
#
-# $NetBSD: GENERIC,v 1.48.2.5 2019/12/08 12:57:21 martin Exp $
+# $NetBSD: GENERIC,v 1.48.2.6 2020/01/27 07:06:02 martin Exp $
#
# GENERIC ARM (aarch32) kernel
#
@@ -614,6 +614,7 @@
sunxicodec* at fdt? # Allwinner audio codec
sunxii2s* at fdt? # I2S/PCM
audio* at audiobus?
+options AUDIO_BLK_MS=4
spkr* at audio?
# SDMMC
diff -r 1c413f3ca02e -r db2fd112a83a sys/arch/evbarm/conf/GENERIC64
--- a/sys/arch/evbarm/conf/GENERIC64 Sun Jan 26 11:29:39 2020 +0000
+++ b/sys/arch/evbarm/conf/GENERIC64 Mon Jan 27 07:06:02 2020 +0000
@@ -1,5 +1,5 @@
#
-# $NetBSD: GENERIC64,v 1.103.2.7 2020/01/21 10:39:58 martin Exp $
+# $NetBSD: GENERIC64,v 1.103.2.8 2020/01/27 07:06:02 martin Exp $
#
# GENERIC ARM (aarch64) kernel
#
@@ -426,6 +426,7 @@
a64acodec* at fdt? # Allwinner A64 audio codec (analog part)
sunxii2s* at fdt? # Allwinner I2S/PCM
audio* at audiobus?
+options AUDIO_BLK_MS=4
spkr* at audio? # PC speaker (synthesized)
diff -r 1c413f3ca02e -r db2fd112a83a sys/dev/audio/audiodef.h
--- a/sys/dev/audio/audiodef.h Sun Jan 26 11:29:39 2020 +0000
+++ b/sys/dev/audio/audiodef.h Mon Jan 27 07:06:02 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: audiodef.h,v 1.7 2019/07/06 12:58:58 isaki Exp $ */
+/* $NetBSD: audiodef.h,v 1.7.2.1 2020/01/27 07:06:02 martin Exp $ */
/*
* Copyright (C) 2017 Tetsuya Isaki. All rights reserved.
@@ -29,6 +29,10 @@
#ifndef _SYS_DEV_AUDIO_AUDIODEF_H_
#define _SYS_DEV_AUDIO_AUDIODEF_H_
+#ifdef _KERNEL_OPT
+#include "opt_audio.h"
+#endif
+
/* Number of HW buffer's blocks. */
#define NBLKHW (3)
diff -r 1c413f3ca02e -r db2fd112a83a sys/dev/files.audio
--- a/sys/dev/files.audio Sun Jan 26 11:29:39 2020 +0000
+++ b/sys/dev/files.audio Mon Jan 27 07:06:02 2020 +0000
@@ -1,4 +1,6 @@
-# $NetBSD: files.audio,v 1.12 2019/05/08 13:40:17 isaki Exp $
+# $NetBSD: files.audio,v 1.12.2.1 2020/01/27 07:06:02 martin Exp $
+
+defparam opt_audio.h AUDIO_BLK_MS
define audiobus { }
define midibus { }
Home |
Main Index |
Thread Index |
Old Index