GSCON: call api of a_reset.c with msc object directly

The API of a_reset.c is currently called with a pointer to struct
reset_ctx. This puts the responsibility of checking the presence of
msc->a.reset_fsm to the caller. It would be much more effective if the
caller would check if msc->a.reset_fsm before dereferencing it.

This also fixes at least one segfault that ocurrs when gscon_timer_cb()
is called but no sccp connection is present yet. Therefore the pointer
to bsc_msc_data would not be populated. This is now detected by
a_reset.c itsself.

- minor code cleanups
- call a_reset.c functions with msc (struct bsc_msc_data)

Change-Id: I0802aaadf0af4e58e41c98999e8c6823838adb61
Related: OS#3447
diff --git a/include/osmocom/bsc/a_reset.h b/include/osmocom/bsc/a_reset.h
index 6b6ce81..a09972e 100644
--- a/include/osmocom/bsc/a_reset.h
+++ b/include/osmocom/bsc/a_reset.h
@@ -20,17 +20,19 @@
 
 #pragma once
 
+struct bsc_msc_data;
+
 /* Create and start state machine which handles the reset/reset-ack procedure */
-struct osmo_fsm_inst *a_reset_alloc(void *ctx, const char *name, void *cb, void *priv);
+void a_reset_alloc(struct bsc_msc_data *msc, const char *name, void *cb);
 
 /* Confirm that we sucessfully received a reset acknowlege message */
-void a_reset_ack_confirm(struct osmo_fsm_inst *reset_fsm);
+void a_reset_ack_confirm(struct bsc_msc_data *msc);
 
 /* Report a failed connection */
-void a_reset_conn_fail(struct osmo_fsm_inst *reset_fsm);
+void a_reset_conn_fail(struct bsc_msc_data *msc);
 
 /* Report a successful connection */
-void a_reset_conn_success(struct osmo_fsm_inst *reset_fsm);
+void a_reset_conn_success(struct bsc_msc_data *msc);
 
 /* Check if we have a connection to a specified msc */
-bool a_reset_conn_ready(struct osmo_fsm_inst *reset_fsm);
+bool a_reset_conn_ready(struct bsc_msc_data *msc);