Commit 4e4a0b7b authored by Chieh-Chun Chen's avatar Chieh-Chun Chen

use bool and fix indentation

parent 3e2d8890
...@@ -118,7 +118,7 @@ static void nr_pdcp_entity_recv_pdu(nr_pdcp_entity_t *entity, ...@@ -118,7 +118,7 @@ static void nr_pdcp_entity_recv_pdu(nr_pdcp_entity_t *entity,
if (memcmp(integrity, buffer + size - integrity_size, 4) != 0) { if (memcmp(integrity, buffer + size - integrity_size, 4) != 0) {
LOG_E(PDCP, "discard NR PDU, integrity failed\n"); LOG_E(PDCP, "discard NR PDU, integrity failed\n");
// return; // return;
entity->stats.rxpdu_dd_pkts++; entity->stats.rxpdu_dd_pkts++;
entity->stats.rxpdu_dd_bytes += size; entity->stats.rxpdu_dd_bytes += size;
...@@ -128,7 +128,7 @@ static void nr_pdcp_entity_recv_pdu(nr_pdcp_entity_t *entity, ...@@ -128,7 +128,7 @@ static void nr_pdcp_entity_recv_pdu(nr_pdcp_entity_t *entity,
if (rcvd_count < entity->rx_deliv if (rcvd_count < entity->rx_deliv
|| nr_pdcp_sdu_in_list(entity->rx_list, rcvd_count)) { || nr_pdcp_sdu_in_list(entity->rx_list, rcvd_count)) {
LOG_W(PDCP, "discard NR PDU rcvd_count=%d, entity->rx_deliv %d,sdu_in_list %d\n", rcvd_count,entity->rx_deliv,nr_pdcp_sdu_in_list(entity->rx_list,rcvd_count)); LOG_W(PDCP, "discard NR PDU rcvd_count=%d, entity->rx_deliv %d,sdu_in_list %d\n", rcvd_count,entity->rx_deliv,nr_pdcp_sdu_in_list(entity->rx_list,rcvd_count));
entity->stats.rxpdu_dd_pkts++; entity->stats.rxpdu_dd_pkts++;
entity->stats.rxpdu_dd_bytes += size; entity->stats.rxpdu_dd_bytes += size;
......
...@@ -1138,8 +1138,8 @@ void nr_rlc_activate_avg_time_to_tx( ...@@ -1138,8 +1138,8 @@ void nr_rlc_activate_avg_time_to_tx(
nr_rlc_manager_unlock(nr_rlc_ue_manager); nr_rlc_manager_unlock(nr_rlc_ue_manager);
} }
/* returns 0 in case of error, 1 if everything ok */ /* returns false in case of error, true if everything ok */
int const nr_rlc_get_statistics( const bool nr_rlc_get_statistics(
int rnti, int rnti,
int srb_flag, int srb_flag,
int rb_id, int rb_id,
...@@ -1147,7 +1147,7 @@ int const nr_rlc_get_statistics( ...@@ -1147,7 +1147,7 @@ int const nr_rlc_get_statistics(
{ {
nr_rlc_ue_t *ue; nr_rlc_ue_t *ue;
nr_rlc_entity_t *rb; nr_rlc_entity_t *rb;
int ret; bool ret;
nr_rlc_manager_lock(nr_rlc_ue_manager); nr_rlc_manager_lock(nr_rlc_ue_manager);
ue = nr_rlc_manager_get_ue(nr_rlc_ue_manager, rnti); ue = nr_rlc_manager_get_ue(nr_rlc_ue_manager, rnti);
...@@ -1164,9 +1164,9 @@ int const nr_rlc_get_statistics( ...@@ -1164,9 +1164,9 @@ int const nr_rlc_get_statistics(
if (rb != NULL) { if (rb != NULL) {
rb->get_stats(rb, out); rb->get_stats(rb, out);
ret = 1; ret = true;
} else { } else {
ret = 0; ret = false;
} }
nr_rlc_manager_unlock(nr_rlc_ue_manager); nr_rlc_manager_unlock(nr_rlc_ue_manager);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment