rspro_client_fsm: Differentiate different log levels

Raw Rx/Tx of messages should be LOGL_DEBUG, while connection
establishment/loss should be something like LOGL_NOTICE.

Change-Id: I1bc6d491a8a748cbd729cbdeede60d32bd760a15
changes/69/26469/3
Harald Welte 1 year ago
parent 50a0972a87
commit 8934412ce5
  1. 7
      src/rspro_client_fsm.c

@ -79,7 +79,7 @@ static int ipa_client_conn_send_rspro(struct ipa_client_conn *ipa, RsproPDU_t *r
static int _server_conn_send_rspro(struct rspro_server_conn *srvc, RsproPDU_t *rspro)
{
LOGPFSM(srvc->fi, "Tx RSPRO %s\n", rspro_msgt_name(rspro));
LOGPFSML(srvc->fi, LOGL_DEBUG, "Tx RSPRO %s\n", rspro_msgt_name(rspro));
return ipa_client_conn_send_rspro(srvc->conn, rspro);
}
@ -124,7 +124,8 @@ static void srvc_updown_cb(struct ipa_client_conn *conn, int up)
{
struct rspro_server_conn *srvc = conn->data;
LOGPFSM(srvc->fi, "RSPRO link to %s:%d %s\n", conn->addr, conn->port, up ? "UP" : "DOWN");
LOGPFSML(srvc->fi, LOGL_NOTICE, "RSPRO link to %s:%d %s\n",
conn->addr, conn->port, up ? "UP" : "DOWN");
osmo_fsm_inst_dispatch(srvc->fi, up ? SRVC_E_TCP_UP: SRVC_E_TCP_DOWN, 0);
}
@ -162,7 +163,7 @@ static int srvc_read_cb(struct ipa_client_conn *conn, struct msgb *msg)
msg->l2h = &he->data[0];
switch (he->proto) {
case IPAC_PROTO_EXT_RSPRO:
LOGPFSM(srvc->fi, "Received RSPRO %s\n", msgb_hexdump(msg));
LOGPFSML(srvc->fi, LOGL_DEBUG, "Received RSPRO %s\n", msgb_hexdump(msg));
pdu = rspro_dec_msg(msg);
if (!pdu) {
rc = -EIO;

Loading…
Cancel
Save