OpenBSD CVS

CVS log for src/usr.bin/sndiod/dev_sioctl.c


[BACK] Up to [local] / src / usr.bin / sndiod

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.8 / (download) - annotate - [select for diffs], Mon Apr 22 10:43:55 2024 UTC (3 weeks, 6 days ago) by ratchov
Branch: MAIN
CVS Tags: HEAD
Changes since 1.7: +17 -11 lines
Diff to previous 1.7 (colored)

sndiod: Hide forgotten debug printfs

Revision 1.7 / (download) - annotate - [select for diffs], Wed Mar 3 10:00:27 2021 UTC (3 years, 2 months ago) by ratchov
Branch: MAIN
CVS Tags: OPENBSD_7_5_BASE, OPENBSD_7_5, OPENBSD_7_4_BASE, OPENBSD_7_4, OPENBSD_7_3_BASE, OPENBSD_7_3, OPENBSD_7_2_BASE, OPENBSD_7_2, OPENBSD_7_1_BASE, OPENBSD_7_1, OPENBSD_7_0_BASE, OPENBSD_7_0, OPENBSD_6_9_BASE, OPENBSD_6_9
Changes since 1.6: +21 -31 lines
Diff to previous 1.6 (colored)

sndiod: Move controls out of the device structure

Moving to a global server-wide controls list is necessary to expose
controls that are not associated to a particular device (ex. a device
selector).

The current hack to use the device-side sioctl_desc->addr variable as
client-side key can't work anymore. So, we use a unique dynamically
allocated ctl->addr key; this is much cleaner. A new "scope" enum
(with two "void *" arguments) is used to determine what the control
does control. This adds flexibility and allows to easily add new
control types that are not associated to devices.

No behavior change.

Revision 1.6 / (download) - annotate - [select for diffs], Sun Jun 28 05:21:39 2020 UTC (3 years, 10 months ago) by ratchov
Branch: MAIN
CVS Tags: OPENBSD_6_8_BASE, OPENBSD_6_8
Changes since 1.5: +5 -4 lines
Diff to previous 1.5 (colored)

Allow switching between alternate devices (-F option) with sndioctl(1)

Revision 1.5 / (download) - annotate - [select for diffs], Fri Apr 24 11:33:28 2020 UTC (4 years ago) by ratchov
Branch: MAIN
CVS Tags: OPENBSD_6_7_BASE, OPENBSD_6_7
Changes since 1.4: +22 -6 lines
Diff to previous 1.4 (colored)

Make sure devices are properly closed in case of an error.

Fixes possible crashes if the contol device fails, while the audio
device continues to work.

Revision 1.4 / (download) - annotate - [select for diffs], Thu Apr 16 12:26:55 2020 UTC (4 years, 1 month ago) by ratchov
Branch: MAIN
Changes since 1.3: +5 -6 lines
Diff to previous 1.3 (colored)

If available, use hardware "output.level" for volume control.

With this change, there's a single outputs.level control: either the
hardware one or software one. Consequently, there can't be control
name clashes and there's no need to move hardware's top-level controls
into the "hw/" group.

Revision 1.3 / (download) - annotate - [select for diffs], Wed Apr 15 14:26:40 2020 UTC (4 years, 1 month ago) by ratchov
Branch: MAIN
Changes since 1.2: +10 -2 lines
Diff to previous 1.2 (colored)

When device is (re-)opened, call dev_ctlsync() if there's no control device

In the dev_reopen() case the controls of the old device are removed,
but if the new device has no controls, we still need to call
dev_ctlsync() so that clients are notified about the removal of the
old controls.

Revision 1.2 / (download) - annotate - [select for diffs], Sun Mar 8 14:52:20 2020 UTC (4 years, 2 months ago) by ratchov
Branch: MAIN
Changes since 1.1: +5 -2 lines
Diff to previous 1.1 (colored)

Don't forget to notify clients when controls list is ready.

This is needed because when devices are swapped, clients need to know
when to rebuild their user interface.

Revision 1.1 / (download) - annotate - [select for diffs], Wed Feb 26 13:53:58 2020 UTC (4 years, 2 months ago) by ratchov
Branch: MAIN

Add API to control audio device parameters exposed by sndiod.

The API exposes controls of modern audio hardware and sndiod software
volume knobs in a uniform way.  Hardware knobs are exposed through
sndiod.  Multiple programs may use the controls at the same time
without the need to continuously scan the controls.

For now sndiod exposes only its own controls and the master output and
input volumes of the underlying hardware (if any), i.e. those
typically exposed by acpi volume keys.

ok deraadt

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.