Jack-Session was bad idea from the start,
so its use was never encouraged in LADI project.
NonSM & NewSM OSC-RPC, as used over UDP only, was and still is
unrealiable in multi computer in a network scenarios because of the
UDP packet loss.
Jack-Session used to be another jackaudio.org recommendation,
which ended in deprecations. However, as loading JS sessions via
LADISH is a feature to be maintained and sensible warnings during
build are to be easy catched, the half-deprecated jack-session api is
now undeprecated for the compiler. Jack-Session is left documented as
deprecated.
It is better to have internal clients and drivers in different directories.
While prefixing the shared library names with "jack_" could be used for
distinguising between drivers and internal clients during load,
this was is not the case with current code.
Also, as neither drivers nor internal clients are supposed to be implicitly
loadable via ld.so as regular shared libraries, they now reside in
<PREFIX>/libexec/jack-driver/ and <PREFIX>/libexec/jack-internal/
The jack_ prefix for drivers is removed.
Windows specific code paths are not updated.
--dbus and --classic options are no more.
jackd is maintained at jackaudio.org
jackdbus is maintained in decicated LADI repo:
https://jackdbus.ladish.org/
See also commit 895472e250
On failure, currently the jack thread exits without notifying the jackd.
So jackd is just waiting for the signals, unaware of the failure.
With this implementation, on error threads can post an event to jackd
notifying it to to exit.
(cherry picked from adit commit c430be1e337f52aba8312f7d29990e190cad204a)
Change-Id: Ib484bb1e126f6bff0db76d44e6e036f92f5d8806
Signed-off-by: Laxmi Devi <Laxmi.Devi@in.bosch.com>
Signed-off-by: Timo Wischer <twischer@de.adit-jv.com>
This would be required so that the polling concept can be used to wait
on signals as well as wait for events from the other threads.
(cherry picked from adit)
Change-Id: Ic7b8d4c816d601d4b5467ec9c2519f3c547ae59f
Signed-off-by: Laxmi Devi <Laxmi.Devi@in.bosch.com>
Signed-off-by: Timo Wischer <twischer@de.adit-jv.com>
Implementators and/or users of the JACK Control API interface header
file are hereby granted right to use my work in control API header file
under one of the licenses (pick any, pick one):
* GPL-2.0-or-later
* LGPL-2.1-or-later
* MIT
* AFL-2.1
An extended license from Nedko Anaudov follows:
JACK control API (GPL or LGPL or MIT or AFL, pick the license that suits you)
Implementators or users of this interface header file are granted rights
under one of the licenses (pick any, pick one):
* GPL-2.0-or-later
* LGPL-2.1-or-later
* MIT
* AFL-2.1
Ignore self connect requests to external ports only is now the default
mode.
In the default now 'e' mode, jack clients are still able to connect
their own ports. jack client attempts to connect its own ports to
other jack client ports, including "system", will be ignored in the
default configuration.
Despite still observable self-connect behaviour of firefox and other
jack clients, it is not desirable for jack (modular) setups.
* fix ringbuffer thread safety on ARM. fix#715#388
This patch addresses the thread safety problem of `jack_ringbuffer_t`
mentioned in #715 and #388. The overbound read bug caused by this problem
is impossible to reproduce on x86 due to its strong memory ordering, but
it is a problem on ARM and other weakly ordered architectures.
Basically, the main problem is that, on a weakly ordered architecture,
it is possible that the pointer increment after `memcpy` becomes visible
to the other thread before `memcpy` finishes:
memcpy (&(rb->buf[rb->write_ptr]), src, n1);
// vvv can be visible to reading thread before memcpy finishes
rb->write_ptr = (rb->write_ptr + n1) & rb->size_mask;
If this happens, the other thread can read the remaining garbage values
in `rb->buf` due to be overwritten by the unfinished `memcpy`.
To fix this, an explicit pair of release/acquire memory fences [1] is
used to ensure the copy on the other thread *happens after* the `memcpy`
finishes so no garbage values can be read.
[1]: https://preshing.com/20130922/acquire-and-release-fences/
* remove volatile qualifier on ringbuf r/w pointers
The volatile constraints are excess when compiler barriers are present.
It generates unnecessary `mov` instructions when pointers aren't going
to be updated.
* simplify read/write space calculations
This optimization is possible because the buffer size is always a power
of 2. See [1] for details.
[1]: https://github.com/drobilla/zix/pull/1#issuecomment-1212687196
* move acq fences to separate lines
This adds a LICENSE file that describes which licenses this project is
licensed under. This is very important, as the project is licensed under
three licenses.
Also added are copyright notices to the wscript files. I added myself as
copyright holder to them, but there are other people who have
contributed to these files which should have their name in the copyright
header. Clearly stating the license of the wscript files should have
been done long ago.