hnbgw: Use LOGHNB() to add log context information to log lines
So far we don't really have any way of matching a given log message
to a specific hNB. Let's use the newly-introduced LOGHNB() macro.
Change-Id: Ia16eed4ca5e9ef231259e94c65105f7586f366bc
diff --git a/src/hnbgw.c b/src/hnbgw.c
index ba8a06f..a6e0d29 100644
--- a/src/hnbgw.c
+++ b/src/hnbgw.c
@@ -235,7 +235,7 @@
msgb_free(msg);
return 0;
} else if (rc < 0) {
- LOGP(DMAIN, LOGL_ERROR, "Error during sctp_recvmsg()\n");
+ LOGHNB(hnb, DMAIN, LOGL_ERROR, "Error during sctp_recvmsg()\n");
/* FIXME: clean up after disappeared HNB */
hnb_context_release(hnb);
goto out;
@@ -260,13 +260,11 @@
case IUH_PPI_SABP:
case IUH_PPI_RNA:
case IUH_PPI_PUA:
- LOGP(DMAIN, LOGL_ERROR, "Unimplemented SCTP PPID=%lu received\n",
- msgb_sctp_ppid(msg));
+ LOGHNB(hnb, DMAIN, LOGL_ERROR, "Unimplemented SCTP PPID=%lu received\n", msgb_sctp_ppid(msg));
rc = 0;
break;
default:
- LOGP(DMAIN, LOGL_ERROR, "Unknown SCTP PPID=%lu received\n",
- msgb_sctp_ppid(msg));
+ LOGHNB(hnb, DMAIN, LOGL_ERROR, "Unknown SCTP PPID=%lu received\n", msgb_sctp_ppid(msg));
rc = 0;
break;
}