aboutsummaryrefslogtreecommitdiffstats
path: root/src/pdch_ul_controller.h
AgeCommit message (Collapse)AuthorFilesLines
2022-11-17constify pdch_ulc_get_next_free_fn() parameterMax1-1/+1
Change-Id: I91738f951f57bd171d8cbd66fe5e5c46e6fa953b
2022-11-17cosmetic: drop unused field from struct pdch_ulcMax1-1/+0
Change-Id: Icf6204d99f91531f5ecad05e3f9f89406e5d12b5
2021-12-14treewide: remove FSF address2021q4Oliver Smith1-4/+0
Remove the paragraph about writing to the Free Software Foundation's mailing address. The FSF has changed addresses in the past, and may do so again. In 2021 this is not useful, let's rather have a bit less boilerplate at the start of source files. Change-Id: I4a49dbeeec89b22624c968152118aecf8886dac6
2021-06-07pdch: Log pdch_ulc reason upon rx of pkt ctrl ackPau Espin Pedrol1-0/+1
Change-Id: I7c7a421b1e9189e2814e9a28698d66655fc9ba60
2021-04-22pdch: rcv_resource_request: Improve robustnessPau Espin Pedrol1-1/+1
Use recently added PDCH UL Controller to verify expectancies. Test test_packet_access_rej_prr is rewritten since it didn't make sense as it was before, since it relied on osmo-pcu not checking stuff properly to trigger the reject. The RACH requests are changed to allocate 8 SBAs (maximum of 7 concurrent USFs). Allocating the SBA doesn't reserve a USF, that happens at PKT RESOURCE REQUEST, hence we end up exhausting resources there and triggering the REJECT at that point. Previous version of the patch allocated TBFs directly through RACH req, and then submitted an extra PKT RESOURCE REQUEST which PCU didn't expect to trigger the reject. Change-Id: I157e72160317340ee7742c78c62a25d3d98fc01e
2021-03-31pdch_ulc: Store TBF poll reasonPau Espin Pedrol1-1/+10
This allows easily checking the initial reason to trigger the poll when either it is received or times out. Later on this reason can be transformed into an FSM event and sent to the related FSM. Related: OS#5020 Change-Id: Ie8fefd1f47ad674ce597a8065b15284088956bde
2021-03-31pdch_ulc: Support picking RRBP other than N+13Pau Espin Pedrol1-0/+8
Current algo always tries to sched RRBP the soonest possible. Related: OS#5020 Change-Id: Ic6ddeea70e1f914cf423d0daab8fc492d0c992e2
2021-03-31Pick unreserved UL FN when allocating an SBAPau Espin Pedrol1-0/+1
Make sure an unreserved FN is picked and reserved when allocating and scheduling an SBA. In practice this has no change in behavior right now, since anyway using an offset of 52 FNs ensure no USF or POLL has alredy been scheduled that far in the future. Since it's also impossible to allocate more than 1 SBA per PDCH and RTS FN, we are also safe about multiple SBAs being allocated, because we use a hardcoded offset of 52. However, that could change in the future, when we dynamically tweak the current offset of 52 FN based on information from BTS about its AGCH queue load: * If load is high, we may need to increase the offset since it will take more time for the BTS to transmit the TBF and hence we must reserve a TBF starting time further in the future (higher FN). * If load turns low, we may schedule next SBA a bit more nearby in time than the previously allocated SBA, hence here there could be a collision. Related: OS#5020 Change-Id: I2d4e21e2307de6c17748e8da5c7e149c947a7eb9
2021-03-24pdch_ulc: Create helper API pdch_ulc_release_nodePau Espin Pedrol1-1/+1
Change-Id: I6362ad7382c2b73e6fedb11182964be96e5c8d35
2021-03-15sched: Use new PDCH UL ControllerPau Espin Pedrol1-0/+1
Take the time to also do small refactorings to clarify and simplify the function, by using rts_next_fn() already available in pcu_utils.h and getting rid of poll_tbf from tbf_candidates, which clearly follows another objective. Using PDCH UL Controller has the advantage that we don't need to check poll_scheduled() on each TBF, but only do the query once. Related: OS#5020 Change-Id: Ia60bb5249a9837dec1f42180e44d9848334d86d6
2021-03-15Replace PollController with newly added PDCH UL ControllerPau Espin Pedrol1-0/+4
TbfTest is updated to submit empty blocks to have somehow meaningful output (at least as meaningful test results as before, not much). That's because we must update bts->curr_fn to have polls expire. Related: OS#5020 Change-Id: I683ca738ce5a133c49c36a1d94439a942d64a831
2021-03-15Add new PDCH UL Controller, drop SBAllocator classPau Espin Pedrol1-0/+79
Right now we handle different types of UL allocations in different classes like PollAllocator and SBAllocator, and they usually don't take into account the other one in most cases. Furthermore, those objects are usually per-BTS object, instead of per PDCH object. This is a first step towards having a unified per-PDCH controller which takes care of controlling what is scheduled and hence expected on the uplink. Each PDCH has a UL Controller which keeps track of all reserved uplink frame, be it SB, RRBP poll or USF assigned, all under the same API. As a first step, only the SBA part is fully implemented and used (being it the easiest part to replace); TBF poll+usf will come in follow-up patches later on. As a result, the SBAllocator per-BTS class dissappears but some of its code is refactored/reused to provide more features to the gprs_rlcmac_sba object, which is also further integrated into the new UL Controller. Related: OS#5020 Change-Id: I84b24beea4a1aa2c1528f41435f77bd16df2b947