1 /*******************************************************************************
2 ################################################################################
3 # Copyright (c) [2017-2019] [Radisys] #
5 # Licensed under the Apache License, Version 2.0 (the "License"); #
6 # you may not use this file except in compliance with the License. #
7 # You may obtain a copy of the License at #
9 # http://www.apache.org/licenses/LICENSE-2.0 #
11 # Unless required by applicable law or agreed to in writing, software #
12 # distributed under the License is distributed on an "AS IS" BASIS, #
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. #
14 # See the License for the specific language governing permissions and #
15 # limitations under the License. #
16 ################################################################################
17 *******************************************************************************/
20 /************************************************************************
26 Desc: C source code for pack/unpack of TFU interface primitives.
30 **********************************************************************/
33 @brief This file contains the packing/unpacking code for the TFU interface
37 /* header include files (.h) */
38 #include "common_def.h"
39 #include "tfu.h" /* RGU Interface defines */
41 /* header/extern include files (.x) */
42 #include "tfu.x" /* RGU Interface includes */
44 #include "du_app_mac_inf.h"
45 //#include "mac_sch_interface.h"
50 /***********************************************************
52 * Func : cmPkTfuBndReq
55 * Desc : This API is used to send a Bind Request from MAC to PHY.
56 * @param pst Pointer to the post structure.
57 * @param suId SAP ID of the service user.
58 * @param spId SAP ID of the service provider.
68 **********************************************************/
77 S16 cmPkTfuBndReq(pst, suId, spId)
85 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
86 #if (ERRCLASS & ERRCLS_ADD_RES)
87 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
88 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
89 (ErrVal)ETFU001, (ErrVal)0, "Packing failed");
93 if (SPkS16(spId, mBuf) != ROK) {
94 #if (ERRCLASS & ERRCLS_ADD_RES)
95 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
96 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
97 (ErrVal)ETFU002, (ErrVal)0, "Packing failed");
102 if (SPkS16(suId, mBuf) != ROK) {
103 #if (ERRCLASS & ERRCLS_ADD_RES)
104 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
105 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
106 (ErrVal)ETFU003, (ErrVal)0, "Packing failed");
111 pst->event = (Event) EVTTFUBNDREQ;
112 return (SPstTsk(pst,mBuf));
116 /***********************************************************
118 * Func : cmUnpkTfuBndReq
121 * Desc : This API is used to send a Bind Request from MAC to PHY.
122 * @param pst Pointer to the post structure.
123 * @param suId SAP ID of the service user.
124 * @param spId SAP ID of the service provider.
125 * @return ROK/RFAILED
134 **********************************************************/
143 S16 cmUnpkTfuBndReq(func, pst, mBuf)
153 if (SUnpkS16(&suId, mBuf) != ROK) {
155 #if (ERRCLASS & ERRCLS_ADD_RES)
156 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
157 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
158 (ErrVal)ETFU004, (ErrVal)0, "Packing failed");
162 if (SUnpkS16(&spId, mBuf) != ROK) {
164 #if (ERRCLASS & ERRCLS_ADD_RES)
165 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
166 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
167 (ErrVal)ETFU005, (ErrVal)0, "Packing failed");
172 return ((*func)(pst, suId, spId));
176 /***********************************************************
178 * Func : cmPkTfuBndCfm
181 * Desc : This API is used to receive a Bind Confirm from PHY to MAC.
182 * @param pst Pointer to the post structure.
183 * @param suId SAP ID of the service user.
184 * @param status Status of the bind request.
185 * @return ROK/RFAILED
194 **********************************************************/
203 S16 cmPkTfuBndCfm(pst, suId, status)
209 Buffer *mBuf = NULLP;
211 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
212 #if (ERRCLASS & ERRCLS_ADD_RES)
213 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
214 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
215 (ErrVal)ETFU006, (ErrVal)0, "Packing failed");
219 if (oduUnpackUInt8(status, mBuf) != ROK) {
220 #if (ERRCLASS & ERRCLS_ADD_RES)
221 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
222 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
223 (ErrVal)ETFU007, (ErrVal)0, "Packing failed");
228 if (SPkS16(suId, mBuf) != ROK) {
229 #if (ERRCLASS & ERRCLS_ADD_RES)
230 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
231 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
232 (ErrVal)ETFU008, (ErrVal)0, "Packing failed");
237 pst->event = (Event) EVTTFUBNDCFM;
238 return (SPstTsk(pst,mBuf));
242 /***********************************************************
244 * Func : cmUnpkTfuBndCfm
247 * Desc : This API is used to receive a Bind Confirm from PHY to MAC.
248 * @param pst Pointer to the post structure.
249 * @param suId SAP ID of the service user.
250 * @param status Status of the bind request.
251 * @return ROK/RFAILED
260 **********************************************************/
269 S16 cmUnpkTfuBndCfm(func, pst, mBuf)
279 if (SUnpkS16(&suId, mBuf) != ROK) {
281 #if (ERRCLASS & ERRCLS_ADD_RES)
282 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
283 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
284 (ErrVal)ETFU009, (ErrVal)0, "Packing failed");
288 if (oduPackUInt8(&status, mBuf) != ROK) {
290 #if (ERRCLASS & ERRCLS_ADD_RES)
291 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
292 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
293 (ErrVal)ETFU010, (ErrVal)0, "Packing failed");
298 return ((*func)(pst, suId, status));
302 /***********************************************************
304 * Func : cmPkTfuUbndReq
307 * Desc : This API is used to send an Unbind Request from MAC to PHY.
308 * @param pst Pointer to the post structure.
309 * @param suId SAP ID of the service provider.
310 * @param reason Reason for Unbind request.
311 * @return ROK/RFAILED
320 **********************************************************/
329 S16 cmPkTfuUbndReq(pst, spId, reason)
335 Buffer *mBuf = NULLP;
337 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
338 #if (ERRCLASS & ERRCLS_ADD_RES)
339 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
340 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
341 (ErrVal)ETFU011, (ErrVal)0, "Packing failed");
345 if (SPkS16(reason, mBuf) != ROK) {
346 #if (ERRCLASS & ERRCLS_ADD_RES)
347 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
348 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
349 (ErrVal)ETFU012, (ErrVal)0, "Packing failed");
354 if (SPkS16(spId, mBuf) != ROK) {
355 #if (ERRCLASS & ERRCLS_ADD_RES)
356 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
357 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
358 (ErrVal)ETFU013, (ErrVal)0, "Packing failed");
363 pst->event = (Event) EVTTFUUBNDREQ;
364 return (SPstTsk(pst,mBuf));
368 /***********************************************************
370 * Func : cmUnpkTfuUbndReq
373 * Desc : This API is used to send an Unbind Request from MAC to PHY.
374 * @param pst Pointer to the post structure.
375 * @param suId SAP ID of the service provider.
376 * @param reason Reason for Unbind request.
377 * @return ROK/RFAILED
386 **********************************************************/
395 S16 cmUnpkTfuUbndReq(func, pst, mBuf)
405 if (SUnpkS16(&spId, mBuf) != ROK) {
407 #if (ERRCLASS & ERRCLS_ADD_RES)
408 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
409 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
410 (ErrVal)ETFU014, (ErrVal)0, "Packing failed");
414 if (SUnpkS16(&reason, mBuf) != ROK) {
416 #if (ERRCLASS & ERRCLS_ADD_RES)
417 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
418 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
419 (ErrVal)ETFU015, (ErrVal)0, "Packing failed");
424 return ((*func)(pst, spId, reason));
428 /***********************************************************
430 * Func : cmPkTfuSchBndReq
433 * Desc : This API is used to send a Bind Request from Scheduler to PHY.
434 * @param pst Pointer to the post structure.
435 * @param suId SAP ID of the service user.
436 * @param spId SAP ID of the service provider.
437 * @return ROK/RFAILED
446 **********************************************************/
455 S16 cmPkTfuSchBndReq(pst, suId, spId)
461 Buffer *mBuf = NULLP;
463 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
464 #if (ERRCLASS & ERRCLS_ADD_RES)
465 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
466 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
467 (ErrVal)ETFU016, (ErrVal)0, "Packing failed");
471 if (SPkS16(spId, mBuf) != ROK) {
472 #if (ERRCLASS & ERRCLS_ADD_RES)
473 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
474 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
475 (ErrVal)ETFU017, (ErrVal)0, "Packing failed");
480 if (SPkS16(suId, mBuf) != ROK) {
481 #if (ERRCLASS & ERRCLS_ADD_RES)
482 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
483 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
484 (ErrVal)ETFU018, (ErrVal)0, "Packing failed");
489 pst->event = (Event) EVTTFUSCHBNDREQ;
490 return (SPstTsk(pst,mBuf));
494 /***********************************************************
496 * Func : cmUnpkTfuSchBndReq
499 * Desc : This API is used to send a Bind Request from Scheduler to PHY.
500 * @param pst Pointer to the post structure.
501 * @param suId SAP ID of the service user.
502 * @param spId SAP ID of the service provider.
503 * @return ROK/RFAILED
512 **********************************************************/
514 S16 cmUnpkTfuSchBndReq
521 S16 cmUnpkTfuSchBndReq(func, pst, mBuf)
531 if (SUnpkS16(&suId, mBuf) != ROK) {
533 #if (ERRCLASS & ERRCLS_ADD_RES)
534 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
535 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
536 (ErrVal)ETFU019, (ErrVal)0, "Packing failed");
540 if (SUnpkS16(&spId, mBuf) != ROK) {
542 #if (ERRCLASS & ERRCLS_ADD_RES)
543 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
544 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
545 (ErrVal)ETFU020, (ErrVal)0, "Packing failed");
550 return ((*func)(pst, suId, spId));
554 /***********************************************************
556 * Func : cmPkTfuSchBndCfm
559 * Desc : This API is used to receive a Bind Confirm from PHY to Scheduler.
560 * @param pst Pointer to the post structure.
561 * @param suId SAP ID of the service user.
562 * @param status Status of the bind request.
563 * @return ROK/RFAILED
572 **********************************************************/
581 S16 cmPkTfuSchBndCfm(pst, suId, status)
587 Buffer *mBuf = NULLP;
589 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
590 #if (ERRCLASS & ERRCLS_ADD_RES)
591 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
592 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
593 (ErrVal)ETFU021, (ErrVal)0, "Packing failed");
597 if (oduUnpackUInt8(status, mBuf) != ROK) {
598 #if (ERRCLASS & ERRCLS_ADD_RES)
599 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
600 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
601 (ErrVal)ETFU022, (ErrVal)0, "Packing failed");
606 if (SPkS16(suId, mBuf) != ROK) {
607 #if (ERRCLASS & ERRCLS_ADD_RES)
608 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
609 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
610 (ErrVal)ETFU023, (ErrVal)0, "Packing failed");
615 pst->event = (Event) EVTTFUSCHBNDCFM;
616 return (SPstTsk(pst,mBuf));
620 /***********************************************************
622 * Func : cmUnpkTfuSchBndCfm
625 * Desc : This API is used to receive a Bind Confirm from PHY to Scheduler.
626 * @param pst Pointer to the post structure.
627 * @param suId SAP ID of the service user.
628 * @param status Status of the bind request.
629 * @return ROK/RFAILED
638 **********************************************************/
640 S16 cmUnpkTfuSchBndCfm
647 S16 cmUnpkTfuSchBndCfm(func, pst, mBuf)
657 if (SUnpkS16(&suId, mBuf) != ROK) {
659 #if (ERRCLASS & ERRCLS_ADD_RES)
660 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
661 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
662 (ErrVal)ETFU024, (ErrVal)0, "Packing failed");
666 if (oduPackUInt8(&status, mBuf) != ROK) {
668 #if (ERRCLASS & ERRCLS_ADD_RES)
669 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
670 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
671 (ErrVal)ETFU025, (ErrVal)0, "Packing failed");
676 return ((*func)(pst, suId, status));
680 /***********************************************************
682 * Func : cmPkTfuSchUbndReq
685 * Desc : This API is used to send an Unbind Request from Scheduler to PHY.
686 * @param pst Pointer to the post structure.
687 * @param suId SAP ID of the service provider.
688 * @param reason Reason for Unbind request.
689 * @return ROK/RFAILED
698 **********************************************************/
700 S16 cmPkTfuSchUbndReq
707 S16 cmPkTfuSchUbndReq(pst, spId, reason)
713 Buffer *mBuf = NULLP;
715 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
716 #if (ERRCLASS & ERRCLS_ADD_RES)
717 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
718 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
719 (ErrVal)ETFU026, (ErrVal)0, "Packing failed");
723 if (SPkS16(reason, mBuf) != ROK) {
724 #if (ERRCLASS & ERRCLS_ADD_RES)
725 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
726 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
727 (ErrVal)ETFU027, (ErrVal)0, "Packing failed");
732 if (SPkS16(spId, mBuf) != ROK) {
733 #if (ERRCLASS & ERRCLS_ADD_RES)
734 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
735 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
736 (ErrVal)ETFU028, (ErrVal)0, "Packing failed");
741 pst->event = (Event) EVTTFUSCHUBNDREQ;
742 return (SPstTsk(pst,mBuf));
746 /***********************************************************
748 * Func : cmUnpkTfuSchUbndReq
751 * Desc : This API is used to send an Unbind Request from Scheduler to PHY.
752 * @param pst Pointer to the post structure.
753 * @param suId SAP ID of the service provider.
754 * @param reason Reason for Unbind request.
755 * @return ROK/RFAILED
764 **********************************************************/
766 S16 cmUnpkTfuSchUbndReq
773 S16 cmUnpkTfuSchUbndReq(func, pst, mBuf)
783 if (SUnpkS16(&spId, mBuf) != ROK) {
785 #if (ERRCLASS & ERRCLS_ADD_RES)
786 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
787 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
788 (ErrVal)ETFU029, (ErrVal)0, "Packing failed");
792 if (SUnpkS16(&reason, mBuf) != ROK) {
794 #if (ERRCLASS & ERRCLS_ADD_RES)
795 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
796 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
797 (ErrVal)ETFU030, (ErrVal)0, "Packing failed");
802 return ((*func)(pst, spId, reason));
806 /***********************************************************
808 * Func : cmPkTfuRaReqInd
811 * Desc : This API is used to indication Random Access Request reception from
813 * @details This primitive is used by physical layer to indicate the reception
814 * of a Random Access Request from a set of UEs. The information passed consists
815 * of the RA-RNTI and the list of preambles received.
816 * @param pst Pointer to the post structure.
817 * @param suId SAP ID of the service user.
818 * @param raReqInd Pointer to the TfuRaReqIndInfo structure.
819 * @return ROK/RFAILED
828 **********************************************************/
834 TfuRaReqIndInfo * raReqInd
837 S16 cmPkTfuRaReqInd(pst, suId, raReqInd)
840 TfuRaReqIndInfo * raReqInd;
843 Buffer *mBuf = NULLP;
845 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
846 #if (ERRCLASS & ERRCLS_ADD_RES)
847 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
848 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
849 (ErrVal)ETFU031, (ErrVal)0, "Packing failed");
851 TFU_FREE_MEM(raReqInd);
854 if (pst->selector == ODU_SELECTOR_LC) {
855 if (cmPkTfuRaReqIndInfo(raReqInd, mBuf) != ROK) {
856 #if (ERRCLASS & ERRCLS_ADD_RES)
857 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
858 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
859 (ErrVal)ETFU032, (ErrVal)0, "Packing failed");
861 TFU_FREE_MEM(raReqInd);
866 else if(pst->selector == ODU_SELECTOR_LWLC)
868 if (oduPackPointer((PTR)raReqInd, mBuf) != ROK)
870 #if (ERRCLASS & ERRCLS_ADD_RES)
871 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
872 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
873 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
875 TFU_FREE_MEM(raReqInd);
881 if (SPkS16(suId, mBuf) != ROK) {
882 #if (ERRCLASS & ERRCLS_ADD_RES)
883 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
884 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
885 (ErrVal)ETFU033, (ErrVal)0, "Packing failed");
887 TFU_FREE_MEM(raReqInd);
891 if (pst->selector != ODU_SELECTOR_LWLC) {
892 TFU_FREE_MEM(raReqInd);
895 pst->event = (Event) EVTTFURAREQIND;
896 return (SPstTsk(pst,mBuf));
900 /***********************************************************
902 * Func : cmUnpkTfuRaReqInd
905 * Desc : This API is used to indication Random Access Request reception from
907 * @details This primitive is used by physical layer to indicate the reception
908 * of a Random Access Request from a set of UEs. The information passed consists
909 * of the RA-RNTI and the list of preambles received.
910 * @param pst Pointer to the post structure.
911 * @param suId SAP ID of the service user.
912 * @param raReqInd Pointer to the TfuRaReqIndInfo structure.
913 * @return ROK/RFAILED
922 **********************************************************/
924 S16 cmUnpkTfuRaReqInd
931 S16 cmUnpkTfuRaReqInd(func, pst, mBuf)
938 TfuRaReqIndInfo *raReqInd;
941 if (SUnpkS16(&suId, mBuf) != ROK) {
943 #if (ERRCLASS & ERRCLS_ADD_RES)
944 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
945 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
946 (ErrVal)ETFU034, (ErrVal)0, "Packing failed");
950 if (pst->selector != ODU_SELECTOR_LWLC) {
952 sMem.region = pst->region;
953 sMem.pool = pst->pool;
954 if ((cmAllocEvnt(sizeof(TfuRaReqIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&raReqInd)) != ROK) {
955 #if (ERRCLASS & ERRCLS_ADD_RES)
956 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
957 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
958 (ErrVal)ETFU035, (ErrVal)0, "Packing failed");
966 if (pst->selector == ODU_SELECTOR_LC)
968 if (cmUnpkTfuRaReqIndInfo(raReqInd, mBuf) != ROK) {
969 TFU_FREE_MEM(raReqInd);
971 #if (ERRCLASS & ERRCLS_ADD_RES)
972 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
973 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
974 (ErrVal)ETFU036, (ErrVal)0, "Packing failed");
979 else if(pst->selector == ODU_SELECTOR_LWLC)
981 if (oduUnpackPointer((PTR *)&raReqInd, mBuf) != ROK)
983 #if (ERRCLASS & ERRCLS_ADD_RES)
984 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
985 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
986 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
988 TFU_FREE_MEM(raReqInd);
994 return ((*func)(pst, suId, raReqInd));
998 /***********************************************************
1000 * Func : cmPkTfuRecpReq
1003 * Desc : This primitive is sent from Scheduler to PHY.
1004 * @details This primitive provides PHY with all the information required by
1005 * PHY to decode transmissions from the UE on either PUCCH or PUSCH.
1006 * -# On PUCCH UE can transmit the following
1012 * -# On PUSCH UE can transmit the following
1015 * -# Data + HARQ Feedback
1016 * This primitive carries all the information for the expected subframe for all
1017 * the UEs that have been scheduled to transmit.
1018 * @param pst Pointer to the post structure.
1019 * @param spId SAP ID of the service provider.
1020 * @param recpReq Pointer to the TfuRecpReqInfo structure.
1021 * @return ROK/RFAILED
1030 **********************************************************/
1036 TfuRecpReqInfo * recpReq
1039 S16 cmPkTfuRecpReq(pst, spId, recpReq)
1042 TfuRecpReqInfo * recpReq;
1045 Buffer *mBuf = NULLP;
1047 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
1048 #if (ERRCLASS & ERRCLS_ADD_RES)
1049 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1050 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1051 (ErrVal)ETFU037, (ErrVal)0, "Packing failed");
1053 TFU_FREE_MEM(recpReq);
1056 if (pst->selector == ODU_SELECTOR_LC) {
1057 if (cmPkTfuRecpReqInfo(recpReq, mBuf) != ROK) {
1058 #if (ERRCLASS & ERRCLS_ADD_RES)
1059 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1060 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1061 (ErrVal)ETFU038, (ErrVal)0, "Packing failed");
1063 TFU_FREE_MEM(recpReq);
1068 else if(pst->selector == ODU_SELECTOR_LWLC)
1070 if (oduPackPointer((PTR)recpReq, mBuf) != ROK)
1072 #if (ERRCLASS & ERRCLS_ADD_RES)
1073 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1074 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1075 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
1077 TFU_FREE_MEM(recpReq);
1084 if (SPkS16(spId, mBuf) != ROK) {
1085 #if (ERRCLASS & ERRCLS_ADD_RES)
1086 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1087 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1088 (ErrVal)ETFU039, (ErrVal)0, "Packing failed");
1090 TFU_FREE_MEM(recpReq);
1094 if (pst->selector != ODU_SELECTOR_LWLC) {
1095 TFU_FREE_MEM(recpReq);
1098 pst->event = (Event) EVTTFURECPREQ;
1099 return (SPstTsk(pst,mBuf));
1103 /***********************************************************
1105 * Func : cmUnpkTfuRecpReq
1108 * Desc : This primitive is sent from Scheduler to PHY.
1109 * @details This primitive provides PHY with all the information required by
1110 * PHY to decode transmissions from the UE on either PUCCH or PUSCH.
1111 * -# On PUCCH UE can transmit the following
1117 * -# On PUSCH UE can transmit the following
1120 * -# Data + HARQ Feedback
1121 * This primitive carries all the information for the expected subframe for all
1122 * the UEs that have been scheduled to transmit.
1123 * @param pst Pointer to the post structure.
1124 * @param spId SAP ID of the service provider.
1125 * @param recpReq Pointer to the TfuRecpReqInfo structure.
1126 * @return ROK/RFAILED
1135 **********************************************************/
1137 S16 cmUnpkTfuRecpReq
1144 S16 cmUnpkTfuRecpReq(func, pst, mBuf)
1151 TfuRecpReqInfo *recpReq;
1154 if (SUnpkS16(&spId, mBuf) != ROK) {
1156 #if (ERRCLASS & ERRCLS_ADD_RES)
1157 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1158 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1159 (ErrVal)ETFU040, (ErrVal)0, "Packing failed");
1163 if (pst->selector != ODU_SELECTOR_LWLC) {
1165 sMem.region = pst->region;
1166 sMem.pool = pst->pool;
1167 if ((cmAllocEvnt(sizeof(TfuRecpReqInfo), TFU_BLKSZ, &sMem, (Ptr *)&recpReq)) != ROK) {
1168 #if (ERRCLASS & ERRCLS_ADD_RES)
1169 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1170 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1171 (ErrVal)ETFU041, (ErrVal)0, "Packing failed");
1177 else if(pst->selector == ODU_SELECTOR_LWLC)
1179 if (oduUnpackPointer((PTR *)&recpReq, mBuf) != ROK)
1181 #if (ERRCLASS & ERRCLS_ADD_RES)
1182 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1183 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1184 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1186 TFU_FREE_MEM(recpReq);
1192 if (pst->selector == ODU_SELECTOR_LC)
1194 if (cmUnpkTfuRecpReqInfo(recpReq, (Ptr)&recpReq->memCp, mBuf) != ROK) {
1195 TFU_FREE_MEM(recpReq);
1197 #if (ERRCLASS & ERRCLS_ADD_RES)
1198 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1199 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1200 (ErrVal)ETFU042, (ErrVal)0, "Packing failed");
1205 else if(pst->selector == ODU_SELECTOR_LWLC)
1207 if (oduUnpackPointer((PTR*)&recpReq, mBuf) != ROK)
1209 #if (ERRCLASS & ERRCLS_ADD_RES)
1210 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1211 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1212 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1214 TFU_FREE_MEM(recpReq);
1221 return ((*func)(pst, spId, recpReq));
1225 /***********************************************************
1227 * Func : cmPkTfuUlCqiInd
1230 * Desc : This API is used to indicate CQI reporting from PHY to Scheduler
1231 * @details This primitive carries an estimate of the uplink Channel quality
1232 * index (CQI) for a list of UEs. This is an extimate of the uplink channel
1233 * quality i.e. the transmission from UE as calculated at the Physical layer at
1235 * It carries a list of subband CQIs for each UE.
1236 * @param pst Pointer to the post structure.
1237 * @param suId SAP ID of the service user.
1238 * @param ulCqiInd Pointer to the TfuUlCqiIndInfo structure.
1239 * @return ROK/RFAILED
1248 **********************************************************/
1254 TfuUlCqiIndInfo * ulCqiInd
1257 S16 cmPkTfuUlCqiInd(pst, suId, ulCqiInd)
1260 TfuUlCqiIndInfo * ulCqiInd;
1263 Buffer *mBuf = NULLP;
1265 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
1266 #if (ERRCLASS & ERRCLS_ADD_RES)
1267 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1268 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1269 (ErrVal)ETFU043, (ErrVal)0, "Packing failed");
1271 TFU_FREE_MEM(ulCqiInd);
1274 if (pst->selector == ODU_SELECTOR_LC) {
1275 if (cmPkTfuUlCqiIndInfo(ulCqiInd, mBuf) != ROK) {
1276 #if (ERRCLASS & ERRCLS_ADD_RES)
1277 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1278 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1279 (ErrVal)ETFU044, (ErrVal)0, "Packing failed");
1281 TFU_FREE_MEM(ulCqiInd);
1286 else if(pst->selector == ODU_SELECTOR_LWLC)
1288 if (oduPackPointer((PTR)ulCqiInd, mBuf) != ROK)
1290 #if (ERRCLASS & ERRCLS_ADD_RES)
1291 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1292 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1293 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
1295 TFU_FREE_MEM(ulCqiInd);
1301 if (SPkS16(suId, mBuf) != ROK) {
1302 #if (ERRCLASS & ERRCLS_ADD_RES)
1303 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1304 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1305 (ErrVal)ETFU045, (ErrVal)0, "Packing failed");
1307 TFU_FREE_MEM(ulCqiInd);
1311 if (pst->selector != ODU_SELECTOR_LWLC) {
1312 TFU_FREE_MEM(ulCqiInd);
1315 pst->event = (Event) EVTTFUULCQIIND;
1316 return (SPstTsk(pst,mBuf));
1320 /***********************************************************
1322 * Func : cmUnpkTfuUlCqiInd
1325 * Desc : This API is used to indicate CQI reporting from PHY to Scheduler
1326 * @details This primitive carries an estimate of the uplink Channel quality
1327 * index (CQI) for a list of UEs. This is an extimate of the uplink channel
1328 * quality i.e. the transmission from UE as calculated at the Physical layer at
1330 * It carries a list of subband CQIs for each UE.
1331 * @param pst Pointer to the post structure.
1332 * @param suId SAP ID of the service user.
1333 * @param ulCqiInd Pointer to the TfuUlCqiIndInfo structure.
1334 * @return ROK/RFAILED
1343 **********************************************************/
1345 S16 cmUnpkTfuUlCqiInd
1352 S16 cmUnpkTfuUlCqiInd(func, pst, mBuf)
1359 TfuUlCqiIndInfo *ulCqiInd;
1362 if (SUnpkS16(&suId, mBuf) != ROK) {
1364 #if (ERRCLASS & ERRCLS_ADD_RES)
1365 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1366 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1367 (ErrVal)ETFU046, (ErrVal)0, "Packing failed");
1371 if (pst->selector != ODU_SELECTOR_LWLC) {
1373 sMem.region = pst->region;
1374 sMem.pool = pst->pool;
1375 if ((cmAllocEvnt(sizeof(TfuUlCqiIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&ulCqiInd)) != ROK) {
1376 #if (ERRCLASS & ERRCLS_ADD_RES)
1377 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1378 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1379 (ErrVal)ETFU047, (ErrVal)0, "Packing failed");
1387 if (pst->selector == ODU_SELECTOR_LC)
1389 if (cmUnpkTfuUlCqiIndInfo(ulCqiInd, (Ptr)&ulCqiInd->memCp, mBuf) != ROK) {
1390 TFU_FREE_MEM(ulCqiInd);
1392 #if (ERRCLASS & ERRCLS_ADD_RES)
1393 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1394 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1395 (ErrVal)ETFU048, (ErrVal)0, "Packing failed");
1400 else if(pst->selector == ODU_SELECTOR_LWLC)
1402 if (oduUnpackPointer((PTR *)&ulCqiInd, mBuf) != ROK)
1404 #if (ERRCLASS & ERRCLS_ADD_RES)
1405 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1406 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1407 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1409 TFU_FREE_MEM(ulCqiInd);
1415 return ((*func)(pst, suId, ulCqiInd));
1419 /***********************************************************
1421 * Func : cmPkTfuHqInd
1424 * Desc : This Primitive carries the HARQ Feedback from PHY to scheduler
1425 * @details HARQ feedback is sent by the UE to the eNodeB, an ACK is sent if UE
1426 * could successfully recieve the data transmitted by the eNodeB, else a NACK is
1427 * sent. This feedback is utilized by MAC for further scheduling, for instance
1428 * it could schedule an adaptive retransmission of the same data.
1431 * @param tfuHqInd pointer to TfuHqIndInfo
1441 **********************************************************/
1447 TfuHqIndInfo * hqInd
1450 S16 cmPkTfuHqInd(pst, spId, hqInd)
1453 TfuHqIndInfo * hqInd;
1456 Buffer *mBuf = NULLP;
1458 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
1459 #if (ERRCLASS & ERRCLS_ADD_RES)
1460 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1461 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1462 (ErrVal)ETFU049, (ErrVal)0, "Packing failed");
1464 TFU_FREE_MEM(hqInd);
1467 if (pst->selector == ODU_SELECTOR_LC) {
1468 if (cmPkTfuHqIndInfo(hqInd, mBuf) != ROK) {
1469 #if (ERRCLASS & ERRCLS_ADD_RES)
1470 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1471 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1472 (ErrVal)ETFU050, (ErrVal)0, "Packing failed");
1474 TFU_FREE_MEM(hqInd);
1479 else if(pst->selector == ODU_SELECTOR_LWLC)
1481 if (oduPackPointer((PTR)hqInd, mBuf) != ROK)
1483 #if (ERRCLASS & ERRCLS_ADD_RES)
1484 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1485 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1486 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
1488 TFU_FREE_MEM(hqInd);
1494 if (SPkS16(spId, mBuf) != ROK) {
1495 #if (ERRCLASS & ERRCLS_ADD_RES)
1496 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1497 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1498 (ErrVal)ETFU051, (ErrVal)0, "Packing failed");
1500 TFU_FREE_MEM(hqInd);
1504 if (pst->selector != ODU_SELECTOR_LWLC) {
1505 TFU_FREE_MEM(hqInd);
1508 pst->event = (Event) EVTTFUHQIND;
1509 return (SPstTsk(pst,mBuf));
1513 /***********************************************************
1515 * Func : cmUnpkTfuHqInd
1518 * Desc : This Primitive carries the HARQ Feedback from PHY to scheduler
1519 * @details HARQ feedback is sent by the UE to the eNodeB, an ACK is sent if UE
1520 * could successfully recieve the data transmitted by the eNodeB, else a NACK is
1521 * sent. This feedback is utilized by MAC for further scheduling, for instance
1522 * it could schedule an adaptive retransmission of the same data.
1525 * @param tfuHqInd pointer to TfuHqIndInfo
1535 **********************************************************/
1544 S16 cmUnpkTfuHqInd(func, pst, mBuf)
1551 TfuHqIndInfo *hqInd;
1554 if (SUnpkS16(&spId, mBuf) != ROK) {
1556 #if (ERRCLASS & ERRCLS_ADD_RES)
1557 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1558 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1559 (ErrVal)ETFU052, (ErrVal)0, "Packing failed");
1563 if (pst->selector != ODU_SELECTOR_LWLC) {
1565 sMem.region = pst->region;
1566 sMem.pool = pst->pool;
1567 if ((cmAllocEvnt(sizeof(TfuHqIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&hqInd)) != ROK) {
1568 #if (ERRCLASS & ERRCLS_ADD_RES)
1569 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1570 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1571 (ErrVal)ETFU053, (ErrVal)0, "Packing failed");
1579 if (pst->selector == ODU_SELECTOR_LC)
1581 if (cmUnpkTfuHqIndInfo(hqInd, (Ptr)&hqInd->memCp, mBuf) != ROK) {
1582 TFU_FREE_MEM(hqInd);
1584 #if (ERRCLASS & ERRCLS_ADD_RES)
1585 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1586 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1587 (ErrVal)ETFU054, (ErrVal)0, "Packing failed");
1592 else if(pst->selector == ODU_SELECTOR_LWLC)
1594 if (oduUnpackPointer((PTR *)&hqInd, mBuf) != ROK)
1596 #if (ERRCLASS & ERRCLS_ADD_RES)
1597 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1598 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1599 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1601 TFU_FREE_MEM(hqInd);
1607 return ((*func)(pst, spId, hqInd));
1611 /***********************************************************
1613 * Func : cmPkTfuSrInd
1616 * Desc : This Primitive carries the SR Indication from PHY to scheduler.
1617 * @details Scheduling Request (SR) is sent by the UE to the eNodeB to request
1618 * for Uplink (UL) grant. This primitive carries a list of SRs for a number of
1619 * UEs received in the indicated subframe.
1622 * @param tfqSrInd pointer to TfuSrIndInfo
1632 **********************************************************/
1638 TfuSrIndInfo * srInd
1641 S16 cmPkTfuSrInd(pst, spId, srInd)
1644 TfuSrIndInfo * srInd;
1647 Buffer *mBuf = NULLP;
1649 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
1650 #if (ERRCLASS & ERRCLS_ADD_RES)
1651 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1652 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1653 (ErrVal)ETFU055, (ErrVal)0, "Packing failed");
1655 TFU_FREE_MEM(srInd);
1658 if (pst->selector == ODU_SELECTOR_LC) {
1659 if (cmPkTfuSrIndInfo(srInd, mBuf) != ROK) {
1660 #if (ERRCLASS & ERRCLS_ADD_RES)
1661 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1662 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1663 (ErrVal)ETFU056, (ErrVal)0, "Packing failed");
1665 TFU_FREE_MEM(srInd);
1670 else if(pst->selector == ODU_SELECTOR_LWLC)
1672 if (oduPackPointer((PTR)srInd, mBuf) != ROK)
1674 #if (ERRCLASS & ERRCLS_ADD_RES)
1675 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1676 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1677 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
1679 TFU_FREE_MEM(srInd);
1685 if (SPkS16(spId, mBuf) != ROK) {
1686 #if (ERRCLASS & ERRCLS_ADD_RES)
1687 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1688 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1689 (ErrVal)ETFU057, (ErrVal)0, "Packing failed");
1691 TFU_FREE_MEM(srInd);
1695 if (pst->selector != ODU_SELECTOR_LWLC) {
1696 TFU_FREE_MEM(srInd);
1699 pst->event = (Event) EVTTFUSRIND;
1700 return (SPstTsk(pst,mBuf));
1704 /***********************************************************
1706 * Func : cmUnpkTfuSrInd
1709 * Desc : This Primitive carries the SR Indication from PHY to scheduler.
1710 * @details Scheduling Request (SR) is sent by the UE to the eNodeB to request
1711 * for Uplink (UL) grant. This primitive carries a list of SRs for a number of
1712 * UEs received in the indicated subframe.
1715 * @param tfqSrInd pointer to TfuSrIndInfo
1725 **********************************************************/
1734 S16 cmUnpkTfuSrInd(func, pst, mBuf)
1741 TfuSrIndInfo *srInd;
1744 if (SUnpkS16(&spId, mBuf) != ROK) {
1746 #if (ERRCLASS & ERRCLS_ADD_RES)
1747 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1748 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1749 (ErrVal)ETFU058, (ErrVal)0, "Packing failed");
1753 if (pst->selector != ODU_SELECTOR_LWLC) {
1755 sMem.region = pst->region;
1756 sMem.pool = pst->pool;
1757 if ((cmAllocEvnt(sizeof(TfuSrIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&srInd)) != ROK) {
1758 #if (ERRCLASS & ERRCLS_ADD_RES)
1759 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1760 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1761 (ErrVal)ETFU059, (ErrVal)0, "Packing failed");
1769 if (pst->selector == ODU_SELECTOR_LC)
1771 if (cmUnpkTfuSrIndInfo(srInd, (Ptr)&srInd->memCp, mBuf) != ROK) {
1772 TFU_FREE_MEM(srInd);
1774 #if (ERRCLASS & ERRCLS_ADD_RES)
1775 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1776 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1777 (ErrVal)ETFU060, (ErrVal)0, "Packing failed");
1782 else if(pst->selector == ODU_SELECTOR_LWLC)
1784 if (oduUnpackPointer((PTR *)&srInd, mBuf) != ROK)
1786 #if (ERRCLASS & ERRCLS_ADD_RES)
1787 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1788 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1789 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1791 TFU_FREE_MEM(srInd);
1797 return ((*func)(pst, spId, srInd));
1801 /***********************************************************
1803 * Func : cmPkTfuDlCqiInd
1806 * Desc : This API is used to indicate the reception of CQI report from PHY to
1807 * Scheduler, also carries the RI.
1808 * @param pst Pointer to the post structure.
1809 * @param suId SAP ID of the service user.
1810 * @param dlCqiInd Pointer to the TfuDlCqiIndInfo structure.
1811 * @return ROK/RFAILED
1820 **********************************************************/
1826 TfuDlCqiIndInfo * dlCqiInd
1829 S16 cmPkTfuDlCqiInd(pst, suId, dlCqiInd)
1832 TfuDlCqiIndInfo * dlCqiInd;
1835 Buffer *mBuf = NULLP;
1837 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
1838 #if (ERRCLASS & ERRCLS_ADD_RES)
1839 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1840 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1841 (ErrVal)ETFU061, (ErrVal)0, "Packing failed");
1843 TFU_FREE_MEM(dlCqiInd);
1846 if (pst->selector == ODU_SELECTOR_LC) {
1847 if (cmPkTfuDlCqiIndInfo(dlCqiInd, mBuf) != ROK) {
1848 #if (ERRCLASS & ERRCLS_ADD_RES)
1849 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1850 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1851 (ErrVal)ETFU062, (ErrVal)0, "Packing failed");
1853 TFU_FREE_MEM(dlCqiInd);
1858 else if(pst->selector == ODU_SELECTOR_LWLC)
1860 if (oduPackPointer((PTR)dlCqiInd, mBuf) != ROK)
1862 #if (ERRCLASS & ERRCLS_ADD_RES)
1863 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1864 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1865 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
1867 TFU_FREE_MEM(dlCqiInd);
1873 if (SPkS16(suId, mBuf) != ROK) {
1874 #if (ERRCLASS & ERRCLS_ADD_RES)
1875 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1876 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1877 (ErrVal)ETFU063, (ErrVal)0, "Packing failed");
1879 TFU_FREE_MEM(dlCqiInd);
1883 if (pst->selector != ODU_SELECTOR_LWLC) {
1884 TFU_FREE_MEM(dlCqiInd);
1886 pst->event = (Event) EVTTFUDLCQIIND;
1887 return (SPstTsk(pst,mBuf));
1891 /***********************************************************
1893 * Func : cmUnpkTfuDlCqiInd
1896 * Desc : This API is used to indicate the reception of CQI report from PHY to
1897 * Scheduler, also carries the RI.
1898 * @param pst Pointer to the post structure.
1899 * @param suId SAP ID of the service user.
1900 * @param dlCqiInd Pointer to the TfuDlCqiIndInfo structure.
1901 * @return ROK/RFAILED
1910 **********************************************************/
1912 S16 cmUnpkTfuDlCqiInd
1919 S16 cmUnpkTfuDlCqiInd(func, pst, mBuf)
1926 TfuDlCqiIndInfo *dlCqiInd;
1929 if (SUnpkS16(&suId, mBuf) != ROK) {
1931 #if (ERRCLASS & ERRCLS_ADD_RES)
1932 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1933 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1934 (ErrVal)ETFU064, (ErrVal)0, "Packing failed");
1938 if (pst->selector != ODU_SELECTOR_LWLC) {
1940 sMem.region = pst->region;
1941 sMem.pool = pst->pool;
1942 if ((cmAllocEvnt(sizeof(TfuDlCqiIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&dlCqiInd)) != ROK) {
1943 #if (ERRCLASS & ERRCLS_ADD_RES)
1944 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1945 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1946 (ErrVal)ETFU065, (ErrVal)0, "Packing failed");
1954 if (pst->selector == ODU_SELECTOR_LC)
1956 if (cmUnpkTfuDlCqiIndInfo(dlCqiInd, (Ptr)&dlCqiInd->memCp, mBuf) != ROK) {
1957 TFU_FREE_MEM(dlCqiInd);
1959 #if (ERRCLASS & ERRCLS_ADD_RES)
1960 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1961 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1962 (ErrVal)ETFU066, (ErrVal)0, "Packing failed");
1967 else if(pst->selector == ODU_SELECTOR_LWLC)
1969 if (oduUnpackPointer((PTR *)&dlCqiInd, mBuf) != ROK)
1971 #if (ERRCLASS & ERRCLS_ADD_RES)
1972 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
1973 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
1974 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
1976 TFU_FREE_MEM(dlCqiInd);
1982 return ((*func)(pst, suId, dlCqiInd));
1989 /***********************************************************
1991 * Func : cmPkTfuRawCqiInd
1994 * Desc : This Primitive is used to convey the Raw CQI information
1995 * transmitted by the UE.
1996 * @details Raw CQI report is the actual bits transmitted by the UE when
1997 * reporting CQI/PMI/RI. The interpretation of these bits to CQI/subband CQI
1998 * etc. shall be done by MAC.
2000 * @param pst Pointer to the post structure.
2001 * @param suId SAP ID of the service user.
2002 * @param cqiInd Pointer to the TfuRawCqiIndInfo structure.
2003 * @return ROK/RFAILED
2012 **********************************************************/
2014 S16 cmPkTfuRawCqiInd
2018 TfuRawCqiIndInfo * rawCqiInd
2021 S16 cmPkTfuRawCqiInd(pst, suId, rawCqiInd)
2024 TfuRawCqiIndInfo * rawCqiInd;
2027 Buffer *mBuf = NULLP;
2029 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2030 #if (ERRCLASS & ERRCLS_ADD_RES)
2031 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2032 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2033 (ErrVal)ETFU067, (ErrVal)0, "Packing failed");
2035 TFU_FREE_MEM(rawCqiInd);
2038 cmPkTfuRawCqiIndInfo(rawCqiInd, mBuf);
2039 if (SPkS16(suId, mBuf) != ROK) {
2040 #if (ERRCLASS & ERRCLS_ADD_RES)
2041 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2042 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2043 (ErrVal)ETFU068, (ErrVal)0, "Packing failed");
2045 TFU_FREE_MEM(rawCqiInd);
2049 TFU_FREE_MEM(rawCqiInd);
2050 pst->event = (Event) EVTTFURAWCQIIND;
2051 return (SPstTsk(pst,mBuf));
2055 /***********************************************************
2057 * Func : cmUnpkTfuRawCqiInd
2060 * Desc : This Primitive is used to convey the Raw CQI information
2061 * transmitted by the UE.
2062 * @details Raw CQI report is the actual bits transmitted by the UE when
2063 * reporting CQI/PMI/RI. The interpretation of these bits to CQI/subband CQI
2064 * etc. shall be done by MAC.
2066 * @param pst Pointer to the post structure.
2067 * @param suId SAP ID of the service user.
2068 * @param cqiInd Pointer to the TfuRawCqiIndInfo structure.
2069 * @return ROK/RFAILED
2078 **********************************************************/
2080 S16 cmUnpkTfuRawCqiInd
2087 S16 cmUnpkTfuRawCqiInd(func, pst, mBuf)
2094 TfuRawCqiIndInfo *rawCqiInd;
2097 if (SUnpkS16(&suId, mBuf) != ROK) {
2099 #if (ERRCLASS & ERRCLS_ADD_RES)
2100 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2101 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2102 (ErrVal)ETFU069, (ErrVal)0, "Packing failed");
2108 sMem.region = pst->region;
2109 sMem.pool = pst->pool;
2110 if ((cmAllocEvnt(sizeof(TfuRawCqiIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&rawCqiInd)) != ROK) {
2111 #if (ERRCLASS & ERRCLS_ADD_RES)
2112 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2113 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2114 (ErrVal)ETFU070, (ErrVal)0, "Packing failed");
2120 cmUnpkTfuRawCqiIndInfo(rawCqiInd, (Ptr)&rawCqiInd->memCp, mBuf);
2122 return ((*func)(pst, suId, rawCqiInd));
2126 /***********************************************************
2128 * Func : cmPkTfuSrsInd
2131 * Desc : This Primitive is used to convey the information derived by the
2132 * physical layer from the SRS transmission from the UE.
2133 * @details This primitive carries information derived from the SRS transmission
2136 * @param pst Pointer to the post structure.
2137 * @param suId SAP ID of the service user.
2138 * @param srsInd Pointer to the TfuSrIndInfo structure.
2139 * @return ROK/RFAILED
2148 **********************************************************/
2154 TfuSrsIndInfo * srsInd
2157 S16 cmPkTfuSrsInd(pst, suId, srsInd)
2160 TfuSrsIndInfo * srsInd;
2163 Buffer *mBuf = NULLP;
2165 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2166 #if (ERRCLASS & ERRCLS_ADD_RES)
2167 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2168 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2169 (ErrVal)ETFU071, (ErrVal)0, "Packing failed");
2171 TFU_FREE_MEM(srsInd);
2174 cmPkTfuSrsIndInfo(srsInd, mBuf);
2175 if (SPkS16(suId, mBuf) != ROK) {
2176 #if (ERRCLASS & ERRCLS_ADD_RES)
2177 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2178 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2179 (ErrVal)ETFU072, (ErrVal)0, "Packing failed");
2181 TFU_FREE_MEM(srsInd);
2185 TFU_FREE_MEM(srsInd);
2186 pst->event = (Event) EVTTFUSRSIND;
2187 return (SPstTsk(pst,mBuf));
2191 /***********************************************************
2193 * Func : cmUnpkTfuSrsInd
2196 * Desc : This Primitive is used to convey the information derived by the
2197 * physical layer from the SRS transmission from the UE.
2198 * @details This primitive carries information derived from the SRS transmission
2201 * @param pst Pointer to the post structure.
2202 * @param suId SAP ID of the service user.
2203 * @param srsInd Pointer to the TfuSrIndInfo structure.
2204 * @return ROK/RFAILED
2213 **********************************************************/
2222 S16 cmUnpkTfuSrsInd(func, pst, mBuf)
2229 TfuSrsIndInfo *srsInd;
2232 if (SUnpkS16(&suId, mBuf) != ROK) {
2234 #if (ERRCLASS & ERRCLS_ADD_RES)
2235 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2236 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2237 (ErrVal)ETFU073, (ErrVal)0, "Packing failed");
2243 sMem.region = pst->region;
2244 sMem.pool = pst->pool;
2245 if ((cmAllocEvnt(sizeof(TfuSrsIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&srsInd)) != ROK) {
2246 #if (ERRCLASS & ERRCLS_ADD_RES)
2247 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2248 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2249 (ErrVal)ETFU074, (ErrVal)0, "Packing failed");
2255 cmUnpkTfuSrsIndInfo(srsInd, (Ptr)&srsInd->memCp, mBuf);
2257 return ((*func)(pst, suId, srsInd));
2263 /***********************************************************
2265 * Func : cmPkTfuDatInd
2268 * Desc : This Primitive carries the Data PDUs from PHY to MAC.
2269 * @details The uplink Data i.e. the data transmitted by the UEs received by the
2270 * physical layer at the eNodeB in the subframe (indicated by the timingInfo),
2271 * is relayed to MAC using this primitive.
2274 * @param tfuDatInd pointer to TfuDatIndInfo
2284 **********************************************************/
2290 TfuDatIndInfo * datInd
2293 S16 cmPkTfuDatInd(pst, spId, datInd)
2296 TfuDatIndInfo * datInd;
2299 Buffer *mBuf = NULLP;
2301 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2302 #if (ERRCLASS & ERRCLS_ADD_RES)
2303 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2304 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2305 (ErrVal)ETFU075, (ErrVal)0, "Packing failed");
2307 TFU_FREE_MEM(datInd);
2310 if (pst->selector == ODU_SELECTOR_LC) {
2311 if (cmPkTfuDatIndInfo(datInd, mBuf) != ROK) {
2312 #if (ERRCLASS & ERRCLS_ADD_RES)
2313 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2314 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2315 (ErrVal)ETFU076, (ErrVal)0, "Packing failed");
2317 TFU_FREE_MEM(datInd);
2322 else if(pst->selector == ODU_SELECTOR_LWLC)
2324 if(oduPackPointer((PTR)datInd, mBuf) != ROK)
2326 #if (ERRCLASS & ERRCLS_ADD_RES)
2327 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2328 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2329 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
2331 TFU_FREE_MEM(datInd);
2337 if (SPkS16(spId, mBuf) != ROK) {
2338 #if (ERRCLASS & ERRCLS_ADD_RES)
2339 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2340 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2341 (ErrVal)ETFU077, (ErrVal)0, "Packing failed");
2343 TFU_FREE_MEM(datInd);
2347 if (pst->selector != ODU_SELECTOR_LWLC) {
2348 TFU_FREE_MEM(datInd);
2351 pst->event = (Event) EVTTFUDATIND;
2352 return (SPstTsk(pst,mBuf));
2356 /***********************************************************
2358 * Func : cmUnpkTfuDatInd
2361 * Desc : This Primitive carries the Data PDUs from PHY to MAC.
2362 * @details The uplink Data i.e. the data transmitted by the UEs received by the
2363 * physical layer at the eNodeB in the subframe (indicated by the timingInfo),
2364 * is relayed to MAC using this primitive.
2367 * @param tfuDatInd pointer to TfuDatIndInfo
2377 **********************************************************/
2386 S16 cmUnpkTfuDatInd(func, pst, mBuf)
2393 TfuDatIndInfo *datInd;
2396 if (SUnpkS16(&spId, mBuf) != ROK) {
2398 #if (ERRCLASS & ERRCLS_ADD_RES)
2399 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2400 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2401 (ErrVal)ETFU078, (ErrVal)0, "Packing failed");
2405 if (pst->selector != ODU_SELECTOR_LWLC) {
2407 sMem.region = pst->region;
2408 sMem.pool = pst->pool;
2409 if ((cmAllocEvnt(sizeof(TfuDatIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&datInd)) != ROK) {
2410 #if (ERRCLASS & ERRCLS_ADD_RES)
2411 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2412 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2413 (ErrVal)ETFU079, (ErrVal)0, "Packing failed");
2421 if (pst->selector == ODU_SELECTOR_LC)
2423 if (cmUnpkTfuDatIndInfo(datInd, (Ptr)&datInd->memCp, mBuf) != ROK) {
2424 TFU_FREE_MEM(datInd);
2426 #if (ERRCLASS & ERRCLS_ADD_RES)
2427 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2428 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2429 (ErrVal)ETFU080, (ErrVal)0, "Packing failed");
2434 else if(pst->selector == ODU_SELECTOR_LWLC)
2436 if(oduUnpackPointer((PTR *)&datInd, mBuf) != ROK)
2438 #if (ERRCLASS & ERRCLS_ADD_RES)
2439 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2440 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2441 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
2443 TFU_FREE_MEM(datInd);
2449 return ((*func)(pst, spId, datInd));
2453 /***********************************************************
2455 * Func : cmPkTfuCrcInd
2458 * Desc : This API is used by the Physical layer to indicate if the CRC Check
2459 * on the PUSCH Data was successful or not.
2460 * @details This primitive carries CRC indication for a list of UEs. This
2461 * is utilized in the scenario where MAC requested the reception of uplink data
2462 * for a particular UE. On reception of the PUSCH data, the CRC check on it
2463 * failed. This CRC failure is indicated to MAC, which would utillize this
2464 * information for further scheduling.
2465 * Physical layer would indicate failure or success for each PUSCH transmission.
2466 * @param pst Pointer to the post structure.
2467 * @param suId SAP ID of the service user.
2468 * @param crcInd Pointer to the TfuCrcIndInfo.
2469 * @return ROK/RFAILED
2478 **********************************************************/
2484 TfuCrcIndInfo * crcIndInfo
2487 S16 cmPkTfuCrcInd(pst, suId, crcIndInfo)
2490 TfuCrcIndInfo * crcIndInfo;
2493 Buffer *mBuf = NULLP;
2495 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2496 #if (ERRCLASS & ERRCLS_ADD_RES)
2497 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2498 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2499 (ErrVal)ETFU081, (ErrVal)0, "Packing failed");
2501 TFU_FREE_MEM(crcIndInfo);
2504 if (pst->selector == ODU_SELECTOR_LC) {
2505 if (cmPkTfuCrcIndInfo(crcIndInfo, mBuf) != ROK) {
2506 #if (ERRCLASS & ERRCLS_ADD_RES)
2507 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2508 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2509 (ErrVal)ETFU082, (ErrVal)0, "Packing failed");
2511 TFU_FREE_MEM(crcIndInfo);
2516 else if(pst->selector == ODU_SELECTOR_LWLC)
2518 if (oduPackPointer((PTR)crcIndInfo, mBuf) != ROK)
2520 #if (ERRCLASS & ERRCLS_ADD_RES)
2521 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2522 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2523 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
2525 TFU_FREE_MEM(crcIndInfo);
2532 if (SPkS16(suId, mBuf) != ROK) {
2533 #if (ERRCLASS & ERRCLS_ADD_RES)
2534 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2535 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2536 (ErrVal)ETFU083, (ErrVal)0, "Packing failed");
2538 TFU_FREE_MEM(crcIndInfo);
2542 if (pst->selector != ODU_SELECTOR_LWLC) {
2543 TFU_FREE_MEM(crcIndInfo);
2546 pst->event = (Event) EVTTFUCRCIND;
2547 return (SPstTsk(pst,mBuf));
2551 /***********************************************************
2553 * Func : cmUnpkTfuCrcInd
2556 * Desc : This API is used by the Physical layer to indicate if the CRC Check
2557 * on the PUSCH Data was successful or not.
2558 * @details This primitive carries CRC indication for a list of UEs. This
2559 * is utilized in the scenario where MAC requested the reception of uplink data
2560 * for a particular UE. On reception of the PUSCH data, the CRC check on it
2561 * failed. This CRC failure is indicated to MAC, which would utillize this
2562 * information for further scheduling.
2563 * Physical layer would indicate failure or success for each PUSCH transmission.
2564 * @param pst Pointer to the post structure.
2565 * @param suId SAP ID of the service user.
2566 * @param crcInd Pointer to the TfuCrcIndInfo.
2567 * @return ROK/RFAILED
2576 **********************************************************/
2585 S16 cmUnpkTfuCrcInd(func, pst, mBuf)
2592 TfuCrcIndInfo *crcIndInfo;
2595 if (SUnpkS16(&suId, mBuf) != ROK) {
2597 #if (ERRCLASS & ERRCLS_ADD_RES)
2598 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2599 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2600 (ErrVal)ETFU084, (ErrVal)0, "Packing failed");
2604 if (pst->selector != ODU_SELECTOR_LWLC) {
2606 sMem.region = pst->region;
2607 sMem.pool = pst->pool;
2608 if ((cmAllocEvnt(sizeof(TfuCrcIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&crcIndInfo)) != ROK) {
2609 #if (ERRCLASS & ERRCLS_ADD_RES)
2610 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2611 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2612 (ErrVal)ETFU085, (ErrVal)0, "Packing failed");
2620 if (pst->selector == ODU_SELECTOR_LC)
2622 if (cmUnpkTfuCrcIndInfo(crcIndInfo, (Ptr)&crcIndInfo->memCp, mBuf) != ROK) {
2623 TFU_FREE_MEM(crcIndInfo);
2625 #if (ERRCLASS & ERRCLS_ADD_RES)
2626 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2627 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2628 (ErrVal)ETFU086, (ErrVal)0, "Packing failed");
2633 else if(pst->selector == ODU_SELECTOR_LWLC)
2635 if (oduUnpackPointer((PTR *)&crcIndInfo, mBuf) != ROK)
2637 #if (ERRCLASS & ERRCLS_ADD_RES)
2638 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2639 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2640 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
2642 TFU_FREE_MEM(crcIndInfo);
2648 return ((*func)(pst, suId, crcIndInfo));
2652 /***********************************************************
2654 * Func : cmPkTfuTimingAdvInd
2657 * Desc : This API is used to indicate a Timing Advance from PHY to Scheduler .
2658 * @details This primitive carries timing advance information for a number of
2659 * UEs that may need timing advance. Timing advance information is an estimate
2660 * of the timing adjustment that a UE would need to apply in order to be
2661 * synchronized in uplink. This estimate is to be calculated by physical layer.
2662 * @param pst Pointer to the post structure.
2663 * @param suId SAP ID of the service user.
2664 * @param timingAdvInd Pointer to the TfuTimingAdvIndInfo structure.
2665 * @return ROK/RFAILED
2674 **********************************************************/
2676 S16 cmPkTfuTimingAdvInd
2680 TfuTimingAdvIndInfo * timingAdvInd
2683 S16 cmPkTfuTimingAdvInd(pst, suId, timingAdvInd)
2686 TfuTimingAdvIndInfo * timingAdvInd;
2689 Buffer *mBuf = NULLP;
2691 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2692 #if (ERRCLASS & ERRCLS_ADD_RES)
2693 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2694 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2695 (ErrVal)ETFU087, (ErrVal)0, "Packing failed");
2697 TFU_FREE_MEM(timingAdvInd);
2700 if (pst->selector == ODU_SELECTOR_LC) {
2701 if (cmPkTfuTimingAdvIndInfo(timingAdvInd, mBuf) != ROK) {
2702 #if (ERRCLASS & ERRCLS_ADD_RES)
2703 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2704 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2705 (ErrVal)ETFU088, (ErrVal)0, "Packing failed");
2707 TFU_FREE_MEM(timingAdvInd);
2712 else if(pst->selector == ODU_SELECTOR_LWLC)
2714 if (oduPackPointer((PTR)timingAdvInd, mBuf) != ROK)
2716 #if (ERRCLASS & ERRCLS_ADD_RES)
2717 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2718 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2719 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
2721 TFU_FREE_MEM(timingAdvInd);
2727 if (SPkS16(suId, mBuf) != ROK) {
2728 #if (ERRCLASS & ERRCLS_ADD_RES)
2729 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2730 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2731 (ErrVal)ETFU089, (ErrVal)0, "Packing failed");
2733 TFU_FREE_MEM(timingAdvInd);
2737 if (pst->selector != ODU_SELECTOR_LWLC) {
2738 TFU_FREE_MEM(timingAdvInd);
2741 pst->event = (Event) EVTTFUTIMINGADVIND;
2742 return (SPstTsk(pst,mBuf));
2746 /***********************************************************
2748 * Func : cmUnpkTfuTimingAdvInd
2751 * Desc : This API is used to indicate a Timing Advance from PHY to Scheduler .
2752 * @details This primitive carries timing advance information for a number of
2753 * UEs that may need timing advance. Timing advance information is an estimate
2754 * of the timing adjustment that a UE would need to apply in order to be
2755 * synchronized in uplink. This estimate is to be calculated by physical layer.
2756 * @param pst Pointer to the post structure.
2757 * @param suId SAP ID of the service user.
2758 * @param timingAdvInd Pointer to the TfuTimingAdvIndInfo structure.
2759 * @return ROK/RFAILED
2768 **********************************************************/
2770 S16 cmUnpkTfuTimingAdvInd
2772 TfuTimingAdvInd func,
2777 S16 cmUnpkTfuTimingAdvInd(func, pst, mBuf)
2778 TfuTimingAdvInd func;
2784 TfuTimingAdvIndInfo *timingAdvInd;
2787 if (SUnpkS16(&suId, mBuf) != ROK) {
2789 #if (ERRCLASS & ERRCLS_ADD_RES)
2790 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2791 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2792 (ErrVal)ETFU090, (ErrVal)0, "Packing failed");
2796 if (pst->selector != ODU_SELECTOR_LWLC) {
2798 sMem.region = pst->region;
2799 sMem.pool = pst->pool;
2800 if ((cmAllocEvnt(sizeof(TfuTimingAdvIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&timingAdvInd)) != ROK) {
2801 #if (ERRCLASS & ERRCLS_ADD_RES)
2802 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2803 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2804 (ErrVal)ETFU091, (ErrVal)0, "Packing failed");
2812 if (pst->selector == ODU_SELECTOR_LC)
2814 if (cmUnpkTfuTimingAdvIndInfo(timingAdvInd, (Ptr)&timingAdvInd->memCp, mBuf) != ROK) {
2815 TFU_FREE_MEM(timingAdvInd);
2817 #if (ERRCLASS & ERRCLS_ADD_RES)
2818 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2819 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2820 (ErrVal)ETFU092, (ErrVal)0, "Packing failed");
2825 else if(pst->selector == ODU_SELECTOR_LWLC)
2827 if (oduUnpackPointer((PTR *)&timingAdvInd, mBuf) != ROK)
2829 #if (ERRCLASS & ERRCLS_ADD_RES)
2830 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2831 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2832 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
2834 TFU_FREE_MEM(timingAdvInd);
2840 return ((*func)(pst, suId, timingAdvInd));
2844 /***********************************************************
2846 * Func : cmPkTfuDatReq
2849 * Desc : This Primitive carries the Data PDUs from MAC to PHY for
2851 * @details The data being sent in this primitive is meant to be transmitted on
2852 * the downlink channel PDSCH and PBCH (if present). To facilitate physical
2853 * layer processing, requisite control information is also sent along with the
2855 * @sa TfUiTfuCntrlReq
2858 * @param tfuDatReq pointer to TfuDatReqInfo
2868 **********************************************************/
2874 TfuDatReqInfo * datReq
2877 S16 cmPkTfuDatReq(pst, spId, datReq)
2880 TfuDatReqInfo * datReq;
2883 Buffer *mBuf = NULLP;
2885 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
2886 #if (ERRCLASS & ERRCLS_ADD_RES)
2887 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2888 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2889 (ErrVal)ETFU093, (ErrVal)0, "Packing failed");
2891 TFU_FREE_MEM(datReq);
2894 if (pst->selector == ODU_SELECTOR_LC) {
2895 if (cmPkTfuDatReqInfo(datReq, mBuf) != ROK) {
2896 #if (ERRCLASS & ERRCLS_ADD_RES)
2897 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2898 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2899 (ErrVal)ETFU094, (ErrVal)0, "Packing failed");
2901 TFU_FREE_MEM(datReq);
2906 else if(pst->selector == ODU_SELECTOR_LWLC)
2908 if(oduPackPointer((PTR)datReq, mBuf) != ROK)
2910 #if (ERRCLASS & ERRCLS_ADD_RES)
2911 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2912 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2913 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
2915 TFU_FREE_MEM(datReq);
2921 if (SPkS16(spId, mBuf) != ROK) {
2922 #if (ERRCLASS & ERRCLS_ADD_RES)
2923 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2924 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2925 (ErrVal)ETFU095, (ErrVal)0, "Packing failed");
2927 TFU_FREE_MEM(datReq);
2931 if (pst->selector != ODU_SELECTOR_LWLC) {
2932 TFU_FREE_MEM(datReq);
2935 pst->event = (Event) EVTTFUDATREQ;
2936 return (SPstTsk(pst,mBuf));
2940 /***********************************************************
2942 * Func : cmUnpkTfuDatReq
2945 * Desc : This Primitive carries the Data PDUs from MAC to PHY for
2947 * @details The data being sent in this primitive is meant to be transmitted on
2948 * the downlink channel PDSCH and PBCH (if present). To facilitate physical
2949 * layer processing, requisite control information is also sent along with the
2951 * @sa TfUiTfuCntrlReq
2954 * @param tfuDatReq pointer to TfuDatReqInfo
2964 **********************************************************/
2973 S16 cmUnpkTfuDatReq(func, pst, mBuf)
2980 TfuDatReqInfo *datReq;
2983 if (SUnpkS16(&spId, mBuf) != ROK) {
2985 #if (ERRCLASS & ERRCLS_ADD_RES)
2986 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2987 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
2988 (ErrVal)ETFU096, (ErrVal)0, "Packing failed");
2992 if (pst->selector != ODU_SELECTOR_LWLC) {
2994 sMem.region = pst->region;
2995 sMem.pool = pst->pool;
2996 if ((cmAllocEvnt(sizeof(TfuDatReqInfo), TFU_BLKSZ, &sMem, (Ptr *)&datReq)) != ROK) {
2997 #if (ERRCLASS & ERRCLS_ADD_RES)
2998 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
2999 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3000 (ErrVal)ETFU097, (ErrVal)0, "Packing failed");
3008 if (pst->selector == ODU_SELECTOR_LC)
3010 if (cmUnpkTfuDatReqInfo(datReq, (Ptr)&datReq->memCp, mBuf) != ROK) {
3011 TFU_FREE_MEM(datReq);
3013 #if (ERRCLASS & ERRCLS_ADD_RES)
3014 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3015 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3016 (ErrVal)ETFU098, (ErrVal)0, "Unpacking failed");
3021 else if (pst->selector == ODU_SELECTOR_LWLC)
3023 if(oduUnpackPointer((PTR *)&datReq, mBuf) != ROK)
3025 TFU_FREE_MEM(datReq);
3027 #if (ERRCLASS & ERRCLS_ADD_RES)
3028 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3029 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3030 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Un-Packing failed");
3036 return ((*func)(pst, spId, datReq));
3040 /***********************************************************
3042 * Func : cmPkTfuCntrlReq
3045 * Desc : This Primitive is sent from Scheduler to PHY. It provides PHY with
3046 * all the control information
3047 * @details This primitive carries the information sent on the following
3055 * @param cntrlReq pointer to TfuCntrlReqInfo
3056 * @return ROK/RFAILED
3065 **********************************************************/
3071 TfuCntrlReqInfo * cntrlReq
3074 S16 cmPkTfuCntrlReq(pst, spId, cntrlReq)
3077 TfuCntrlReqInfo * cntrlReq;
3080 Buffer *mBuf = NULLP;
3082 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
3083 #if (ERRCLASS & ERRCLS_ADD_RES)
3084 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3085 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3086 (ErrVal)ETFU099, (ErrVal)0, "Packing failed");
3088 TFU_FREE_MEM(cntrlReq);
3091 if (pst->selector == ODU_SELECTOR_LC) {
3092 if (cmPkTfuCntrlReqInfo(cntrlReq, mBuf) != ROK) {
3093 #if (ERRCLASS & ERRCLS_ADD_RES)
3094 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3095 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3096 (ErrVal)ETFU100, (ErrVal)0, "Packing failed");
3098 TFU_FREE_MEM(cntrlReq);
3103 else if(pst->selector == ODU_SELECTOR_LWLC)
3105 if (oduPackPointer((PTR)cntrlReq, mBuf) != ROK)
3107 #if (ERRCLASS & ERRCLS_ADD_RES)
3108 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3109 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3110 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
3112 TFU_FREE_MEM(cntrlReq);
3119 if (SPkS16(spId, mBuf) != ROK) {
3120 #if (ERRCLASS & ERRCLS_ADD_RES)
3121 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3122 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3123 (ErrVal)ETFU101, (ErrVal)0, "Packing failed");
3125 TFU_FREE_MEM(cntrlReq);
3129 if (pst->selector != ODU_SELECTOR_LWLC) {
3130 TFU_FREE_MEM(cntrlReq);
3133 pst->event = (Event) EVTTFUCNTRLREQ;
3134 return (SPstTsk(pst,mBuf));
3138 /***********************************************************
3140 * Func : cmUnpkTfuCntrlReq
3143 * Desc : This Primitive is sent from Scheduler to PHY. It provides PHY with
3144 * all the control information
3145 * @details This primitive carries the information sent on the following
3153 * @param cntrlReq pointer to TfuCntrlReqInfo
3154 * @return ROK/RFAILED
3163 **********************************************************/
3165 S16 cmUnpkTfuCntrlReq
3172 S16 cmUnpkTfuCntrlReq(func, pst, mBuf)
3179 TfuCntrlReqInfo *cntrlReq;
3182 if (SUnpkS16(&spId, mBuf) != ROK) {
3184 #if (ERRCLASS & ERRCLS_ADD_RES)
3185 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3186 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3187 (ErrVal)ETFU102, (ErrVal)0, "Packing failed");
3191 if (pst->selector != ODU_SELECTOR_LWLC) {
3193 sMem.region = pst->region;
3194 sMem.pool = pst->pool;
3195 if ((cmAllocEvnt(sizeof(TfuCntrlReqInfo), TFU_BLKSZ, &sMem, (Ptr *)&cntrlReq)) != ROK) {
3196 #if (ERRCLASS & ERRCLS_ADD_RES)
3197 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3198 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3199 (ErrVal)ETFU103, (ErrVal)0, "Packing failed");
3207 if (pst->selector == ODU_SELECTOR_LC)
3209 if (cmUnpkTfuCntrlReqInfo(cntrlReq, (Ptr)&cntrlReq->memCp, mBuf) != ROK) {
3210 TFU_FREE_MEM(cntrlReq);
3212 #if (ERRCLASS & ERRCLS_ADD_RES)
3213 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3214 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3215 (ErrVal)ETFU104, (ErrVal)0, "Packing failed");
3220 else if(pst->selector == ODU_SELECTOR_LWLC)
3222 if (oduUnpackPointer((PTR *)&cntrlReq, mBuf) != ROK)
3224 #if (ERRCLASS & ERRCLS_ADD_RES)
3225 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3226 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3227 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
3229 TFU_FREE_MEM(cntrlReq);
3235 return ((*func)(pst, spId, cntrlReq));
3240 /***********************************************************
3242 * Func : cmPkTfuTtiInd
3245 * Desc : This API is the TTI indication from PHY to MAC .
3246 * @details This primitive provides the timing information (SFN and subframe)
3247 * which is currently running on the physical layer.
3248 * @param pst Pointer to the post structure.
3249 * @param suId SAP ID of the service user.
3250 * @param ttiInd Pointer to the TfuTtiIndInfo.
3251 * @return ROK/RFAILED
3260 **********************************************************/
3266 TfuTtiIndInfo * ttiInd
3269 S16 cmPkTfuTtiInd(pst, suId, ttiInd)
3272 TfuTtiIndInfo * ttiInd;
3275 Buffer *mBuf = NULLP;
3277 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
3278 #if (ERRCLASS & ERRCLS_ADD_RES)
3279 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3280 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3281 (ErrVal)ETFU105, (ErrVal)0, "Packing failed");
3283 SPutSBuf(pst->region, pst->pool, (Data *)ttiInd, sizeof(TfuTtiIndInfo));
3286 if (pst->selector == ODU_SELECTOR_LC) {
3287 if (cmPkTfuTtiIndInfo(ttiInd, mBuf) != ROK) {
3288 #if (ERRCLASS & ERRCLS_ADD_RES)
3289 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3290 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3291 (ErrVal)ETFU106, (ErrVal)0, "Packing failed");
3293 SPutSBuf(pst->region, pst->pool, (Data *)ttiInd, sizeof(TfuTtiIndInfo));
3298 else if(pst->selector == ODU_SELECTOR_LWLC)
3300 if (oduPackPointer((PTR)ttiInd, mBuf) != ROK)
3302 #if (ERRCLASS & ERRCLS_ADD_RES)
3303 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3304 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3305 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
3308 /*MS_FIX:71858:Changed to SPutSBuf as being allocated with SGetSBuf*/
3309 SPutSBuf(pst->region, pst->pool, (Data *)ttiInd, sizeof(TfuTtiIndInfo));
3315 if (SPkS16(suId, mBuf) != ROK) {
3316 #if (ERRCLASS & ERRCLS_ADD_RES)
3317 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3318 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3319 (ErrVal)ETFU107, (ErrVal)0, "Packing failed");
3321 SPutSBuf(pst->region, pst->pool, (Data *)ttiInd, sizeof(TfuTtiIndInfo));
3325 if (pst->selector != ODU_SELECTOR_LWLC) {
3326 if (SPutSBuf(pst->region, pst->pool, (Data *)ttiInd, sizeof(TfuTtiIndInfo)) != ROK) {
3327 #if (ERRCLASS & ERRCLS_ADD_RES)
3328 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3329 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3330 (ErrVal)ETFU108, (ErrVal)0, "Packing failed");
3337 //pst->event = (Event) EVENT_SLOT_IND_TO_MAC;
3338 return (SPstTsk(pst,mBuf));
3341 #if defined(TENB_T2K3K_SPECIFIC_CHANGES) && defined(LTE_TDD)
3342 /***********************************************************
3344 * Func : cmPkTfuNonRtInd
3347 * Desc : This API is the Non-Rt indication from CL to MAC .
3348 * @param pst Pointer to the post structure.
3349 * @param suId SAP ID of the service user.
3350 * @return ROK/RFAILED
3359 **********************************************************/
3367 S16 cmPkTfuNonRtInd(pst, suId)
3372 Buffer *mBuf = NULLP;
3374 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
3375 #if (ERRCLASS & ERRCLS_ADD_RES)
3376 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3377 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3378 (ErrVal)ETFU105, (ErrVal)0, "Packing failed");
3382 if (SPkS16(suId, mBuf) != ROK) {
3383 #if (ERRCLASS & ERRCLS_ADD_RES)
3384 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3385 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3386 (ErrVal)ETFU107, (ErrVal)0, "Packing failed");
3391 pst->event = (Event) EVTTFUNONRTIND;
3392 return (SPstTsk(pst,mBuf));
3395 /***********************************************************
3397 * Func : cmUnpkTfuNonRtInd
3400 * Desc : This API is the Non Rt indication from PHY to MAC .
3401 * @param pst Pointer to the post structure.
3402 * @param suId SAP ID of the service user.
3403 * @return ROK/RFAILED
3412 **********************************************************/
3414 S16 cmUnpkTfuNonRtInd
3421 S16 cmUnpkTfuNonRtInd(func, pst, mBuf)
3429 if (SUnpkS16(&suId, mBuf) != ROK) {
3431 #if (ERRCLASS & ERRCLS_ADD_RES)
3432 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3433 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3434 (ErrVal)ETFU109, (ErrVal)0, "Packing failed");
3439 return ((*func)(pst, suId));
3445 /***********************************************************
3447 * Func : cmPkTfuPucchDeltaPwr
3450 * Desc : This Primitive is used to convey PUCCH Delta power calculated by the
3452 * This information is utilized by Scheduler for power control.
3453 * @param pst Pointer to the post structure.
3454 * @param suId SAP ID of the service user.
3455 * @param Pointer to the TfuPucchDeltaPwrIndInfo structure.
3456 * @return ROK/RFAILED
3465 **********************************************************/
3467 S16 cmPkTfuPucchDeltaPwr
3471 TfuPucchDeltaPwrIndInfo * pucchDeltaPwr
3474 S16 cmPkTfuPucchDeltaPwr(pst, suId, pucchDeltaPwr)
3477 TfuPucchDeltaPwrIndInfo * pucchDeltaPwr;
3480 Buffer *mBuf = NULLP;
3482 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
3483 #if (ERRCLASS & ERRCLS_ADD_RES)
3484 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3485 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3486 (ErrVal)ETFU119, (ErrVal)0, "Packing failed");
3488 SPutSBuf(pst->region, pst->pool, (Data *)pucchDeltaPwr, sizeof(TfuPucchDeltaPwrIndInfo));
3491 if (pst->selector == ODU_SELECTOR_LC) {
3492 if (cmPkTfuPucchDeltaPwrIndInfo(pucchDeltaPwr, mBuf) != ROK) {
3493 #if (ERRCLASS & ERRCLS_ADD_RES)
3494 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3495 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3496 (ErrVal)ETFU120, (ErrVal)0, "Packing failed");
3498 TFU_FREE_MEM(pucchDeltaPwr);
3503 else if(pst->selector == ODU_SELECTOR_LWLC)
3505 if (oduPackPointer((PTR)pucchDeltaPwr, mBuf) != ROK)
3507 #if (ERRCLASS & ERRCLS_ADD_RES)
3508 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3509 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3510 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
3512 TFU_FREE_MEM(pucchDeltaPwr);
3518 if (SPkS16(suId, mBuf) != ROK) {
3519 #if (ERRCLASS & ERRCLS_ADD_RES)
3520 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3521 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3522 (ErrVal)ETFU121, (ErrVal)0, "Packing failed");
3524 TFU_FREE_MEM(pucchDeltaPwr);
3528 if (pst->selector != ODU_SELECTOR_LWLC) {
3529 TFU_FREE_MEM(pucchDeltaPwr);
3531 pst->event = (Event) EVTTFUPUCCHDELPWR;
3532 return (SPstTsk(pst,mBuf));
3536 /***********************************************************
3538 * Func : cmUnpkTfuPucchDeltaPwr
3541 * Desc : This Primitive is used to convey PUCCH Delta power calculated by the
3543 * This information is utilized by Scheduler for power control.
3544 * @param pst Pointer to the post structure.
3545 * @param suId SAP ID of the service user.
3546 * @param Pointer to the TfuPucchDeltaPwrIndInfo structure.
3547 * @return ROK/RFAILED
3556 **********************************************************/
3558 S16 cmUnpkTfuPucchDeltaPwr
3560 TfuPucchDeltaPwrInd func,
3565 S16 cmUnpkTfuPucchDeltaPwr(func, pst, mBuf)
3566 TfuPucchDeltaPwrInd func;
3572 TfuPucchDeltaPwrIndInfo *pucchDeltaPwr;
3575 if (SUnpkS16(&suId, mBuf) != ROK) {
3577 #if (ERRCLASS & ERRCLS_ADD_RES)
3578 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3579 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3580 (ErrVal)ETFU122, (ErrVal)0, "Packing failed");
3584 if (pst->selector != ODU_SELECTOR_LWLC) {
3586 sMem.region = pst->region;
3587 sMem.pool = pst->pool;
3588 if ((cmAllocEvnt(sizeof(TfuPucchDeltaPwrIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&pucchDeltaPwr)) != ROK) {
3589 #if (ERRCLASS & ERRCLS_ADD_RES)
3590 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3591 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3592 (ErrVal)ETFU123, (ErrVal)0, "Packing failed");
3599 if (pst->selector == ODU_SELECTOR_LC)
3601 if (cmUnpkTfuPucchDeltaPwrIndInfo(pucchDeltaPwr, (Ptr)&pucchDeltaPwr->memCp, mBuf) != ROK) {
3602 TFU_FREE_MEM(pucchDeltaPwr);
3604 #if (ERRCLASS & ERRCLS_ADD_RES)
3605 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3606 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3607 (ErrVal)ETFU124, (ErrVal)0, "Packing failed");
3612 else if(pst->selector == ODU_SELECTOR_LWLC)
3614 if (oduUnpackPointer((PTR *)&pucchDeltaPwr, mBuf) != ROK)
3616 #if (ERRCLASS & ERRCLS_ADD_RES)
3617 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
3618 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
3619 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
3621 TFU_FREE_MEM(pucchDeltaPwr);
3627 return ((*func)(pst, suId, pucchDeltaPwr));
3632 /***********************************************************
3634 * Func : cmPkTfuRbAssignA1Val324
3637 * Desc : This structure contains the information needed to convey RIV value 324.
3646 **********************************************************/
3648 S16 cmPkTfuRbAssignA1Val324
3650 TfuRbAssignA1Val324 *param,
3654 S16 cmPkTfuRbAssignA1Val324(param, mBuf)
3655 TfuRbAssignA1Val324 *param;
3661 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
3662 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
3663 CMCHKPK(oduUnpackUInt8, param->hqProcId, mBuf);
3665 printf("cmPkTfuRbAssignA1Val324 param->ndi %d mcs %d param->hqProcId %d \n",param->ndi,param->mcs,param->hqProcId);
3671 /***********************************************************
3673 * Func : cmPkTfuRbAssignB1Val324
3676 * Desc : This structure contains the information needed to convey RIV value 324.
3685 **********************************************************/
3687 S16 cmPkTfuRbAssignB1Val324
3689 TfuRbAssignB1Val324 *param,
3693 S16 cmPkTfuRbAssignB1Val324(param, mBuf)
3694 TfuRbAssignB1Val324 *param;
3700 CMCHKPK(oduUnpackUInt8, param->bmiHqAckNack, mBuf);
3701 CMCHKPK(oduUnpackUInt8, param->RV, mBuf);
3702 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
3703 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
3704 CMCHKPK(oduUnpackUInt8, param->hqProcId, mBuf);
3709 /***********************************************************
3711 * Func : cmPkTfuRbAssignVal326
3714 * Desc : This structure contains the information needed to convey RIV value 326.
3723 **********************************************************/
3725 S16 cmPkTfuRbAssignVal326
3727 TfuRbAssignVal326 *param,
3731 S16 cmPkTfuRbAssignVal326(param, mBuf)
3732 TfuRbAssignVal326 *param;
3738 CMCHKPK(oduUnpackUInt8, param->CyclicShiftInd, mBuf);
3739 CMCHKPK(oduUnpackUInt8, param->OCCInd, mBuf);
3740 CMCHKPK(oduUnpackUInt8, param->FreqBandIdx, mBuf);
3745 /***********************************************************
3747 * Func : cmUnpkTfuRbAssignA1Val324
3750 * Desc : This structure contains the information needed to convey RIV value 324.
3759 **********************************************************/
3761 S16 cmUnpkTfuRbAssignA1Val324
3763 TfuRbAssignA1Val324 *param,
3767 S16 cmUnpkTfuRbAssignA1Val324(param, mBuf)
3768 TfuRbAssignA1Val324 *param;
3774 CMCHKUNPK(oduPackUInt8, ¶m->hqProcId, mBuf);
3775 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
3776 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
3781 /***********************************************************
3783 * Func : cmUnpkTfuRbAssignB1Val324
3786 * Desc : This structure contains the information needed to convey RIV value 324.
3795 **********************************************************/
3797 S16 cmUnpkTfuRbAssignB1Val324
3799 TfuRbAssignB1Val324 *param,
3803 S16 cmUnpkTfuRbAssignB1Val324(param, mBuf)
3804 TfuRbAssignB1Val324 *param;
3810 CMCHKUNPK(oduPackUInt8, ¶m->hqProcId, mBuf);
3811 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
3812 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
3813 CMCHKUNPK(oduPackUInt8, ¶m->RV, mBuf);
3814 CMCHKUNPK(oduPackUInt8, ¶m->bmiHqAckNack, mBuf);
3819 /***********************************************************
3821 * Func : cmUnpkTfuRbAssignVal326
3824 * Desc : This structure contains the information needed to convey RIV value 326.
3833 **********************************************************/
3835 S16 cmUnpkTfuRbAssignVal326
3837 TfuRbAssignVal326 *param,
3841 S16 cmUnpkTfuRbAssignVal326(param, mBuf)
3842 TfuRbAssignVal326 *param;
3848 CMCHKUNPK(oduPackUInt8, ¶m->FreqBandIdx, mBuf);
3849 CMCHKUNPK(oduPackUInt8, ¶m->OCCInd, mBuf);
3850 CMCHKUNPK(oduPackUInt8, ¶m->CyclicShiftInd, mBuf);
3856 /***********************************************************
3858 * Func : cmPkTfuDciFormatA1A2Info
3861 * Desc : This structure contains the information needed to convey DCI format A1/A2.
3870 **********************************************************/
3872 S16 cmPkTfuDciFormatA1A2Info
3874 TfuDciFormatA1Info *param,
3878 S16 cmPkTfuDciFormatA1A2Info(param, mBuf)
3879 TfuDciFormatA1Info *param;
3885 //printf("5GTF_DBG: cmPkTfuDciFormatA1Info() called by eNB\n");
3886 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
3887 CMCHKPK(oduUnpackUInt8, param->UL_PCRS, mBuf);
3888 CMCHKPK(oduUnpackUInt8, param->PMI, mBuf);
3889 CMCHKPK(oduUnpackUInt8, param->SCID, mBuf);
3891 CMCHKPK(oduUnpackUInt8, param->REMapIdx_DMRS_PCRS_numLayers, mBuf);
3892 CMCHKPK(oduUnpackUInt8, param->SRS_Symbol, mBuf);
3893 CMCHKPK(oduUnpackUInt8, param->SRS_Config, mBuf);
3894 CMCHKPK(oduUnpackUInt8, param->beamSwitch, mBuf);
3895 CMCHKPK(oduUnpackUInt8, param->uciOnxPUSCH, mBuf);
3897 CMCHKPK(oduUnpackUInt8, param->numBSI_Reports, mBuf);
3898 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_ProcInd, mBuf);
3899 CMCHKPK(oduUnpackUInt8, param->CSI_BRRS_Indicator, mBuf);
3900 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_SymbIdx, mBuf);
3901 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_TxTiming, mBuf);
3902 CMCHKPK(oduUnpackUInt8, param->CSI_BSI_BRI_Req, mBuf);
3904 if(param->RBAssign <= TFU_RIV_324)
3906 CMCHKPK(cmPkTfuRbAssignA1Val324, ¶m->u.rbAssignA1Val324, mBuf);
3908 else if (param->RBAssign == TFU_RIV_326)
3910 CMCHKPK(cmPkTfuRbAssignVal326, ¶m->u.rbAssignVal326, mBuf);
3913 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
3914 CMCHKPK(oduUnpackUInt8, param->symbIdx, mBuf);
3915 CMCHKPK(oduUnpackUInt8, param->beamIndex, mBuf);
3916 CMCHKPK(oduUnpackUInt16, param->RBAssign, mBuf);
3917 CMCHKPK(oduUnpackUInt8, param->xPUSCH_TxTiming, mBuf);
3918 CMCHKPK(oduUnpackUInt8, param->xPUSCHRange, mBuf);
3919 CMCHKPK(oduUnpackUInt8, param->formatType, mBuf);
3924 /***********************************************************
3926 * Func : cmPkTfuDciFormatB1B2Info
3929 * Desc : This structure contains the information needed to convey DCI format B1/B2.
3938 **********************************************************/
3940 S16 cmPkTfuDciFormatB1B2Info
3942 TfuDciFormatB1Info *param,
3946 S16 cmPkTfuDciFormatB1B2Info(param, mBuf)
3947 TfuDciFormatB1Info *param;
3953 CMCHKPK(oduUnpackUInt8, param->DL_PCRS, mBuf);
3954 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
3955 CMCHKPK(oduUnpackUInt8, param->SCID, mBuf);
3957 CMCHKPK(oduUnpackUInt8, param->AntPorts_numLayers, mBuf);
3958 CMCHKPK(oduUnpackUInt8, param->SRS_Symbol, mBuf);
3959 CMCHKPK(oduUnpackUInt8, param->SRS_Config, mBuf);
3960 CMCHKPK(oduUnpackUInt8, param->beamSwitch, mBuf);
3961 CMCHKPK(oduUnpackUInt8, param->freqResIdx_xPUCCH, mBuf);
3963 CMCHKPK(oduUnpackUInt8, param->xPUCCH_TxTiming, mBuf);
3965 CMCHKPK(oduUnpackUInt8, param->numBSI_Reports, mBuf);
3966 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_ProcInd, mBuf);
3967 CMCHKPK(oduUnpackUInt8, param->CSI_BRRS_Indicator, mBuf);
3968 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_SymbIdx, mBuf);
3969 CMCHKPK(oduUnpackUInt8, param->CSIRS_BRRS_TxTiming, mBuf);
3970 CMCHKPK(oduUnpackUInt8, param->CSI_BSI_BRI_Req, mBuf);
3972 if(param->RBAssign <= TFU_RIV_324)
3974 CMCHKPK(cmPkTfuRbAssignB1Val324, ¶m->u.rbAssignB1Val324, mBuf);
3976 else if (param->RBAssign == TFU_RIV_326)
3978 CMCHKPK(cmPkTfuRbAssignVal326, ¶m->u.rbAssignVal326, mBuf);
3981 CMCHKPK(oduUnpackUInt8, param->symbIdx, mBuf);
3982 CMCHKPK(oduUnpackUInt8, param->beamIndex, mBuf);
3983 CMCHKPK(oduUnpackUInt16, param->RBAssign, mBuf);
3984 CMCHKPK(oduUnpackUInt8, param->xPDSCHRange, mBuf);
3985 CMCHKPK(oduUnpackUInt8, param->formatType, mBuf);
3991 /***********************************************************
3993 * Func : cmUnpkTfuDciFormatA1A2Info
3996 * Desc : This structure contains the information needed to convey DCI format A1/A2.
4005 **********************************************************/
4007 S16 cmUnpkTfuDciFormatA1A2Info
4009 TfuDciFormatA1Info *param,
4013 S16 cmUnpkTfuDciFormatA1A2Info(param, mBuf)
4014 TfuDciFormatA1Info *param;
4020 CMCHKUNPK(oduPackUInt8, ¶m->formatType, mBuf);
4021 CMCHKUNPK(oduPackUInt8, ¶m->xPUSCHRange, mBuf);
4022 CMCHKUNPK(oduPackUInt8, ¶m->xPUSCH_TxTiming, mBuf);
4023 CMCHKUNPK(oduPackUInt16, ¶m->RBAssign, mBuf);
4024 CMCHKUNPK(oduPackUInt8, ¶m->beamIndex, mBuf);
4025 CMCHKUNPK(oduPackUInt8, ¶m->symbIdx, mBuf);
4026 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
4028 if(param->RBAssign <= TFU_RIV_324)
4030 CMCHKUNPK(cmUnpkTfuRbAssignA1Val324, ¶m->u.rbAssignA1Val324, mBuf);
4032 else if(param->RBAssign == TFU_RIV_326)
4034 CMCHKUNPK(cmUnpkTfuRbAssignVal326, ¶m->u.rbAssignVal326, mBuf);
4037 CMCHKUNPK(oduPackUInt8, ¶m->CSI_BSI_BRI_Req, mBuf);
4038 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_TxTiming, mBuf);
4039 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_SymbIdx, mBuf);
4040 CMCHKUNPK(oduPackUInt8, ¶m->CSI_BRRS_Indicator, mBuf);
4041 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_ProcInd, mBuf);
4042 CMCHKUNPK(oduPackUInt8, ¶m->numBSI_Reports, mBuf);
4044 CMCHKUNPK(oduPackUInt8, ¶m->uciOnxPUSCH, mBuf);
4045 CMCHKUNPK(oduPackUInt8, ¶m->beamSwitch, mBuf);
4046 CMCHKUNPK(oduPackUInt8, ¶m->SRS_Config, mBuf);
4047 CMCHKUNPK(oduPackUInt8, ¶m->SRS_Symbol, mBuf);
4048 CMCHKUNPK(oduPackUInt8, ¶m->REMapIdx_DMRS_PCRS_numLayers, mBuf);
4050 CMCHKUNPK(oduPackUInt8, ¶m->SCID, mBuf);
4051 CMCHKUNPK(oduPackUInt8, ¶m->PMI, mBuf);
4052 CMCHKUNPK(oduPackUInt8, ¶m->UL_PCRS, mBuf);
4053 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
4059 /***********************************************************
4061 * Func : cmUnpkTfuDciFormatB1B2Info
4064 * Desc : This structure contains the information needed to convey DCI format B1/B2.
4073 **********************************************************/
4075 S16 cmUnpkTfuDciFormatB1B2Info
4077 TfuDciFormatB1Info *param,
4081 S16 cmUnpkTfuDciFormatB1B2Info(param, mBuf)
4082 TfuDciFormatB1Info *param;
4088 CMCHKUNPK(oduPackUInt8, ¶m->formatType, mBuf);
4089 CMCHKUNPK(oduPackUInt8, ¶m->xPDSCHRange, mBuf);
4090 CMCHKUNPK(oduPackUInt16, ¶m->RBAssign, mBuf);
4091 CMCHKUNPK(oduPackUInt8, ¶m->beamIndex, mBuf);
4092 CMCHKUNPK(oduPackUInt8, ¶m->symbIdx, mBuf);
4094 if(param->RBAssign <= TFU_RIV_324)
4096 CMCHKUNPK(cmUnpkTfuRbAssignB1Val324, ¶m->u.rbAssignB1Val324, mBuf);
4098 else if (param->RBAssign == TFU_RIV_326)
4100 CMCHKUNPK(cmUnpkTfuRbAssignVal326, ¶m->u.rbAssignVal326, mBuf);
4103 CMCHKUNPK(oduPackUInt8, ¶m->CSI_BSI_BRI_Req, mBuf);
4104 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_TxTiming, mBuf);
4105 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_SymbIdx, mBuf);
4106 CMCHKUNPK(oduPackUInt8, ¶m->CSI_BRRS_Indicator, mBuf);
4107 CMCHKUNPK(oduPackUInt8, ¶m->CSIRS_BRRS_ProcInd, mBuf);
4108 CMCHKUNPK(oduPackUInt8, ¶m->numBSI_Reports, mBuf);
4110 CMCHKUNPK(oduPackUInt8, ¶m->xPUCCH_TxTiming, mBuf);
4111 CMCHKUNPK(oduPackUInt8, ¶m->freqResIdx_xPUCCH, mBuf);
4112 CMCHKUNPK(oduPackUInt8, ¶m->beamSwitch, mBuf);
4113 CMCHKUNPK(oduPackUInt8, ¶m->SRS_Config, mBuf);
4114 CMCHKUNPK(oduPackUInt8, ¶m->SRS_Symbol, mBuf);
4115 CMCHKUNPK(oduPackUInt8, ¶m->AntPorts_numLayers, mBuf);
4116 CMCHKUNPK(oduPackUInt8, ¶m->SCID, mBuf);
4117 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
4118 CMCHKUNPK(oduPackUInt8, ¶m->DL_PCRS, mBuf);
4124 #endif /* TFU_5GTF */
4127 /***********************************************************
4129 * Func : cmPkTfuDciFormat0Info
4132 * Desc : This structure contains the information needed to convey DCI format 0.
4141 **********************************************************/
4143 S16 cmPkTfuDciFormat0Info
4145 TfuDciFormat0Info *param,
4149 S16 cmPkTfuDciFormat0Info(param, mBuf)
4150 TfuDciFormat0Info *param;
4156 /* tfu_c_001.main_3: Adding pack for hqProcId */
4157 CMCHKPK(oduUnpackUInt8, param->hqProcId, mBuf);
4158 CMCHKPK(oduUnpackUInt8, param->txAntenna, mBuf);
4159 CMCHKPK(oduUnpackUInt8, param->numCqiBit, mBuf);
4160 CMCHKPK(oduUnpackUInt8, param->cqiReq, mBuf);
4161 CMCHKPK(oduUnpackUInt8, param->nDmrs, mBuf);
4164 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
4165 CMCHKPK(oduUnpackUInt8, param->ulIdx, mBuf);
4168 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
4169 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
4170 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
4171 CMCHKPK(oduUnpackUInt8, param->hoppingBits, mBuf);
4172 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
4174 CMCHKPK(oduUnpackUInt32, param->riv, mBuf);
4176 CMCHKPK(oduUnpackUInt8, param->numRb, mBuf);
4177 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
4178 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
4184 /***********************************************************
4186 * Func : cmUnpkTfuDciFormat0Info
4189 * Desc : This structure contains the information needed to convey DCI format 0.
4198 **********************************************************/
4200 S16 cmUnpkTfuDciFormat0Info
4202 TfuDciFormat0Info *param,
4206 S16 cmUnpkTfuDciFormat0Info(param, mBuf)
4207 TfuDciFormat0Info *param;
4213 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
4214 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
4215 CMCHKUNPK(oduPackUInt8, ¶m->numRb, mBuf);
4217 CMCHKUNPK(oduPackUInt32, ¶m->riv, mBuf);
4218 #endif /* TFU_UPGRADE */
4219 CMCHKUNPK(oduPackUInt8, ¶m->hoppingBits, mBuf);
4220 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
4221 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
4222 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
4225 CMCHKUNPK(oduPackUInt8, ¶m->ulIdx, mBuf);
4226 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
4229 CMCHKUNPK(oduPackUInt8, ¶m->nDmrs, mBuf);
4230 CMCHKUNPK(oduPackUInt8, ¶m->cqiReq, mBuf);
4231 CMCHKUNPK(oduPackUInt8, ¶m->numCqiBit, mBuf);
4232 CMCHKUNPK(oduPackUInt8, ¶m->txAntenna, mBuf);
4233 /* tfu_c_001.main_3: Adding unpack for hqProcId */
4234 CMCHKUNPK(oduPackUInt8, ¶m->hqProcId, mBuf);
4241 /***********************************************************
4243 * Func : cmPkTfuAllocMapOrRiv
4246 * Desc : This Structure could either contain a resource allocation bit map OR a
4247 * RIV Value as defined in 213 - 7.1.6.
4256 **********************************************************/
4258 S16 cmPkTfuAllocMapOrRiv
4260 TfuAllocMapOrRiv *param,
4264 S16 cmPkTfuAllocMapOrRiv(param, mBuf)
4265 TfuAllocMapOrRiv *param;
4272 switch(param->type) {
4273 /*tfu_c_001.main_7 - ADD - TFU_RESMAP_CHANGE support */
4274 #ifdef TFU_RESMAP_CHANGE
4276 CMCHKPK(cmPkTfuAllocMap, ¶m->u.allocMap, mBuf);
4281 /*tfu_c_001.main_7 - ADD - TFU_RESMAP_CHANGE support */
4282 #ifndef TFU_RESMAP_CHANGE
4283 case TFU_ALLOC_TYPE_MAP:
4284 for (i=TFU_MAX_ALLOC_BYTES-1; i >= 0; i--) {
4285 CMCHKPK(oduUnpackUInt8, param->u.resAllocMap[i], mBuf);
4290 case TFU_ALLOC_TYPE_RIV:
4291 CMCHKPK(oduUnpackUInt32, param->u.riv, mBuf);
4296 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
4302 /***********************************************************
4304 * Func : cmUnpkTfuAllocMapOrRiv
4307 * Desc : This Structure could either contain a resource allocation bit map OR a
4308 * RIV Value as defined in 213 - 7.1.6.
4317 **********************************************************/
4319 S16 cmUnpkTfuAllocMapOrRiv
4321 TfuAllocMapOrRiv *param,
4325 S16 cmUnpkTfuAllocMapOrRiv(param, mBuf)
4326 TfuAllocMapOrRiv *param;
4333 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
4334 switch(param->type) {
4335 case TFU_ALLOC_TYPE_RIV:
4336 CMCHKUNPK(oduPackUInt32, ¶m->u.riv, mBuf);
4339 /*tfu_c_001.main_7 - ADD - TFU_RESMAP_CHANGE support */
4340 #ifndef TFU_RESMAP_CHANGE
4341 case TFU_ALLOC_TYPE_MAP:
4342 for (i=0; i<TFU_MAX_ALLOC_BYTES; i++) {
4343 CMCHKUNPK(oduPackUInt8, ¶m->u.resAllocMap[i], mBuf);
4349 /*tfu_c_001.main_7 - ADD - TFU_RESMAP_CHANGE support */
4350 #ifdef TFU_RESMAP_CHANGE
4352 CMCHKUNPK(cmUnpkTfuAllocMap, ¶m->u.allocMap, mBuf);
4364 /***********************************************************
4366 * Func : cmPkTfuDciFormat1AllocInfo
4369 * Desc : This structure contains only the allocation information, thats part
4371 * @details Allocation information also contains parameters necessary
4372 * for Physical layer to process Downlink Data. This structure accompanies the
4373 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4374 * @sa TfuDciFormat1Info
4383 **********************************************************/
4385 S16 cmPkTfuDciFormat1AllocInfo
4387 TfuDciFormat1AllocInfo *param,
4391 S16 cmPkTfuDciFormat1AllocInfo(param, mBuf)
4392 TfuDciFormat1AllocInfo *param;
4399 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
4400 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
4401 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
4402 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
4403 for (i=TFU_MAX_ALLOC_BYTES-1; i >= 0; i--) {
4404 CMCHKPK(oduUnpackUInt8, param->resAllocMap[i], mBuf);
4406 CMCHKPK(oduUnpackUInt8, param->isAllocType0, mBuf);
4412 /***********************************************************
4414 * Func : cmUnpkTfuDciFormat1AllocInfo
4417 * Desc : This structure contains only the allocation information, thats part
4419 * @details Allocation information also contains parameters necessary
4420 * for Physical layer to process Downlink Data. This structure accompanies the
4421 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4422 * @sa TfuDciFormat1Info
4431 **********************************************************/
4433 S16 cmUnpkTfuDciFormat1AllocInfo
4435 TfuDciFormat1AllocInfo *param,
4439 S16 cmUnpkTfuDciFormat1AllocInfo(param, mBuf)
4440 TfuDciFormat1AllocInfo *param;
4447 CMCHKUNPK(oduPackUInt8, ¶m->isAllocType0, mBuf);
4448 for (i=0; i<TFU_MAX_ALLOC_BYTES; i++) {
4449 CMCHKUNPK(oduPackUInt8, ¶m->resAllocMap[i], mBuf);
4451 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
4452 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
4453 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
4454 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
4459 /***********************************************************
4461 * Func : cmPkTfuDciFormat1Info
4464 * Desc : This structure contains the information needed to convey DCI format 1.
4465 * @details Allocation information is separated from the other control
4466 * information carried in this format. This separation is needed as Data shall
4467 * also carry some control information, essentially allocation information,
4468 * along with it, in order to aid physical layer processing of the data.
4477 **********************************************************/
4479 S16 cmPkTfuDciFormat1Info
4481 TfuDciFormat1Info *param,
4485 S16 cmPkTfuDciFormat1Info(param, mBuf)
4486 TfuDciFormat1Info *param;
4492 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
4495 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
4498 CMCHKPK(cmPkTfuDciFormat1AllocInfo, ¶m->allocInfo, mBuf);
4504 /***********************************************************
4506 * Func : cmUnpkTfuDciFormat1Info
4509 * Desc : This structure contains the information needed to convey DCI format 1.
4510 * @details Allocation information is separated from the other control
4511 * information carried in this format. This separation is needed as Data shall
4512 * also carry some control information, essentially allocation information,
4513 * along with it, in order to aid physical layer processing of the data.
4522 **********************************************************/
4524 S16 cmUnpkTfuDciFormat1Info
4526 TfuDciFormat1Info *param,
4530 S16 cmUnpkTfuDciFormat1Info(param, mBuf)
4531 TfuDciFormat1Info *param;
4537 CMCHKUNPK(cmUnpkTfuDciFormat1AllocInfo, ¶m->allocInfo, mBuf);
4540 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
4543 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
4549 /***********************************************************
4551 * Func : cmPkTfuDciFormat2AAllocInfo
4554 * Desc : This structure contains only the allocation information, that is part
4556 * @details Allocation information also contains parameters necessary
4557 * for Physical layer to process Downlink data. This structure accompanies the
4558 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4559 * @sa TfuDciFormat2AInfo
4568 **********************************************************/
4570 S16 cmPkTfuDciFormat2AAllocInfo
4572 TfuDciFormat2AAllocInfo *param,
4576 S16 cmPkTfuDciFormat2AAllocInfo(param, mBuf)
4577 TfuDciFormat2AAllocInfo *param;
4584 CMCHKPK(oduUnpackUInt8, param->transSwap, mBuf);
4585 CMCHKPK(oduUnpackUInt8, param->precoding, mBuf);
4587 for (i=1; i >= 0; i--) {
4588 CMCHKPK(cmPkTfuDciFormatTbInfo, ¶m->tbInfo[i], mBuf);
4591 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
4592 for (i=TFU_MAX_ALLOC_BYTES-1; i >= 0; i--) {
4593 CMCHKPK(oduUnpackUInt8, param->resAllocMap[i], mBuf);
4596 CMCHKPK(oduUnpackUInt8, param->isAllocType0, mBuf);
4603 /***********************************************************
4605 * Func : cmUnpkTfuDciFormat2AAllocInfo
4608 * Desc : This structure contains only the allocation information, that is part
4610 * @details Allocation information also contains parameters necessary
4611 * for Physical layer to process Downlink data. This structure accompanies the
4612 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4613 * @sa TfuDciFormat2AInfo
4622 **********************************************************/
4624 S16 cmUnpkTfuDciFormat2AAllocInfo
4626 TfuDciFormat2AAllocInfo *param,
4630 S16 cmUnpkTfuDciFormat2AAllocInfo(param, mBuf)
4631 TfuDciFormat2AAllocInfo *param;
4639 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4640 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4641 CMCHKUNPK(oduPackUInt8, ¶m->isAllocType0, mBuf);
4644 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4645 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4646 for (i=0; i<TFU_MAX_ALLOC_BYTES; i++) {
4647 CMCHKUNPK(oduPackUInt8, ¶m->resAllocMap[i], mBuf);
4649 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
4651 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4652 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4654 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4655 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4656 for (i=0; i<=1; i++) {
4657 CMCHKUNPK(cmUnpkTfuDciFormatTbInfo, ¶m->tbInfo[i], mBuf);
4660 CMCHKUNPK(oduPackUInt8, ¶m->precoding, mBuf);
4661 CMCHKUNPK(oduPackUInt8, ¶m->transSwap, mBuf);
4666 /***********************************************************
4668 * Func : cmPkTfuDciFormat6AAllocInfo
4671 * Desc : This structure contains only the allocation information, that is part
4672 * of DCI format 6-1A.
4673 * @details Allocation information also contains parameters necessary
4674 * for Physical layer to process Downlink data. This structure accompanies the
4675 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4676 * @sa TfuDciFormat61aInfo
4685 **********************************************************/
4687 S16 cmPkTfuDciFormat6AAllocInfo
4689 TfuDciFormat61AllocInfo *param,
4693 S16 cmPkTfuDciFormat6AAllocInfo(param, mBuf)
4694 TfuDciFormat61AllocInfo *param;
4700 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
4701 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
4702 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
4703 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
4704 CMCHKPK(oduUnpackUInt32, param->riv, mBuf);
4711 /***********************************************************
4713 * Func : cmUnpkTfuDciFormat6AAllocInfo
4716 * Desc : This structure contains only the allocation information, that is part
4717 * of DCI format 6-1A.
4718 * @details Allocation information also contains parameters necessary
4719 * for Physical layer to process Downlink data. This structure accompanies the
4720 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4721 * @sa TfuDciFormat61aInfo
4730 **********************************************************/
4732 S16 cmUnpkTfuDciFormat6AAllocInfo
4734 TfuDciFormat61AllocInfo *param,
4738 S16 cmUnpkTfuDciFormat6AAllocInfo(param, mBuf)
4739 TfuDciFormat61AllocInfo *param;
4745 CMCHKUNPK(oduPackUInt32, ¶m->riv, mBuf);
4746 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
4747 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
4748 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
4749 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
4750 printf("In cmUnpkTfuDciFormat6AAllocInfo :: Passed \n");
4757 /***********************************************************
4759 * Func : cmPkTfuDciFormat2AInfo
4762 * Desc : This structure contains the information carried by DCI format 2A.
4763 * @details It carries the allocation information and other control information.
4772 **********************************************************/
4774 S16 cmPkTfuDciFormat2AInfo
4776 TfuDciFormat2AInfo *param,
4780 S16 cmPkTfuDciFormat2AInfo(param, mBuf)
4781 TfuDciFormat2AInfo *param;
4787 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
4790 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
4793 CMCHKPK(cmPkTfuDciFormat2AAllocInfo, ¶m->allocInfo, mBuf);
4799 /***********************************************************
4801 * Func : cmUnpkTfuDciFormat2AInfo
4804 * Desc : This structure contains the information carried by DCI format 2A.
4805 * @details It carries the allocation information and other control information.
4814 **********************************************************/
4816 S16 cmUnpkTfuDciFormat2AInfo
4818 TfuDciFormat2AInfo *param,
4822 S16 cmUnpkTfuDciFormat2AInfo(param, mBuf)
4823 TfuDciFormat2AInfo *param;
4829 CMCHKUNPK(cmUnpkTfuDciFormat2AAllocInfo, ¶m->allocInfo, mBuf);
4832 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
4835 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
4841 /***********************************************************
4843 * Func : cmPkTfuDciFormat2AllocInfo
4846 * Desc : This structure contains only the allocation information, that is part
4848 * @details Allocation information also contains parameters necessary
4849 * for Physical layer to process Downlink data. This structure accompanies the
4850 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4851 * @sa TfuDciFormat2Info
4860 **********************************************************/
4862 S16 cmPkTfuDciFormat2AllocInfo
4864 TfuDciFormat2AllocInfo *param,
4868 S16 cmPkTfuDciFormat2AllocInfo(param, mBuf)
4869 TfuDciFormat2AllocInfo *param;
4877 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4878 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4879 for (i=1; i >= 0; i--) {
4880 CMCHKPK(cmPkTfuDciFormatTbInfo, ¶m->tbInfo[i], mBuf);
4882 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
4884 CMCHKPK(oduUnpackUInt8, param->precoding, mBuf);
4885 CMCHKPK(oduUnpackUInt8, param->transSwap, mBuf);
4887 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4888 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4891 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
4894 for (i=TFU_MAX_ALLOC_BYTES-1; i >= 0; i--) {
4895 CMCHKPK(oduUnpackUInt8, param->resAllocMap[i], mBuf);
4898 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4899 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4901 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4902 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4903 CMCHKPK(oduUnpackUInt8, param->isAllocType0, mBuf);
4910 /***********************************************************
4912 * Func : cmUnpkTfuDciFormat2AllocInfo
4915 * Desc : This structure contains only the allocation information, that is part
4917 * @details Allocation information also contains parameters necessary
4918 * for Physical layer to process Downlink data. This structure accompanies the
4919 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
4920 * @sa TfuDciFormat2Info
4929 **********************************************************/
4931 S16 cmUnpkTfuDciFormat2AllocInfo
4933 TfuDciFormat2AllocInfo *param,
4937 S16 cmUnpkTfuDciFormat2AllocInfo(param, mBuf)
4938 TfuDciFormat2AllocInfo *param;
4946 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4947 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4948 CMCHKUNPK(oduPackUInt8, ¶m->isAllocType0, mBuf);
4951 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4952 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4953 for (i=0; i<TFU_MAX_ALLOC_BYTES; i++) {
4954 CMCHKUNPK(oduPackUInt8, ¶m->resAllocMap[i], mBuf);
4958 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
4962 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4963 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4964 CMCHKUNPK(oduPackUInt8, ¶m->transSwap, mBuf);
4965 CMCHKUNPK(oduPackUInt8, ¶m->precoding, mBuf);
4967 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
4968 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
4969 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
4970 for (i=0; i<=1; i++) {
4971 CMCHKUNPK(cmUnpkTfuDciFormatTbInfo, ¶m->tbInfo[i], mBuf);
4979 /***********************************************************
4981 * Func : cmPkTfuDciFormat2Info
4984 * Desc : This structure contains the information carried by DCI format 2.
4985 * @details Allocation information is separated from the other control
4986 * information carried in this format. This separation is needed as Data must
4987 * also carry some control information, essentially, allocation information
4988 * along with it, in order to aid physical layer processing of the data.
4997 **********************************************************/
4999 S16 cmPkTfuDciFormat2Info
5001 TfuDciFormat2Info *param,
5005 S16 cmPkTfuDciFormat2Info(param, mBuf)
5006 TfuDciFormat2Info *param;
5013 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
5014 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
5017 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
5021 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
5023 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
5024 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
5025 CMCHKPK(cmPkTfuDciFormat2AllocInfo, ¶m->allocInfo, mBuf);
5031 /***********************************************************
5033 * Func : cmUnpkTfuDciFormat2Info
5036 * Desc : This structure contains the information carried by DCI format 2.
5037 * @details Allocation information is separated from the other control
5038 * information carried in this format. This separation is needed as Data must
5039 * also carry some control information, essentially, allocation information
5040 * along with it, in order to aid physical layer processing of the data.
5049 **********************************************************/
5051 S16 cmUnpkTfuDciFormat2Info
5053 TfuDciFormat2Info *param,
5057 S16 cmUnpkTfuDciFormat2Info(param, mBuf)
5058 TfuDciFormat2Info *param;
5064 CMCHKUNPK(cmUnpkTfuDciFormat2AllocInfo, ¶m->allocInfo, mBuf);
5066 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
5067 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
5068 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
5070 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
5071 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
5074 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
5083 /***********************************************************
5085 * Func : cmPkTfuDciFormat3Info
5088 * Desc : This structure contains the information carried in DCI format 3.
5097 **********************************************************/
5099 S16 cmPkTfuDciFormat3Info
5101 TfuDciFormat3Info *param,
5105 S16 cmPkTfuDciFormat3Info(param, mBuf)
5106 TfuDciFormat3Info *param;
5113 CMCHKPK(oduUnpackUInt8, param->isPucch, mBuf);
5114 for (i=TFU_MAX_2BIT_TPC-1; i >= 0; i--) {
5115 CMCHKPK(oduUnpackUInt8, param->tpcCmd[i], mBuf);
5122 /***********************************************************
5124 * Func : cmUnpkTfuDciFormat3Info
5127 * Desc : This structure contains the information carried in DCI format 3.
5136 **********************************************************/
5138 S16 cmUnpkTfuDciFormat3Info
5140 TfuDciFormat3Info *param,
5144 S16 cmUnpkTfuDciFormat3Info(param, mBuf)
5145 TfuDciFormat3Info *param;
5152 for (i=0; i<TFU_MAX_2BIT_TPC; i++) {
5153 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd[i], mBuf);
5155 CMCHKUNPK(oduPackUInt8, ¶m->isPucch, mBuf);
5161 /***********************************************************
5163 * Func : cmPkTfuDciFormat3AInfo
5166 * Desc : This structure contains the information carried by DCI format 3A.
5175 **********************************************************/
5177 S16 cmPkTfuDciFormat3AInfo
5179 TfuDciFormat3AInfo *param,
5183 S16 cmPkTfuDciFormat3AInfo(param, mBuf)
5184 TfuDciFormat3AInfo *param;
5190 CMCHKPK(oduUnpackUInt8, param->isPucch, mBuf);
5191 for (i=TFU_MAX_2BIT_TPC-1; i >= 0; i--) {
5192 CMCHKPK(oduUnpackUInt8, param->tpcCmd[i], mBuf);
5199 /***********************************************************
5201 * Func : cmUnpkTfuDciFormat3AInfo
5204 * Desc : This structure contains the information carried by DCI format 3A.
5213 **********************************************************/
5215 S16 cmUnpkTfuDciFormat3AInfo
5217 TfuDciFormat3AInfo *param,
5221 S16 cmUnpkTfuDciFormat3AInfo(param, mBuf)
5222 TfuDciFormat3AInfo *param;
5229 for (i=0; i<TFU_MAX_2BIT_TPC; i++) {
5230 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd[i], mBuf);
5232 CMCHKUNPK(oduPackUInt8, ¶m->isPucch, mBuf);
5239 /***********************************************************
5241 * Func : cmPkTfuDciFormat60aInfo
5244 * Desc : This structure contains the information that is carried in DCI
5254 ************************************************************/
5257 PRIVATE S16 cmPkTfuDciFormat60aInfo
5259 TfuDciFormat60aInfo *param,
5263 PRIVATE S16 cmPkTfuDciFormat60aInfo(param, mBuf)
5264 TfuDciFormat60aInfo *param;
5270 CMCHKPK(oduUnpackUInt8, param->dciRep, mBuf);
5271 CMCHKPK(oduUnpackUInt8, param->isSrs, mBuf);
5272 CMCHKPK(oduUnpackUInt8, param->cqiReq, mBuf);
5274 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
5275 CMCHKPK(oduUnpackUInt8, param->ulIdx, mBuf);
5277 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
5278 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
5279 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
5280 CMCHKPK(oduUnpackUInt8, param->hqProcId, mBuf);
5281 CMCHKPK(oduUnpackUInt8, param->rep, mBuf);
5282 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
5283 CMCHKPK(oduUnpackUInt32, param->riv, mBuf);
5284 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
5287 /***********************************************************
5289 * Func : cmPkTfuPdcchOrderInfoEmtc
5292 * Desc : This structure contains the information that is carried in DCI
5293 * format 6-1A in the case of a PDCCH order.
5302 **********************************************************/
5304 PRIVATE S16 cmPkTfuPdcchOrderInfoEmtc
5306 TfuPdcchOrderInfoEmtc *param,
5310 PRIVATE S16 cmPkTfuPdcchOrderInfoEmtc(param, mBuf)
5311 TfuPdcchOrderInfoEmtc *param;
5317 CMCHKPK(oduUnpackUInt8, param->ceLevel, mBuf);
5318 CMCHKPK(oduUnpackUInt8, param->prachMaskIdx, mBuf);
5319 CMCHKPK(oduUnpackUInt8, param->preambleIdx, mBuf);
5320 CMCHKPK(oduUnpackUInt32, param->riv, mBuf);
5324 /***********************************************************
5326 * Func : cmPkTfudciformat61aPdsch
5329 * Desc : This structure contains the information carried in DCI format 6-1A
5330 * when it is NOT used for a PDCCH order.
5339 **********************************************************/
5341 PRIVATE S16 cmPkTfudciformat61aPdsch
5343 Tfudciformat61aPdsch *param,
5347 PRIVATE S16 cmPkTfudciformat61aPdsch(param, mBuf)
5348 Tfudciformat61aPdsch *param;
5354 CMCHKPK(oduUnpackUInt8, param->isTBMsg4, mBuf);
5355 CMCHKPK(oduUnpackUInt8, param->dciRep, mBuf);
5356 CMCHKPK(oduUnpackUInt8, param->harqAckOffst, mBuf);
5357 CMCHKPK(oduUnpackUInt8, param->pmiCfm, mBuf);
5358 CMCHKPK(oduUnpackUInt8, param->tPmi, mBuf);
5359 CMCHKPK(oduUnpackUInt8, param->isSrs, mBuf);
5360 CMCHKPK(oduUnpackUInt8, param->antPortAndScrId, mBuf);
5363 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
5365 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
5366 CMCHKPK(oduUnpackUInt8, param->rep, mBuf);
5367 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
5368 CMCHKPK(cmPkTfuDciFormat6AAllocInfo, ¶m->allocInfo, mBuf);
5373 /***********************************************************
5375 * Func : cmPkTfuDciFormat61aInfo
5378 * Desc : This structure contains the information needed to convey DCI format 6-1A.
5379 * @details Format can possibly carry PDSCH allocation or information needed for
5380 * a PDCCH order, used to initiate a RACH procedure in cases where UE looses
5390 **********************************************************/
5392 S16 cmPkTfuDciFormat61aInfo
5394 TfuDciFormat61aInfo *param,
5398 S16 cmPkTfuDciFormat61aInfo(param, mBuf)
5399 TfuDciFormat61aInfo *param;
5405 switch(param->isPdcchOrder) {
5407 CMCHKPK(cmPkTfudciformat61aPdsch, ¶m->t.pdschInfo, mBuf);
5410 CMCHKPK(cmPkTfuPdcchOrderInfoEmtc, ¶m->t.pdcchOrder, mBuf);
5415 CMCHKPK(oduUnpackUInt8, param->isPdcchOrder, mBuf);
5420 /***********************************************************
5422 * Func : cmUnpkTfuDciFormat60aInfo
5425 * Desc : This structure contains the information that is carried in DCI
5435 * **********************************************************/
5438 PRIVATE S16 cmUnpkTfuDciFormat60aInfo
5440 TfuDciFormat60aInfo *param,
5444 PRIVATE S16 cmUnpkTfuDciFormat60aInfo(param, mBuf)
5445 TfuDciFormat60aInfo *param;
5451 printf("In cmUnpkTfuDciFormat60aInfo :: Entry \n");
5452 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
5453 CMCHKUNPK(oduPackUInt32, ¶m->riv, mBuf);
5454 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
5455 CMCHKUNPK(oduPackUInt8, ¶m->rep, mBuf);
5456 CMCHKUNPK(oduPackUInt8, ¶m->hqProcId, mBuf);
5457 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
5458 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
5459 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
5461 CMCHKUNPK(oduPackUInt8, ¶m->ulIdx, mBuf);
5462 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
5464 CMCHKUNPK(oduPackUInt8, ¶m->cqiReq, mBuf);
5465 CMCHKUNPK(oduPackUInt8, ¶m->isSrs, mBuf);
5466 CMCHKUNPK(oduPackUInt8, ¶m->dciRep, mBuf);
5467 printf("In cmUnpkTfuDciFormat60aInfo :: Exit \n");
5470 /***********************************************************
5472 * Func : cmUnpkTfuPdcchOrderInfoEmtc
5475 * Desc : This structure contains the information that is carried in DCI
5476 * format 6-1A in the case of a PDCCH order.
5485 **********************************************************/
5487 PRIVATE S16 cmUnpkTfuPdcchOrderInfoEmtc
5489 TfuPdcchOrderInfoEmtc *param,
5493 PRIVATE S16 cmUnpkTfuPdcchOrderInfoEmtc(param, mBuf)
5494 TfuPdcchOrderInfoEmtc *param;
5500 printf("In cmUnpkTfuPdcchOrderInfoEmtc :: Entry \n");
5501 CMCHKUNPK(oduPackUInt32, ¶m->riv, mBuf);
5502 CMCHKUNPK(oduPackUInt8, ¶m->preambleIdx, mBuf);
5503 CMCHKUNPK(oduPackUInt8, ¶m->prachMaskIdx, mBuf);
5504 CMCHKUNPK(oduPackUInt8, ¶m->ceLevel, mBuf);
5505 printf("In cmUnpkTfuPdcchOrderInfoEmtc :: Passed \n");
5509 /***********************************************************
5511 * Func : cmUnpkTfuDciFormat61aInfo
5514 * Desc : This structure contains the information carried by DCI format 6-1A.
5523 **********************************************************/
5525 S16 cmUnpkTfuDciFormat61aInfo
5527 TfuDciFormat61aInfo *param,
5531 S16 cmUnpkTfuDciFormat61aInfo(param, mBuf)
5532 TfuDciFormat61aInfo *param;
5538 CMCHKUNPK(oduPackUInt8, ¶m->isPdcchOrder, mBuf);
5539 printf("1. cmUnpkTfuDciFormat61aInfo :: isPdcchOrder %d \n", param->isPdcchOrder);
5540 switch(param->isPdcchOrder) {
5542 CMCHKUNPK(cmUnpkTfuPdcchOrderInfoEmtc, ¶m->t.pdcchOrder, mBuf);
5545 CMCHKUNPK(cmUnpkTfudciformat61aPdsch, ¶m->t.pdschInfo, mBuf);
5554 /***********************************************************
5556 * Func : cmPkTfuDciFormat1dAllocInfo
5559 * Desc : This structure contains only the allocation information, thats part
5561 * @details Allocation information also contains parameters necessary
5562 * for Physical layer to process Downlink Data. This structure accompanies the
5563 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5564 * @sa TfuDciFormat1dInfo
5573 **********************************************************/
5575 S16 cmPkTfuDciFormat1dAllocInfo
5577 TfuDciFormat1dAllocInfo *param,
5581 S16 cmPkTfuDciFormat1dAllocInfo(param, mBuf)
5582 TfuDciFormat1dAllocInfo *param;
5588 CMCHKPK(oduUnpackUInt8, param->tPmi, mBuf);
5589 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
5590 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
5591 CMCHKPK(cmPkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5592 CMCHKPK(cmPkTknU8, ¶m->nGap2, mBuf);
5593 CMCHKPK(oduUnpackUInt8, param->isLocal, mBuf);
5599 /***********************************************************
5601 * Func : cmUnpkTfuDciFormat1dAllocInfo
5604 * Desc : This structure contains only the allocation information, thats part
5606 * @details Allocation information also contains parameters necessary
5607 * for Physical layer to process Downlink Data. This structure accompanies the
5608 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5609 * @sa TfuDciFormat1dInfo
5618 **********************************************************/
5620 S16 cmUnpkTfuDciFormat1dAllocInfo
5622 TfuDciFormat1dAllocInfo *param,
5626 S16 cmUnpkTfuDciFormat1dAllocInfo(param, mBuf)
5627 TfuDciFormat1dAllocInfo *param;
5633 CMCHKUNPK(oduPackUInt8, ¶m->isLocal, mBuf);
5634 CMCHKUNPK(cmUnpkTknU8, ¶m->nGap2, mBuf);
5635 CMCHKUNPK(cmUnpkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5636 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
5637 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
5638 CMCHKUNPK(oduPackUInt8, ¶m->tPmi, mBuf);
5644 /***********************************************************
5646 * Func : cmPkTfuDciFormat1dInfo
5649 * Desc : This structure contains the information carried by DCI format 1D.
5650 * @details Allocation information is separated from the other control
5651 * information carried in this format. This separation is needed as Data shall
5652 * also carry some control information, essentially allocation information,
5653 * along with it, in order to aid physical layer processing of the data.
5662 **********************************************************/
5664 S16 cmPkTfuDciFormat1dInfo
5666 TfuDciFormat1dInfo *param,
5670 S16 cmPkTfuDciFormat1dInfo(param, mBuf)
5671 TfuDciFormat1dInfo *param;
5677 CMCHKPK(oduUnpackUInt8, param->dlPwrOffset, mBuf);
5680 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
5683 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
5684 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
5685 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
5686 CMCHKPK(cmPkTfuDciFormat1dAllocInfo, ¶m->allocInfo, mBuf);
5692 /***********************************************************
5694 * Func : cmUnpkTfuDciFormat1dInfo
5697 * Desc : This structure contains the information carried by DCI format 1D.
5698 * @details Allocation information is separated from the other control
5699 * information carried in this format. This separation is needed as Data shall
5700 * also carry some control information, essentially allocation information,
5701 * along with it, in order to aid physical layer processing of the data.
5710 **********************************************************/
5712 S16 cmUnpkTfuDciFormat1dInfo
5714 TfuDciFormat1dInfo *param,
5718 S16 cmUnpkTfuDciFormat1dInfo(param, mBuf)
5719 TfuDciFormat1dInfo *param;
5725 CMCHKUNPK(cmUnpkTfuDciFormat1dAllocInfo, ¶m->allocInfo, mBuf);
5726 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
5727 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
5728 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
5731 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
5734 CMCHKUNPK(oduPackUInt8, ¶m->dlPwrOffset, mBuf);
5740 /***********************************************************
5742 * Func : cmPkTfuDciFormat1cInfo
5745 * Desc : This structure contains only the allocation information, thats part
5747 * @details Allocation information also contains parameters necessary
5748 * for Physical layer to process Downlink Data. This structure accompanies the
5749 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5750 * @sa TfuDciFormat1CInfo
5759 **********************************************************/
5761 S16 cmPkTfuDciFormat1cInfo
5763 TfuDciFormat1cInfo *param,
5767 S16 cmPkTfuDciFormat1cInfo(param, mBuf)
5768 TfuDciFormat1cInfo *param;
5774 CMCHKPK(oduUnpackUInt8, param->iTbs, mBuf);
5775 CMCHKPK(cmPkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5776 CMCHKPK(cmPkTknU8, ¶m->nGap2, mBuf);
5782 /***********************************************************
5784 * Func : cmUnpkTfuDciFormat1cInfo
5787 * Desc : This structure contains only the allocation information, thats part
5789 * @details Allocation information also contains parameters necessary
5790 * for Physical layer to process Downlink Data. This structure accompanies the
5791 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5792 * @sa TfuDciFormat1CInfo
5801 **********************************************************/
5803 S16 cmUnpkTfuDciFormat1cInfo
5805 TfuDciFormat1cInfo *param,
5809 S16 cmUnpkTfuDciFormat1cInfo(param, mBuf)
5810 TfuDciFormat1cInfo *param;
5816 CMCHKUNPK(cmUnpkTknU8, ¶m->nGap2, mBuf);
5817 CMCHKUNPK(cmUnpkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5818 CMCHKUNPK(oduPackUInt8, ¶m->iTbs, mBuf);
5824 /***********************************************************
5826 * Func : cmPkTfuDciFormat1bAllocInfo
5829 * Desc : This structure contains only the allocation information, thats part
5830 * of DCI format 1 B.
5831 * @details Allocation information also contains parameters necessary
5832 * for Physical layer to process Downlink Data. This structure accompanies the
5833 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5834 * @sa TfuDciFormat1BInfo
5843 **********************************************************/
5845 S16 cmPkTfuDciFormat1bAllocInfo
5847 TfuDciFormat1bAllocInfo *param,
5851 S16 cmPkTfuDciFormat1bAllocInfo(param, mBuf)
5852 TfuDciFormat1bAllocInfo *param;
5858 CMCHKPK(oduUnpackUInt8, param->pmiCfm, mBuf);
5859 CMCHKPK(oduUnpackUInt8, param->tPmi, mBuf);
5860 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
5861 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
5862 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
5863 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
5864 CMCHKPK(cmPkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5865 CMCHKPK(cmPkTknU8, ¶m->nGap2, mBuf);
5866 CMCHKPK(oduUnpackUInt8, param->isLocal, mBuf);
5872 /***********************************************************
5874 * Func : cmUnpkTfuDciFormat1bAllocInfo
5877 * Desc : This structure contains only the allocation information, thats part
5878 * of DCI format 1 B.
5879 * @details Allocation information also contains parameters necessary
5880 * for Physical layer to process Downlink Data. This structure accompanies the
5881 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
5882 * @sa TfuDciFormat1BInfo
5891 **********************************************************/
5893 S16 cmUnpkTfuDciFormat1bAllocInfo
5895 TfuDciFormat1bAllocInfo *param,
5899 S16 cmUnpkTfuDciFormat1bAllocInfo(param, mBuf)
5900 TfuDciFormat1bAllocInfo *param;
5906 CMCHKUNPK(oduPackUInt8, ¶m->isLocal, mBuf);
5907 CMCHKUNPK(cmUnpkTknU8, ¶m->nGap2, mBuf);
5908 CMCHKUNPK(cmUnpkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
5909 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
5910 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
5911 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
5912 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
5913 CMCHKUNPK(oduPackUInt8, ¶m->tPmi, mBuf);
5914 CMCHKUNPK(oduPackUInt8, ¶m->pmiCfm, mBuf);
5920 /***********************************************************
5922 * Func : cmPkTfuPdcchOrderInfo
5925 * Desc : This structure contains the information that is carried in DCI
5926 * format 1A in the case of a PDCCH order.
5935 **********************************************************/
5937 S16 cmPkTfuPdcchOrderInfo
5939 TfuPdcchOrderInfo *param,
5943 S16 cmPkTfuPdcchOrderInfo(param, mBuf)
5944 TfuPdcchOrderInfo *param;
5950 CMCHKPK(oduUnpackUInt8, param->prachMaskIdx, mBuf);
5951 CMCHKPK(oduUnpackUInt8, param->preambleIdx, mBuf);
5957 /***********************************************************
5959 * Func : cmUnpkTfuPdcchOrderInfo
5962 * Desc : This structure contains the information that is carried in DCI
5963 * format 1A in the case of a PDCCH order.
5972 **********************************************************/
5974 S16 cmUnpkTfuPdcchOrderInfo
5976 TfuPdcchOrderInfo *param,
5980 S16 cmUnpkTfuPdcchOrderInfo(param, mBuf)
5981 TfuPdcchOrderInfo *param;
5987 CMCHKUNPK(oduPackUInt8, ¶m->preambleIdx, mBuf);
5988 CMCHKUNPK(oduPackUInt8, ¶m->prachMaskIdx, mBuf);
5994 /***********************************************************
5996 * Func : cmPkTfuDciFormat1aAllocInfo
5999 * Desc : This structure contains only the allocation information, thats part
6001 * @details Allocation information also contains parameters necessary
6002 * for Physical layer to process Downlink Data. This structure accompanies the
6003 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
6004 * @sa TfuDciFormat1AInfo
6013 **********************************************************/
6015 S16 cmPkTfuDciFormat1aAllocInfo
6017 TfuDciFormat1aAllocInfo *param,
6021 S16 cmPkTfuDciFormat1aAllocInfo(param, mBuf)
6022 TfuDciFormat1aAllocInfo *param;
6028 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
6029 CMCHKPK(cmPkTknU8, ¶m->harqProcId, mBuf);
6030 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
6031 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
6032 CMCHKPK(cmPkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
6033 CMCHKPK(cmPkTknU8, ¶m->nGap2, mBuf);
6034 CMCHKPK(oduUnpackUInt8, param->isLocal, mBuf);
6040 /***********************************************************
6042 * Func : cmUnpkTfuDciFormat1aAllocInfo
6045 * Desc : This structure contains only the allocation information, thats part
6047 * @details Allocation information also contains parameters necessary
6048 * for Physical layer to process Downlink Data. This structure accompanies the
6049 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
6050 * @sa TfuDciFormat1AInfo
6059 **********************************************************/
6061 S16 cmUnpkTfuDciFormat1aAllocInfo
6063 TfuDciFormat1aAllocInfo *param,
6067 S16 cmUnpkTfuDciFormat1aAllocInfo(param, mBuf)
6068 TfuDciFormat1aAllocInfo *param;
6074 CMCHKUNPK(oduPackUInt8, ¶m->isLocal, mBuf);
6075 CMCHKUNPK(cmUnpkTknU8, ¶m->nGap2, mBuf);
6076 CMCHKUNPK(cmUnpkTfuAllocMapOrRiv, ¶m->alloc, mBuf);
6077 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
6078 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
6079 CMCHKUNPK(cmUnpkTknU8, ¶m->harqProcId, mBuf);
6080 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
6086 /***********************************************************
6088 * Func : cmPkTfudciformat1aPdsch
6091 * Desc : This structure contains the information carried in DCI format 1A
6092 * when it is NOT used for a PDCCH order.
6101 **********************************************************/
6103 S16 cmPkTfudciformat1aPdsch
6105 Tfudciformat1aPdsch *param,
6109 S16 cmPkTfudciformat1aPdsch(param, mBuf)
6110 Tfudciformat1aPdsch *param;
6116 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
6119 CMCHKPK(cmPkTknU8, ¶m->dai, mBuf);
6122 CMCHKPK(cmPkTfuDciFormat1aAllocInfo, ¶m->allocInfo, mBuf);
6128 /***********************************************************
6130 * Func : cmUnpkTfudciformat1aPdsch
6133 * Desc : This structure contains the information carried in DCI format 1A
6134 * when it is NOT used for a PDCCH order.
6143 **********************************************************/
6145 S16 cmUnpkTfudciformat1aPdsch
6147 Tfudciformat1aPdsch *param,
6151 S16 cmUnpkTfudciformat1aPdsch(param, mBuf)
6152 Tfudciformat1aPdsch *param;
6158 CMCHKUNPK(cmUnpkTfuDciFormat1aAllocInfo, ¶m->allocInfo, mBuf);
6161 CMCHKUNPK(cmUnpkTknU8, ¶m->dai, mBuf);
6164 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
6171 /***********************************************************
6173 * Func : cmUnpkTfudciformat61aPdsch
6176 * Desc : This structure contains the information carried in DCI format 6-1A
6177 * when it is NOT used for a PDCCH order.
6186 **********************************************************/
6188 S16 cmUnpkTfudciformat61aPdsch
6190 Tfudciformat61aPdsch *param,
6194 S16 cmUnpkTfudciformat61aPdsch(param, mBuf)
6195 Tfudciformat61aPdsch *param;
6201 printf("1. cmUnpkTfudciformat61aPdsch :: Entry \n");
6202 CMCHKUNPK(cmUnpkTfuDciFormat6AAllocInfo, ¶m->allocInfo, mBuf);
6203 printf("2. cmUnpkTfudciformat61aPdsch :: Entry \n");
6204 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
6205 printf("3. cmUnpkTfudciformat61aPdsch :: Entry \n");
6206 CMCHKUNPK(oduPackUInt8, ¶m->rep, mBuf);
6207 printf("4. cmUnpkTfudciformat61aPdsch :: Entry \n");
6208 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
6209 printf("5. cmUnpkTfudciformat61aPdsch :: Entry \n");
6211 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
6212 printf("6. cmUnpkTfudciformat61aPdsch :: Entry \n");
6214 CMCHKUNPK(oduPackUInt8, ¶m->antPortAndScrId, mBuf);
6215 printf("7. cmUnpkTfudciformat61aPdsch :: Entry \n");
6216 CMCHKUNPK(oduPackUInt8, ¶m->isSrs, mBuf);
6217 printf("8. cmUnpkTfudciformat61aPdsch :: Entry \n");
6218 CMCHKUNPK(oduPackUInt8, ¶m->tPmi, mBuf);
6219 printf("9. cmUnpkTfudciformat61aPdsch :: Entry \n");
6220 CMCHKUNPK(oduPackUInt8, ¶m->pmiCfm, mBuf);
6221 printf("10. cmUnpkTfudciformat61aPdsch :: Entry \n");
6222 CMCHKUNPK(oduPackUInt8, ¶m->harqAckOffst, mBuf);
6223 printf("11. cmUnpkTfudciformat61aPdsch :: Entry \n");
6224 CMCHKUNPK(oduPackUInt8, ¶m->dciRep, mBuf);
6225 printf("12. cmUnpkTfudciformat61aPdsch :: Entry \n");
6226 CMCHKUNPK(oduPackUInt8, ¶m->isTBMsg4, mBuf);
6227 printf("1. cmUnpkTfudciformat61aPdsch :: Passed \n");
6230 /***********************************************************
6232 * Func : cmUnpkTfuDirectIndication
6235 * Desc : This structure contains the information that is carried in DCI
6236 * format 6-2 in the case of a Direct information indication.
6245 **********************************************************/
6247 PRIVATE S16 cmUnpkTfuDirectIndication
6249 TfuDirectIndication *param,
6253 PRIVATE S16 cmUnpkTfuDirectIndication(param, mBuf)
6254 TfuDirectIndication *param;
6259 CMCHKUNPK(oduPackUInt8, ¶m->directInd, mBuf);
6265 /***********************************************************
6267 * Func : cmUnpkTfuDciFormat62AllocInfo
6270 * Desc : This structure contains only the allocation information, that is part
6271 * of DCI format 6-2.
6272 * @details Allocation information also contains parameters necessary
6273 * for Physical layer to process Downlink data. This structure accompanies the
6274 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
6275 * @sa TfuDciFormat62Info
6284 **********************************************************/
6286 S16 cmUnpkTfuDciFormat62AllocInfo
6288 TfuDciFormat62AllocInfo *param,
6292 S16 cmUnpkTfuDciFormat62AllocInfo(param, mBuf)
6293 TfuDciFormat62AllocInfo *param;
6297 CMCHKUNPK(oduPackUInt8, ¶m->riv, mBuf);
6298 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
6299 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
6304 /***********************************************************
6306 * Func : cmUnpkTfudciformat62Pdsch
6309 * Desc : This structure contains the information carried in DCI format 6-2
6310 * when It is used for Paging message.
6319 **********************************************************/
6321 PRIVATE S16 cmUnpkTfudciformat62Pdsch
6323 Tfudciformat62Pdsch *param,
6327 PRIVATE S16 cmUnpkTfudciformat62Pdsch(param, mBuf)
6328 Tfudciformat62Pdsch *param;
6334 CMCHKUNPK(cmUnpkTfuDciFormat62AllocInfo, ¶m->format62AllocInfo, mBuf);
6335 CMCHKUNPK(oduPackUInt8, ¶m->repNum, mBuf);
6336 CMCHKUNPK(oduPackUInt8, ¶m->dciSubRepNum, mBuf);
6341 /***********************************************************
6343 * Func : cmUnpkTfuDciFormat62Info
6346 * Desc : This structure contains the information needed to convey DCI format 6-2.
6347 * @details Format can possibly carry PDSCH allocation or information needed for
6348 * a Direct information Indication.
6358 **********************************************************/
6360 S16 cmUnpkTfuDciFormat62Info
6362 TfuDciFormat62Info *param,
6366 S16 cmUnpkTfuDciFormat62Info(param, mBuf)
6367 TfuDciFormat62Info *param;
6372 CMCHKUNPK(oduPackUInt8, ¶m->isPaging, mBuf);
6373 switch(param->isPaging) {
6375 CMCHKUNPK(cmUnpkTfuDirectIndication, ¶m->t.directIndication, mBuf);
6378 CMCHKUNPK(cmUnpkTfudciformat62Pdsch, ¶m->t.pdschInfo, mBuf);
6399 /***********************************************************
6401 * Func : cmPkTfuDirectIndication
6404 * Desc : This structure contains the information that is carried in DCI
6405 * format 6-2 in the case of a Direct information indication.
6414 **********************************************************/
6416 PRIVATE S16 cmPkTfuDirectIndication
6418 TfuDirectIndication *param,
6422 PRIVATE S16 cmPkTfuDirectIndication(param, mBuf)
6423 TfuDirectIndication *param;
6428 CMCHKPK(oduUnpackUInt8, param->directInd, mBuf);
6436 /***********************************************************
6438 * Func : cmPkTfuDciFormat62AllocInfo
6441 * Desc : This structure contains only the allocation information, that is part
6442 * of DCI format 6-2.
6443 * @details Allocation information also contains parameters necessary
6444 * for Physical layer to process Downlink data. This structure accompanies the
6445 * Data that is sent from MAC to PHY in the TfUiTfuDatReq primitive.
6446 * @sa TfuDciFormat62Info
6455 **********************************************************/
6457 S16 cmPkTfuDciFormat62AllocInfo
6459 TfuDciFormat62AllocInfo *param,
6463 S16 cmPkTfuDciFormat62AllocInfo(param, mBuf)
6464 TfuDciFormat62AllocInfo *param;
6469 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
6470 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
6471 CMCHKPK(oduUnpackUInt8, param->riv, mBuf);
6478 /***********************************************************
6480 * Func : cmPkTfudciformat62Pdsch
6483 * Desc : This structure contains the information carried in DCI format 6-2
6484 * when It is used for Paging message.
6493 **********************************************************/
6495 PRIVATE S16 cmPkTfudciformat62Pdsch
6497 Tfudciformat62Pdsch *param,
6501 PRIVATE S16 cmPkTfudciformat62Pdsch(param, mBuf)
6502 Tfudciformat62Pdsch *param;
6507 CMCHKPK(oduUnpackUInt8, param->dciSubRepNum, mBuf);
6508 CMCHKPK(oduUnpackUInt8, param->repNum, mBuf);
6509 CMCHKPK(cmPkTfuDciFormat62AllocInfo, ¶m->format62AllocInfo, mBuf);
6516 /***********************************************************
6518 * Func : cmPkTfuDciFormat62Info
6521 * Desc : This structure contains the information needed to convey DCI format 6-2.
6522 * @details Format can possibly carry PDSCH allocation or information needed for
6523 * a Direct information Indication.
6533 **********************************************************/
6535 S16 cmPkTfuDciFormat62Info
6537 TfuDciFormat62Info *param,
6541 S16 cmPkTfuDciFormat62Info(param, mBuf)
6542 TfuDciFormat62Info *param;
6547 switch(param->isPaging) {
6549 CMCHKPK(cmPkTfudciformat62Pdsch, ¶m->t.pdschInfo, mBuf);
6552 CMCHKPK(cmPkTfuDirectIndication, ¶m->t.directIndication, mBuf);
6557 CMCHKPK(oduUnpackUInt8, param->isPaging, mBuf);
6570 /***********************************************************
6572 * Func : cmPkTfuDciFormat1aInfo
6575 * Desc : This structure contains the information needed to convey DCI format 1A.
6576 * @details Format can possibly carry PDSCH allocation or information needed for
6577 * a PDCCH order, used to initiate a RACH procedure in cases where UE looses
6587 **********************************************************/
6589 S16 cmPkTfuDciFormat1aInfo
6591 TfuDciFormat1aInfo *param,
6595 S16 cmPkTfuDciFormat1aInfo(param, mBuf)
6596 TfuDciFormat1aInfo *param;
6602 switch(param->isPdcchOrder) {
6604 CMCHKPK(cmPkTfudciformat1aPdsch, ¶m->t.pdschInfo, mBuf);
6607 CMCHKPK(cmPkTfuPdcchOrderInfo, ¶m->t.pdcchOrder, mBuf);
6612 CMCHKPK(oduUnpackUInt8, param->isPdcchOrder, mBuf);
6619 /***********************************************************
6621 * Func : cmUnpkTfuDciFormat1aInfo
6624 * Desc : This structure contains the information needed to convey DCI format 1A.
6625 * @details Format can possibly carry PDSCH allocation or information needed for
6626 * a PDCCH order, used to initiate a RACH procedure in cases where UE looses
6636 **********************************************************/
6638 S16 cmUnpkTfuDciFormat1aInfo
6640 TfuDciFormat1aInfo *param,
6644 S16 cmUnpkTfuDciFormat1aInfo(param, mBuf)
6645 TfuDciFormat1aInfo *param;
6651 CMCHKUNPK(oduPackUInt8, ¶m->isPdcchOrder, mBuf);
6652 switch(param->isPdcchOrder) {
6654 CMCHKUNPK(cmUnpkTfuPdcchOrderInfo, ¶m->t.pdcchOrder, mBuf);
6657 CMCHKUNPK(cmUnpkTfudciformat1aPdsch, ¶m->t.pdschInfo, mBuf);
6667 /***********************************************************
6669 * Func : cmPkTfuDciFormat1bInfo
6672 * Desc : This structure contains the information needed to convey DCI format 1A.
6673 * @details Allocation information is separated from the other control
6674 * information carried in this format. This separation is needed as Data shall
6675 * also carry some control information, essentially allocation information,
6676 * along with it, in order to aid physical layer processing of the data.
6685 **********************************************************/
6687 S16 cmPkTfuDciFormat1bInfo
6689 TfuDciFormat1bInfo *param,
6693 S16 cmPkTfuDciFormat1bInfo(param, mBuf)
6694 TfuDciFormat1bInfo *param;
6700 CMCHKPK(oduUnpackUInt8, param->tpcCmd, mBuf);
6703 CMCHKPK(oduUnpackUInt8, param->dai, mBuf);
6706 CMCHKPK(cmPkTfuDciFormat1bAllocInfo, ¶m->allocInfo, mBuf);
6712 /***********************************************************
6714 * Func : cmUnpkTfuDciFormat1bInfo
6717 * Desc : This structure contains the information needed to convey DCI format 1A.
6718 * @details Allocation information is separated from the other control
6719 * information carried in this format. This separation is needed as Data shall
6720 * also carry some control information, essentially allocation information,
6721 * along with it, in order to aid physical layer processing of the data.
6730 **********************************************************/
6732 S16 cmUnpkTfuDciFormat1bInfo
6734 TfuDciFormat1bInfo *param,
6738 S16 cmUnpkTfuDciFormat1bInfo(param, mBuf)
6739 TfuDciFormat1bInfo *param;
6745 CMCHKUNPK(cmUnpkTfuDciFormat1bAllocInfo, ¶m->allocInfo, mBuf);
6748 CMCHKUNPK(oduPackUInt8, ¶m->dai, mBuf);
6751 CMCHKUNPK(oduPackUInt8, ¶m->tpcCmd, mBuf);
6757 /***********************************************************
6759 * Func : cmPkTfuDciInfo
6762 * Desc : This structure contains the information needed to convey the possible DCI
6763 * formats. The following are the supported formats -
6764 * -# Format 0 - used for PUSCH scheduling
6765 * -# Format 1 - used for PDSCH scheduling
6766 * -# Format 1A - used for compact scheduling of PDSCH or RA procedure
6767 * intitiated by a PDCCH order.
6768 * -# Format 1B - used for compact scheduling of PDSCH with precoding
6770 * -# Format 1C - used for very compact scheduling of PDSCH.
6771 * -# Format 1D - used for compact scheduling for PDSCH with precoding
6772 * information with power offset.
6773 * -# Format 2 - used for PDSCH Scheduling
6774 * -# Format 2A - used for PDSCH Scheduling
6775 * -# Format 3 - used for power control
6776 * -# Format 3A - used for power control
6785 **********************************************************/
6793 S16 cmPkTfuDciInfo(param, mBuf)
6800 switch(param->dciFormat) {
6802 case TFU_DCI_FORMAT_B1:
6803 CMCHKPK(cmPkTfuDciFormatB1B2Info, ¶m->u.formatB1Info, mBuf);
6805 case TFU_DCI_FORMAT_B2:
6806 CMCHKPK(cmPkTfuDciFormatB1B2Info, ¶m->u.formatB2Info, mBuf);
6808 case TFU_DCI_FORMAT_A1:
6809 CMCHKPK(cmPkTfuDciFormatA1A2Info, ¶m->u.formatA1Info, mBuf);
6811 case TFU_DCI_FORMAT_A2:
6812 CMCHKPK(cmPkTfuDciFormatA1A2Info, ¶m->u.formatA2Info, mBuf);
6816 case TFU_DCI_FORMAT_6_2:
6817 CMCHKPK(cmPkTfuDciFormat62Info, ¶m->u.format62Info, mBuf);
6819 case TFU_DCI_FORMAT_6_1A:
6820 CMCHKPK(cmPkTfuDciFormat61aInfo, ¶m->u.format61aInfo, mBuf);
6822 case TFU_DCI_FORMAT_6_0A:
6823 CMCHKPK(cmPkTfuDciFormat60aInfo, ¶m->u.format60aInfo, mBuf);
6826 case TFU_DCI_FORMAT_3A:
6827 CMCHKPK(cmPkTfuDciFormat3AInfo, ¶m->u.format3AInfo, mBuf);
6829 case TFU_DCI_FORMAT_3:
6830 CMCHKPK(cmPkTfuDciFormat3Info, ¶m->u.format3Info, mBuf);
6832 case TFU_DCI_FORMAT_2A:
6833 CMCHKPK(cmPkTfuDciFormat2AInfo, ¶m->u.format2AInfo, mBuf);
6835 case TFU_DCI_FORMAT_2:
6836 CMCHKPK(cmPkTfuDciFormat2Info, ¶m->u.format2Info, mBuf);
6838 case TFU_DCI_FORMAT_1D:
6839 CMCHKPK(cmPkTfuDciFormat1dInfo, ¶m->u.format1dInfo, mBuf);
6841 case TFU_DCI_FORMAT_1C:
6842 CMCHKPK(cmPkTfuDciFormat1cInfo, ¶m->u.format1cInfo, mBuf);
6844 case TFU_DCI_FORMAT_1B:
6845 CMCHKPK(cmPkTfuDciFormat1bInfo, ¶m->u.format1bInfo, mBuf);
6847 case TFU_DCI_FORMAT_1A:
6848 CMCHKPK(cmPkTfuDciFormat1aInfo, ¶m->u.format1aInfo, mBuf);
6850 case TFU_DCI_FORMAT_1:
6851 CMCHKPK(cmPkTfuDciFormat1Info, ¶m->u.format1Info, mBuf);
6853 case TFU_DCI_FORMAT_0:
6854 CMCHKPK(cmPkTfuDciFormat0Info, ¶m->u.format0Info, mBuf);
6859 CMCHKPK(oduUnpackUInt32, param->dciFormat, mBuf);
6865 /***********************************************************
6867 * Func : cmUnpkTfuDciInfo
6870 * Desc : This structure contains the information needed to convey the possible DCI
6871 * formats. The following are the supported formats -
6872 * -# Format 0 - used for PUSCH scheduling
6873 * -# Format 1 - used for PDSCH scheduling
6874 * -# Format 1A - used for compact scheduling of PDSCH or RA procedure
6875 * intitiated by a PDCCH order.
6876 * -# Format 1B - used for compact scheduling of PDSCH with precoding
6878 * -# Format 1C - used for very compact scheduling of PDSCH.
6879 * -# Format 1D - used for compact scheduling for PDSCH with precoding
6880 * information with power offset.
6881 * -# Format 2 - used for PDSCH Scheduling
6882 * -# Format 2A - used for PDSCH Scheduling
6883 * -# Format 3 - used for power control
6884 * -# Format 3A - used for power control
6893 **********************************************************/
6895 S16 cmUnpkTfuDciInfo
6901 S16 cmUnpkTfuDciInfo(param, mBuf)
6909 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->dciFormat, mBuf);
6910 switch(param->dciFormat) {
6911 case TFU_DCI_FORMAT_0:
6912 CMCHKUNPK(cmUnpkTfuDciFormat0Info, ¶m->u.format0Info, mBuf);
6914 case TFU_DCI_FORMAT_1:
6915 CMCHKUNPK(cmUnpkTfuDciFormat1Info, ¶m->u.format1Info, mBuf);
6917 case TFU_DCI_FORMAT_1A:
6918 CMCHKUNPK(cmUnpkTfuDciFormat1aInfo, ¶m->u.format1aInfo, mBuf);
6920 case TFU_DCI_FORMAT_1B:
6921 CMCHKUNPK(cmUnpkTfuDciFormat1bInfo, ¶m->u.format1bInfo, mBuf);
6923 case TFU_DCI_FORMAT_1C:
6924 CMCHKUNPK(cmUnpkTfuDciFormat1cInfo, ¶m->u.format1cInfo, mBuf);
6926 case TFU_DCI_FORMAT_1D:
6927 CMCHKUNPK(cmUnpkTfuDciFormat1dInfo, ¶m->u.format1dInfo, mBuf);
6929 case TFU_DCI_FORMAT_2:
6930 CMCHKUNPK(cmUnpkTfuDciFormat2Info, ¶m->u.format2Info, mBuf);
6932 case TFU_DCI_FORMAT_2A:
6933 CMCHKUNPK(cmUnpkTfuDciFormat2AInfo, ¶m->u.format2AInfo, mBuf);
6935 case TFU_DCI_FORMAT_3:
6936 CMCHKUNPK(cmUnpkTfuDciFormat3Info, ¶m->u.format3Info, mBuf);
6938 case TFU_DCI_FORMAT_3A:
6939 CMCHKUNPK(cmUnpkTfuDciFormat3AInfo, ¶m->u.format3AInfo, mBuf);
6942 case TFU_DCI_FORMAT_6_0A:
6943 CMCHKUNPK(cmUnpkTfuDciFormat60aInfo, ¶m->u.format60aInfo, mBuf);
6944 printf("2. cmUnpkTfuDciInfo :: dciFormat %d \n", param->dciFormat);
6946 case TFU_DCI_FORMAT_6_1A:
6947 CMCHKUNPK(cmUnpkTfuDciFormat61aInfo, ¶m->u.format61aInfo, mBuf);
6948 printf("2. cmUnpkTfuDciInfo :: dciFormat %d \n", param->dciFormat);
6950 case TFU_DCI_FORMAT_6_2:
6951 CMCHKUNPK(cmUnpkTfuDciFormat62Info, ¶m->u.format62Info, mBuf);
6956 case TFU_DCI_FORMAT_A1:
6957 CMCHKUNPK(cmUnpkTfuDciFormatA1A2Info, ¶m->u.formatA1Info, mBuf);
6959 case TFU_DCI_FORMAT_A2:
6960 CMCHKUNPK(cmUnpkTfuDciFormatA1A2Info, ¶m->u.formatA2Info, mBuf);
6962 case TFU_DCI_FORMAT_B1:
6963 CMCHKUNPK(cmUnpkTfuDciFormatB1B2Info, ¶m->u.formatB1Info, mBuf);
6965 case TFU_DCI_FORMAT_B2:
6966 CMCHKUNPK(cmUnpkTfuDciFormatB1B2Info, ¶m->u.formatB2Info, mBuf);
6977 /***********************************************************
6979 * Func : cmPkTfuSubbandInfo
6982 * Desc : This structure contains the information needed to convey the start and size
6983 * of the subband in the CQI report.
6992 **********************************************************/
6994 S16 cmPkTfuSubbandInfo
6996 TfuSubbandInfo *param,
7000 S16 cmPkTfuSubbandInfo(param, mBuf)
7001 TfuSubbandInfo *param;
7007 CMCHKPK(oduUnpackUInt8, param->numRb, mBuf);
7008 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
7014 /***********************************************************
7016 * Func : cmUnpkTfuSubbandInfo
7019 * Desc : This structure contains the information needed to convey the start and size
7020 * of the subband in the CQI report.
7029 **********************************************************/
7031 S16 cmUnpkTfuSubbandInfo
7033 TfuSubbandInfo *param,
7037 S16 cmUnpkTfuSubbandInfo(param, mBuf)
7038 TfuSubbandInfo *param;
7044 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
7045 CMCHKUNPK(oduPackUInt8, ¶m->numRb, mBuf);
7052 /***********************************************************
7054 * Func : cmPkTfuSubbandCqiInfo
7057 * Desc : This structure is used to convey the subbannd CQI reported.
7066 **********************************************************/
7068 S16 cmPkTfuSubbandCqiInfo
7070 TfuSubbandCqiInfo *param,
7074 S16 cmPkTfuSubbandCqiInfo(param, mBuf)
7075 TfuSubbandCqiInfo *param;
7081 CMCHKPK(oduUnpackUInt8, param->cqiIdx, mBuf);
7082 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subband, mBuf);
7088 /***********************************************************
7090 * Func : cmUnpkTfuSubbandCqiInfo
7093 * Desc : This structure is used to convey the subbannd CQI reported.
7102 **********************************************************/
7104 S16 cmUnpkTfuSubbandCqiInfo
7106 TfuSubbandCqiInfo *param,
7110 S16 cmUnpkTfuSubbandCqiInfo(param, mBuf)
7111 TfuSubbandCqiInfo *param;
7117 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subband, mBuf);
7118 CMCHKUNPK(oduPackUInt8, ¶m->cqiIdx, mBuf);
7124 /***********************************************************
7126 * Func : cmPkTfuPdcchCceInfo
7129 * Desc : This structure conveys the CCE information.
7138 **********************************************************/
7140 S16 cmPkTfuPdcchCceInfo
7142 TfuPdcchCceInfo *param,
7146 S16 cmPkTfuPdcchCceInfo(param, mBuf)
7147 TfuPdcchCceInfo *param;
7153 CMCHKPK(cmPkLteAggrLvl, param->aggrLvl, mBuf);
7154 CMCHKPK(oduUnpackUInt8, param->cceIdx, mBuf);
7160 /***********************************************************
7162 * Func : cmUnpkTfuPdcchCceInfo
7165 * Desc : This structure conveys the CCE information.
7174 **********************************************************/
7176 S16 cmUnpkTfuPdcchCceInfo
7178 TfuPdcchCceInfo *param,
7182 S16 cmUnpkTfuPdcchCceInfo(param, mBuf)
7183 TfuPdcchCceInfo *param;
7189 CMCHKUNPK(oduPackUInt8, ¶m->cceIdx, mBuf);
7190 CMCHKUNPK(cmUnpkLteAggrLvl,(U32 *)¶m->aggrLvl, mBuf);
7196 /***********************************************************
7198 * Func : cmPkTfuCqiPucchMode10
7201 * Desc : This structure maps to the CQI mode 10. The report could either
7202 * convey a Rank index or a wideband CQI.
7211 **********************************************************/
7213 S16 cmPkTfuCqiPucchMode10
7215 TfuCqiPucchMode10 *param,
7219 S16 cmPkTfuCqiPucchMode10(param, mBuf)
7220 TfuCqiPucchMode10 *param;
7226 switch(param->type) {
7228 CMCHKPK(oduUnpackUInt8, param->u.cqi, mBuf);
7231 CMCHKPK(oduUnpackUInt8, param->u.ri, mBuf);
7236 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
7242 /***********************************************************
7244 * Func : cmUnpkTfuCqiPucchMode10
7247 * Desc : This structure maps to the CQI mode 10. The report could either
7248 * convey a Rank index or a wideband CQI.
7257 **********************************************************/
7259 S16 cmUnpkTfuCqiPucchMode10
7261 TfuCqiPucchMode10 *param,
7265 S16 cmUnpkTfuCqiPucchMode10(param, mBuf)
7266 TfuCqiPucchMode10 *param;
7272 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
7273 switch(param->type) {
7275 CMCHKUNPK(oduPackUInt8, ¶m->u.ri, mBuf);
7278 CMCHKUNPK(oduPackUInt8, ¶m->u.cqi, mBuf);
7288 /***********************************************************
7290 * Func : cmPkTfuCqiMode11Cqi
7293 * Desc : This structure contains a wideband CQI, PMI and optionally a
7294 * wideband differential CQI.
7303 **********************************************************/
7305 S16 cmPkTfuCqiMode11Cqi
7307 TfuCqiMode11Cqi *param,
7311 S16 cmPkTfuCqiMode11Cqi(param, mBuf)
7312 TfuCqiMode11Cqi *param;
7318 CMCHKPK(cmPkTknU8, ¶m->wideDiffCqi, mBuf);
7319 CMCHKPK(oduUnpackUInt8, param->pmi, mBuf);
7320 CMCHKPK(oduUnpackUInt8, param->cqi, mBuf);
7326 /***********************************************************
7328 * Func : cmUnpkTfuCqiMode11Cqi
7331 * Desc : This structure contains a wideband CQI, PMI and optionally a
7332 * wideband differential CQI.
7341 **********************************************************/
7343 S16 cmUnpkTfuCqiMode11Cqi
7345 TfuCqiMode11Cqi *param,
7349 S16 cmUnpkTfuCqiMode11Cqi(param, mBuf)
7350 TfuCqiMode11Cqi *param;
7356 CMCHKUNPK(oduPackUInt8, ¶m->cqi, mBuf);
7357 CMCHKUNPK(oduPackUInt8, ¶m->pmi, mBuf);
7358 CMCHKUNPK(cmUnpkTknU8, ¶m->wideDiffCqi, mBuf);
7364 /***********************************************************
7366 * Func : cmPkTfuCqiPucchMode11
7369 * Desc : This structure maps to the CQI mode 11. The report could either
7370 * convey a Rank index or a CQI report.
7379 **********************************************************/
7381 S16 cmPkTfuCqiPucchMode11
7383 TfuCqiPucchMode11 *param,
7387 S16 cmPkTfuCqiPucchMode11(param, mBuf)
7388 TfuCqiPucchMode11 *param;
7394 switch(param->type) {
7396 CMCHKPK(cmPkTfuCqiMode11Cqi, ¶m->u.cqi, mBuf);
7399 CMCHKPK(oduUnpackUInt8, param->u.ri, mBuf);
7404 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
7410 /***********************************************************
7412 * Func : cmUnpkTfuCqiPucchMode11
7415 * Desc : This structure maps to the CQI mode 11. The report could either
7416 * convey a Rank index or a CQI report.
7425 **********************************************************/
7427 S16 cmUnpkTfuCqiPucchMode11
7429 TfuCqiPucchMode11 *param,
7433 S16 cmUnpkTfuCqiPucchMode11(param, mBuf)
7434 TfuCqiPucchMode11 *param;
7440 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
7441 switch(param->type) {
7443 CMCHKUNPK(oduPackUInt8, ¶m->u.ri, mBuf);
7446 CMCHKUNPK(cmUnpkTfuCqiMode11Cqi, ¶m->u.cqi, mBuf);
7456 /***********************************************************
7458 * Func : cmPkTfuCqiMode20SubCqi
7461 * Desc : This structure contains the SubBand CQI for mode 2-0.
7470 **********************************************************/
7472 S16 cmPkTfuCqiMode20SubCqi
7474 TfuCqiMode20SubCqi *param,
7478 S16 cmPkTfuCqiMode20SubCqi(param, mBuf)
7479 TfuCqiMode20SubCqi *param;
7485 CMCHKPK(oduUnpackUInt8, param->l, mBuf);
7486 CMCHKPK(oduUnpackUInt8, param->cqi, mBuf);
7492 /***********************************************************
7494 * Func : cmUnpkTfuCqiMode20SubCqi
7497 * Desc : This structure contains the SubBand CQI for mode 2-0.
7506 **********************************************************/
7508 S16 cmUnpkTfuCqiMode20SubCqi
7510 TfuCqiMode20SubCqi *param,
7514 S16 cmUnpkTfuCqiMode20SubCqi(param, mBuf)
7515 TfuCqiMode20SubCqi *param;
7521 CMCHKUNPK(oduPackUInt8, ¶m->cqi, mBuf);
7522 CMCHKUNPK(oduPackUInt8, ¶m->l, mBuf);
7528 /***********************************************************
7530 * Func : cmPkTfuCqiMode20Cqi
7533 * Desc : This structure contains Mode20 CQI report. It could either be a
7534 * wideband CQI or a sub-band CQI.
7543 **********************************************************/
7545 S16 cmPkTfuCqiMode20Cqi
7547 TfuCqiMode20Cqi *param,
7551 S16 cmPkTfuCqiMode20Cqi(param, mBuf)
7552 TfuCqiMode20Cqi *param;
7558 switch(param->isWideband) {
7560 CMCHKPK(cmPkTfuCqiMode20SubCqi, ¶m->u.subCqi, mBuf);
7563 CMCHKPK(oduUnpackUInt8, param->u.wideCqi, mBuf);
7568 CMCHKPK(oduUnpackUInt8, param->isWideband, mBuf);
7574 /***********************************************************
7576 * Func : cmUnpkTfuCqiMode20Cqi
7579 * Desc : This structure contains Mode20 CQI report. It could either be a
7580 * wideband CQI or a sub-band CQI.
7589 **********************************************************/
7591 S16 cmUnpkTfuCqiMode20Cqi
7593 TfuCqiMode20Cqi *param,
7597 S16 cmUnpkTfuCqiMode20Cqi(param, mBuf)
7598 TfuCqiMode20Cqi *param;
7604 CMCHKUNPK(oduPackUInt8, ¶m->isWideband, mBuf);
7605 switch(param->isWideband) {
7607 CMCHKUNPK(oduPackUInt8, ¶m->u.wideCqi, mBuf);
7610 CMCHKUNPK(cmUnpkTfuCqiMode20SubCqi, ¶m->u.subCqi, mBuf);
7620 /***********************************************************
7622 * Func : cmPkTfuCqiPucchMode20
7625 * Desc : This structure maps to CQI mode 20. The report either contains a
7626 * Rank Index or a CQI report.
7635 **********************************************************/
7637 S16 cmPkTfuCqiPucchMode20
7639 TfuCqiPucchMode20 *param,
7643 S16 cmPkTfuCqiPucchMode20(param, mBuf)
7644 TfuCqiPucchMode20 *param;
7650 switch(param->type) {
7652 CMCHKPK(cmPkTfuCqiMode20Cqi, ¶m->u.cqi, mBuf);
7655 CMCHKPK(oduUnpackUInt8, param->u.ri, mBuf);
7660 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
7666 /***********************************************************
7668 * Func : cmUnpkTfuCqiPucchMode20
7671 * Desc : This structure maps to CQI mode 20. The report either contains a
7672 * Rank Index or a CQI report.
7681 **********************************************************/
7683 S16 cmUnpkTfuCqiPucchMode20
7685 TfuCqiPucchMode20 *param,
7689 S16 cmUnpkTfuCqiPucchMode20(param, mBuf)
7690 TfuCqiPucchMode20 *param;
7696 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
7697 switch(param->type) {
7699 CMCHKUNPK(oduPackUInt8, ¶m->u.ri, mBuf);
7702 CMCHKUNPK(cmUnpkTfuCqiMode20Cqi, ¶m->u.cqi, mBuf);
7712 /***********************************************************
7714 * Func : cmPkTfuCqiMode21SubCqi
7717 * Desc : This structure contains the sub-band CQI report for mode 2-1.
7718 * It carries a CQI, 'L' bit sub-band label, and optionally a differential CQI.
7727 **********************************************************/
7729 S16 cmPkTfuCqiMode21SubCqi
7731 TfuCqiMode21SubCqi *param,
7735 S16 cmPkTfuCqiMode21SubCqi(param, mBuf)
7736 TfuCqiMode21SubCqi *param;
7742 CMCHKPK(cmPkTknU8, ¶m->diffCqi, mBuf);
7743 CMCHKPK(oduUnpackUInt8, param->l, mBuf);
7744 CMCHKPK(oduUnpackUInt8, param->cqi, mBuf);
7750 /***********************************************************
7752 * Func : cmUnpkTfuCqiMode21SubCqi
7755 * Desc : This structure contains the sub-band CQI report for mode 2-1.
7756 * It carries a CQI, 'L' bit sub-band label, and optionally a differential CQI.
7765 **********************************************************/
7767 S16 cmUnpkTfuCqiMode21SubCqi
7769 TfuCqiMode21SubCqi *param,
7773 S16 cmUnpkTfuCqiMode21SubCqi(param, mBuf)
7774 TfuCqiMode21SubCqi *param;
7780 CMCHKUNPK(oduPackUInt8, ¶m->cqi, mBuf);
7781 CMCHKUNPK(oduPackUInt8, ¶m->l, mBuf);
7782 CMCHKUNPK(cmUnpkTknU8, ¶m->diffCqi, mBuf);
7788 /***********************************************************
7790 * Func : cmPkTfuCqiMode21WideCqi
7793 * Desc : This structure contains the wideband CQI report for mode 2-1.
7794 * It carries a wideband CQI, PMI and optionally a differential CQI.
7803 **********************************************************/
7805 S16 cmPkTfuCqiMode21WideCqi
7807 TfuCqiMode21WideCqi *param,
7811 S16 cmPkTfuCqiMode21WideCqi(param, mBuf)
7812 TfuCqiMode21WideCqi *param;
7818 CMCHKPK(cmPkTknU8, ¶m->diffCqi, mBuf);
7819 CMCHKPK(oduUnpackUInt8, param->pmi, mBuf);
7820 CMCHKPK(oduUnpackUInt8, param->cqi, mBuf);
7826 /***********************************************************
7828 * Func : cmUnpkTfuCqiMode21WideCqi
7831 * Desc : This structure contains the wideband CQI report for mode 2-1.
7832 * It carries a wideband CQI, PMI and optionally a differential CQI.
7841 **********************************************************/
7843 S16 cmUnpkTfuCqiMode21WideCqi
7845 TfuCqiMode21WideCqi *param,
7849 S16 cmUnpkTfuCqiMode21WideCqi(param, mBuf)
7850 TfuCqiMode21WideCqi *param;
7856 CMCHKUNPK(oduPackUInt8, ¶m->cqi, mBuf);
7857 CMCHKUNPK(oduPackUInt8, ¶m->pmi, mBuf);
7858 CMCHKUNPK(cmUnpkTknU8, ¶m->diffCqi, mBuf);
7864 /***********************************************************
7866 * Func : cmPkTfuCqiMode21Cqi
7869 * Desc : This structure conveys CQI report for mode 2-1. The reported value
7870 * could either be wideband or sub-band.
7879 **********************************************************/
7881 S16 cmPkTfuCqiMode21Cqi
7883 TfuCqiMode21Cqi *param,
7887 S16 cmPkTfuCqiMode21Cqi(param, mBuf)
7888 TfuCqiMode21Cqi *param;
7894 switch(param->isWideband) {
7896 CMCHKPK(cmPkTfuCqiMode21SubCqi, ¶m->u.subCqi, mBuf);
7899 CMCHKPK(cmPkTfuCqiMode21WideCqi, ¶m->u.wideCqi, mBuf);
7904 CMCHKPK(oduUnpackUInt8, param->isWideband, mBuf);
7910 /***********************************************************
7912 * Func : cmUnpkTfuCqiMode21Cqi
7915 * Desc : This structure conveys CQI report for mode 2-1. The reported value
7916 * could either be wideband or sub-band.
7925 **********************************************************/
7927 S16 cmUnpkTfuCqiMode21Cqi
7929 TfuCqiMode21Cqi *param,
7933 S16 cmUnpkTfuCqiMode21Cqi(param, mBuf)
7934 TfuCqiMode21Cqi *param;
7940 CMCHKUNPK(oduPackUInt8, ¶m->isWideband, mBuf);
7941 switch(param->isWideband) {
7943 CMCHKUNPK(cmUnpkTfuCqiMode21WideCqi, ¶m->u.wideCqi, mBuf);
7946 CMCHKUNPK(cmUnpkTfuCqiMode21SubCqi, ¶m->u.subCqi, mBuf);
7956 /***********************************************************
7958 * Func : cmPkTfuCqiPucchMode21
7961 * Desc : This structure maps to the CQI reporting mode 2-1. The report either
7962 * conveys a Rank Indicator or a CQI report.
7971 **********************************************************/
7973 S16 cmPkTfuCqiPucchMode21
7975 TfuCqiPucchMode21 *param,
7979 S16 cmPkTfuCqiPucchMode21(param, mBuf)
7980 TfuCqiPucchMode21 *param;
7986 switch(param->type) {
7988 CMCHKPK(cmPkTfuCqiMode21Cqi, ¶m->u.cqi, mBuf);
7991 CMCHKPK(oduUnpackUInt8, param->u.ri, mBuf);
7996 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
8002 /***********************************************************
8004 * Func : cmUnpkTfuCqiPucchMode21
8007 * Desc : This structure maps to the CQI reporting mode 2-1. The report either
8008 * conveys a Rank Indicator or a CQI report.
8017 **********************************************************/
8019 S16 cmUnpkTfuCqiPucchMode21
8021 TfuCqiPucchMode21 *param,
8025 S16 cmUnpkTfuCqiPucchMode21(param, mBuf)
8026 TfuCqiPucchMode21 *param;
8032 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
8033 switch(param->type) {
8035 CMCHKUNPK(oduPackUInt8, ¶m->u.ri, mBuf);
8038 CMCHKUNPK(cmUnpkTfuCqiMode21Cqi, ¶m->u.cqi, mBuf);
8048 /***********************************************************
8050 * Func : cmPkTfuDlCqiPucch
8053 * Desc : This structure conveys the Downlink CQI reported on PUCCH.
8062 **********************************************************/
8064 S16 cmPkTfuDlCqiPucch
8066 TfuDlCqiPucch *param,
8070 S16 cmPkTfuDlCqiPucch(param, mBuf)
8071 TfuDlCqiPucch *param;
8077 switch(param->mode) {
8078 case TFU_PUCCH_CQI_MODE21:
8079 CMCHKPK(cmPkTfuCqiPucchMode21, ¶m->u.mode21Info, mBuf);
8081 case TFU_PUCCH_CQI_MODE20:
8082 CMCHKPK(cmPkTfuCqiPucchMode20, ¶m->u.mode20Info, mBuf);
8084 case TFU_PUCCH_CQI_MODE11:
8085 CMCHKPK(cmPkTfuCqiPucchMode11, ¶m->u.mode11Info, mBuf);
8087 case TFU_PUCCH_CQI_MODE10:
8088 CMCHKPK(cmPkTfuCqiPucchMode10, ¶m->u.mode10Info, mBuf);
8093 CMCHKPK(oduUnpackUInt32, param->mode, mBuf);
8094 CMCHKPK(oduUnpackUInt8, param->cellIdx, mBuf);
8100 /***********************************************************
8102 * Func : cmUnpkTfuDlCqiPucch
8105 * Desc : This structure conveys the Downlink CQI reported on PUCCH.
8114 **********************************************************/
8116 S16 cmUnpkTfuDlCqiPucch
8118 TfuDlCqiPucch *param,
8122 S16 cmUnpkTfuDlCqiPucch(param, mBuf)
8123 TfuDlCqiPucch *param;
8129 CMCHKUNPK(oduPackUInt8, ¶m->cellIdx, mBuf);
8130 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->mode, mBuf);
8131 switch(param->mode) {
8132 case TFU_PUCCH_CQI_MODE10:
8133 CMCHKUNPK(cmUnpkTfuCqiPucchMode10, ¶m->u.mode10Info, mBuf);
8135 case TFU_PUCCH_CQI_MODE11:
8136 CMCHKUNPK(cmUnpkTfuCqiPucchMode11, ¶m->u.mode11Info, mBuf);
8138 case TFU_PUCCH_CQI_MODE20:
8139 CMCHKUNPK(cmUnpkTfuCqiPucchMode20, ¶m->u.mode20Info, mBuf);
8141 case TFU_PUCCH_CQI_MODE21:
8142 CMCHKUNPK(cmUnpkTfuCqiPucchMode21, ¶m->u.mode21Info, mBuf);
8152 /***********************************************************
8154 * Func : cmPkTfuSubbandMode12
8157 * Desc : This structure carries subband information and PMI, in the CQI
8158 * reporting format 1-2.
8167 **********************************************************/
8169 S16 cmPkTfuSubbandMode12
8171 TfuSubbandMode12 *param,
8175 S16 cmPkTfuSubbandMode12(param, mBuf)
8176 TfuSubbandMode12 *param;
8182 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subBand, mBuf);
8183 CMCHKPK(oduUnpackUInt8, param->pmi, mBuf);
8189 /***********************************************************
8191 * Func : cmUnpkTfuSubbandMode12
8194 * Desc : This structure carries subband information and PMI, in the CQI
8195 * reporting format 1-2.
8204 **********************************************************/
8206 S16 cmUnpkTfuSubbandMode12
8208 TfuSubbandMode12 *param,
8212 S16 cmUnpkTfuSubbandMode12(param, mBuf)
8213 TfuSubbandMode12 *param;
8219 CMCHKUNPK(oduPackUInt8, ¶m->pmi, mBuf);
8220 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subBand, mBuf);
8226 /***********************************************************
8228 * Func : cmPkTfuCqiPuschMode12
8231 * Desc : This structure conveys information present in CQI reporting mode 1-2 received
8241 **********************************************************/
8243 S16 cmPkTfuCqiPuschMode12
8245 TfuCqiPuschMode12 *param,
8249 S16 cmPkTfuCqiPuschMode12(param, mBuf)
8250 TfuCqiPuschMode12 *param;
8257 for (i=TFU_MAX_DL_SUBBAND-1; i >= 0; i--) {
8258 CMCHKPK(cmPkTfuSubbandMode12, ¶m->subbandArr[i], mBuf);
8260 for (i=TFU_MAX_TB-1; i >= 0; i--) {
8261 CMCHKPK(oduUnpackUInt8, param->cqiIdx[i], mBuf);
8263 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
8269 /***********************************************************
8271 * Func : cmUnpkTfuCqiPuschMode12
8274 * Desc : This structure conveys information present in CQI reporting mode 1-2 received
8284 **********************************************************/
8286 S16 cmUnpkTfuCqiPuschMode12
8288 TfuCqiPuschMode12 *param,
8292 S16 cmUnpkTfuCqiPuschMode12(param, mBuf)
8293 TfuCqiPuschMode12 *param;
8300 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
8301 for (i=0; i<TFU_MAX_TB; i++) {
8302 CMCHKUNPK(oduPackUInt8, ¶m->cqiIdx[i], mBuf);
8304 for (i=0; i<TFU_MAX_DL_SUBBAND; i++) {
8305 CMCHKUNPK(cmUnpkTfuSubbandMode12, ¶m->subbandArr[i], mBuf);
8312 /***********************************************************
8314 * Func : cmPkTfuCqiPuschMode20
8317 * Desc : This structure conveys information present in CQI reporting mode 2-0 received
8318 * over PUSCH. This mode is for UE selected sub-band feedback.
8327 **********************************************************/
8329 S16 cmPkTfuCqiPuschMode20
8331 TfuCqiPuschMode20 *param,
8335 S16 cmPkTfuCqiPuschMode20(param, mBuf)
8336 TfuCqiPuschMode20 *param;
8343 for (i=TFU_MAX_DL_SUBBAND-1; i >= 0; i--) {
8344 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subbandArr[i], mBuf);
8346 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
8347 CMCHKPK(oduUnpackUInt8, param->wideBandCqi, mBuf);
8348 CMCHKPK(oduUnpackUInt8, param->cqiIdx, mBuf);
8354 /***********************************************************
8356 * Func : cmUnpkTfuCqiPuschMode20
8359 * Desc : This structure conveys information present in CQI reporting mode 2-0 received
8360 * over PUSCH. This mode is for UE selected sub-band feedback.
8369 **********************************************************/
8371 S16 cmUnpkTfuCqiPuschMode20
8373 TfuCqiPuschMode20 *param,
8377 S16 cmUnpkTfuCqiPuschMode20(param, mBuf)
8378 TfuCqiPuschMode20 *param;
8385 CMCHKUNPK(oduPackUInt8, ¶m->cqiIdx, mBuf);
8386 CMCHKUNPK(oduPackUInt8, ¶m->wideBandCqi, mBuf);
8387 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
8388 for (i=0; i<TFU_MAX_DL_SUBBAND; i++) {
8389 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subbandArr[i], mBuf);
8395 /***********************************************************
8397 * Func : cmPkTfuCqiPuschMode22
8400 * Desc : This structure conveys information present in CQI reporting mode 2-2 received
8410 **********************************************************/
8412 S16 cmPkTfuCqiPuschMode22
8414 TfuCqiPuschMode22 *param,
8418 S16 cmPkTfuCqiPuschMode22(param, mBuf)
8419 TfuCqiPuschMode22 *param;
8427 for (i=TFU_MAX_DL_SUBBAND-1; i >= 0; i--) {
8428 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subbandArr[i], mBuf);
8431 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
8432 CMCHKPK(oduUnpackUInt8, param->wideBandPmi, mBuf);
8433 for (i=TFU_MAX_TB-1; i >= 0; i--) {
8434 CMCHKPK(oduUnpackUInt8, param->wideBandCqi[i], mBuf);
8436 CMCHKPK(oduUnpackUInt8, param->pmi, mBuf);
8437 for (i=TFU_MAX_TB-1; i >= 0; i--) {
8438 CMCHKPK(oduUnpackUInt8, param->cqi[i], mBuf);
8445 /***********************************************************
8447 * Func : cmUnpkTfuCqiPuschMode22
8450 * Desc : This structure conveys information present in CQI reporting mode 2-2 received
8460 **********************************************************/
8462 S16 cmUnpkTfuCqiPuschMode22
8464 TfuCqiPuschMode22 *param,
8468 S16 cmUnpkTfuCqiPuschMode22(param, mBuf)
8469 TfuCqiPuschMode22 *param;
8476 for (i=0; i<TFU_MAX_TB; i++) {
8477 CMCHKUNPK(oduPackUInt8, ¶m->cqi[i], mBuf);
8479 CMCHKUNPK(oduPackUInt8, ¶m->pmi, mBuf);
8480 for (i=0; i<TFU_MAX_TB; i++) {
8481 CMCHKUNPK(oduPackUInt8, ¶m->wideBandCqi[i], mBuf);
8483 CMCHKUNPK(oduPackUInt8, ¶m->wideBandPmi, mBuf);
8484 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
8486 for (i=0; i<TFU_MAX_DL_SUBBAND; i++) {
8487 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subbandArr[i], mBuf);
8495 S16 cmPkTfuSubbandMode30
8497 TfuSubbandMode30 *param,
8501 S16 cmPkTfuSubbandMode30(param, mBuf)
8502 TfuSubbandMode30 *param;
8508 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subBand, mBuf);
8509 CMCHKPK(oduUnpackUInt8, param->cqi, mBuf);
8515 S16 cmUnpkTfuSubbandMode30
8517 TfuSubbandMode30 *param,
8521 S16 cmUnpkTfuSubbandMode30(param, mBuf)
8522 TfuSubbandMode30 *param;
8528 CMCHKUNPK(oduPackUInt8, ¶m->cqi, mBuf);
8529 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subBand, mBuf);
8535 /***********************************************************
8537 * Func : cmPkTfuCqiPuschMode30
8540 * Desc : This structure conveys information present in CQI reporting mode 3-0
8541 * received over PUSCH.
8550 **********************************************************/
8552 S16 cmPkTfuCqiPuschMode30
8554 TfuCqiPuschMode30 *param,
8558 S16 cmPkTfuCqiPuschMode30(param, mBuf)
8559 TfuCqiPuschMode30 *param;
8566 for (i=TFU_MAX_DL_SUBBAND-1; i >= 0; i--) {
8567 CMCHKPK(cmPkTfuSubbandMode30, ¶m->subbandArr[i], mBuf);
8569 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
8570 CMCHKPK(oduUnpackUInt8, param->wideBandCqi, mBuf);
8576 /***********************************************************
8578 * Func : cmUnpkTfuCqiPuschMode30
8581 * Desc : This structure conveys information present in CQI reporting mode 3-0
8582 * received over PUSCH.
8591 **********************************************************/
8593 S16 cmUnpkTfuCqiPuschMode30
8595 TfuCqiPuschMode30 *param,
8599 S16 cmUnpkTfuCqiPuschMode30(param, mBuf)
8600 TfuCqiPuschMode30 *param;
8607 CMCHKUNPK(oduPackUInt8, ¶m->wideBandCqi, mBuf);
8608 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
8609 for (i=0; i<TFU_MAX_DL_SUBBAND; i++) {
8610 CMCHKUNPK(cmUnpkTfuSubbandMode30, ¶m->subbandArr[i], mBuf);
8617 S16 cmPkTfuSubbandMode31
8619 TfuSubbandMode31 *param,
8623 S16 cmPkTfuSubbandMode31(param, mBuf)
8624 TfuSubbandMode31 *param;
8631 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subBand, mBuf);
8632 for (i=TFU_MAX_TB-1; i >= 0; i--) {
8633 CMCHKPK(oduUnpackUInt8, param->cqi[i], mBuf);
8640 S16 cmUnpkTfuSubbandMode31
8642 TfuSubbandMode31 *param,
8646 S16 cmUnpkTfuSubbandMode31(param, mBuf)
8647 TfuSubbandMode31 *param;
8654 for (i=0; i<TFU_MAX_TB; i++) {
8655 CMCHKUNPK(oduPackUInt8, ¶m->cqi[i], mBuf);
8657 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subBand, mBuf);
8663 /***********************************************************
8665 * Func : cmPkTfuCqiPuschMode31
8668 * Desc : This structure conveys information present in CQI reporting mode 3-1
8669 * received over PUSCH.
8678 **********************************************************/
8680 S16 cmPkTfuCqiPuschMode31
8682 TfuCqiPuschMode31 *param,
8686 S16 cmPkTfuCqiPuschMode31(param, mBuf)
8687 TfuCqiPuschMode31 *param;
8695 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
8696 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
8698 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
8699 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
8700 for (i=param->numSubband-1; i >= 0; i--) {
8701 CMCHKPK(cmPkTfuSubbandDlCqiInfo, ¶m->subbandCqiArr[i], mBuf);
8704 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
8705 for (i=TFU_MAX_TB-1; i >= 0; i--) {
8706 CMCHKPK(oduUnpackUInt8, param->wideBandCqi[i], mBuf);
8708 CMCHKPK(oduUnpackUInt8, param->pmi, mBuf);
8714 /***********************************************************
8716 * Func : cmUnpkTfuCqiPuschMode31
8719 * Desc : This structure conveys information present in CQI reporting mode 3-1
8720 * received over PUSCH.
8729 **********************************************************/
8731 S16 cmUnpkTfuCqiPuschMode31
8733 TfuCqiPuschMode31 *param,
8737 S16 cmUnpkTfuCqiPuschMode31(param, mBuf)
8738 TfuCqiPuschMode31 *param;
8745 CMCHKUNPK(oduPackUInt8, ¶m->pmi, mBuf);
8746 for (i=0; i<TFU_MAX_TB; i++) {
8747 CMCHKUNPK(oduPackUInt8, ¶m->wideBandCqi[i], mBuf);
8749 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
8751 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
8752 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
8753 for (i=0; i<param->numSubband; i++) {
8754 CMCHKUNPK(cmUnpkTfuSubbandDlCqiInfo, ¶m->subbandCqiArr[i], mBuf);
8758 /* tfu_c_001.main_4 - Changes for MIMO feature addition */
8759 /* tfu_c_001.main_5 - Removed dependency on MIMO compile-time flag */
8766 /***********************************************************
8768 * Func : cmPkTfuDlCqiPusch
8771 * Desc : This structure conveys Downlink CQI information (mode and corresponding
8772 * CQI) received over PUSCH.
8781 **********************************************************/
8783 S16 cmPkTfuDlCqiPusch
8785 TfuDlCqiPusch *param,
8789 S16 cmPkTfuDlCqiPusch(param, mBuf)
8790 TfuDlCqiPusch *param;
8796 switch(param->mode) {
8797 case TFU_PUSCH_CQI_MODE_31:
8798 CMCHKPK(cmPkTfuCqiPuschMode31, ¶m->u.mode31Info, mBuf);
8800 case TFU_PUSCH_CQI_MODE_30:
8801 CMCHKPK(cmPkTfuCqiPuschMode30, ¶m->u.mode30Info, mBuf);
8803 case TFU_PUSCH_CQI_MODE_22:
8804 CMCHKPK(cmPkTfuCqiPuschMode22, ¶m->u.mode22Info, mBuf);
8806 case TFU_PUSCH_CQI_MODE_20:
8807 CMCHKPK(cmPkTfuCqiPuschMode20, ¶m->u.mode20Info, mBuf);
8809 case TFU_PUSCH_CQI_MODE_12:
8810 CMCHKPK(cmPkTfuCqiPuschMode12, ¶m->u.mode12Info, mBuf);
8816 CMCHKPK(cmPkTknU8, ¶m->ri, mBuf);
8817 CMCHKPK(oduUnpackUInt32, param->mode, mBuf);
8819 CMCHKPK(oduUnpackUInt8, param->cellIdx, mBuf);
8825 /***********************************************************
8827 * Func : cmUnpkTfuDlCqiPusch
8830 * Desc : This structure conveys Downlink CQI information (mode and corresponding
8831 * CQI) received over PUSCH.
8840 **********************************************************/
8842 S16 cmUnpkTfuDlCqiPusch
8844 TfuDlCqiPusch *param,
8848 S16 cmUnpkTfuDlCqiPusch(param, mBuf)
8849 TfuDlCqiPusch *param;
8855 CMCHKUNPK(oduPackUInt8, ¶m->cellIdx, mBuf);
8856 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->mode, mBuf);
8857 CMCHKUNPK(cmUnpkTknU8, ¶m->ri, mBuf);
8858 switch(param->mode) {
8859 case TFU_PUSCH_CQI_MODE_12:
8860 CMCHKUNPK(cmUnpkTfuCqiPuschMode12, ¶m->u.mode12Info, mBuf);
8862 case TFU_PUSCH_CQI_MODE_20:
8863 CMCHKUNPK(cmUnpkTfuCqiPuschMode20, ¶m->u.mode20Info, mBuf);
8865 case TFU_PUSCH_CQI_MODE_22:
8866 CMCHKUNPK(cmUnpkTfuCqiPuschMode22, ¶m->u.mode22Info, mBuf);
8868 case TFU_PUSCH_CQI_MODE_30:
8869 CMCHKUNPK(cmUnpkTfuCqiPuschMode30, ¶m->u.mode30Info, mBuf);
8871 case TFU_PUSCH_CQI_MODE_31:
8872 CMCHKUNPK(cmUnpkTfuCqiPuschMode31, ¶m->u.mode31Info, mBuf);
8881 /***********************************************************
8883 * Func : cmPkTfuDlCqiInfo
8886 * Desc : This structure contains CQI information received over PUCCH or PUSCH.
8895 **********************************************************/
8897 S16 cmPkTfuDlCqiInfo
8900 TfuDlCqiInfo *param,
8904 S16 cmPkTfuDlCqiInfo(selector, param, mBuf)
8906 TfuDlCqiInfo *param;
8915 for (idx = 0; idx < param->pusch.numOfCells; idx++)
8917 CMCHKPK(cmPkTfuDlCqiPusch, ¶m->pusch.puschCqi[idx], mBuf);
8919 CMCHKPK(oduUnpackUInt8, param->pusch.numOfCells, mBuf);
8922 CMCHKPK(cmPkTfuDlCqiPucch, ¶m->pucchCqi, mBuf);
8932 /***********************************************************
8934 * Func : cmUnpkTfuDlCqiInfo
8937 * Desc : This structure contains CQI information received over PUCCH or PUSCH.
8946 **********************************************************/
8948 S16 cmUnpkTfuDlCqiInfo
8951 TfuDlCqiInfo *param,
8955 S16 cmUnpkTfuDlCqiInfo(selector, param, mBuf)
8957 TfuDlCqiInfo *param;
8966 CMCHKUNPK(cmUnpkTfuDlCqiPucch, ¶m->pucchCqi, mBuf);
8969 CMCHKUNPK(oduPackUInt8, ¶m->pusch.numOfCells, mBuf);
8970 for (idx = param->pusch.numOfCells; idx > 0; idx--)
8972 CMCHKUNPK(cmUnpkTfuDlCqiPusch, ¶m->pusch.puschCqi[idx-1], mBuf);
8983 /***********************************************************
8985 * Func : cmPkTfuRecpReqInfo
8988 * Desc : This structure is sent from Scheduler to PHY. This includes params
8989 * needed by PHY to decode the following
8991 * 2. HARQ Feedback on PUCCH
8994 * 5. SR Indications.
8995 * This structure carries the reception information for all the scheduled UE.
9004 **********************************************************/
9006 S16 cmPkTfuRecpReqInfo
9008 TfuRecpReqInfo *param,
9012 S16 cmPkTfuRecpReqInfo(param, mBuf)
9013 TfuRecpReqInfo *param;
9019 TfuUeRecpReqInfo *tfuUeRecpReqInfo;
9022 /*ccpu00116923 - ADD - SRS present support*/
9023 /*tfu_c_001.main_7 - ADD - SRS present field inclusion */
9025 CMCHKPK(oduUnpackUInt8, param->srsPres, mBuf);
9027 count = param->ueRecpReqLst.count;
9028 node = param->ueRecpReqLst.last;
9030 tfuUeRecpReqInfo = (TfuUeRecpReqInfo *)node->node;
9032 CMCHKPK(cmPkTfuUeRecpReqInfo, tfuUeRecpReqInfo, mBuf);
9033 cmLListDelFrm(¶m->ueRecpReqLst, &tfuUeRecpReqInfo->lnk);
9034 tfuUeRecpReqInfo->lnk.node = (PTR)NULLP;
9036 CMCHKPK(oduUnpackUInt32, count, mBuf);
9037 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
9038 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
9044 /***********************************************************
9046 * Func : cmUnpkTfuRecpReqInfo
9049 * Desc : This structure is sent from Scheduler to PHY. This includes params
9050 * needed by PHY to decode the following
9052 * 2. HARQ Feedback on PUCCH
9055 * 5. SR Indications.
9056 * This structure carries the reception information for all the scheduled UE.
9065 **********************************************************/
9067 S16 cmUnpkTfuRecpReqInfo
9069 TfuRecpReqInfo *param,
9074 S16 cmUnpkTfuRecpReqInfo(param, memCp, mBuf)
9075 TfuRecpReqInfo *param;
9082 TfuUeRecpReqInfo *tfuUeRecpReqInfo;
9085 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
9086 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
9087 cmLListInit(¶m->ueRecpReqLst);
9088 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9089 for (loopCnt=0; loopCnt<count; loopCnt++) {
9090 cmGetMem((Ptr)memCp, sizeof(*tfuUeRecpReqInfo), (Ptr *)&tfuUeRecpReqInfo);
9091 CMCHKUNPK(cmUnpkTfuUeRecpReqInfo, tfuUeRecpReqInfo, mBuf);
9092 cmLListAdd2Tail(¶m->ueRecpReqLst, &tfuUeRecpReqInfo->lnk);
9093 tfuUeRecpReqInfo->lnk.node = (PTR)tfuUeRecpReqInfo;
9095 /*ccpu00116923 - ADD - SRS present support*/
9096 /*tfu_c_001.main_7 - ADD - SRS present field inclusion */
9098 CMCHKUNPK(oduPackUInt8, ¶m->srsPres, mBuf);
9105 /***********************************************************
9107 * Func : cmPkTfuPdcchInfo
9110 * Desc : This structure contains the PDCCH to be sent on PHY i.e. DCI
9111 * formats. This information is associated with an RNTI.
9120 **********************************************************/
9122 S16 cmPkTfuPdcchInfo
9124 TfuPdcchInfo *param,
9128 S16 cmPkTfuPdcchInfo(param, mBuf)
9129 TfuPdcchInfo *param;
9135 CMCHKPK(oduUnpackUInt8, param->grpId, mBuf);
9136 CMCHKPK(oduUnpackUInt8, param->sccIdx, mBuf);
9137 CMCHKPK(oduUnpackUInt8, param->sectorId, mBuf);
9138 #endif /* TFU_5GTF */
9139 CMCHKPK(cmPkTfuDciInfo, ¶m->dci, mBuf);
9140 CMCHKPK(oduUnpackUInt8, param->dciNumOfBits, mBuf);
9141 CMCHKPK(cmPkLteAggrLvl, param->aggrLvl, mBuf);
9142 CMCHKPK(oduUnpackUInt16, param->nCce, mBuf);
9144 CMCHKPK(cmPkLteRnti, param->crnti, mBuf);
9145 CMCHKPK(oduUnpackUInt8, param->isSpsRnti, mBuf);
9147 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
9153 /***********************************************************
9155 * Func : cmUnpkTfuPdcchInfo
9158 * Desc : This structure contains the PDCCH to be sent on PHY i.e. DCI
9159 * formats. This information is associated with an RNTI.
9168 **********************************************************/
9170 S16 cmUnpkTfuPdcchInfo
9172 TfuPdcchInfo *param,
9176 S16 cmUnpkTfuPdcchInfo(param, mBuf)
9177 TfuPdcchInfo *param;
9183 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
9185 CMCHKUNPK(oduPackUInt8, ¶m->isSpsRnti, mBuf);
9186 CMCHKUNPK(cmUnpkLteRnti, ¶m->crnti, mBuf);
9188 CMCHKUNPK(oduPackUInt16, ¶m->nCce, mBuf);
9189 CMCHKUNPK(cmUnpkLteAggrLvl, (U32*)¶m->aggrLvl, mBuf);
9190 CMCHKUNPK(oduPackUInt8, ¶m->dciNumOfBits, mBuf);
9191 CMCHKUNPK(cmUnpkTfuDciInfo, ¶m->dci, mBuf);
9193 CMCHKUNPK(oduPackUInt8, ¶m->sectorId, mBuf);
9194 CMCHKUNPK(oduPackUInt8, ¶m->sccIdx, mBuf);
9195 CMCHKUNPK(oduPackUInt8, ¶m->grpId, mBuf);
9196 #endif /* TFU_5GTF */
9202 /***********************************************************
9204 * Func : cmPkTfuPhichInfo
9207 * Desc : This structure contains one PHICH information. In order to locate the
9208 * resources to be used for PHICH the following information is provided along
9209 * with the feedback -
9220 **********************************************************/
9222 S16 cmPkTfuPhichInfo
9224 TfuPhichInfo *param,
9228 S16 cmPkTfuPhichInfo(param, mBuf)
9229 TfuPhichInfo *param;
9234 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
9236 CMCHKPK(oduUnpackUInt16, param->txPower, mBuf);
9239 CMCHKPK(oduUnpackUInt8, param->iPhich, mBuf);
9241 CMCHKPK(oduUnpackUInt8, param->isAck, mBuf);
9242 CMCHKPK(oduUnpackUInt8, param->nDmrs, mBuf);
9243 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
9249 /***********************************************************
9251 * Func : cmUnpkTfuPhichInfo
9254 * Desc : This structure contains one PHICH information. In order to locate the
9255 * resources to be used for PHICH the following information is provided along
9256 * with the feedback -
9267 **********************************************************/
9269 S16 cmUnpkTfuPhichInfo
9271 TfuPhichInfo *param,
9275 S16 cmUnpkTfuPhichInfo(param, mBuf)
9276 TfuPhichInfo *param;
9282 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
9283 CMCHKUNPK(oduPackUInt8, ¶m->nDmrs, mBuf);
9284 CMCHKUNPK(oduPackUInt8, ¶m->isAck, mBuf);
9285 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
9287 CMCHKUNPK(oduPackUInt8, ¶m->iPhich, mBuf);
9290 CMCHKUNPK(oduPackUInt16, ¶m->txPower, mBuf);
9297 /***********************************************************
9299 * Func : cmPkTfuCntrlReqInfo
9302 * Desc : This structure is sent from Scheduler to PHY. This includes all the
9303 * control information to be sent to the UE.
9304 * -# PDCCH Physical Downlink Control Channel
9305 * -# PHICH Physical HARQ Indicator Channel
9306 * -# PCFICH Physical Control Format Indicator Channel
9315 **********************************************************/
9317 S16 cmPkTfuCntrlReqInfo
9319 TfuCntrlReqInfo *param,
9323 S16 cmPkTfuCntrlReqInfo(param, mBuf)
9324 TfuCntrlReqInfo *param;
9329 TfuPdcchInfo *tfuPdcchInfo;
9330 TfuPhichInfo *tfuPhichInfo;
9335 count = param->dlMpdcchLst.count;
9336 node = param->dlMpdcchLst.last;
9338 tfuPdcchInfo = (TfuPdcchInfo *)node->node;
9340 CMCHKPK(cmPkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9341 cmLListDelFrm(¶m->dlMpdcchLst, &tfuPdcchInfo->lnk);
9342 tfuPdcchInfo->lnk.node = (PTR)NULLP;
9344 CMCHKPK(oduUnpackUInt32, count, mBuf);
9345 count = param->ulMpdcchLst.count;
9346 node = param->ulMpdcchLst.last;
9348 tfuPdcchInfo = (TfuPdcchInfo *)node->node;
9350 CMCHKPK(cmPkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9351 cmLListDelFrm(¶m->ulMpdcchLst, &tfuPdcchInfo->lnk);
9352 tfuPdcchInfo->lnk.node = (PTR)NULLP;
9354 CMCHKPK(oduUnpackUInt32, count, mBuf);
9356 #ifdef LTEMAC_SPS /* SPS_NEW_CHGS */
9357 CMCHKPK(oduPackBool, param->isSPSOcc, mBuf);
9359 count = param->phichLst.count;
9360 node = param->phichLst.last;
9362 tfuPhichInfo = (TfuPhichInfo *)node->node;
9364 CMCHKPK(cmPkTfuPhichInfo, tfuPhichInfo, mBuf);
9365 cmLListDelFrm(¶m->phichLst, &tfuPhichInfo->lnk);
9366 tfuPhichInfo->lnk.node = (PTR)NULLP;
9368 CMCHKPK(oduUnpackUInt32, count, mBuf);
9369 count = param->dlPdcchLst.count;
9370 node = param->dlPdcchLst.last;
9372 tfuPdcchInfo = (TfuPdcchInfo *)node->node;
9374 CMCHKPK(cmPkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9375 cmLListDelFrm(¶m->dlPdcchLst, &tfuPdcchInfo->lnk);
9376 tfuPdcchInfo->lnk.node = (PTR)NULLP;
9378 CMCHKPK(oduUnpackUInt32, count, mBuf);
9379 count = param->ulPdcchLst.count;
9380 node = param->ulPdcchLst.last;
9382 tfuPdcchInfo = (TfuPdcchInfo *)node->node;
9385 printf("ulPdcchLst count %d time[ %d %d] \n",count,param->ulTiming.sfn,param->ulTiming.subframe);
9387 CMCHKPK(cmPkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9388 cmLListDelFrm(¶m->ulPdcchLst, &tfuPdcchInfo->lnk);
9389 tfuPdcchInfo->lnk.node = (PTR)NULLP;
9391 CMCHKPK(oduUnpackUInt32, count, mBuf);
9392 CMCHKPK(oduUnpackUInt8, param->cfi, mBuf);
9393 CMCHKPK(cmPkLteTimingInfo, ¶m->dlTiming, mBuf);
9394 CMCHKPK(cmPkLteTimingInfo, ¶m->ulTiming, mBuf);
9395 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
9401 /***********************************************************
9403 * Func : cmUnpkTfuCntrlReqInfo
9406 * Desc : This structure is sent from Scheduler to PHY. This includes all the
9407 * control information to be sent to the UE.
9408 * -# PDCCH Physical Downlink Control Channel
9409 * -# PHICH Physical HARQ Indicator Channel
9410 * -# PCFICH Physical Control Format Indicator Channel
9419 **********************************************************/
9421 S16 cmUnpkTfuCntrlReqInfo
9423 TfuCntrlReqInfo *param,
9428 S16 cmUnpkTfuCntrlReqInfo(param, memCp, mBuf)
9429 TfuCntrlReqInfo *param;
9435 TfuPdcchInfo *tfuPdcchInfo;
9437 TfuPhichInfo *tfuPhichInfo;
9440 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
9441 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->ulTiming, mBuf);
9442 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->dlTiming, mBuf);
9443 CMCHKUNPK(oduPackUInt8, ¶m->cfi, mBuf);
9444 cmLListInit(¶m->ulPdcchLst);
9445 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9446 for (loopCnt=0; loopCnt<count; loopCnt++) {
9447 cmGetMem((Ptr)memCp, sizeof(*tfuPdcchInfo), (Ptr *)&tfuPdcchInfo);
9448 CMCHKUNPK(cmUnpkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9449 cmLListAdd2Tail(¶m->ulPdcchLst, &tfuPdcchInfo->lnk);
9450 tfuPdcchInfo->lnk.node = (PTR)tfuPdcchInfo;
9452 cmLListInit(¶m->dlPdcchLst);
9453 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9454 for (loopCnt=0; loopCnt<count; loopCnt++) {
9455 cmGetMem((Ptr)memCp, sizeof(*tfuPdcchInfo), (Ptr *)&tfuPdcchInfo);
9456 CMCHKUNPK(cmUnpkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9457 cmLListAdd2Tail(¶m->dlPdcchLst, &tfuPdcchInfo->lnk);
9458 tfuPdcchInfo->lnk.node = (PTR)tfuPdcchInfo;
9460 cmLListInit(¶m->phichLst);
9461 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9462 for (loopCnt=0; loopCnt<count; loopCnt++) {
9463 cmGetMem((Ptr)memCp, sizeof(*tfuPhichInfo), (Ptr *)&tfuPhichInfo);
9464 CMCHKUNPK(cmUnpkTfuPhichInfo, tfuPhichInfo, mBuf);
9465 cmLListAdd2Tail(¶m->phichLst, &tfuPhichInfo->lnk);
9466 tfuPhichInfo->lnk.node = (PTR)tfuPhichInfo;
9469 #ifdef LTEMAC_SPS /* SPS_NEW_CHGS */
9470 CMCHKUNPK(oduUnpackBool, ¶m->isSPSOcc, mBuf);
9473 cmLListInit(¶m->ulMpdcchLst);
9474 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9475 for (loopCnt=0; loopCnt<count; loopCnt++) {
9476 cmGetMem((Ptr)memCp, sizeof(*tfuPdcchInfo), (Ptr *)&tfuPdcchInfo);
9477 CMCHKUNPK(cmUnpkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9478 cmLListAdd2Tail(¶m->ulMpdcchLst, &tfuPdcchInfo->lnk);
9479 tfuPdcchInfo->lnk.node = (PTR)tfuPdcchInfo;
9481 cmLListInit(¶m->dlMpdcchLst);
9482 CMCHKUNPK(oduPackUInt32, &count, mBuf);
9483 printf("4. cmUnpkTfuCntrlReqInfo :: count %ld \n", count);
9484 for (loopCnt=0; loopCnt<count; loopCnt++) {
9485 cmGetMem((Ptr)memCp, sizeof(*tfuPdcchInfo), (Ptr *)&tfuPdcchInfo);
9486 CMCHKUNPK(cmUnpkTfuPdcchInfo, tfuPdcchInfo, mBuf);
9487 cmLListAdd2Tail(¶m->dlMpdcchLst, &tfuPdcchInfo->lnk);
9488 tfuPdcchInfo->lnk.node = (PTR)tfuPdcchInfo;
9489 printf("5. cmUnpkTfuCntrlReqInfo :: Failed \n");
9497 /***********************************************************
9499 * Func : cmPkTfuPdschDciInfo
9502 * Desc : This structure Carries the control information that would be needed
9503 * by the Physical layer to process the data to be sent on PDSCH.
9512 **********************************************************/
9514 S16 cmPkTfuPdschDciInfo
9516 TfuPdschDciInfo *param,
9520 S16 cmPkTfuPdschDciInfo(param, mBuf)
9521 TfuPdschDciInfo *param;
9527 switch(param->format) {
9529 case TFU_DCI_FORMAT_B1:
9531 if (param->u.formatB1Info.RBAssign <= 324)
9533 printf("DCI Format: [B1] RBAssign: [%d] MCS: [%d]",
9534 param->u.formatB1Info.RBAssign,
9535 param->u.formatB1Info.u.rbAssignB1Val324.mcs);
9538 CMCHKPK(cmPkTfuDciFormatB1B2Info, ¶m->u.formatB1Info, mBuf);
9540 case TFU_DCI_FORMAT_B2:
9542 if (param->u.formatB2Info.RBAssign <= 324)
9544 printf("DCI Format: [B2] RBAssign: [%d] MCS: [%d]",
9545 param->u.formatB2Info.RBAssign,
9546 param->u.formatB2Info.u.rbAssignB1Val324.mcs);
9549 CMCHKPK(cmPkTfuDciFormatB1B2Info, ¶m->u.formatB2Info, mBuf);
9551 case TFU_DCI_FORMAT_A1:
9552 CMCHKPK(cmPkTfuDciFormatA1A2Info, ¶m->u.formatA1Info, mBuf);
9554 case TFU_DCI_FORMAT_A2:
9555 CMCHKPK(cmPkTfuDciFormatA1A2Info, ¶m->u.formatA2Info, mBuf);
9559 case TFU_DCI_FORMAT_6_2:
9560 CMCHKPK(cmPkTfuDciFormat62AllocInfo, ¶m->u.format62AllocInfo, mBuf);
9562 case TFU_DCI_FORMAT_6_1A:
9563 CMCHKPK(cmPkTfuDciFormat6AAllocInfo, ¶m->u.format61AllocInfo, mBuf);
9566 case TFU_DCI_FORMAT_2A:
9567 CMCHKPK(cmPkTfuDciFormat2AAllocInfo, ¶m->u.format2AAllocInfo, mBuf);
9569 case TFU_DCI_FORMAT_2:
9570 CMCHKPK(cmPkTfuDciFormat2AllocInfo, ¶m->u.format2AllocInfo, mBuf);
9572 case TFU_DCI_FORMAT_1D:
9573 CMCHKPK(cmPkTfuDciFormat1dAllocInfo, ¶m->u.format1dAllocInfo, mBuf);
9575 case TFU_DCI_FORMAT_1C:
9576 CMCHKPK(cmPkTfuDciFormat1cInfo, ¶m->u.format1cAllocInfo, mBuf);
9578 case TFU_DCI_FORMAT_1B:
9579 CMCHKPK(cmPkTfuDciFormat1bAllocInfo, ¶m->u.format1bAllocInfo, mBuf);
9581 case TFU_DCI_FORMAT_1A:
9582 CMCHKPK(cmPkTfuDciFormat1aAllocInfo, ¶m->u.format1aAllocInfo, mBuf);
9584 case TFU_DCI_FORMAT_1:
9585 CMCHKPK(cmPkTfuDciFormat1AllocInfo, ¶m->u.format1AllocInfo, mBuf);
9590 CMCHKPK(oduUnpackUInt32, param->format, mBuf);
9596 /***********************************************************
9598 * Func : cmUnpkTfuPdschDciInfo
9601 * Desc : This structure Carries the control information that would be needed
9602 * by the Physical layer to process the data to be sent on PDSCH.
9611 **********************************************************/
9613 S16 cmUnpkTfuPdschDciInfo
9615 TfuPdschDciInfo *param,
9619 S16 cmUnpkTfuPdschDciInfo(param, mBuf)
9620 TfuPdschDciInfo *param;
9626 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->format, mBuf);
9627 switch(param->format) {
9628 case TFU_DCI_FORMAT_1:
9629 CMCHKUNPK(cmUnpkTfuDciFormat1AllocInfo, ¶m->u.format1AllocInfo, mBuf);
9631 case TFU_DCI_FORMAT_1A:
9632 CMCHKUNPK(cmUnpkTfuDciFormat1aAllocInfo, ¶m->u.format1aAllocInfo, mBuf);
9634 case TFU_DCI_FORMAT_1B:
9635 CMCHKUNPK(cmUnpkTfuDciFormat1bAllocInfo, ¶m->u.format1bAllocInfo, mBuf);
9637 case TFU_DCI_FORMAT_1C:
9638 CMCHKUNPK(cmUnpkTfuDciFormat1cInfo, ¶m->u.format1cAllocInfo, mBuf);
9640 case TFU_DCI_FORMAT_1D:
9641 CMCHKUNPK(cmUnpkTfuDciFormat1dAllocInfo, ¶m->u.format1dAllocInfo, mBuf);
9643 case TFU_DCI_FORMAT_2:
9644 CMCHKUNPK(cmUnpkTfuDciFormat2AllocInfo, ¶m->u.format2AllocInfo, mBuf);
9646 case TFU_DCI_FORMAT_2A:
9647 CMCHKUNPK(cmUnpkTfuDciFormat2AAllocInfo, ¶m->u.format2AAllocInfo, mBuf);
9650 case TFU_DCI_FORMAT_6_1A:
9651 CMCHKUNPK(cmUnpkTfuDciFormat6AAllocInfo, ¶m->u.format61AllocInfo, mBuf);
9653 case TFU_DCI_FORMAT_6_2:
9654 CMCHKUNPK(cmUnpkTfuDciFormat62AllocInfo, ¶m->u.format62AllocInfo, mBuf);
9658 case TFU_DCI_FORMAT_A1:
9659 CMCHKUNPK(cmUnpkTfuDciFormatA1A2Info, ¶m->u.formatA1Info, mBuf);
9661 case TFU_DCI_FORMAT_A2:
9662 CMCHKUNPK(cmUnpkTfuDciFormatA1A2Info, ¶m->u.formatA2Info, mBuf);
9664 case TFU_DCI_FORMAT_B1:
9665 CMCHKUNPK(cmUnpkTfuDciFormatB1B2Info, ¶m->u.formatB1Info, mBuf);
9667 case TFU_DCI_FORMAT_B2:
9668 CMCHKUNPK(cmUnpkTfuDciFormatB1B2Info, ¶m->u.formatB2Info, mBuf);
9676 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
9678 /***********************************************************
9680 * Func : cmPkTfuBfVectorInfo
9683 * Desc : This structure conveys the BeamForming Vector
9684 * Information that hold relevance to Tx Mode 7
9693 **********************************************************/
9695 S16 cmPkTfuBfVectorInfo
9697 TfuBfVectorInfo *param,
9701 S16 cmPkTfuBfVectorInfo(param, mBuf)
9702 TfuBfVectorInfo *param;
9707 for(idx=TFU_MAX_DL_SUBBAND-1;idx>=0; idx--)
9709 for (idx2=param->numPhyAnt -1; idx2 >= 0; idx2--) {
9710 CMCHKPK(oduUnpackUInt16, param->bfValue[idx2], mBuf);}
9711 CMCHKPK(oduUnpackUInt8, param->numPhyAnt, mBuf);
9712 CMCHKPK(oduUnpackUInt8, param->sbIndex, mBuf);
9717 /***********************************************************
9719 * Func : cmUnpkTfuBfVectorInfo
9722 * Desc : This structure conveys the BeamForming Vector
9723 * Information that hold relevance to Tx Mode 7
9732 **********************************************************/
9734 S16 cmUnpkTfuBfVectorInfo
9736 TfuBfVectorInfo *param,
9740 S16 cmUnpkTfuBfVectorInfo(param, mBuf)
9741 TfuBfVectorInfo *param;
9746 for(idx=0;idx<TFU_MAX_DL_SUBBAND; idx++)
9748 CMCHKUNPK(oduPackUInt8, ¶m->sbIndex, mBuf);
9749 CMCHKUNPK(oduPackUInt8, ¶m->numPhyAnt, mBuf);
9750 for (idx2=0; idx2 <param->numPhyAnt; idx2++) {
9751 CMCHKUNPK(oduPackUInt16, ¶m->bfValue[idx2], mBuf);}
9758 /***********************************************************
9760 * Func : cmPkTfuDatReqPduInfo
9763 * Desc : Pack Function for Tfu Dat Req PDU.
9772 **********************************************************/
9774 S16 cmPkTfuDatReqPduInfo
9776 TfuDatReqPduInfo *param,
9780 S16 cmPkTfuDatReqPduInfo(param, mBuf)
9781 TfuDatReqPduInfo *param;
9793 /* LTE_ADV_FLAG_REMOVED_START */
9794 CMCHKPK(oduUnpackUInt8, param->isEnbSFR, mBuf);
9795 /* LTE_ADV_FLAG_REMOVED_END */
9797 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
9799 CMCHKPK(oduUnpackUInt16, param->txPwrOffset, mBuf);
9800 if(param->transMode == TFU_UE_TM_7)
9802 CMCHKPK(cmPkTfuBfVectorInfo, param->bfVector, mBuf);
9803 CMCHKPK(oduUnpackUInt8, param->numBfVectors, mBuf);
9804 CMCHKPK(oduUnpackUInt8, param->numBfPrbPerSb, mBuf);
9806 CMCHKPK(oduUnpackUInt8, param->deltaPowOffIdx, mBuf);
9807 /* LTE_ADV_FLAG_REMOVED_START */
9808 CMCHKPK(oduUnpackUInt8, param->pa, mBuf);
9809 /* LTE_ADV_FLAG_REMOVED_END */
9810 CMCHKPK(oduUnpackUInt8, param->numLayers, mBuf);
9812 CMCHKPK(oduPackBool, param->isTApres, mBuf);
9813 CMCHKPK(cmPkTknU32, ¶m->doa, mBuf);
9814 CMCHKPK(oduUnpackUInt32, param->transMode, mBuf);
9815 CMCHKPK(cmPkTfuDlCqiPuschInfo, ¶m->puschPmiInfo, mBuf);
9816 CMCHKPK(oduUnpackUInt8, param->puschRptUsd, mBuf);
9817 for (i = 0; i < TFU_MAX_TB; i++)
9820 if (param->mBuf[i] != NULLP)
9822 tbMask = tbMask | (1 << i);
9824 #else /* L2_OPTMZ */
9825 for(lchIdx = 0; lchIdx < param->tbInfo[i].numLch; lchIdx++)
9827 for(pduIdx = 0; pduIdx < param->tbInfo[i].lchInfo[lchIdx].numPdu;
9830 if (param->tbInfo[i].lchInfo[lchIdx].mBuf[pduIdx] != NULLP)
9832 tbMask = tbMask | (1 << i);
9836 #endif /* L2_OPTMZ */
9838 /* tfu_c_001.main_2: Packing should consider nmbOfTBs.*/
9839 for (i=TFU_MAX_TB - 1; i >= 0; i--) {
9841 if (param->mBuf[i] != NULLP)
9843 CMCHKPK(cmPkBuffer, ¶m->mBuf[i], mBuf);
9846 // CMCHKPK(cmPkBuffer, ¶m->tbInfo[i].macPad, mBuf);
9847 for(lchIdx = 0; lchIdx < param->tbInfo[i].numLch; lchIdx++)
9849 for(pduIdx = 0; pduIdx < param->tbInfo[i].lchInfo[lchIdx].numPdu;
9852 CMCHKPK(cmPkBuffer, ¶m->tbInfo[i].lchInfo[lchIdx].mBuf[pduIdx],
9856 CMCHKPK(oduUnpackUInt32, param->tbInfo[i].lchInfo[lchIdx].numPdu, mBuf);
9858 CMCHKPK(oduUnpackUInt32, param->tbInfo[i].numLch, mBuf);
9859 CMCHKPK(oduUnpackUInt32, param->tbInfo[i].padSize, mBuf);
9860 CMCHKPK(cmPkBuffer, ¶m->tbInfo[i].macCes, mBuf);
9861 CMCHKPK(cmPkBuffer, ¶m->tbInfo[i].macHdr, mBuf);
9862 CMCHKPK(cmPkMsgLen, param->tbInfo[i].tbSize, mBuf);
9863 CMCHKPK(oduPackBool, param->tbInfo[i].tbPres, mBuf);
9866 CMCHKPK(oduUnpackUInt8, tbMask, mBuf);
9867 CMCHKPK(oduUnpackUInt8, param->nmbOfTBs, mBuf);
9868 CMCHKPK(cmPkTfuPdschDciInfo, ¶m->dciInfo, mBuf);
9869 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
9875 /***********************************************************
9877 * Func : cmUnpkTfuDatReqPduInfo
9880 * Desc : UnPack function for Tfu Dat req pdu .
9889 **********************************************************/
9891 S16 cmUnpkTfuDatReqPduInfo
9893 TfuDatReqPduInfo *param,
9897 S16 cmUnpkTfuDatReqPduInfo(param, mBuf)
9898 TfuDatReqPduInfo *param;
9909 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
9910 CMCHKUNPK(cmUnpkTfuPdschDciInfo, ¶m->dciInfo, mBuf);
9911 CMCHKUNPK(oduPackUInt8, ¶m->nmbOfTBs, mBuf);
9913 CMCHKUNPK(oduPackUInt8, &tbMask, mBuf);
9914 for (i=0; i<TFU_MAX_TB; i++) {
9916 if (tbMask & (1<<i))
9918 CMCHKUNPK(cmUnpkBuffer, ¶m->mBuf[i], mBuf);
9922 param->mBuf[i] = NULLP;
9925 CMCHKUNPK(oduUnpackBool, ¶m->tbInfo[i].tbPres, mBuf);
9926 CMCHKUNPK(cmUnpkMsgLen, ¶m->tbInfo[i].tbSize, mBuf);
9927 CMCHKUNPK(cmUnpkBuffer, ¶m->tbInfo[i].macHdr, mBuf);
9928 CMCHKUNPK(cmUnpkBuffer, ¶m->tbInfo[i].macCes, mBuf);
9929 CMCHKUNPK(oduPackUInt32, ¶m->tbInfo[i].padSize, mBuf);
9930 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->tbInfo[i].numLch, mBuf);
9931 for(lchIdx = 0; lchIdx < param->tbInfo[i].numLch; lchIdx++)
9933 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->tbInfo[i].lchInfo[lchIdx].numPdu,
9935 for(pduIdx = 0; pduIdx < param->tbInfo[i].lchInfo[lchIdx].numPdu;
9938 if (tbMask & (1<<i))
9940 CMCHKUNPK(cmUnpkBuffer, ¶m->tbInfo[i].lchInfo[lchIdx].\
9941 mBuf[pduIdx], mBuf);
9945 param->tbInfo[i].lchInfo[lchIdx].mBuf[pduIdx] = NULLP;
9949 //CMCHKUNPK(cmUnpkBuffer, ¶m->tbInfo[i].macPad, mBuf);
9950 #endif /* L2_OPTMZ*/
9953 CMCHKUNPK(oduPackUInt8, ¶m->puschRptUsd, mBuf);
9954 CMCHKUNPK(cmUnpkTfuDlCqiPuschInfo, ¶m->puschPmiInfo, mBuf);
9955 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->transMode, mBuf);
9956 CMCHKUNPK(cmUnpkTknU32, ¶m->doa, mBuf);
9957 CMCHKUNPK(oduUnpackBool, ¶m->isTApres, mBuf);
9958 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
9960 CMCHKUNPK(oduPackUInt8, ¶m->numLayers, mBuf);
9961 /* LTE_ADV_FLAG_REMOVED_START */
9962 CMCHKUNPK(oduPackUInt8, ¶m->pa, mBuf);
9963 /* LTE_ADV_FLAG_REMOVED_END */
9964 CMCHKUNPK(oduPackUInt8, ¶m->deltaPowOffIdx, mBuf);
9965 if(param->transMode == TFU_UE_TM_7)
9967 CMCHKUNPK(oduPackUInt8, ¶m->numBfPrbPerSb, mBuf);
9968 CMCHKUNPK(oduPackUInt8, ¶m->numBfVectors, mBuf);
9969 CMCHKUNPK(cmUnpkTfuBfVectorInfo, param->bfVector, mBuf);
9971 CMCHKUNPK(oduPackUInt16, ¶m->txPwrOffset, mBuf);
9974 /* LTE_ADV_FLAG_REMOVED_START */
9975 CMCHKUNPK(oduPackUInt8, ¶m->isEnbSFR, mBuf);
9976 /* LTE_ADV_FLAG_REMOVED_END */
9983 /***********************************************************
9985 * Func : cmPkTfuDatReqInfo
9988 * Desc : This structure contains the Data PDUs
9989 * @details This structure contains Data meant to be sent on both PBCH and
9990 * PDSCH. Control information necessary for processing of the data is sent along
10000 **********************************************************/
10002 S16 cmPkTfuDatReqInfo
10004 TfuDatReqInfo *param,
10008 S16 cmPkTfuDatReqInfo(param, mBuf)
10009 TfuDatReqInfo *param;
10016 TfuDatReqPduInfo *tfuDatReqPduInfo;
10019 count = param->pdus.count;
10020 node = param->pdus.last;
10022 tfuDatReqPduInfo = (TfuDatReqPduInfo *)node->node;
10024 CMCHKPK(cmPkTfuDatReqPduInfo, tfuDatReqPduInfo, mBuf);
10025 cmLListDelFrm(¶m->pdus, &tfuDatReqPduInfo->lnk);
10026 tfuDatReqPduInfo->lnk.node = (PTR)NULLP;
10028 CMCHKPK(oduUnpackUInt32, count, mBuf);
10029 CMCHKPK(cmPkTknBuf, ¶m->bchDat, mBuf);
10030 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
10031 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
10037 /***********************************************************
10039 * Func : cmUnpkTfuDatReqInfo
10042 * Desc : This structure contains the Data PDUs
10043 * @details This structure contains Data meant to be sent on both PBCH and
10044 * PDSCH. Control information necessary for processing of the data is sent along
10054 **********************************************************/
10056 S16 cmUnpkTfuDatReqInfo
10058 TfuDatReqInfo *param,
10063 S16 cmUnpkTfuDatReqInfo(param, memCp, mBuf)
10064 TfuDatReqInfo *param;
10070 U32 count, loopCnt;
10071 TfuDatReqPduInfo *tfuDatReqPduInfo;
10074 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
10075 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
10076 CMCHKUNPK(cmUnpkTknBuf, ¶m->bchDat, &mBuf);
10077 cmLListInit(¶m->pdus);
10078 CMCHKUNPK(oduPackUInt32, &count, mBuf);
10079 for (loopCnt=0; loopCnt<count; loopCnt++) {
10080 cmGetMem((Ptr)memCp, sizeof(*tfuDatReqPduInfo), (Ptr *)&tfuDatReqPduInfo);
10081 CMCHKUNPK(cmUnpkTfuDatReqPduInfo, tfuDatReqPduInfo, mBuf);
10082 cmLListAdd2Tail(¶m->pdus, &tfuDatReqPduInfo->lnk);
10083 tfuDatReqPduInfo->lnk.node = (PTR)tfuDatReqPduInfo;
10090 /***********************************************************
10092 * Func : cmPkTfuDatInfo
10095 * Desc : This structure contains the Data PDU and the RNTI of the UE.
10104 **********************************************************/
10112 S16 cmPkTfuDatInfo(param, mBuf)
10119 CMCHKPK(cmPkBuffer, ¶m->mBuf, mBuf);
10120 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
10126 /***********************************************************
10128 * Func : cmUnpkTfuDatInfo
10131 * Desc : This structure contains the Data PDU and the RNTI of the UE.
10140 **********************************************************/
10142 S16 cmUnpkTfuDatInfo
10148 S16 cmUnpkTfuDatInfo(param, mBuf)
10155 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
10156 CMCHKUNPK(cmUnpkBuffer, ¶m->mBuf, mBuf);
10162 /***********************************************************
10164 * Func : cmPkTfuDatIndInfo
10167 * Desc : This structure contains the Data PDUs received at Physical Layer.
10168 * @details All the PDUs received by Physical layer in one subframe are clubbed
10169 * together into a single data structure and sent to MAC for processing.
10178 **********************************************************/
10180 S16 cmPkTfuDatIndInfo
10182 TfuDatIndInfo *param,
10186 S16 cmPkTfuDatIndInfo(param, mBuf)
10187 TfuDatIndInfo *param;
10194 TfuDatInfo *tfuDatInfo;
10198 CMCHKPK(oduUnpackUInt8, param->sccIdx, mBuf);
10199 CMCHKPK(oduUnpackUInt8, param->sectorId, mBuf);
10200 #endif /* TFU_5GTF */
10201 count = param->datIndLst.count;
10202 node = param->datIndLst.last;
10204 tfuDatInfo = (TfuDatInfo *)node->node;
10206 CMCHKPK(cmPkTfuDatInfo, tfuDatInfo, mBuf);
10207 cmLListDelFrm(¶m->datIndLst, &tfuDatInfo->lnk);
10208 tfuDatInfo->lnk.node = (PTR)NULLP;
10210 CMCHKPK(oduUnpackUInt32, count, mBuf);
10211 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
10212 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
10218 /***********************************************************
10220 * Func : cmUnpkTfuDatIndInfo
10223 * Desc : This structure contains the Data PDUs received at Physical Layer.
10224 * @details All the PDUs received by Physical layer in one subframe are clubbed
10225 * together into a single data structure and sent to MAC for processing.
10234 **********************************************************/
10236 S16 cmUnpkTfuDatIndInfo
10238 TfuDatIndInfo *param,
10243 S16 cmUnpkTfuDatIndInfo(param, memCp, mBuf)
10244 TfuDatIndInfo *param;
10250 U32 count, loopCnt;
10251 TfuDatInfo *tfuDatInfo;
10254 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
10255 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
10256 cmLListInit(¶m->datIndLst);
10257 CMCHKUNPK(oduPackUInt32, &count, mBuf);
10258 for (loopCnt=0; loopCnt<count; loopCnt++) {
10259 cmGetMem((Ptr)memCp, sizeof(*tfuDatInfo), (Ptr *)&tfuDatInfo);
10260 CMCHKUNPK(cmUnpkTfuDatInfo, tfuDatInfo, mBuf);
10261 cmLListAdd2Tail(¶m->datIndLst, &tfuDatInfo->lnk);
10262 tfuDatInfo->lnk.node = (PTR)tfuDatInfo;
10265 CMCHKUNPK(oduPackUInt8, ¶m->sectorId, mBuf);
10266 CMCHKUNPK(oduPackUInt8, ¶m->sccIdx, mBuf);
10267 #endif /* TFU_5GTF */
10273 /***********************************************************
10275 * Func : cmPkTfuSrInfo
10278 * Desc : This structure contains the SR indication for a UE, identified by
10279 * the given RNTI. The structure also contains a PUCCH Delta power, that is
10280 * calculated by the physical layer, and is used by the scheduler for Power
10281 * control of the UE.
10290 **********************************************************/
10298 S16 cmPkTfuSrInfo(param, mBuf)
10305 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
10311 /***********************************************************
10313 * Func : cmUnpkTfuSrInfo
10316 * Desc : This structure contains the SR indication for a UE, identified by
10317 * the given RNTI. The structure also contains a PUCCH Delta power, that is
10318 * calculated by the physical layer, and is used by the scheduler for Power
10319 * control of the UE.
10328 **********************************************************/
10330 S16 cmUnpkTfuSrInfo
10336 S16 cmUnpkTfuSrInfo(param, mBuf)
10343 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
10349 /***********************************************************
10351 * Func : cmPkTfuSrIndInfo
10354 * Desc : This structure contains all the Scheduling Requests (SR) indications
10355 * received in a subframe.
10364 **********************************************************/
10366 S16 cmPkTfuSrIndInfo
10368 TfuSrIndInfo *param,
10372 S16 cmPkTfuSrIndInfo(param, mBuf)
10373 TfuSrIndInfo *param;
10380 TfuSrInfo *tfuSrInfo;
10383 count = param->srLst.count;
10384 node = param->srLst.last;
10386 tfuSrInfo = (TfuSrInfo *)node->node;
10388 CMCHKPK(cmPkTfuSrInfo, tfuSrInfo, mBuf);
10389 cmLListDelFrm(¶m->srLst, &tfuSrInfo->lnk);
10390 tfuSrInfo->lnk.node = (PTR)NULLP;
10392 CMCHKPK(oduUnpackUInt32, count, mBuf);
10393 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
10394 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
10400 /***********************************************************
10402 * Func : cmUnpkTfuSrIndInfo
10405 * Desc : This structure contains all the Scheduling Requests (SR) indications
10406 * received in a subframe.
10415 **********************************************************/
10417 S16 cmUnpkTfuSrIndInfo
10419 TfuSrIndInfo *param,
10424 S16 cmUnpkTfuSrIndInfo(param, memCp, mBuf)
10425 TfuSrIndInfo *param;
10431 U32 count, loopCnt;
10432 TfuSrInfo *tfuSrInfo;
10435 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
10436 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
10437 cmLListInit(¶m->srLst);
10438 CMCHKUNPK(oduPackUInt32, &count, mBuf);
10439 for (loopCnt=0; loopCnt<count; loopCnt++) {
10440 cmGetMem((Ptr)memCp, sizeof(*tfuSrInfo), (Ptr *)&tfuSrInfo);
10441 CMCHKUNPK(cmUnpkTfuSrInfo, tfuSrInfo, mBuf);
10442 cmLListAdd2Tail(¶m->srLst, &tfuSrInfo->lnk);
10443 tfuSrInfo->lnk.node = (PTR)tfuSrInfo;
10448 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
10449 /***********************************************************
10451 * Func : cmPkTfuHqInfo
10454 * Desc : This structure contains the HARQ feedback for a single UE.
10455 * @details RNTI is present to identify the UE.
10456 * For FDD a single feedback is present.
10457 * For TDD HARQ multiplexing a list of HARQ feedbacks is present.
10466 **********************************************************/
10474 S16 cmPkTfuHqInfo(param, mBuf)
10482 CMCHKPK(oduUnpackUInt8, param->isPusch, mBuf);
10483 for (i=TFU_MAX_HARQ_FDBKS-1; i >= 0; i--) {
10484 CMCHKPK(oduUnpackUInt32, param->isAck[i], mBuf);
10487 CMCHKPK(oduUnpackUInt8, param->M, mBuf);
10489 CMCHKPK(oduUnpackUInt8, param->noOfTbs, mBuf);
10490 /* ACC-TDD ccpu00130520 */
10491 CMCHKPK(oduUnpackUInt32, param->hqFdbkMode, mBuf);
10492 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
10496 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
10497 /***********************************************************
10499 * Func : cmUnpkTfuHqInfo
10502 * Desc : This structure contains the HARQ feedback for a single UE.
10503 * @details RNTI is present to identify the UE.
10504 * For FDD a single feedback is present.
10505 * For TDD HARQ multiplexing a list of HARQ feedbacks is present.
10514 **********************************************************/
10516 S16 cmUnpkTfuHqInfo
10522 S16 cmUnpkTfuHqInfo(param, mBuf)
10529 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
10530 /* ACC-TDD ccpu00130520 */
10531 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->hqFdbkMode, mBuf);
10532 CMCHKUNPK(oduPackUInt8, ¶m->noOfTbs, mBuf);
10534 CMCHKUNPK(oduPackUInt8, ¶m->M, mBuf);
10536 for (i=0; i<TFU_MAX_HARQ_FDBKS; i++) {
10537 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->isAck[i], mBuf);
10539 CMCHKUNPK(oduPackUInt8, ¶m->isPusch, mBuf);
10547 /***********************************************************
10549 * Func : cmPkTfuHqIndInfo
10552 * Desc : This structure contains a list of HARQ feedback for a number of UEs.
10553 * @details All the HARQ feedback received in the subframe are clubbed together
10554 * in this data structure and given to the scheduler for processing.
10563 **********************************************************/
10565 S16 cmPkTfuHqIndInfo
10567 TfuHqIndInfo *param,
10571 S16 cmPkTfuHqIndInfo(param, mBuf)
10572 TfuHqIndInfo *param;
10579 TfuHqInfo *tfuHqInfo;
10582 count = param->hqIndLst.count;
10583 node = param->hqIndLst.last;
10585 tfuHqInfo = (TfuHqInfo *)node->node;
10587 CMCHKPK(cmPkTfuHqInfo, tfuHqInfo, mBuf);
10588 cmLListDelFrm(¶m->hqIndLst, &tfuHqInfo->lnk);
10589 tfuHqInfo->lnk.node = (PTR)NULLP;
10591 CMCHKPK(oduUnpackUInt32, count, mBuf);
10592 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
10593 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
10599 /***********************************************************
10601 * Func : cmUnpkTfuHqIndInfo
10604 * Desc : This structure contains a list of HARQ feedback for a number of UEs.
10605 * @details All the HARQ feedback received in the subframe are clubbed together
10606 * in this data structure and given to the scheduler for processing.
10615 **********************************************************/
10617 S16 cmUnpkTfuHqIndInfo
10619 TfuHqIndInfo *param,
10624 S16 cmUnpkTfuHqIndInfo(param, memCp, mBuf)
10625 TfuHqIndInfo *param;
10631 U32 count, loopCnt;
10632 TfuHqInfo *tfuHqInfo;
10635 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
10636 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
10637 cmLListInit(¶m->hqIndLst);
10638 CMCHKUNPK(oduPackUInt32, &count, mBuf);
10639 for (loopCnt=0; loopCnt<count; loopCnt++) {
10640 cmGetMem((Ptr)memCp, sizeof(*tfuHqInfo), (Ptr *)&tfuHqInfo);
10641 CMCHKUNPK(cmUnpkTfuHqInfo, tfuHqInfo, mBuf);
10642 cmLListAdd2Tail(¶m->hqIndLst, &tfuHqInfo->lnk);
10643 tfuHqInfo->lnk.node = (PTR)tfuHqInfo;
10650 /***********************************************************
10652 * Func : cmPkTfuUlCqiInfo
10655 * Desc : This structure conveys the Uplink CQI information for a single subband.
10664 **********************************************************/
10666 S16 cmPkTfuUlCqiInfo
10668 TfuUlCqiInfo *param,
10672 S16 cmPkTfuUlCqiInfo(param, mBuf)
10673 TfuUlCqiInfo *param;
10679 CMCHKPK(cmPkTfuSubbandCqiInfo, ¶m->subbandCqi, mBuf);
10685 /***********************************************************
10687 * Func : cmUnpkTfuUlCqiInfo
10690 * Desc : This structure conveys the Uplink CQI information for a single subband.
10699 **********************************************************/
10701 S16 cmUnpkTfuUlCqiInfo
10703 TfuUlCqiInfo *param,
10707 S16 cmUnpkTfuUlCqiInfo(param, mBuf)
10708 TfuUlCqiInfo *param;
10714 CMCHKUNPK(cmUnpkTfuSubbandCqiInfo, ¶m->subbandCqi, mBuf);
10720 /***********************************************************
10722 * Func : cmPkTfuUlCqiRpt
10725 * Desc : This structure contains the UL CQI estimated by the physical layer.
10726 * @details The report could be wideband CQI or subBand CQI or both.
10735 **********************************************************/
10737 S16 cmPkTfuUlCqiRpt
10739 TfuUlCqiRpt *param,
10743 S16 cmPkTfuUlCqiRpt(param, mBuf)
10744 TfuUlCqiRpt *param;
10751 for (i=TFU_MAX_UL_SUBBAND-1; i >= 0; i--) {
10752 CMCHKPK(cmPkTfuUlCqiInfo, ¶m->ulCqiInfoArr[i], mBuf);
10754 CMCHKPK(oduUnpackUInt8, param->numSubband, mBuf);
10755 CMCHKPK(oduUnpackUInt8, param->wideCqi, mBuf);
10756 CMCHKPK(oduUnpackUInt8, param->isTxPort0, mBuf);
10757 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
10763 /***********************************************************
10765 * Func : cmUnpkTfuUlCqiRpt
10768 * Desc : This structure contains the UL CQI estimated by the physical layer.
10769 * @details The report could be wideband CQI or subBand CQI or both.
10778 **********************************************************/
10780 S16 cmUnpkTfuUlCqiRpt
10782 TfuUlCqiRpt *param,
10786 S16 cmUnpkTfuUlCqiRpt(param, mBuf)
10787 TfuUlCqiRpt *param;
10794 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
10795 CMCHKUNPK(oduPackUInt8, ¶m->isTxPort0, mBuf);
10796 CMCHKUNPK(oduPackUInt8, ¶m->wideCqi, mBuf);
10797 CMCHKUNPK(oduPackUInt8, ¶m->numSubband, mBuf);
10798 for (i=0; i<TFU_MAX_UL_SUBBAND; i++) {
10799 CMCHKUNPK(cmUnpkTfuUlCqiInfo, ¶m->ulCqiInfoArr[i], mBuf);
10806 /***********************************************************
10808 * Func : cmPkTfuUlCqiIndInfo
10811 * Desc : This structure conveys the Uplink CQI information.
10812 * @details Uplink CQI is calculated by the physical layer, and is this
10813 * information is provided to the scheduler.
10814 * This data structure clubs together the UL CQI estimates for all the UEs that
10815 * have been scheduled in the subframe for uplink transmission.
10824 **********************************************************/
10826 S16 cmPkTfuUlCqiIndInfo
10828 TfuUlCqiIndInfo *param,
10832 S16 cmPkTfuUlCqiIndInfo(param, mBuf)
10833 TfuUlCqiIndInfo *param;
10840 TfuUlCqiRpt *tfuUlCqiRpt;
10843 count = param->ulCqiRpt.count;
10844 node = param->ulCqiRpt.last;
10846 tfuUlCqiRpt = (TfuUlCqiRpt *)node->node;
10848 CMCHKPK(cmPkTfuUlCqiRpt, tfuUlCqiRpt, mBuf);
10849 cmLListDelFrm(¶m->ulCqiRpt, &tfuUlCqiRpt->lnk);
10850 tfuUlCqiRpt->lnk.node = (PTR)NULLP;
10852 CMCHKPK(oduUnpackUInt32, count, mBuf);
10853 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
10854 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
10860 /***********************************************************
10862 * Func : cmUnpkTfuUlCqiIndInfo
10865 * Desc : This structure conveys the Uplink CQI information.
10866 * @details Uplink CQI is calculated by the physical layer, and is this
10867 * information is provided to the scheduler.
10868 * This data structure clubs together the UL CQI estimates for all the UEs that
10869 * have been scheduled in the subframe for uplink transmission.
10878 **********************************************************/
10880 S16 cmUnpkTfuUlCqiIndInfo
10882 TfuUlCqiIndInfo *param,
10887 S16 cmUnpkTfuUlCqiIndInfo(param, memCp, mBuf)
10888 TfuUlCqiIndInfo *param;
10894 U32 count, loopCnt;
10895 TfuUlCqiRpt *tfuUlCqiRpt;
10898 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
10899 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
10900 cmLListInit(¶m->ulCqiRpt);
10901 CMCHKUNPK(oduPackUInt32, &count, mBuf);
10902 for (loopCnt=0; loopCnt<count; loopCnt++) {
10903 cmGetMem((Ptr)memCp, sizeof(*tfuUlCqiRpt), (Ptr *)&tfuUlCqiRpt);
10904 CMCHKUNPK(cmUnpkTfuUlCqiRpt, tfuUlCqiRpt, mBuf);
10905 cmLListAdd2Tail(¶m->ulCqiRpt, &tfuUlCqiRpt->lnk);
10906 tfuUlCqiRpt->lnk.node = (PTR)tfuUlCqiRpt;
10914 /***********************************************************
10916 * Func : cmPkTfuDlCqiRpt
10919 * Desc : This structure contains the DL CQI report for a single UE.
10920 * @details The report could either be reported on PUCCH or PUSCH, a flag
10921 * conveys this information.
10930 **********************************************************/
10932 S16 cmPkTfuDlCqiRpt
10934 TfuDlCqiRpt *param,
10938 S16 cmPkTfuDlCqiRpt(param, mBuf)
10939 TfuDlCqiRpt *param;
10945 if (cmPkTfuDlCqiInfo(param->isPucchInfo, ¶m->dlCqiInfo, mBuf) != ROK)
10947 CMCHKPK(oduUnpackUInt8, param->isPucchInfo, mBuf);
10948 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
10954 /***********************************************************
10956 * Func : cmUnpkTfuDlCqiRpt
10959 * Desc : This structure contains the DL CQI report for a single UE.
10960 * @details The report could either be reported on PUCCH or PUSCH, a flag
10961 * conveys this information.
10970 **********************************************************/
10972 S16 cmUnpkTfuDlCqiRpt
10974 TfuDlCqiRpt *param,
10978 S16 cmUnpkTfuDlCqiRpt(param, mBuf)
10979 TfuDlCqiRpt *param;
10985 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
10986 CMCHKUNPK(oduPackUInt8, ¶m->isPucchInfo, mBuf);
10987 if (cmUnpkTfuDlCqiInfo (param->isPucchInfo, ¶m->dlCqiInfo, mBuf) != ROK)
10994 /***********************************************************
10996 * Func : cmPkTfuDlCqiIndInfo
10999 * Desc : This structure contains a list of Downlink CQI reports transmitted by
11001 * @details This structure clubs together DL CQI reports for a number of UEs.
11010 **********************************************************/
11012 S16 cmPkTfuDlCqiIndInfo
11014 TfuDlCqiIndInfo *param,
11018 S16 cmPkTfuDlCqiIndInfo(param, mBuf)
11019 TfuDlCqiIndInfo *param;
11026 TfuDlCqiRpt *tfuDlCqiRpt;
11029 count = param->dlCqiRptsLst.count;
11030 node = param->dlCqiRptsLst.last;
11032 tfuDlCqiRpt = (TfuDlCqiRpt *)node->node;
11034 CMCHKPK(cmPkTfuDlCqiRpt, tfuDlCqiRpt, mBuf);
11035 cmLListDelFrm(¶m->dlCqiRptsLst, &tfuDlCqiRpt->lnk);
11036 tfuDlCqiRpt->lnk.node = (PTR)NULLP;
11038 CMCHKPK(oduUnpackUInt32, count, mBuf);
11039 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
11040 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
11046 /***********************************************************
11048 * Func : cmUnpkTfuDlCqiIndInfo
11051 * Desc : This structure contains a list of Downlink CQI reports transmitted by
11053 * @details This structure clubs together DL CQI reports for a number of UEs.
11062 **********************************************************/
11064 S16 cmUnpkTfuDlCqiIndInfo
11066 TfuDlCqiIndInfo *param,
11071 S16 cmUnpkTfuDlCqiIndInfo(param, memCp, mBuf)
11072 TfuDlCqiIndInfo *param;
11078 U32 count, loopCnt;
11079 TfuDlCqiRpt *tfuDlCqiRpt;
11082 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
11083 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
11084 cmLListInit(¶m->dlCqiRptsLst);
11085 CMCHKUNPK(oduPackUInt32, &count, mBuf);
11086 for (loopCnt=0; loopCnt<count; loopCnt++) {
11087 cmGetMem((Ptr)memCp, sizeof(*tfuDlCqiRpt), (Ptr *)&tfuDlCqiRpt);
11088 CMCHKUNPK(cmUnpkTfuDlCqiRpt, tfuDlCqiRpt, mBuf);
11089 cmLListAdd2Tail(¶m->dlCqiRptsLst, &tfuDlCqiRpt->lnk);
11090 tfuDlCqiRpt->lnk.node = (PTR)tfuDlCqiRpt;
11097 /***********************************************************
11099 * Func : cmPkTfuCrcInfo
11102 * Desc : This structure contains the CRC indication for a single
11112 **********************************************************/
11120 S16 cmPkTfuCrcInfo(param, mBuf)
11127 CMCHKPK(cmPkTknU8, ¶m->rv, mBuf);
11128 CMCHKPK(oduUnpackUInt8, param->isFailure, mBuf);
11129 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
11135 /***********************************************************
11137 * Func : cmUnpkTfuCrcInfo
11140 * Desc : This structure contains the CRC indication for a single
11150 **********************************************************/
11152 S16 cmUnpkTfuCrcInfo
11158 S16 cmUnpkTfuCrcInfo(param, mBuf)
11165 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
11166 CMCHKUNPK(oduPackUInt8, ¶m->isFailure, mBuf);
11167 CMCHKUNPK(cmUnpkTknU8, ¶m->rv, mBuf);
11173 /***********************************************************
11175 * Func : cmPkTfuCrcIndInfo
11178 * Desc : This structure contains information that is passed as a part of the
11179 * CRC Indication from PHY to MAC.
11180 * @details This structure clubs together all the CRC indications for
11181 * a single subframe and conveys this information to the scheduler.
11190 **********************************************************/
11192 S16 cmPkTfuCrcIndInfo
11194 TfuCrcIndInfo *param,
11198 S16 cmPkTfuCrcIndInfo(param, mBuf)
11199 TfuCrcIndInfo *param;
11206 TfuCrcInfo *tfuCrcIndInfo;
11210 CMCHKPK(oduUnpackUInt8, param->sccIdx, mBuf);
11211 CMCHKPK(oduUnpackUInt8, param->sectorId, mBuf);
11212 #endif /* TFU_5GTF */
11213 count = param->crcLst.count;
11214 node = param->crcLst.last;
11216 tfuCrcIndInfo = (TfuCrcInfo *)node->node;
11218 CMCHKPK(cmPkTfuCrcInfo, tfuCrcIndInfo, mBuf);
11219 cmLListDelFrm(¶m->crcLst, &tfuCrcIndInfo->lnk);
11220 tfuCrcIndInfo->lnk.node = (PTR)NULLP;
11222 CMCHKPK(oduUnpackUInt32, count, mBuf);
11223 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
11224 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
11230 /***********************************************************
11232 * Func : cmUnpkTfuCrcIndInfo
11235 * Desc : This structure contains information that is passed as a part of the
11236 * CRC Indication from PHY to MAC.
11237 * @details This structure clubs together all the CRC indications for
11238 * a single subframe and conveys this information to the scheduler.
11247 **********************************************************/
11249 S16 cmUnpkTfuCrcIndInfo
11251 TfuCrcIndInfo *param,
11256 S16 cmUnpkTfuCrcIndInfo(param, memCp, mBuf)
11257 TfuCrcIndInfo *param;
11263 U32 count, loopCnt;
11264 TfuCrcInfo *tfuCrcIndInfo;
11267 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
11268 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
11269 cmLListInit(¶m->crcLst);
11270 CMCHKUNPK(oduPackUInt32, &count, mBuf);
11271 for (loopCnt=0; loopCnt<count; loopCnt++) {
11272 cmGetMem((Ptr)memCp, sizeof(*tfuCrcIndInfo), (Ptr *)&tfuCrcIndInfo);
11273 CMCHKUNPK(cmUnpkTfuCrcInfo, tfuCrcIndInfo, mBuf);
11274 cmLListAdd2Tail(¶m->crcLst, &tfuCrcIndInfo->lnk);
11275 tfuCrcIndInfo->lnk.node = (PTR)tfuCrcIndInfo;
11278 CMCHKUNPK(oduPackUInt8, ¶m->sectorId, mBuf);
11279 CMCHKUNPK(oduPackUInt8, ¶m->sccIdx, mBuf);
11280 #endif /* TFU_5GTF */
11286 /***********************************************************
11288 * Func : cmPkTfuTimingAdvInfo
11291 * Desc : This structure contains the timing advance information for a single
11301 **********************************************************/
11303 S16 cmPkTfuTimingAdvInfo
11305 TfuTimingAdvInfo *param,
11309 S16 cmPkTfuTimingAdvInfo(param, mBuf)
11310 TfuTimingAdvInfo *param;
11316 CMCHKPK(oduUnpackUInt8, param->timingAdv, mBuf);
11317 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
11323 /***********************************************************
11325 * Func : cmUnpkTfuTimingAdvInfo
11328 * Desc : This structure contains the timing advance information for a single
11338 **********************************************************/
11340 S16 cmUnpkTfuTimingAdvInfo
11342 TfuTimingAdvInfo *param,
11346 S16 cmUnpkTfuTimingAdvInfo(param, mBuf)
11347 TfuTimingAdvInfo *param;
11353 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
11354 CMCHKUNPK(oduPackUInt8, ¶m->timingAdv, mBuf);
11360 /***********************************************************
11362 * Func : cmPkTfuTimingAdvIndInfo
11365 * Desc : This structure contains information that is passed as part of the Timing
11366 * Advance indication from PHY to MAC.
11367 * @details This structure clubs together timing advances for a number of UEs.
11376 **********************************************************/
11378 S16 cmPkTfuTimingAdvIndInfo
11380 TfuTimingAdvIndInfo *param,
11384 S16 cmPkTfuTimingAdvIndInfo(param, mBuf)
11385 TfuTimingAdvIndInfo *param;
11392 TfuTimingAdvInfo *tfuTimingAdvInfo;
11395 count = param->timingAdvLst.count;
11396 node = param->timingAdvLst.last;
11398 tfuTimingAdvInfo = (TfuTimingAdvInfo *)node->node;
11400 CMCHKPK(cmPkTfuTimingAdvInfo, tfuTimingAdvInfo, mBuf);
11401 cmLListDelFrm(¶m->timingAdvLst, &tfuTimingAdvInfo->lnk);
11402 tfuTimingAdvInfo->lnk.node = (PTR)NULLP;
11404 CMCHKPK(oduUnpackUInt32, count, mBuf);
11405 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
11406 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
11412 /***********************************************************
11414 * Func : cmUnpkTfuTimingAdvIndInfo
11417 * Desc : This structure contains information that is passed as part of the Timing
11418 * Advance indication from PHY to MAC.
11419 * @details This structure clubs together timing advances for a number of UEs.
11428 **********************************************************/
11430 S16 cmUnpkTfuTimingAdvIndInfo
11432 TfuTimingAdvIndInfo *param,
11437 S16 cmUnpkTfuTimingAdvIndInfo(param, memCp, mBuf)
11438 TfuTimingAdvIndInfo *param;
11444 U32 count, loopCnt;
11445 TfuTimingAdvInfo *tfuTimingAdvInfo;
11448 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
11449 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
11450 cmLListInit(¶m->timingAdvLst);
11451 CMCHKUNPK(oduPackUInt32, &count, mBuf);
11452 for (loopCnt=0; loopCnt<count; loopCnt++) {
11453 cmGetMem((Ptr)memCp, sizeof(*tfuTimingAdvInfo), (Ptr *)&tfuTimingAdvInfo);
11454 CMCHKUNPK(cmUnpkTfuTimingAdvInfo, tfuTimingAdvInfo, mBuf);
11455 cmLListAdd2Tail(¶m->timingAdvLst, &tfuTimingAdvInfo->lnk);
11456 tfuTimingAdvInfo->lnk.node = (PTR)tfuTimingAdvInfo;
11462 /***********************************************************
11464 * Func : cmPkTfuTtiCellInfo
11467 * Desc : This structure contains information that is
11468 * passed as a part of the TTI indication sent
11469 * from CL to MAC and SCH
11478 **********************************************************/
11480 S16 cmPkTfuTtiCellInfo
11482 TfuTtiCellInfo *param,
11486 S16 cmPkTfuTtiCellInfo(param, mBuf)
11487 TfuTtiCellInfo *param;
11493 CMCHKPK(oduUnpackUInt8, param->ulBlankSf, mBuf);
11494 CMCHKPK(oduUnpackUInt8, param->dlBlankSf, mBuf);
11495 CMCHKPK(oduUnpackUInt8, param->schTickDelta, mBuf);
11496 CMCHKPK(oduPackBool, param->isDummyTti, mBuf);
11497 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
11498 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
11503 /***********************************************************
11505 * Func : cmPkTfuTtiIndInfo
11508 * Desc : This structure contains information that is passed as a part of the TTI
11509 * indication sent from PHY to MAC.
11518 **********************************************************/
11520 S16 cmPkTfuTtiIndInfo
11522 TfuTtiIndInfo *param,
11526 S16 cmPkTfuTtiIndInfo(param, mBuf)
11527 TfuTtiIndInfo *param;
11535 for (i=(param->numCells-1); i >= 0; i--) {
11536 CMCHKPK(cmPkTfuTtiCellInfo, ¶m->cells[i], mBuf);
11538 CMCHKPK(oduUnpackUInt8, param->numCells, mBuf);
11544 /***********************************************************
11546 * Func : cmUnpkTfuTtiCellInfo
11549 * Desc : This structure contains information that is
11550 * passed as a part of the TTI indication sent
11551 * from CL to MAC and SCH
11560 **********************************************************/
11562 S16 cmUnpkTfuTtiCellInfo
11564 TfuTtiCellInfo *param,
11568 S16 cmUnpkTfuTtiCellInfo(param, mBuf)
11569 TfuTtiCellInfo *param;
11575 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
11576 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
11577 CMCHKUNPK(oduUnpackBool, ¶m->isDummyTti, mBuf);
11578 CMCHKUNPK(oduPackUInt8, ¶m->schTickDelta, mBuf);
11579 CMCHKUNPK(oduPackUInt8, ¶m->dlBlankSf, mBuf);
11580 CMCHKUNPK(oduPackUInt8, ¶m->ulBlankSf, mBuf);
11586 /***********************************************************
11588 * Func : cmPkTfuRaReqInfo
11591 * Desc : This structure contains the information for a single Random Access Request.
11592 * @details The information present in this structure is for a single preamble.
11593 * Associated with each preamble are fields that the physical layer calculates
11594 * based on the reception of the Random Access Request. These are the following
11595 * -# Timing Advance
11597 * -# CQI (optional).
11606 **********************************************************/
11608 S16 cmPkTfuRaReqInfo
11610 TfuRaReqInfo *param,
11614 S16 cmPkTfuRaReqInfo(param, mBuf)
11615 TfuRaReqInfo *param;
11621 CMCHKPK(oduUnpackUInt8, param->cqiIdx, mBuf);
11622 CMCHKPK(oduUnpackUInt8, param->cqiPres, mBuf);
11623 CMCHKPK(oduUnpackUInt8, param->tpc, mBuf);
11624 CMCHKPK(oduUnpackUInt16, param->ta, mBuf);
11625 CMCHKPK(oduUnpackUInt8, param->rapId, mBuf);
11631 /***********************************************************
11633 * Func : cmUnpkTfuRaReqInfo
11636 * Desc : This structure contains the information for a single Random Access Request.
11637 * @details The information present in this structure is for a single preamble.
11638 * Associated with each preamble are fields that the physical layer calculates
11639 * based on the reception of the Random Access Request. These are the following
11640 * -# Timing Advance
11642 * -# CQI (optional).
11651 **********************************************************/
11653 S16 cmUnpkTfuRaReqInfo
11655 TfuRaReqInfo *param,
11659 S16 cmUnpkTfuRaReqInfo(param, mBuf)
11660 TfuRaReqInfo *param;
11666 CMCHKUNPK(oduPackUInt8, ¶m->rapId, mBuf);
11667 CMCHKUNPK(oduPackUInt16, ¶m->ta, mBuf);
11668 CMCHKUNPK(oduPackUInt8, ¶m->tpc, mBuf);
11669 CMCHKUNPK(oduPackUInt8, ¶m->cqiPres, mBuf);
11670 CMCHKUNPK(oduPackUInt8, ¶m->cqiIdx, mBuf);
11676 /***********************************************************
11678 * Func : cmPkTfuRachInfo
11681 * Desc : This structure contains RACH request information for a single
11691 **********************************************************/
11693 S16 cmPkTfuRachInfo
11696 TfuRachInfo *param,
11700 S16 cmPkTfuRachInfo(memCp, param, mBuf)
11702 TfuRachInfo *param;
11709 for (i= (param->numRaReqInfo - 1); i >= 0; i--) {
11710 CMCHKPK(cmPkTfuRaReqInfo, &(param->raReqInfoArr[i]), mBuf);
11713 CMCHKPK(oduUnpackUInt16, param->nPwrFactor, mBuf);
11714 CMCHKPK(oduUnpackUInt8, param->nPRACHSymbIndex, mBuf);
11715 CMCHKPK(oduUnpackUInt8, param->nf1Value, mBuf);
11716 CMCHKPK(oduUnpackUInt8, param->nCyclicShift, mBuf);
11717 CMCHKPK(oduUnpackUInt8, param->nRootSeq, mBuf);
11718 CMCHKPK(oduUnpackUInt8, param->nPRACHConfiguration, mBuf);
11719 CMCHKPK(oduUnpackUInt8, param->nPreambleFormat, mBuf);
11721 CMCHKPK(oduUnpackUInt8, param->numRaReqInfo, mBuf);
11722 CMCHKPK(cmPkLteRnti, param->raRnti, mBuf);
11728 /***********************************************************
11730 * Func : cmUnpkTfuRachInfo
11733 * Desc : This structure contains RACH request information for a single
11743 **********************************************************/
11745 S16 cmUnpkTfuRachInfo
11748 TfuRachInfo *param,
11752 S16 cmUnpkTfuRachInfo(memCp, param, mBuf)
11754 TfuRachInfo *param;
11761 CMCHKUNPK(cmUnpkLteRnti, ¶m->raRnti, mBuf);
11762 CMCHKUNPK(oduPackUInt8, ¶m->numRaReqInfo, mBuf);
11764 CMCHKUNPK(oduUnpackUInt8, param->nPreambleFormat, mBuf);
11765 CMCHKUNPK(oduUnpackUInt8, param->nPRACHConfiguration, mBuf);
11766 CMCHKUNPK(oduUnpackUInt8, param->nRootSeq, mBuf);
11767 CMCHKUNPK(oduUnpackUInt8, param->nCyclicShift, mBuf);
11768 CMCHKUNPK(oduUnpackUInt8, param->nf1Value, mBuf);
11769 CMCHKUNPK(oduUnpackUInt8, param->nPRACHSymbIndex, mBuf);
11770 CMCHKUNPK(oduUnpackUInt16, param->nPwrFactor, mBuf);
11772 if (cmGetMem (&(memCp), (sizeof(TfuRaReqInfo) * param->numRaReqInfo),
11773 (Ptr *)¶m->raReqInfoArr) != ROK)
11777 for (i=0; i<param->numRaReqInfo; i++) {
11778 CMCHKUNPK(cmUnpkTfuRaReqInfo, ¶m->raReqInfoArr[i], mBuf);
11785 /***********************************************************
11787 * Func : cmPkTfuRaReqIndInfo
11790 * Desc : This structure contains the list of Random Access Requests received in a
11792 * @details Random Access Request is associated with a RA-RNTI, which remains
11793 * common for all the Random access requests within a subframe. This structure
11794 * thus carries the RA-RNTI and a list of Random Access Request information.
11795 * This information consists of the following
11796 * -# preamble-id - this corresponds to the Index of the Preamble choosen by the
11798 * -# Timing Advance - this corresponds to the timing adjustment that the UE
11799 * needs to be uplink synchronized. This value is calculated by physical layer.
11800 * -# tpc - this is the power control command that the physical layer calculates
11801 * from the received RA request. This value is transmitted in the RA Response
11803 * -# CQI - this is the Channel quality index of the UL channel estimated by the
11804 * physical layer. This aids MAC in the scheduling of this UE.
11813 **********************************************************/
11815 S16 cmPkTfuRaReqIndInfo
11817 TfuRaReqIndInfo *param,
11821 S16 cmPkTfuRaReqIndInfo(param, mBuf)
11822 TfuRaReqIndInfo *param;
11829 for (i= (param->nmbOfRaRnti-1); i >= 0; i--)
11831 if (ROK != cmPkTfuRachInfo(param->memCp,
11832 &(param->rachInfoArr[i]), mBuf))
11837 CMCHKPK(oduUnpackUInt8, param->nmbOfRaRnti, mBuf);
11838 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
11839 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
11845 /***********************************************************
11847 * Func : cmUnpkTfuRaReqIndInfo
11850 * Desc : This structure contains the list of Random Access Requests received in a
11852 * @details Random Access Request is associated with a RA-RNTI, which remains
11853 * common for all the Random access requests within a subframe. This structure
11854 * thus carries the RA-RNTI and a list of Random Access Request information.
11855 * This information consists of the following
11856 * -# preamble-id - this corresponds to the Index of the Preamble choosen by the
11858 * -# Timing Advance - this corresponds to the timing adjustment that the UE
11859 * needs to be uplink synchronized. This value is calculated by physical layer.
11860 * -# tpc - this is the power control command that the physical layer calculates
11861 * from the received RA request. This value is transmitted in the RA Response
11863 * -# CQI - this is the Channel quality index of the UL channel estimated by the
11864 * physical layer. This aids MAC in the scheduling of this UE.
11873 **********************************************************/
11875 S16 cmUnpkTfuRaReqIndInfo
11877 TfuRaReqIndInfo *param,
11881 S16 cmUnpkTfuRaReqIndInfo(param, mBuf)
11882 TfuRaReqIndInfo *param;
11889 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
11890 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
11891 CMCHKUNPK(oduPackUInt8, ¶m->nmbOfRaRnti, mBuf);
11892 if (cmGetMem (&(param->memCp), (sizeof(TfuRachInfo) * param->nmbOfRaRnti),
11893 (Ptr *)¶m->rachInfoArr) != ROK)
11897 for (i=0; i<param->nmbOfRaRnti; i++)
11899 if (ROK != cmUnpkTfuRachInfo(param->memCp, ¶m->rachInfoArr[i], mBuf))
11909 /***********************************************************
11911 * Func : cmPkTfuPucchDeltaPwr
11914 * Desc : This structure contains PUCCH Delta power for a single UE.
11923 **********************************************************/
11925 S16 cmPkTfuPucchDeltaPwrInfo
11927 TfuPucchDeltaPwr *param,
11931 S16 cmPkTfuPucchDeltaPwrInfo(param, mBuf)
11932 TfuPucchDeltaPwr *param;
11938 CMCHKPK(SPkS8, param->pucchDeltaPwr, mBuf);
11939 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
11945 /***********************************************************
11947 * Func : cmUnpkTfuPucchDeltaPwr
11950 * Desc : This structure contains PUCCH Delta power for a single UE.
11959 **********************************************************/
11961 S16 cmUnpkTfuPucchDeltaPwrInfo
11963 TfuPucchDeltaPwr *param,
11967 S16 cmUnpkTfuPucchDeltaPwrInfo(param, mBuf)
11968 TfuPucchDeltaPwr *param;
11974 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
11975 CMCHKUNPK(SUnpkS8, ¶m->pucchDeltaPwr, mBuf);
11981 /***********************************************************
11983 * Func : cmPkTfuPucchDeltaPwrIndInfo
11986 * Desc : This structure contains information that is passed as a part of the
11987 * PUCCH Delta power indication from PHY to SCH.
11988 * @details This structure clubs together PUCCH Delta power values for a number
11998 **********************************************************/
12000 S16 cmPkTfuPucchDeltaPwrIndInfo
12002 TfuPucchDeltaPwrIndInfo *param,
12006 S16 cmPkTfuPucchDeltaPwrIndInfo(param, mBuf)
12007 TfuPucchDeltaPwrIndInfo *param;
12014 TfuPucchDeltaPwr *tfuPucchDeltaPwr;
12017 count = param->pucchDeltaPwrLst.count;
12018 node = param->pucchDeltaPwrLst.last;
12020 tfuPucchDeltaPwr = (TfuPucchDeltaPwr *)node->node;
12022 CMCHKPK(cmPkTfuPucchDeltaPwrInfo, tfuPucchDeltaPwr, mBuf);
12023 cmLListDelFrm(¶m->pucchDeltaPwrLst, &tfuPucchDeltaPwr->lnk);
12024 tfuPucchDeltaPwr->lnk.node = (PTR)NULLP;
12026 CMCHKPK(oduUnpackUInt32, count, mBuf);
12027 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
12028 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
12034 /***********************************************************
12036 * Func : cmUnpkTfuPucchDeltaPwrIndInfo
12039 * Desc : This structure contains information that is passed as a part of the
12040 * PUCCH Delta power indication from PHY to SCH.
12041 * @details This structure clubs together PUCCH Delta power values for a number
12051 **********************************************************/
12053 S16 cmUnpkTfuPucchDeltaPwrIndInfo
12055 TfuPucchDeltaPwrIndInfo *param,
12060 S16 cmUnpkTfuPucchDeltaPwrIndInfo(param, memCp, mBuf)
12061 TfuPucchDeltaPwrIndInfo *param;
12067 U32 count, loopCnt;
12068 TfuPucchDeltaPwr *tfuPucchDeltaPwr;
12071 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
12072 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
12073 cmLListInit(¶m->pucchDeltaPwrLst);
12074 CMCHKUNPK(oduPackUInt32, &count, mBuf);
12075 for (loopCnt=0; loopCnt<count; loopCnt++) {
12076 cmGetMem((Ptr)memCp, sizeof(*tfuPucchDeltaPwr), (Ptr *)&tfuPucchDeltaPwr);
12077 CMCHKUNPK(cmUnpkTfuPucchDeltaPwrInfo, tfuPucchDeltaPwr, mBuf);
12078 cmLListAdd2Tail(¶m->pucchDeltaPwrLst, &tfuPucchDeltaPwr->lnk);
12079 tfuPucchDeltaPwr->lnk.node = (PTR)tfuPucchDeltaPwr;
12091 S16 cmPkBuffer(param, mBuf)
12097 if (SFndLenMsg(*param, &msgLen) != ROK)
12099 if (SCatMsg(mBuf, *param, M1M2) != ROK)
12101 TFU_FREE_MSG(*param);
12103 CMCHKPK(cmPkMsgLen, msgLen, mBuf);
12113 S16 cmUnpkBuffer(param, mBuf)
12118 MsgLen msgLen=0, totalMsgLen=0;
12119 CMCHKUNPK(cmUnpkMsgLen, &msgLen, mBuf);
12120 if (SFndLenMsg(mBuf, &totalMsgLen) != ROK)
12122 if (SSegMsg(mBuf, totalMsgLen-msgLen, param) != ROK)
12128 /***********************************************************
12130 * Func : cmPkTfuDoaInd
12133 * Desc : This API is used to indicate DOA(Direction Of Arrival)
12134 * identifier for one or more UEs.
12135 * It carries a DOA for each UE.
12136 * @param pst Pointer to the post structure.
12137 * @param suId SAP ID of the service user.
12138 * @param doaInd Pointer to the TfuDoaIndInfo structure.
12139 * @return ROK/RFAILED
12148 **********************************************************/
12154 TfuDoaIndInfo * doaInd
12157 S16 cmPkTfuDoaInd(pst, suId, doaInd)
12160 TfuDoaIndInfo * doaInd;
12163 Buffer *mBuf = NULLP;
12165 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
12166 #if (ERRCLASS & ERRCLS_ADD_RES)
12167 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
12168 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
12169 (ErrVal)ETFU125, (ErrVal)0, "Packing failed");
12171 SPutSBuf(pst->region, pst->pool, (Data *)doaInd, sizeof(TfuDoaIndInfo));
12174 cmPkTfuDoaIndInfo(doaInd, mBuf);
12175 if (SPkS16(suId, mBuf) != ROK) {
12176 #if (ERRCLASS & ERRCLS_ADD_RES)
12177 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
12178 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
12179 (ErrVal)ETFU126, (ErrVal)0, "Packing failed");
12181 TFU_FREE_MEM(doaInd);
12182 TFU_FREE_MSG(mBuf);
12185 TFU_FREE_MEM(doaInd);
12186 pst->event = (Event) EVTTFUDOAIND;
12187 return (SPstTsk(pst,mBuf));
12191 /***********************************************************
12193 * Func : cmUnpkTfuDoaInd
12196 * Desc : This API is used to indicate DOA(Direction Of Arrival)
12197 * identifier for one or more UEs.
12198 * It carries a DOA for each UE.
12199 * @param pst Pointer to the post structure.
12200 * @param suId SAP ID of the service user.
12201 * @param doaInd Pointer to the TfuDoaIndInfo structure.
12202 * @return ROK/RFAILED
12211 **********************************************************/
12213 S16 cmUnpkTfuDoaInd
12220 S16 cmUnpkTfuDoaInd(func, pst, mBuf)
12227 TfuDoaIndInfo *doaInd;
12230 if (SUnpkS16(&suId, mBuf) != ROK) {
12231 TFU_FREE_MSG(mBuf);
12232 #if (ERRCLASS & ERRCLS_ADD_RES)
12233 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
12234 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
12235 (ErrVal)ETFU127, (ErrVal)0, "Packing failed");
12241 sMem.region = pst->region;
12242 sMem.pool = pst->pool;
12243 if ((cmAllocEvnt(sizeof(TfuDoaIndInfo), TFU_BLKSZ, &sMem, (Ptr *)&doaInd)) != ROK) {
12244 #if (ERRCLASS & ERRCLS_ADD_RES)
12245 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
12246 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
12247 (ErrVal)ETFU128, (ErrVal)0, "Packing failed");
12249 TFU_FREE_MSG(mBuf);
12254 cmUnpkTfuDoaIndInfo(doaInd, (Ptr)&doaInd->memCp, mBuf);
12255 TFU_FREE_MSG(mBuf);
12256 return ((*func)(pst, suId, doaInd));
12261 /***********************************************************
12263 * Func : cmPkTfuDciFormatTbInfo
12266 * Desc : This structure contains the TB level DCI signalling
12267 * parameters in case of DCI formats 2 and 2A
12276 **********************************************************/
12278 S16 cmPkTfuDciFormatTbInfo
12280 TfuDciFormatTbInfo *param,
12284 S16 cmPkTfuDciFormatTbInfo(param, mBuf)
12285 TfuDciFormatTbInfo *param;
12291 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
12292 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
12293 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
12299 /***********************************************************
12301 * Func : cmUnpkTfuDciFormatTbInfo
12304 * Desc : This structure contains the TB level DCI signalling
12305 * parameters in case of DCI formats 2 and 2A
12314 **********************************************************/
12316 S16 cmUnpkTfuDciFormatTbInfo
12318 TfuDciFormatTbInfo *param,
12322 S16 cmUnpkTfuDciFormatTbInfo(param, mBuf)
12323 TfuDciFormatTbInfo *param;
12329 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
12330 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
12331 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
12337 /***********************************************************
12339 * Func : cmPkTfuSubbandDlCqiInfo
12342 * Desc : This structure is used to convey the subbannd CQI reported.
12351 **********************************************************/
12353 S16 cmPkTfuSubbandDlCqiInfo
12355 TfuSubbandDlCqiInfo *param,
12359 S16 cmPkTfuSubbandDlCqiInfo(param, mBuf)
12360 TfuSubbandDlCqiInfo *param;
12367 for (i=TFU_MAX_TB-1; i >= 0; i--) {
12368 CMCHKPK(oduUnpackUInt8, param->cqiIdx[i], mBuf);
12370 CMCHKPK(cmPkTfuSubbandInfo, ¶m->subband, mBuf);
12376 /***********************************************************
12378 * Func : cmUnpkTfuSubbandDlCqiInfo
12381 * Desc : This structure is used to convey the subbannd CQI reported.
12390 **********************************************************/
12392 S16 cmUnpkTfuSubbandDlCqiInfo
12394 TfuSubbandDlCqiInfo *param,
12398 S16 cmUnpkTfuSubbandDlCqiInfo(param, mBuf)
12399 TfuSubbandDlCqiInfo *param;
12406 CMCHKUNPK(cmUnpkTfuSubbandInfo, ¶m->subband, mBuf);
12407 for (i=0; i<TFU_MAX_TB; i++) {
12408 CMCHKUNPK(oduPackUInt8, ¶m->cqiIdx[i], mBuf);
12413 /***********************************************************
12415 * Func : cmPkTfuDlCqiPuschInfo
12418 * Desc : This structure conveys explicitly the PMI information in case
12419 * of PUSCH feedback usage in scheduling. Applicable for TM 4,5,6.
12428 **********************************************************/
12430 S16 cmPkTfuDlCqiPuschInfo
12432 TfuDlCqiPuschInfo *param,
12436 S16 cmPkTfuDlCqiPuschInfo(param, mBuf)
12437 TfuDlCqiPuschInfo *param;
12443 switch(param->mode) {
12444 case TFU_PUSCH_CQI_MODE_31:
12445 CMCHKPK(cmPkTfuCqiPuschMode31, ¶m->u.mode31Info, mBuf);
12447 case TFU_PUSCH_CQI_MODE_22:
12448 CMCHKPK(cmPkTfuCqiPuschMode22, ¶m->u.mode22Info, mBuf);
12450 case TFU_PUSCH_CQI_MODE_12:
12451 CMCHKPK(cmPkTfuCqiPuschMode12, ¶m->u.mode12Info, mBuf);
12456 CMCHKPK(oduUnpackUInt32, param->mode, mBuf);
12462 /***********************************************************
12464 * Func : cmUnpkTfuDlCqiPuschInfo
12467 * Desc : This structure conveys explicitly the PMI information in case
12468 * of PUSCH feedback usage in scheduling. Applicable for TM 4,5,6.
12477 **********************************************************/
12479 S16 cmUnpkTfuDlCqiPuschInfo
12481 TfuDlCqiPuschInfo *param,
12485 S16 cmUnpkTfuDlCqiPuschInfo(param, mBuf)
12486 TfuDlCqiPuschInfo *param;
12492 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->mode, mBuf);
12493 switch(param->mode) {
12494 case TFU_PUSCH_CQI_MODE_12:
12495 CMCHKUNPK(cmUnpkTfuCqiPuschMode12, ¶m->u.mode12Info, mBuf);
12497 case TFU_PUSCH_CQI_MODE_22:
12498 CMCHKUNPK(cmUnpkTfuCqiPuschMode22, ¶m->u.mode22Info, mBuf);
12500 case TFU_PUSCH_CQI_MODE_31:
12501 CMCHKUNPK(cmUnpkTfuCqiPuschMode31, ¶m->u.mode31Info, mBuf);
12509 /***********************************************************
12511 * Func : cmPkTfuDoaRpt
12514 * Desc : This structure contains the DOA estimated by the physical layer.
12515 * @details DOA for a given UE.
12524 **********************************************************/
12532 S16 cmPkTfuDoaRpt(param, mBuf)
12539 CMCHKPK(oduUnpackUInt32, param->doa, mBuf);
12540 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
12546 /***********************************************************
12548 * Func : cmUnpkTfuDoaRpt
12551 * Desc : This structure contains the DOA estimated by the physical layer.
12552 * @details DOA for a given UE.
12561 **********************************************************/
12563 S16 cmUnpkTfuDoaRpt
12569 S16 cmUnpkTfuDoaRpt(param, mBuf)
12576 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
12577 CMCHKUNPK(oduPackUInt32, ¶m->doa, mBuf);
12583 /***********************************************************
12585 * Func : cmPkTfuDoaIndInfo
12588 * Desc : This structure conveys the DOA(Direction Of Arrival) indicator.
12589 * @details DOA is calculated by the physical layer, and this
12590 * information is provided to the scheduler.
12591 * This data structure clubs together the DOAs for all the UEs
12592 * calculated by PHY in this subframe.
12601 **********************************************************/
12603 S16 cmPkTfuDoaIndInfo
12605 TfuDoaIndInfo *param,
12609 S16 cmPkTfuDoaIndInfo(param, mBuf)
12610 TfuDoaIndInfo *param;
12617 TfuDoaRpt *tfuDoaRpt;
12619 count = param->doaRpt.count;
12620 node = param->doaRpt.last;
12622 tfuDoaRpt = (TfuDoaRpt *)node->node;
12624 CMCHKPK(cmPkTfuDoaRpt, tfuDoaRpt, mBuf);
12625 cmLListDelFrm(¶m->doaRpt, &tfuDoaRpt->lnk);
12626 tfuDoaRpt->lnk.node = (PTR)NULLP;
12628 CMCHKPK(oduUnpackUInt32, count, mBuf);
12629 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
12635 /***********************************************************
12637 * Func : cmUnpkTfuDoaIndInfo
12640 * Desc : This structure conveys the DOA(Direction Of Arrival) indicator.
12641 * @details DOA is calculated by the physical layer, and this
12642 * information is provided to the scheduler.
12643 * This data structure clubs together the DOAs for all the UEs
12644 * calculated by PHY in this subframe.
12653 **********************************************************/
12655 S16 cmUnpkTfuDoaIndInfo
12657 TfuDoaIndInfo *param,
12662 S16 cmUnpkTfuDoaIndInfo(param, memCp, mBuf)
12663 TfuDoaIndInfo *param;
12669 U32 count, loopCnt;
12670 TfuDoaRpt *tfuDoaRpt;
12672 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
12673 cmLListInit(¶m->doaRpt);
12674 CMCHKUNPK(oduPackUInt32, &count, mBuf);
12675 for (loopCnt=0; loopCnt<count; loopCnt++) {
12676 cmGetMem((Ptr)memCp, sizeof(*tfuDoaRpt), (Ptr *)&tfuDoaRpt);
12677 CMCHKUNPK(cmUnpkTfuDoaRpt, tfuDoaRpt, mBuf);
12678 cmLListAdd2Tail(¶m->doaRpt, &tfuDoaRpt->lnk);
12679 tfuDoaRpt->lnk.node = (PTR)tfuDoaRpt;
12685 /* tfu_c_001.main_7. Added changes of TFU_UPGRADE */
12689 /***********************************************************
12691 * Func : cmPkTfuSrsRpt
12694 * Desc : This structure conveys the Uplink SRS indication of a UE.
12695 * @details Uplink SRS from each UE is received by the physical layer, and this
12696 * information is provided to the scheduler.
12705 **********************************************************/
12713 S16 cmPkTfuSrsRpt(param, mBuf)
12721 CMCHKPK(oduUnpackUInt8, param->wideCqi, mBuf);
12722 CMCHKPK(oduUnpackUInt8, param->wideCqiPres, mBuf);
12723 for (i=TFU_MAX_UL_RB-1; i >= 0; i--) {
12724 CMCHKPK(oduUnpackUInt8, param->snr[i], mBuf);
12726 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
12727 CMCHKPK(oduUnpackUInt8, param->numRbs, mBuf);
12728 CMCHKPK(oduUnpackUInt16, param->ta, mBuf);
12729 CMCHKPK(oduUnpackUInt16, param->dopEst, mBuf);
12730 CMCHKPK(cmPkLteRnti, param->ueId, mBuf);
12736 /***********************************************************
12738 * Func : cmUnpkTfuSrsRpt
12741 * Desc : This structure conveys the Uplink SRS indication of a UE.
12742 * @details Uplink SRS from each UE is received by the physical layer, and this
12743 * information is provided to the scheduler.
12752 **********************************************************/
12754 S16 cmUnpkTfuSrsRpt
12760 S16 cmUnpkTfuSrsRpt(param, mBuf)
12768 CMCHKUNPK(cmUnpkLteRnti, ¶m->ueId, mBuf);
12769 CMCHKUNPK(oduPackUInt16, ¶m->dopEst, mBuf);
12770 CMCHKUNPK(oduPackUInt16, ¶m->ta, mBuf);
12771 CMCHKUNPK(oduPackUInt8, ¶m->numRbs, mBuf);
12772 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
12773 for (i=0; i<TFU_MAX_UL_RB; i++) {
12774 CMCHKUNPK(oduPackUInt8, ¶m->snr[i], mBuf);
12776 CMCHKUNPK(oduPackUInt8, ¶m->wideCqiPres, mBuf);
12777 CMCHKUNPK(oduPackUInt8, ¶m->wideCqi, mBuf);
12783 /***********************************************************
12785 * Func : cmPkTfuSrsIndInfo
12788 * Desc : This structure conveys the Uplink SRS indication.
12789 * @details Uplink SRS is received by the physical layer, and this
12790 * information is provided to the scheduler.
12791 * This data structure clubs together the UL SRS indications of all the UEs
12801 **********************************************************/
12803 S16 cmPkTfuSrsIndInfo
12805 TfuSrsIndInfo *param,
12809 S16 cmPkTfuSrsIndInfo(param, mBuf)
12810 TfuSrsIndInfo *param;
12817 TfuSrsRpt *tfuSrsRpt;
12820 count = param->srsRpt.count;
12821 node = param->srsRpt.last;
12823 tfuSrsRpt = (TfuSrsRpt *)node->node;
12825 CMCHKPK(cmPkTfuSrsRpt, tfuSrsRpt, mBuf);
12826 cmLListDelFrm(¶m->srsRpt, &tfuSrsRpt->lnk);
12827 tfuSrsRpt->lnk.node = (PTR)NULLP;
12829 CMCHKPK(oduUnpackUInt32, count, mBuf);
12830 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
12831 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
12837 /***********************************************************
12839 * Func : cmUnpkTfuSrsIndInfo
12842 * Desc : This structure conveys the Uplink SRS indication.
12843 * @details Uplink SRS is received by the physical layer, and this
12844 * information is provided to the scheduler.
12845 * This data structure clubs together the UL SRS indications of all the UEs
12855 **********************************************************/
12857 S16 cmUnpkTfuSrsIndInfo
12859 TfuSrsIndInfo *param,
12864 S16 cmUnpkTfuSrsIndInfo(param, memCp, mBuf)
12865 TfuSrsIndInfo *param;
12871 U32 count, loopCnt;
12872 TfuSrsRpt *tfuSrsRpt;
12875 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
12876 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
12877 cmLListInit(¶m->srsRpt);
12878 CMCHKUNPK(oduPackUInt32, &count, mBuf);
12879 for (loopCnt=0; loopCnt<count; loopCnt++) {
12880 cmGetMem((Ptr)memCp, sizeof(*tfuSrsRpt), (Ptr *)&tfuSrsRpt);
12881 CMCHKUNPK(cmUnpkTfuSrsRpt, tfuSrsRpt, mBuf);
12882 cmLListAdd2Tail(¶m->srsRpt, &tfuSrsRpt->lnk);
12883 tfuSrsRpt->lnk.node = (PTR)tfuSrsRpt;
12890 /***********************************************************
12892 * Func : cmPkTfuRawCqiRpt
12895 * Desc : This structure contains the Raw CQI information i.e. the CQI report
12896 * as transmitted by the UE.
12897 * @details These bits shall be interpretted by MAC to derive the following
12910 **********************************************************/
12912 S16 cmPkTfuRawCqiRpt
12914 TfuRawCqiRpt *param,
12918 S16 cmPkTfuRawCqiRpt(param, mBuf)
12919 TfuRawCqiRpt *param;
12925 CMCHKPK(oduUnpackUInt32, param->uciPayload, mBuf);
12928 for (i=CM_LTE_MAX_CELLS-1; i >= 0; i--) {
12929 CMCHKPK(oduUnpackUInt8, param->ri[i], mBuf);
12931 for (i=TFU_MAX_CQI_BYTES-1; i >= 0; i--) {
12932 CMCHKPK(oduUnpackUInt8, param->cqiBits[i], mBuf);
12935 CMCHKPK(oduUnpackUInt8, param->numBits, mBuf);
12936 CMCHKPK(cmPkLteRnti, param->crnti, mBuf);
12942 /***********************************************************
12944 * Func : cmUnpkTfuRawCqiRpt
12947 * Desc : This structure contains the Raw CQI information i.e. the CQI report
12948 * as transmitted by the UE.
12949 * @details These bits shall be interpretted by MAC to derive the following
12962 **********************************************************/
12964 S16 cmUnpkTfuRawCqiRpt
12966 TfuRawCqiRpt *param,
12970 S16 cmUnpkTfuRawCqiRpt(param, mBuf)
12971 TfuRawCqiRpt *param;
12977 CMCHKUNPK(cmUnpkLteRnti, ¶m->crnti, mBuf);
12978 CMCHKUNPK(oduPackUInt8, ¶m->numBits, mBuf);
12981 for (i=0; i<TFU_MAX_CQI_BYTES; i++) {
12982 CMCHKUNPK(oduPackUInt8, ¶m->cqiBits[i], mBuf);
12984 for (i=0; i<CM_LTE_MAX_CELLS; i++) {
12985 CMCHKUNPK(oduPackUInt8, ¶m->ri[i], mBuf);
12988 CMCHKUNPK(oduPackUInt32, ¶m->uciPayload, mBuf);
12995 /***********************************************************
12997 * Func : cmPkTfuRawCqiIndInfo
13000 * Desc : This structure contains the Raw CQI reports received for the
13001 * transmitting UEs in a single subframe.
13002 * @details Raw CQI corresponds to the actual bits transmitted by the UE, whose
13003 * interpretation is upto the MAC layer.
13012 **********************************************************/
13014 S16 cmPkTfuRawCqiIndInfo
13016 TfuRawCqiIndInfo *param,
13020 S16 cmPkTfuRawCqiIndInfo(param, mBuf)
13021 TfuRawCqiIndInfo *param;
13027 TfuRawCqiRpt *tfuRawCqiRpt;
13031 count = param->rawCqiRpt.count;
13032 node = param->rawCqiRpt.last;
13034 tfuRawCqiRpt = (TfuRawCqiRpt *)node->node;
13036 CMCHKPK(cmPkTfuRawCqiRpt, tfuRawCqiRpt, mBuf);
13037 cmLListDelFrm(¶m->rawCqiRpt, &tfuRawCqiRpt->lnk);
13038 tfuRawCqiRpt->lnk.node = (PTR)NULLP;
13040 CMCHKPK(oduUnpackUInt32, count, mBuf);
13041 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
13042 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
13048 /***********************************************************
13050 * Func : cmUnpkTfuRawCqiIndInfo
13053 * Desc : This structure contains the Raw CQI reports received for the
13054 * transmitting UEs in a single subframe.
13055 * @details Raw CQI corresponds to the actual bits transmitted by the UE, whose
13056 * interpretation is upto the MAC layer.
13065 **********************************************************/
13067 S16 cmUnpkTfuRawCqiIndInfo
13069 TfuRawCqiIndInfo *param,
13074 S16 cmUnpkTfuRawCqiIndInfo(param, memCp, mBuf)
13075 TfuRawCqiIndInfo *param;
13081 U32 count, loopCnt;
13082 TfuRawCqiRpt *tfuRawCqiRpt;
13085 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
13086 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
13087 cmLListInit(¶m->rawCqiRpt);
13088 CMCHKUNPK(oduPackUInt32, &count, mBuf);
13089 for (loopCnt=0; loopCnt<count; loopCnt++) {
13090 cmGetMem((Ptr)memCp, sizeof(*tfuRawCqiRpt), (Ptr *)&tfuRawCqiRpt);
13091 CMCHKUNPK(cmUnpkTfuRawCqiRpt, tfuRawCqiRpt, mBuf);
13092 cmLListAdd2Tail(¶m->rawCqiRpt, &tfuRawCqiRpt->lnk);
13093 tfuRawCqiRpt->lnk.node = (PTR)tfuRawCqiRpt;
13104 /***********************************************************
13106 * Func : cmPkTfuUePucchHqRecpInfo
13109 * Desc : This structure is sent from scheduler to PHY in order to request the
13110 * reception of harq information on PUCCH.
13119 **********************************************************/
13121 S16 cmPkTfuUePucchHqRecpInfo
13123 TfuUePucchHqRecpInfo *param,
13127 S16 cmPkTfuUePucchHqRecpInfo(param, mBuf)
13128 TfuUePucchHqRecpInfo *param;
13135 CMCHKPK(oduUnpackUInt8, param->a, mBuf);
13136 for (i=TFU_MAX_HQ_RES-1; i >= 0; i--) {
13137 CMCHKPK(oduUnpackUInt16, param->hqRes[i], mBuf);
13139 CMCHKPK(oduUnpackUInt8, param->pucchResCnt, mBuf);
13140 CMCHKPK(oduUnpackUInt8, param->hqSz, mBuf);
13141 CMCHKPK(oduUnpackUInt32, param->hqFdbkMode, mBuf);
13147 /***********************************************************
13149 * Func : cmUnpkTfuUePucchHqRecpInfo
13152 * Desc : This structure is sent from scheduler to PHY in order to request the
13153 * reception of harq information on PUCCH.
13162 **********************************************************/
13164 S16 cmUnpkTfuUePucchHqRecpInfo
13166 TfuUePucchHqRecpInfo *param,
13170 S16 cmUnpkTfuUePucchHqRecpInfo(param, mBuf)
13171 TfuUePucchHqRecpInfo *param;
13178 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->hqFdbkMode, mBuf);
13179 CMCHKUNPK(oduPackUInt8, ¶m->hqSz, mBuf);
13180 CMCHKUNPK(oduPackUInt8, ¶m->pucchResCnt, mBuf);
13181 for (i=0; i<TFU_MAX_HQ_RES; i++) {
13182 CMCHKUNPK(oduPackUInt16, ¶m->hqRes[i], mBuf);
13184 CMCHKUNPK(oduPackUInt8, ¶m->a, mBuf);
13193 #ifndef TFU_TDD /* else of TFU_TDD */
13195 #ifndef TFU_TDD /* else of TFU_TDD */
13198 /***********************************************************
13200 * Func : cmPkTfuUePucchHqRecpInfo
13203 * Desc : This structure is sent from scheduler to PHY in order to request the
13204 * reception of harq information on PUCCH.
13213 **********************************************************/
13215 S16 cmPkTfuUePucchHqRecpInfo
13217 TfuUePucchHqRecpInfo *param,
13221 S16 cmPkTfuUePucchHqRecpInfo(param, mBuf)
13222 TfuUePucchHqRecpInfo *param;
13229 for (idx=(TFU_MAX_HQ_RES-1); idx >= 0; idx--) {
13230 CMCHKPK(oduUnpackUInt16, param->hqRes[idx], mBuf);
13233 CMCHKPK(oduUnpackUInt16, param->hqRes[0], mBuf);
13235 CMCHKPK(oduUnpackUInt8, param->pucchResCnt, mBuf);
13236 CMCHKPK(oduUnpackUInt8, param->hqSz, mBuf);
13237 CMCHKPK(oduUnpackUInt32, param->hqFdbkMode, mBuf);
13244 /***********************************************************
13246 * Func : cmUnpkTfuUePucchHqRecpInfo
13249 * Desc : This structure is sent from scheduler to PHY in order to request the
13250 * reception of harq information on PUCCH.
13259 **********************************************************/
13261 S16 cmUnpkTfuUePucchHqRecpInfo
13263 TfuUePucchHqRecpInfo *param,
13267 S16 cmUnpkTfuUePucchHqRecpInfo(param, mBuf)
13268 TfuUePucchHqRecpInfo *param;
13273 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->hqFdbkMode, mBuf);
13274 CMCHKUNPK(oduPackUInt8, ¶m->hqSz, mBuf);
13275 CMCHKUNPK(oduPackUInt8, ¶m->pucchResCnt, mBuf);
13278 for (idx=0; idx<TFU_MAX_HQ_RES; idx++) {
13279 CMCHKUNPK(oduPackUInt16, ¶m->hqRes[idx], mBuf);
13282 CMCHKUNPK(oduPackUInt16, ¶m->hqRes[0], mBuf);
13294 /***********************************************************
13296 * Func : cmPkTfuUePucchSrRecpInfo
13299 * Desc : This structure is sent from scheduler to PHY in order to request the
13300 * reception of SR information on PUCCH.
13309 **********************************************************/
13311 S16 cmPkTfuUePucchSrRecpInfo
13313 TfuUePucchSrRecpInfo *param,
13317 S16 cmPkTfuUePucchSrRecpInfo(param, mBuf)
13318 TfuUePucchSrRecpInfo *param;
13324 CMCHKPK(oduUnpackUInt16, param->n1PucchIdx, mBuf);
13330 /***********************************************************
13332 * Func : cmUnpkTfuUePucchSrRecpInfo
13335 * Desc : This structure is sent from scheduler to PHY in order to request the
13336 * reception of SR information on PUCCH.
13345 **********************************************************/
13347 S16 cmUnpkTfuUePucchSrRecpInfo
13349 TfuUePucchSrRecpInfo *param,
13353 S16 cmUnpkTfuUePucchSrRecpInfo(param, mBuf)
13354 TfuUePucchSrRecpInfo *param;
13360 CMCHKUNPK(oduPackUInt16, ¶m->n1PucchIdx, mBuf);
13366 /***********************************************************
13368 * Func : cmPkTfuUePucchCqiRecpInfo
13371 * Desc : This structure is sent from scheduler to PHY in order to request the
13372 * reception of CQI information on PUCCH.
13381 **********************************************************/
13383 S16 cmPkTfuUePucchCqiRecpInfo
13385 TfuUePucchCqiRecpInfo *param,
13389 S16 cmPkTfuUePucchCqiRecpInfo(param, mBuf)
13390 TfuUePucchCqiRecpInfo *param;
13396 CMCHKPK(oduUnpackUInt8, param->cqiPmiSz, mBuf);
13397 CMCHKPK(oduUnpackUInt16, param->n2PucchIdx, mBuf);
13403 /***********************************************************
13405 * Func : cmUnpkTfuUePucchCqiRecpInfo
13408 * Desc : This structure is sent from scheduler to PHY in order to request the
13409 * reception of CQI information on PUCCH.
13418 **********************************************************/
13420 S16 cmUnpkTfuUePucchCqiRecpInfo
13422 TfuUePucchCqiRecpInfo *param,
13426 S16 cmUnpkTfuUePucchCqiRecpInfo(param, mBuf)
13427 TfuUePucchCqiRecpInfo *param;
13433 CMCHKUNPK(oduPackUInt16, ¶m->n2PucchIdx, mBuf);
13434 CMCHKUNPK(oduPackUInt8, ¶m->cqiPmiSz, mBuf);
13440 /***********************************************************
13442 * Func : cmPkTfuUePucchSrsRecpInfo
13445 * Desc : This structure is sent from scheduler to PHY in order to request the
13446 * reception of SRS information on PUCCH.
13455 **********************************************************/
13457 S16 cmPkTfuUePucchSrsRecpInfo
13459 TfuUePucchSrsRecpInfo *param,
13463 S16 cmPkTfuUePucchSrsRecpInfo(param, mBuf)
13464 TfuUePucchSrsRecpInfo *param;
13470 CMCHKPK(oduUnpackUInt32, param->srsCyclicShft, mBuf);
13471 CMCHKPK(oduUnpackUInt16, param->srsCfgIdx, mBuf);
13472 CMCHKPK(oduUnpackUInt8, param->transComb, mBuf);
13473 CMCHKPK(oduUnpackUInt32, param->srsHopBw, mBuf);
13474 CMCHKPK(oduUnpackUInt8, param->nRrc, mBuf);
13475 CMCHKPK(oduUnpackUInt32, param->srsBw, mBuf);
13481 S16 cmPkTfuUePucchUciRecpInfo
13483 TfuUePucchUciRecpInfo *param,
13487 S16 cmPkTfuUePucchUciRecpInfo(param, mBuf)
13488 TfuUePucchUciRecpInfo *param;
13494 CMCHKPK(oduUnpackUInt8, param->SCID, mBuf);
13495 CMCHKPK(oduUnpackUInt8, param->pucchIndex, mBuf);
13496 CMCHKPK(oduUnpackUInt8, param->numBits, mBuf);
13502 /***********************************************************
13504 * Func : cmUnpkTfuUePucchSrsRecpInfo
13507 * Desc : This structure is sent from scheduler to PHY in order to request the
13508 * reception of SRS information on PUCCH.
13517 **********************************************************/
13519 S16 cmUnpkTfuUePucchSrsRecpInfo
13521 TfuUePucchSrsRecpInfo *param,
13525 S16 cmUnpkTfuUePucchSrsRecpInfo(param, mBuf)
13526 TfuUePucchSrsRecpInfo *param;
13532 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->srsBw, mBuf);
13533 CMCHKUNPK(oduPackUInt8, ¶m->nRrc, mBuf);
13534 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->srsHopBw, mBuf);
13535 CMCHKUNPK(oduPackUInt8, ¶m->transComb, mBuf);
13536 CMCHKUNPK(oduPackUInt16, ¶m->srsCfgIdx, mBuf);
13537 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->srsCyclicShft, mBuf);
13542 /***********************************************************
13544 * Func : cmPkTfuUePucchBsiBriRecpInfo
13547 * Desc : This structure is sent from scheduler to PHY in order to request the
13548 * reception of BSI_BRI information on PUCCH.
13557 **********************************************************/
13559 S16 cmPkTfuUePucchBsiBriRecpInfo
13561 TfuUePucchBsiBriRecpInfo *param,
13565 S16 cmPkTfuUePucchBsiBriRecpInfo(param, mBuf)
13566 TfuUePucchBsiBriRecpInfo *param;
13572 CMCHKPK(oduUnpackUInt8, param->briRpt, mBuf);
13573 CMCHKPK(oduUnpackUInt8, param->bsiRpt, mBuf);
13574 CMCHKPK(oduUnpackUInt8, param->SCID, mBuf);
13575 CMCHKPK(oduUnpackUInt8, param->pucchIndex, mBuf);
13576 CMCHKPK(oduUnpackUInt8, param->puschFlag, mBuf);
13580 /***********************************************************
13582 * Func : cmUnpkTfuUePucchBsiBriRecpInfo
13585 * Desc : This structure is sent from scheduler to PHY in order to request the
13586 * reception of BSI_BRI information on PUCCH.
13595 **********************************************************/
13597 S16 cmUnpkTfuUePucchBsiBriRecpInfo
13599 TfuUePucchBsiBriRecpInfo *param,
13603 S16 cmUnpkTfuUePucchBsiBriRecpInfo(param, mBuf)
13604 TfuUePucchBsiBriRecpInfo *param;
13610 CMCHKUNPK(oduPackUInt8, ¶m->puschFlag, mBuf);
13611 CMCHKUNPK(oduPackUInt8, ¶m->pucchIndex, mBuf);
13612 CMCHKUNPK(oduPackUInt8, ¶m->SCID, mBuf);
13613 CMCHKUNPK(oduPackUInt8, ¶m->bsiRpt, mBuf);
13614 CMCHKUNPK(oduPackUInt8, ¶m->briRpt, mBuf);
13621 S16 cmUnpkTfuUePucchUciRecpInfo
13623 TfuUePucchUciRecpInfo *param,
13627 S16 cmUnpkTfuUePucchUciRecpInfo(param, mBuf)
13628 TfuUePucchUciRecpInfo *param;
13634 CMCHKUNPK(oduPackUInt8, ¶m->numBits, mBuf);
13635 CMCHKUNPK(oduPackUInt8, ¶m->pucchIndex, mBuf);
13636 CMCHKUNPK(oduPackUInt8, ¶m->SCID, mBuf);
13643 /***********************************************************
13645 * Func : cmPkTfuUePucchRecpReq
13648 * Desc : This structure is sent from scheduler to PHY in order to request the
13649 * reception of UCI on PUCCH. This may contain the following:
13669 **********************************************************/
13671 S16 cmPkTfuUePucchRecpReq
13673 TfuUePucchRecpReq *param,
13677 S16 cmPkTfuUePucchRecpReq(param, mBuf)
13678 TfuUePucchRecpReq *param;
13685 CMCHKPK(cmPkTfuUePucchBsiBriRecpInfo, ¶m->bsiBriInfo, mBuf);
13686 CMCHKPK(cmPkTfuUePucchUciRecpInfo, ¶m->uciPduInfo, mBuf);
13687 #endif /* TFU_5GTF */
13688 CMCHKPK(cmPkTfuUePucchSrsRecpInfo, ¶m->srsInfo, mBuf);
13689 CMCHKPK(cmPkTfuUePucchHqRecpInfo, ¶m->hqInfo, mBuf);
13690 CMCHKPK(cmPkTfuUePucchSrRecpInfo, ¶m->srInfo, mBuf);
13691 CMCHKPK(cmPkTfuUePucchCqiRecpInfo, ¶m->cqiInfo, mBuf);
13692 CMCHKPK(oduUnpackUInt32, param->uciInfo, mBuf);
13698 /***********************************************************
13700 * Func : cmUnpkTfuUePucchRecpReq
13703 * Desc : This structure is sent from scheduler to PHY in order to request the
13704 * reception of UCI on PUCCH. This may contain the following:
13724 **********************************************************/
13726 S16 cmUnpkTfuUePucchRecpReq
13728 TfuUePucchRecpReq *param,
13732 S16 cmUnpkTfuUePucchRecpReq(param, mBuf)
13733 TfuUePucchRecpReq *param;
13739 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->uciInfo, mBuf);
13740 CMCHKUNPK(cmUnpkTfuUePucchCqiRecpInfo, ¶m->cqiInfo, mBuf);
13741 CMCHKUNPK(cmUnpkTfuUePucchSrRecpInfo, ¶m->srInfo, mBuf);
13742 CMCHKUNPK(cmUnpkTfuUePucchHqRecpInfo, ¶m->hqInfo, mBuf);
13743 CMCHKUNPK(cmUnpkTfuUePucchSrsRecpInfo, ¶m->srsInfo, mBuf);
13745 CMCHKUNPK(cmUnpkTfuUePucchUciRecpInfo, ¶m->uciPduInfo, mBuf);
13746 CMCHKUNPK(cmUnpkTfuUePucchBsiBriRecpInfo, ¶m->bsiBriInfo, mBuf);
13747 #endif /* TFU_5GTF */
13753 /***********************************************************
13755 * Func : cmPkTfuUeUlSchRecpInfo
13758 * Desc : This structure is sent from scheduler to PHY in order to request the
13759 * reception of UEs data on ULSCH.
13768 **********************************************************/
13770 S16 cmPkTfuUeUlSchRecpInfo
13772 TfuUeUlSchRecpInfo *param,
13776 S16 cmPkTfuUeUlSchRecpInfo(param, mBuf)
13777 TfuUeUlSchRecpInfo *param;
13783 CMCHKPK(oduUnpackUInt8, param->beamIndex, mBuf);
13784 CMCHKPK(oduUnpackUInt8, param->uciWoTBFlag, mBuf);
13785 CMCHKPK(oduUnpackUInt8, param->PMI, mBuf);
13786 CMCHKPK(oduUnpackUInt8, param->SCID, mBuf);
13787 CMCHKPK(oduUnpackUInt8, param->nAntPortLayer, mBuf);
13788 CMCHKPK(oduUnpackUInt8, param->xPUSCHRange, mBuf);
13789 CMCHKPK(oduUnpackUInt8, param->numRbg, mBuf);
13790 CMCHKPK(oduUnpackUInt8, param->rbgStart, mBuf);
13792 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
13793 CMCHKPK(oduUnpackUInt8, param->nSrs, mBuf);
13794 CMCHKPK(oduUnpackUInt8, param->crntTxNb, mBuf);
13795 CMCHKPK(oduUnpackUInt8, param->txMode, mBuf);
13796 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
13797 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
13798 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
13799 CMCHKPK(oduUnpackUInt8, param->isRtx, mBuf);
13800 CMCHKPK(oduUnpackUInt8, param->hoppingBits, mBuf);
13801 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
13802 CMCHKPK(oduUnpackUInt8, param->nDmrs, mBuf);
13803 CMCHKPK(oduUnpackUInt32, param->modType, mBuf);
13804 CMCHKPK(oduUnpackUInt8, param->numRb, mBuf);
13805 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
13806 CMCHKPK(oduUnpackUInt16, param->size, mBuf);
13813 /***********************************************************
13815 * Func : cmUnpkTfuUeUlSchRecpInfo
13818 * Desc : This structure is sent from scheduler to PHY in order to request the
13819 * reception of UEs data on ULSCH.
13828 **********************************************************/
13830 S16 cmUnpkTfuUeUlSchRecpInfo
13832 TfuUeUlSchRecpInfo *param,
13836 S16 cmUnpkTfuUeUlSchRecpInfo(param, mBuf)
13837 TfuUeUlSchRecpInfo *param;
13843 CMCHKUNPK(oduPackUInt16, ¶m->size, mBuf);
13844 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
13845 CMCHKUNPK(oduPackUInt8, ¶m->numRb, mBuf);
13846 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->modType, mBuf);
13847 CMCHKUNPK(oduPackUInt8, ¶m->nDmrs, mBuf);
13848 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
13849 CMCHKUNPK(oduPackUInt8, ¶m->hoppingBits, mBuf);
13850 CMCHKUNPK(oduPackUInt8, ¶m->isRtx, mBuf);
13851 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
13852 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
13853 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
13854 CMCHKUNPK(oduPackUInt8, ¶m->txMode, mBuf);
13855 CMCHKUNPK(oduPackUInt8, ¶m->crntTxNb, mBuf);
13856 CMCHKUNPK(oduPackUInt8, ¶m->nSrs, mBuf);
13857 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
13859 CMCHKUNPK(oduPackUInt8, ¶m->rbgStart, mBuf);
13860 CMCHKUNPK(oduPackUInt8, ¶m->numRbg, mBuf);
13861 CMCHKUNPK(oduPackUInt8, ¶m->xPUSCHRange, mBuf);
13862 CMCHKUNPK(oduPackUInt8, ¶m->nAntPortLayer, mBuf);
13863 CMCHKUNPK(oduPackUInt8, ¶m->SCID, mBuf);
13864 CMCHKUNPK(oduPackUInt8, ¶m->PMI, mBuf);
13865 CMCHKUNPK(oduPackUInt8, ¶m->uciWoTBFlag, mBuf);
13866 CMCHKUNPK(oduPackUInt8, ¶m->beamIndex, mBuf);
13873 /***********************************************************
13875 * Func : cmPkTfuUePuschCqiRecpInfo
13878 * Desc : This structure is sent from scheduler to PHY in order to request the
13879 * reception of CQI_RI info on PUSCH.
13888 **********************************************************/
13890 S16 cmPkTfuUePuschCqiRecpInfo
13892 TfuUePuschCqiRecpInfo *param,
13896 S16 cmPkTfuUePuschCqiRecpInfo(param, mBuf)
13897 TfuUePuschCqiRecpInfo *param;
13904 CMCHKPK(oduUnpackUInt8, param->riBetaOff, mBuf);
13905 CMCHKPK(oduUnpackUInt8, param->cqiBetaOff, mBuf);
13906 for (idx = 0; idx < param->cCNum; idx++)
13908 CMCHKPK(cmPkTknU8, ¶m->riSz[idx], mBuf);
13909 CMCHKPK(oduUnpackUInt8, param->cqiPmiSzRn1[idx], mBuf);
13910 CMCHKPK(oduUnpackUInt8, param->cqiPmiSzR1[idx], mBuf);
13912 CMCHKPK(oduUnpackUInt8, param->cCNum, mBuf);
13913 CMCHKPK(oduUnpackUInt8, param->reportType, mBuf);
13919 /***********************************************************
13921 * Func : cmUnpkTfuUePuschCqiRecpInfo
13924 * Desc : This structure is sent from scheduler to PHY in order to request the
13925 * reception of CQI_RI info on PUSCH.
13934 **********************************************************/
13936 S16 cmUnpkTfuUePuschCqiRecpInfo
13938 TfuUePuschCqiRecpInfo *param,
13942 S16 cmUnpkTfuUePuschCqiRecpInfo(param, mBuf)
13943 TfuUePuschCqiRecpInfo *param;
13950 CMCHKUNPK(oduPackUInt8, ¶m->reportType, mBuf);
13951 CMCHKUNPK(oduPackUInt8, ¶m->cCNum, mBuf);
13952 for (idx = param->cCNum; idx > 0; idx--)
13954 CMCHKUNPK(oduPackUInt8, ¶m->cqiPmiSzR1[idx-1], mBuf);
13955 CMCHKUNPK(oduPackUInt8, ¶m->cqiPmiSzRn1[idx-1], mBuf);
13956 CMCHKUNPK(cmUnpkTknU8, ¶m->riSz[idx-1], mBuf);
13958 CMCHKUNPK(oduPackUInt8, ¶m->cqiBetaOff, mBuf);
13959 CMCHKUNPK(oduPackUInt8, ¶m->riBetaOff, mBuf);
13965 /***********************************************************
13967 * Func : cmPkTfuUePuschHqRecpInfo
13970 * Desc : This structure is sent from scheduler to PHY in order to request the
13971 * reception of Harq info on PUSCH.
13980 **********************************************************/
13982 S16 cmPkTfuUePuschHqRecpInfo
13984 TfuUePuschHqRecpInfo *param,
13988 S16 cmPkTfuUePuschHqRecpInfo(param, mBuf)
13989 TfuUePuschHqRecpInfo *param;
13997 CMCHKPK(oduUnpackUInt8, param->ulDai, mBuf);
13998 CMCHKPK(oduUnpackUInt8, param->nBundled, mBuf);
13999 CMCHKPK(oduUnpackUInt32, param->hqFdbkMode, mBuf);
14001 CMCHKPK(oduUnpackUInt8, param->hqBetaOff, mBuf);
14002 CMCHKPK(oduUnpackUInt8, param->hqSz, mBuf);
14008 /***********************************************************
14010 * Func : cmUnpkTfuUePuschHqRecpInfo
14013 * Desc : This structure is sent from scheduler to PHY in order to request the
14014 * reception of Harq info on PUSCH.
14023 **********************************************************/
14025 S16 cmUnpkTfuUePuschHqRecpInfo
14027 TfuUePuschHqRecpInfo *param,
14031 S16 cmUnpkTfuUePuschHqRecpInfo(param, mBuf)
14032 TfuUePuschHqRecpInfo *param;
14038 CMCHKUNPK(oduPackUInt8, ¶m->hqSz, mBuf);
14039 CMCHKUNPK(oduPackUInt8, ¶m->hqBetaOff, mBuf);
14042 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->hqFdbkMode, mBuf);
14043 CMCHKUNPK(oduPackUInt8, ¶m->nBundled, mBuf);
14044 CMCHKUNPK(oduPackUInt8, ¶m->ulDai, mBuf);
14051 /***********************************************************
14053 * Func : cmPkTfuUePuschRecpReq
14056 * Desc : This structure is sent from scheduler to PHY in order to request the
14057 * reception of UEs data on PUSCH. This may contain the following:
14061 * -# Data + HARQ + SRS
14063 * -# Data + CQI/RI + SRS
14064 * -# Data + CQI/RI + HARQ
14065 * -# Data + CQI/RI + HARQ + SRS
14074 **********************************************************/
14076 S16 cmPkTfuUePuschRecpReq
14078 TfuUePuschRecpReq *param,
14082 S16 cmPkTfuUePuschRecpReq(param, mBuf)
14083 TfuUePuschRecpReq *param;
14089 CMCHKPK(cmPkTknU8, ¶m->initialNumRbs, mBuf);
14090 CMCHKPK(cmPkTknU8, ¶m->initialNSrs, mBuf);
14091 CMCHKPK(cmPkTfuUePucchSrsRecpInfo, ¶m->srsInfo, mBuf);
14092 CMCHKPK(cmPkTfuUePuschHqRecpInfo, ¶m->hqInfo, mBuf);
14093 CMCHKPK(cmPkTfuUePuschCqiRecpInfo, ¶m->cqiRiInfo, mBuf);
14094 CMCHKPK(cmPkTfuUeUlSchRecpInfo, ¶m->ulSchInfo, mBuf);
14095 CMCHKPK(oduUnpackUInt32, param->rcpInfo, mBuf);
14101 /***********************************************************
14103 * Func : cmUnpkTfuUePuschRecpReq
14106 * Desc : This structure is sent from scheduler to PHY in order to request the
14107 * reception of UEs data on PUSCH. This may contain the following:
14111 * -# Data + HARQ + SRS
14113 * -# Data + CQI/RI + SRS
14114 * -# Data + CQI/RI + HARQ
14115 * -# Data + CQI/RI + HARQ + SRS
14124 **********************************************************/
14126 S16 cmUnpkTfuUePuschRecpReq
14128 TfuUePuschRecpReq *param,
14132 S16 cmUnpkTfuUePuschRecpReq(param, mBuf)
14133 TfuUePuschRecpReq *param;
14139 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->rcpInfo, mBuf);
14140 CMCHKUNPK(cmUnpkTfuUeUlSchRecpInfo, ¶m->ulSchInfo, mBuf);
14141 CMCHKUNPK(cmUnpkTfuUePuschCqiRecpInfo, ¶m->cqiRiInfo, mBuf);
14142 CMCHKUNPK(cmUnpkTfuUePuschHqRecpInfo, ¶m->hqInfo, mBuf);
14143 CMCHKUNPK(cmUnpkTfuUePucchSrsRecpInfo, ¶m->srsInfo, mBuf);
14144 CMCHKUNPK(cmUnpkTknU8, ¶m->initialNSrs, mBuf);
14145 CMCHKUNPK(cmUnpkTknU8, ¶m->initialNumRbs, mBuf);
14151 /***********************************************************
14153 * Func : cmPkTfuUeRecpReqInfo
14156 * Desc : This structure is a Per UE reception request for either PUCCH or PUSCH
14157 * data. This contains information needed by PHY to decode the data sent by the
14167 **********************************************************/
14169 S16 cmPkTfuUeRecpReqInfo
14171 TfuUeRecpReqInfo *param,
14175 S16 cmPkTfuUeRecpReqInfo(param, mBuf)
14176 TfuUeRecpReqInfo *param;
14182 switch(param->type) {
14183 case TFU_RECP_REQ_PUSCH:
14184 CMCHKPK(cmPkTfuUePuschRecpReq, ¶m->t.puschRecpReq, mBuf);
14186 case TFU_RECP_REQ_PUCCH:
14187 CMCHKPK(cmPkTfuUePucchRecpReq, ¶m->t.pucchRecpReq, mBuf);
14192 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
14194 CMCHKPK(oduUnpackUInt8, param->groupId, mBuf);
14195 #endif /* TFU_5GTF */
14196 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
14202 /***********************************************************
14204 * Func : cmUnpkTfuUeRecpReqInfo
14207 * Desc : This structure is a Per UE reception request for either PUCCH or PUSCH
14208 * data. This contains information needed by PHY to decode the data sent by the
14218 **********************************************************/
14220 S16 cmUnpkTfuUeRecpReqInfo
14222 TfuUeRecpReqInfo *param,
14226 S16 cmUnpkTfuUeRecpReqInfo(param, mBuf)
14227 TfuUeRecpReqInfo *param;
14233 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
14235 CMCHKUNPK(oduPackUInt8, ¶m->groupId, mBuf);
14236 #endif /* TFU_5GTF */
14237 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
14238 switch(param->type) {
14239 case TFU_RECP_REQ_PUCCH:
14240 CMCHKUNPK(cmUnpkTfuUePucchRecpReq, ¶m->t.pucchRecpReq, mBuf);
14242 case TFU_RECP_REQ_PUSCH:
14243 CMCHKUNPK(cmUnpkTfuUePuschRecpReq, ¶m->t.puschRecpReq, mBuf);
14250 #endif /* TFU_UPGRADE */
14251 #ifndef TFU_UPGRADE /* TFU_UPGRADE */
14252 /***********************************************************
14254 * Func : cmPkTfuUePucchRecpReq
14257 * Desc : This structure is sent from Scheduler to PHY in order to request the
14258 * reception of an UEs data on PUCCH. This may contain the following:
14260 * -# Scheduling Request (SR)
14261 * -# HARQ-ACK and SR
14263 * -# CQI and HARQ-ACK
14272 **********************************************************/
14274 S16 cmPkTfuUePucchRecpReq
14276 TfuUePucchRecpReq *param,
14280 S16 cmPkTfuUePucchRecpReq(param, mBuf)
14281 TfuUePucchRecpReq *param;
14292 for (i=TFU_MAX_M-1; i >= 0; i--) {
14293 CMCHKPK(oduUnpackUInt8, param->p[i], mBuf);
14295 for (i=TFU_MAX_M-1; i >= 0; i--) {
14296 CMCHKPK(oduUnpackUInt8, param->m[i], mBuf);
14298 CMCHKPK(oduUnpackUInt8, param->M, mBuf);
14299 CMCHKPK(oduUnpackUInt8, param->multCnt, mBuf);
14302 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
14303 switch(param->hqType) {
14304 case TFU_HQ_RECP_REQ_N1PUCCH:
14305 CMCHKPK(oduUnpackUInt16, param->t.n1Pucch, mBuf);
14309 case TFU_HQ_RECP_REQ_NORMAL:
14310 for (i=TFU_MAX_M-1; i >= 0; i--) {
14311 CMCHKPK(oduUnpackUInt16, param->t.nCce[i], mBuf);
14318 case TFU_HQ_RECP_REQ_NORMAL:
14319 CMCHKPK(oduUnpackUInt16, param->t.nCce, mBuf);
14326 CMCHKPK(oduUnpackUInt32, param->hqType, mBuf);
14332 /***********************************************************
14334 * Func : cmUnpkTfuUePucchRecpReq
14337 * Desc : This structure is sent from Scheduler to PHY in order to request the
14338 * reception of an UEs data on PUCCH. This may contain the following:
14340 * -# Scheduling Request (SR)
14341 * -# HARQ-ACK and SR
14343 * -# CQI and HARQ-ACK
14352 **********************************************************/
14354 S16 cmUnpkTfuUePucchRecpReq
14356 TfuUePucchRecpReq *param,
14360 S16 cmUnpkTfuUePucchRecpReq(param, mBuf)
14361 TfuUePucchRecpReq *param;
14370 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->hqType, mBuf);
14371 switch(param->hqType) {
14374 case TFU_HQ_RECP_REQ_NORMAL:
14375 CMCHKUNPK(oduPackUInt16, ¶m->t.nCce, mBuf);
14381 case TFU_HQ_RECP_REQ_NORMAL:
14382 for (i=0; i<TFU_MAX_M; i++) {
14383 CMCHKUNPK(oduPackUInt16, ¶m->t.nCce[i], mBuf);
14388 case TFU_HQ_RECP_REQ_N1PUCCH:
14389 CMCHKUNPK(oduPackUInt16, ¶m->t.n1Pucch, mBuf);
14394 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
14397 CMCHKUNPK(oduPackUInt8, ¶m->multCnt, mBuf);
14398 CMCHKUNPK(oduPackUInt8, ¶m->M, mBuf);
14399 for (i=0; i<TFU_MAX_M; i++) {
14400 CMCHKUNPK(oduPackUInt8, ¶m->m[i], mBuf);
14402 for (i=0; i<TFU_MAX_M; i++) {
14403 CMCHKUNPK(oduPackUInt8, ¶m->p[i], mBuf);
14412 /***********************************************************
14414 * Func : cmPkTfuUeMsg3RecpReq
14417 * Desc : This structure is sent from scheduler to PHY in order to request the
14418 * reception of UEs data sent as MSG3 for Random access.
14427 **********************************************************/
14429 S16 cmPkTfuUeMsg3RecpReq
14431 TfuUeMsg3RecpReq *param,
14435 S16 cmPkTfuUeMsg3RecpReq(param, mBuf)
14436 TfuUeMsg3RecpReq *param;
14442 CMCHKPK(oduUnpackUInt32, param->modType, mBuf);
14443 CMCHKPK(oduUnpackUInt16, param->size, mBuf);
14444 /*ccpu00128993 - ADD - fix for msg3 softcombining bug*/
14445 CMCHKPK(oduUnpackUInt8, param->nDmrs, mBuf);
14446 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
14447 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
14448 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
14449 CMCHKPK(oduUnpackUInt8, param->isRtx, mBuf);
14450 CMCHKPK(oduUnpackUInt8, param->ulDelay, mBuf);
14451 CMCHKPK(oduUnpackUInt8, param->expCqi, mBuf);
14452 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
14453 CMCHKPK(oduUnpackUInt8, param->numRb, mBuf);
14454 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
14455 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
14461 /***********************************************************
14463 * Func : cmUnpkTfuUeMsg3RecpReq
14466 * Desc : This structure is sent from scheduler to PHY in order to request the
14467 * reception of UEs data sent as MSG3 for Random access.
14476 **********************************************************/
14478 S16 cmUnpkTfuUeMsg3RecpReq
14480 TfuUeMsg3RecpReq *param,
14484 S16 cmUnpkTfuUeMsg3RecpReq(param, mBuf)
14485 TfuUeMsg3RecpReq *param;
14491 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
14492 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
14493 CMCHKUNPK(oduPackUInt8, ¶m->numRb, mBuf);
14494 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
14495 CMCHKUNPK(oduPackUInt8, ¶m->expCqi, mBuf);
14496 CMCHKUNPK(oduPackUInt8, ¶m->ulDelay, mBuf);
14497 CMCHKUNPK(oduPackUInt8, ¶m->isRtx, mBuf);
14498 /*ccpu00128993 - ADD - fix for msg3 softcombining bug*/
14499 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
14500 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
14501 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
14502 CMCHKUNPK(oduPackUInt8, ¶m->nDmrs, mBuf);
14503 CMCHKUNPK(oduPackUInt16, ¶m->size, mBuf);
14504 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->modType, mBuf);
14510 /***********************************************************
14512 * Func : cmPkTfuUePuschRecpReq
14515 * Desc : This structure is sent from scheduler to PHY in order to request the
14516 * reception of UEs data on PUSCH. This may contain the following:
14518 * -# Data + CQI and RI
14519 * -# Data + CQI and HARQ
14528 **********************************************************/
14530 S16 cmPkTfuUePuschRecpReq
14532 TfuUePuschRecpReq *param,
14536 S16 cmPkTfuUePuschRecpReq(param, mBuf)
14537 TfuUePuschRecpReq *param;
14543 CMCHKPK(oduUnpackUInt32, param->modType, mBuf);
14544 CMCHKPK(oduUnpackUInt16, param->size, mBuf);
14545 CMCHKPK(oduUnpackUInt32, param->mode, mBuf);
14546 CMCHKPK(oduUnpackUInt8, param->expHarq, mBuf);
14547 CMCHKPK(oduUnpackUInt8, param->expCqi, mBuf);
14548 CMCHKPK(oduUnpackUInt8, param->nDmrs, mBuf);
14549 CMCHKPK(oduUnpackUInt8, param->rv, mBuf);
14550 CMCHKPK(oduUnpackUInt8, param->isRtx, mBuf);
14551 CMCHKPK(oduUnpackUInt8, param->ndi, mBuf);
14552 CMCHKPK(oduUnpackUInt8, param->harqProcId, mBuf);
14553 CMCHKPK(oduUnpackUInt8, param->mcs, mBuf);
14554 CMCHKPK(oduUnpackUInt8, param->numRb, mBuf);
14555 CMCHKPK(oduUnpackUInt8, param->rbStart, mBuf);
14556 CMCHKPK(oduUnpackUInt8, param->hoppingBits, mBuf);
14557 CMCHKPK(oduUnpackUInt8, param->hoppingEnbld, mBuf);
14563 /***********************************************************
14565 * Func : cmUnpkTfuUePuschRecpReq
14568 * Desc : This structure is sent from scheduler to PHY in order to request the
14569 * reception of UEs data on PUSCH. This may contain the following:
14571 * -# Data + CQI and RI
14572 * -# Data + CQI and HARQ
14581 **********************************************************/
14583 S16 cmUnpkTfuUePuschRecpReq
14585 TfuUePuschRecpReq *param,
14589 S16 cmUnpkTfuUePuschRecpReq(param, mBuf)
14590 TfuUePuschRecpReq *param;
14596 CMCHKUNPK(oduPackUInt8, ¶m->hoppingEnbld, mBuf);
14597 CMCHKUNPK(oduPackUInt8, ¶m->hoppingBits, mBuf);
14598 CMCHKUNPK(oduPackUInt8, ¶m->rbStart, mBuf);
14599 CMCHKUNPK(oduPackUInt8, ¶m->numRb, mBuf);
14600 CMCHKUNPK(oduPackUInt8, ¶m->mcs, mBuf);
14601 CMCHKUNPK(oduPackUInt8, ¶m->harqProcId, mBuf);
14602 CMCHKUNPK(oduPackUInt8, ¶m->ndi, mBuf);
14603 CMCHKUNPK(oduPackUInt8, ¶m->isRtx, mBuf);
14604 CMCHKUNPK(oduPackUInt8, ¶m->rv, mBuf);
14605 CMCHKUNPK(oduPackUInt8, ¶m->nDmrs, mBuf);
14606 CMCHKUNPK(oduPackUInt8, ¶m->expCqi, mBuf);
14607 CMCHKUNPK(oduPackUInt8, ¶m->expHarq, mBuf);
14608 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->mode, mBuf);
14609 CMCHKUNPK(oduPackUInt16, ¶m->size, mBuf);
14610 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->modType, mBuf);
14616 /***********************************************************
14618 * Func : cmPkTfuUeRecpReqInfo
14621 * Desc : This structure is a Per UE reception request for either PUCCH or PUSCH
14622 * data. This contains information needed by PHY to decode the data sent by the
14632 **********************************************************/
14634 S16 cmPkTfuUeRecpReqInfo
14636 TfuUeRecpReqInfo *param,
14640 S16 cmPkTfuUeRecpReqInfo(param, mBuf)
14641 TfuUeRecpReqInfo *param;
14647 switch(param->type) {
14648 case TFU_RECP_REQ_PUSCH:
14649 CMCHKPK(cmPkTfuUePuschRecpReq, ¶m->t.puschRecpReq, mBuf);
14651 case TFU_RECP_REQ_MSG3:
14652 CMCHKPK(cmPkTfuUeMsg3RecpReq, ¶m->t.msg3RecpReq, mBuf);
14654 case TFU_RECP_REQ_PUCCH:
14655 CMCHKPK(cmPkTfuUePucchRecpReq, ¶m->t.pucchRecpReq, mBuf);
14660 CMCHKPK(oduUnpackUInt32, param->type, mBuf);
14661 CMCHKPK(cmPkLteRnti, param->rnti, mBuf);
14667 /***********************************************************
14669 * Func : cmUnpkTfuUeRecpReqInfo
14672 * Desc : This structure is a Per UE reception request for either PUCCH or PUSCH
14673 * data. This contains information needed by PHY to decode the data sent by the
14683 **********************************************************/
14685 S16 cmUnpkTfuUeRecpReqInfo
14687 TfuUeRecpReqInfo *param,
14691 S16 cmUnpkTfuUeRecpReqInfo(param, mBuf)
14692 TfuUeRecpReqInfo *param;
14698 CMCHKUNPK(cmUnpkLteRnti, ¶m->rnti, mBuf);
14699 CMCHKUNPK(oduPackUInt32, (U32 *)¶m->type, mBuf);
14700 switch(param->type) {
14701 case TFU_RECP_REQ_PUCCH:
14702 CMCHKUNPK(cmUnpkTfuUePucchRecpReq, ¶m->t.pucchRecpReq, mBuf);
14704 case TFU_RECP_REQ_MSG3:
14705 CMCHKUNPK(cmUnpkTfuUeMsg3RecpReq, ¶m->t.msg3RecpReq, mBuf);
14707 case TFU_RECP_REQ_PUSCH:
14708 CMCHKUNPK(cmUnpkTfuUePuschRecpReq, ¶m->t.puschRecpReq, mBuf);
14717 #endif /* ifndef TFU_UPGRADE */
14718 /*LAA: Packing and Unpacking*/
14720 /***********************************************************
14722 * Func : cmPkTfuErrIndInfo
14725 * Desc : This structure contains information that is passed as a part of
14726 * the ERR indication sent from PHY to MAC.
14735 **********************************************************/
14737 PRIVATE S16 cmPkTfuErrIndInfo
14739 TfuErrIndInfo *param,
14743 PRIVATE S16 cmPkTfuErrIndInfo(param, mBuf)
14744 TfuErrIndInfo *param;
14750 CMCHKPK(cmPkLteTimingInfo, ¶m->timingInfo, mBuf);
14751 CMCHKPK(cmPkLteCellId, param->cellId, mBuf);
14754 /***********************************************************
14756 * Func : cmUnpkTfuErrIndInfo
14759 * Desc : This structure contains information that is passed as a part of the ERR
14760 * indication sent from PHY to MAC.
14769 **********************************************************/
14771 PRIVATE S16 cmUnpkTfuErrIndInfo
14773 TfuErrIndInfo *param,
14777 PRIVATE S16 cmUnpkTfuErrIndInfo(param, mBuf)
14778 TfuErrIndInfo *param;
14784 CMCHKUNPK(cmUnpkLteCellId, ¶m->cellId, mBuf);
14785 CMCHKUNPK(cmUnpkLteTimingInfo, ¶m->timingInfo, mBuf);
14789 /***********************************************************
14791 * Func : cmPkTfuErrInd
14794 * This API is invoked by PHY to send ERROR INDICATION to scheduler
14795 * Currently invoked in the cases when the Unlicensed SCell transmission
14797 * This API contains the Cell and subframe information for which the
14798 * transmission failed.
14800 * @param[in] Pst *pst
14801 * @param[in] SuId suId
14802 * @param[in] TfuErrIndInfo *errIndInfo
14814 **********************************************************/
14820 TfuErrIndInfo * errInd
14823 S16 cmPkTfuErrInd(pst, suId, errInd)
14826 TfuErrIndInfo * errInd;
14829 Buffer *mBuf = NULLP;
14831 if (SGetMsg(pst->region, pst->pool, &mBuf) != ROK) {
14832 #if (ERRCLASS & ERRCLS_ADD_RES)
14833 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14834 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14835 (ErrVal)ETFU105, (ErrVal)0, "Packing failed");
14837 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14840 if (pst->selector == ODU_SELECTOR_LC) {
14841 if (cmPkTfuErrIndInfo(errInd, mBuf) != ROK) {
14842 #if (ERRCLASS & ERRCLS_ADD_RES)
14843 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14844 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14845 (ErrVal)ETFU106, (ErrVal)0, "Packing failed");
14847 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14848 TFU_FREE_MSG(mBuf);
14852 else if(pst->selector == ODU_SELECTOR_LWLC)
14854 if (oduPackPointer((PTR)errInd, mBuf) != ROK)
14856 #if (ERRCLASS & ERRCLS_ADD_RES)
14857 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14858 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14859 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC Packing failed");
14862 /*MS_FIX:71858:Changed to SPutSBuf as being allocated with SGetSBuf*/
14863 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14864 TFU_FREE_MSG(mBuf);
14869 if (SPkS16(suId, mBuf) != ROK) {
14870 #if (ERRCLASS & ERRCLS_ADD_RES)
14871 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14872 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14873 (ErrVal)ETFU107, (ErrVal)0, "Packing failed");
14875 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14876 TFU_FREE_MSG(mBuf);
14879 if (pst->selector != ODU_SELECTOR_LWLC) {
14880 if (SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo)) != ROK) {
14881 #if (ERRCLASS & ERRCLS_ADD_RES)
14882 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14883 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14884 (ErrVal)ETFU108, (ErrVal)0, "Packing failed");
14886 TFU_FREE_MSG(mBuf);
14891 pst->event = (Event) EVTTFUERRIND;
14892 return (SPstTsk(pst,mBuf));
14896 /***********************************************************
14898 * Func : cmUnpkTfuErrInd
14901 * This API is invoked by PHY to send ERROR INDICATION to scheduler
14902 * Currently invoked in the cases when the Unlicensed SCell transmission
14904 * This API contains the Cell and subframe information for which the
14905 * transmission failed.
14906 * @param pst Pointer to the post structure.
14907 * @param suId SAP ID of the service user.
14908 * @param errInd Pointer to the TfuErrIndInfo.
14909 * @return ROK/RFAILED
14918 **********************************************************/
14920 S16 cmUnpkTfuErrInd
14927 S16 cmUnpkTfuErrInd(func, pst, mBuf)
14934 TfuErrIndInfo *errInd;
14937 if (SUnpkS16(&suId, mBuf) != ROK) {
14938 TFU_FREE_MSG(mBuf);
14939 #if (ERRCLASS & ERRCLS_ADD_RES)
14940 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14941 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14942 (ErrVal)ETFU109, (ErrVal)0, "Packing failed");
14946 if (pst->selector != ODU_SELECTOR_LWLC) {
14947 if ((SGetSBuf(pst->region, pst->pool, (Data **)&errInd, sizeof(TfuErrIndInfo))) != ROK) {
14948 #if (ERRCLASS & ERRCLS_ADD_RES)
14949 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14950 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14951 (ErrVal)ETFU110, (ErrVal)0, "Packing failed");
14953 TFU_FREE_MSG(mBuf);
14958 if (pst->selector == ODU_SELECTOR_LC)
14960 if (cmUnpkTfuErrIndInfo(errInd, mBuf) != ROK) {
14961 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14962 TFU_FREE_MSG(mBuf);
14963 #if (ERRCLASS & ERRCLS_ADD_RES)
14964 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14965 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14966 (ErrVal)ETFU111, (ErrVal)0, "Packing failed");
14971 else if(pst->selector == ODU_SELECTOR_LWLC)
14973 if (oduUnpackPointer((PTR *)&errInd, mBuf) != ROK)
14975 #if (ERRCLASS & ERRCLS_ADD_RES)
14976 SLogError(pst->srcEnt, pst->srcInst, pst->srcProcId,
14977 __FILE__, __LINE__, (ErrCls)ERRCLS_ADD_RES,
14978 (ErrVal)ETFUXXX, (ErrVal)0, "LWLC un-Packing failed");
14980 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14981 TFU_FREE_MSG(mBuf);
14985 TFU_FREE_MSG(mBuf);
14986 /* [ccpu00141698]-MOD- MAC/SCH does not free the TTI ind anymore */
14987 (*func)(pst, suId, errInd);
14988 SPutSBuf(pst->region, pst->pool, (Data *)errInd, sizeof(TfuErrIndInfo));
14992 #endif /* if defined(LCTFU) */
14994 /**********************************************************************
14996 **********************************************************************/