aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bts-octphy
diff options
context:
space:
mode:
authorHarald Welte <laforge@osmocom.org>2023-03-29 13:31:42 +0200
committerlaforge <laforge@osmocom.org>2023-04-09 14:10:09 +0000
commitc3d839be9e0b49be84d6f4700927f57bcbdc7d2c (patch)
tree489b61e49ec861f1e7017cb8eb3e0896ab396992 /src/osmo-bts-octphy
parent5b75e5dc8d81f467a1dfcb5a74a5f871ee69fa16 (diff)
cosmetic: Change LOGPLCFN argument order
As it has come up during code review of Change-ID I214af0448652a9f321ccbab77977b67663ba28f9 introducing LOGPLCNF, my approach to the strict preserval of argument order (lchan first from LOGPLCHAN and fn *after* loglevel from LOGPFN) was considered sub-optimal. I used the following spatch rule to clean this up: @@ expression lc, ss, logl, fn; expression list trailer; @@ -LOGPLCFN(lc, ss, logl, fn, trailer); +LOGPLCFN(lc, fn, ss, logl, trailer); Change-Id: Iba4a8416545673d03cb057e4855f8b1ecae3e1ec
Diffstat (limited to 'src/osmo-bts-octphy')
-rw-r--r--src/osmo-bts-octphy/l1_if.c2
-rw-r--r--src/osmo-bts-octphy/l1_tch.c12
2 files changed, 7 insertions, 7 deletions
diff --git a/src/osmo-bts-octphy/l1_if.c b/src/osmo-bts-octphy/l1_if.c
index 1488a9d6..f132cddc 100644
--- a/src/osmo-bts-octphy/l1_if.c
+++ b/src/osmo-bts-octphy/l1_if.c
@@ -589,7 +589,7 @@ static int ph_tch_req(struct gsm_bts_trx *trx, struct msgb *msg,
if (msg) {
nmsg = l1p_msgb_alloc();
if (!nmsg) {
- LOGPLCFN(lchan, DL1C, LOGL_FATAL, u32Fn, "L1SAP PH-TCH.req msg alloc failed\n");
+ LOGPLCFN(lchan, u32Fn, DL1C, LOGL_FATAL, "L1SAP PH-TCH.req msg alloc failed\n");
return -ENOMEM;
}
diff --git a/src/osmo-bts-octphy/l1_tch.c b/src/osmo-bts-octphy/l1_tch.c
index f8800fdc..4b542d11 100644
--- a/src/osmo-bts-octphy/l1_tch.c
+++ b/src/osmo-bts-octphy/l1_tch.c
@@ -146,7 +146,7 @@ int l1if_tch_rx(struct gsm_bts_trx *trx, uint8_t chan_nr,
&trx->ts[L1SAP_CHAN2TS(chan_nr)].lchan[l1sap_chan2ss(chan_nr)];
if (data_ind->Data.ulDataLength < 1) {
- LOGPLCFN(lchan, DL1P, LOGL_DEBUG, fn, "chan_nr %d Rx Payload size 0\n", chan_nr);
+ LOGPLCFN(lchan, fn, DL1P, LOGL_DEBUG, "chan_nr %d Rx Payload size 0\n", chan_nr);
/* Push empty payload to upper layers */
rmsg = msgb_alloc_headroom(256, 128, "L1P-to-RTP");
return add_l1sap_header(trx, rmsg, lchan, chan_nr,
@@ -173,13 +173,13 @@ int l1if_tch_rx(struct gsm_bts_trx *trx, uint8_t chan_nr,
goto err_payload_match;
break;
default:
- LOGPLCFN(lchan, DL1P, LOGL_NOTICE, fn, "%s Rx Payload Type %d is unsupported\n",
+ LOGPLCFN(lchan, fn, DL1P, LOGL_NOTICE, "%s Rx Payload Type %d is unsupported\n",
gsm_lchan_name(lchan), payload_type);
break;
}
- LOGPLCFN(lchan, DL1P, LOGL_DEBUG, fn, "%s Rx codec frame (%u): %s\n", gsm_lchan_name(lchan),
- payload_len, osmo_hexdump(payload, payload_len));
+ LOGPLCFN(lchan, fn, DL1P, LOGL_DEBUG, "%s Rx codec frame (%u): %s\n", gsm_lchan_name(lchan), payload_len,
+ osmo_hexdump(payload, payload_len));
switch (payload_type) {
case cOCTVC1_GSM_PAYLOAD_TYPE_ENUM_FULL_RATE:
@@ -201,7 +201,7 @@ int l1if_tch_rx(struct gsm_bts_trx *trx, uint8_t chan_nr,
rmsg = l1_to_rtppayload_amr(payload, payload_len,
&lchan->tch.amr_mr);
#else
- LOGPLCFN(lchan, DL1P, LOGL_ERROR, fn, "OctPHY only supports FR!\n");
+ LOGPLCFN(lchan, fn, DL1P, LOGL_ERROR, "OctPHY only supports FR!\n");
return -1;
#endif
break;
@@ -215,7 +215,7 @@ int l1if_tch_rx(struct gsm_bts_trx *trx, uint8_t chan_nr,
return 0;
err_payload_match:
- LOGPLCFN(lchan, DL1P, LOGL_ERROR, fn, "%s Rx Payload Type %d incompatible with lchan\n",
+ LOGPLCFN(lchan, fn, DL1P, LOGL_ERROR, "%s Rx Payload Type %d incompatible with lchan\n",
gsm_lchan_name(lchan), payload_type);
return -EINVAL;
}