i460: pass more context to call-back functions
When calling a user-provided call-back function for the i460 mux
or demux, always pass a pointer to the osmo_i460_subchan the callback
relates to. This way, the user can walk the i460 data structures
to obtain information about which mux/demux instances is calling.
Change-Id: Id842c72ce371a67fe5df6694e195c281aaf607ab
diff --git a/tests/i460_mux/i460_mux_test.c b/tests/i460_mux/i460_mux_test.c
index 53144fd..d63b2ae 100644
--- a/tests/i460_mux/i460_mux_test.c
+++ b/tests/i460_mux/i460_mux_test.c
@@ -3,7 +3,8 @@
#include <osmocom/gsm/i460_mux.h>
-static void bits_cb(void *user_data, const ubit_t *bits, unsigned int num_bits)
+static void bits_cb(struct osmo_i460_subchan *schan, void *user_data,
+ const ubit_t *bits, unsigned int num_bits)
{
char *str = user_data;
printf("demux_bits_cb '%s': %s\n", str, osmo_ubit_dump(bits, num_bits));