Commit 57c4633f authored by Robert Schmidt's avatar Robert Schmidt Committed by Teodora Vladić

Take the long PRACH into account in queues

Fixes the commit ID: 03096dd4Signed-off-by: default avatarTeodora Vladić <teodora.vladic@openairinterface.org>
parent 38dc3782
...@@ -34,7 +34,8 @@ static bool drop_old_prach(const void *data, void *user) ...@@ -34,7 +34,8 @@ static bool drop_old_prach(const void *data, void *user)
{ {
const prach_item_t *p = data; const prach_item_t *p = data;
const fsn_t *now = user; const fsn_t *now = user;
const fsn_t t = {p->frame, p->slot, now->mu}; // account for long PRACH over more than 1 slot
const fsn_t t = {p->frame, p->slot + p->num_slots - 1, now->mu};
bool drop = fsn_in_the_past(t, *now); bool drop = fsn_in_the_past(t, *now);
if (drop) if (drop)
LOG_E(NR_PHY, "%4d.%2d PRACH job is in the past (%4d.%2d)\n", now->f, now->s, t.f, t.s); LOG_E(NR_PHY, "%4d.%2d PRACH job is in the past (%4d.%2d)\n", now->f, now->s, t.f, t.s);
...@@ -45,7 +46,8 @@ static bool get_current_prach(const void *data, void *user) ...@@ -45,7 +46,8 @@ static bool get_current_prach(const void *data, void *user)
{ {
const prach_item_t *p = data; const prach_item_t *p = data;
const fsn_t *now = user; const fsn_t *now = user;
const fsn_t t = {p->frame, p->slot, now->mu}; // account for long PRACH over more than 1 slot
const fsn_t t = {p->frame, p->slot + p->num_slots - 1, now->mu};
return fsn_equal(t, *now); return fsn_equal(t, *now);
} }
......
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