1
0
mirror of https://github.com/openbsd/src.git synced 2025-01-03 06:45:37 -08:00
Commit Graph

15 Commits

Author SHA1 Message Date
jsg
f007d8ce71 remove unneeded proc.h include 2024-10-14 00:47:36 +00:00
mvs
cedac2f907 Use existing audio_lock' mutex(9) to make midi{read,write}_filtops' MP
safe. knote_locked(9) will not grab kernel lock, so call it directly from
interrupt handlers instead of scheduling software interrupts.

feedback and ok ratchov
2023-09-26 19:55:24 +00:00
miod
0d6a2fdefd Constify struct {audio,midi,radio,video}_hw_if. No functional change.
ok mpi@ ratchov@ "More const is good" deraadt@
2022-03-21 19:22:39 +00:00
ratchov
02e0ccc46e Defer selwakeup() calls to a softintr
selwakeup() needs to be protected by KERNEL_LOCK, but we're not
allowed to grab KERNEL_LOCK on interrupt context because midi runs at
IPL_AUDIO with the audio_lock held. Furthermore, doing so is a locking
order bug: syscall code-path grabs KERNEL_LOCK first while interrupt
code-path does the opposite when calling selwakeup().

ok visa
2021-10-30 12:26:26 +00:00
ratchov
3f3327608c Remove unused MIDI_MAXWRITE macro 2020-01-10 20:17:45 +00:00
kettenis
c0cd44e386 Remove SIGIO support. The audio(4) driver doesn't implement it either and
the preferred method to access MIDI hardware is through sndiod(8) which
doesn't use it.

Fixes a potential issue with a stale struct proc pointer found by Ilja van
Sprundel.

ok deraadt@, ratchov@
2017-07-19 22:23:54 +00:00
ratchov
d0b9e3b5a0 Use device_lookup() instead of digging into midi_cd.cd_devs[] and
maintaining a "dying" flag which is already present in the device
structure. As a side-effect, this adds the missing refcounting
that mididetach() was missing. With from mpi@ and dlg@

ok mpi
2015-05-16 09:56:10 +00:00
ratchov
c8d03e3ab4 remove the sc->isopen flag, as sc->flags already hold the
same information.
2015-05-12 18:39:30 +00:00
ratchov
1d0cd54ed7 Delete the sequencer(4) driver, since its not used any longer. Diff
mostly from armani.
ok miod, mpi, jsg and help from sthen
2013-03-15 09:10:52 +00:00
ratchov
f3db5e0d9a If the MIDI UART is not ready for output, don't spin at IPL_CLOCK;
just return and make the midi(4) driver retry later. UART buffers
are large enough for this, except eap(4) which uses interrupts for
output.
help from and ok jsg@
2012-03-30 08:18:19 +00:00
millert
39539e65e5 Move contents of sys/select.h to sys/selinfo.h in preparation for a
userland-visible sys/select.h.  Consistent with what Net and Free do.
OK deraadt@, tested with full ports build by naddy@.
2005-11-21 18:16:36 +00:00
jsg
48f0b64651 add some missing $, ok djm@ 'That looks fine to me' millert@ 2004-10-01 04:08:45 +00:00
deraadt
081bdb7544 better midi stuff from alex@caoua.org 2004-06-27 19:44:48 +00:00
art
8d302f0e78 Convert to new timeouts. 2000-06-26 22:43:21 +00:00
niklas
5daee67f96 Midi & sequencer support from NetBSD, mostly by Lennart Augustsson 1999-01-02 00:02:32 +00:00