Code Review
/
o-du
/
l2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
[Epic-ID: ODUHIGH-488][Task-ID: ODUHIGH-498] Fix in DL data flow and trace alignment
[o-du/l2.git]
/
src
/
cm
/
cm_bdy5.c
diff --git
a/src/cm/cm_bdy5.c
b/src/cm/cm_bdy5.c
index
cab21f7
..
6099a90
100644
(file)
--- a/
src/cm/cm_bdy5.c
+++ b/
src/cm/cm_bdy5.c
@@
-86,7
+86,7
@@
*
* Desc: Handle a timer entry
*
*
* Desc: Handle a timer entry
*
-* Ret:
RETVOID
+* Ret:
void
*
* Notes:
*
*
* Notes:
*
@@
-95,29
+95,21
@@
*/
#ifdef SS_FAP
*/
#ifdef SS_FAP
-#ifdef ANSI
-PUBLIC Void cmPrcTmr
+Void cmPrcTmr
(
CmTqCp *tqCp, /* timing que control point */
CmTqType *tq, /* timing queue */
PFV func /* function */
)
(
CmTqCp *tqCp, /* timing que control point */
CmTqType *tq, /* timing queue */
PFV func /* function */
)
-#else
-PUBLIC Void cmPrcTmr(tqCp, tq, func)
-CmTqCp *tqCp; /* connection control block */
-CmTqType *tq; /* message buffer */
-PFV func; /* function */
-#endif
{
/**/
{
/**/
-
U32
expire;
-
U32
entry;
+
uint32_t
expire;
+
uint32_t
entry;
S16 event;
PTR cb;
CmTimer *tmp1;
CmTimer **tmp2;
S16 event;
PTR cb;
CmTimer *tmp1;
CmTimer **tmp2;
- TRC2(cmPrcTmr)
#ifdef CMDBG
{
#ifdef CMDBG
{
@@
-140,7
+132,7
@@
PFV func; /* function */
++tqCp->nxtEnt;
expire = tqCp->nxtEnt;
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
++tqCp->nxtEnt;
expire = tqCp->nxtEnt;
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
- entry = (
U32) (expire % (U32
)(tqCp->tmrLen));
+ entry = (
uint32_t) (expire % (uint32_t
)(tqCp->tmrLen));
tmp2 = &tq[entry].first;
while ((tmp1 = *tmp2) != NULLP)
tmp2 = &tq[entry].first;
while ((tmp1 = *tmp2) != NULLP)
@@
-160,35
+152,27
@@
PFV func; /* function */
else
tmp2 = &tmp1->next;
}
else
tmp2 = &tmp1->next;
}
-
RETVOID
;
+
return
;
} /* end of cmPrcTmr */
#else /* not defined SS_FAP */
} /* end of cmPrcTmr */
#else /* not defined SS_FAP */
-#ifdef ANSI
-PUBLIC Void cmPrcTmr
+Void cmPrcTmr
(
CmTqCp *tqCp, /* timing que control point */
CmTqType *tq, /* timing queue */
PFV func /* function */
)
(
CmTqCp *tqCp, /* timing que control point */
CmTqType *tq, /* timing queue */
PFV func /* function */
)
-#else
-PUBLIC Void cmPrcTmr(tqCp, tq, func)
-CmTqCp *tqCp; /* connection control block */
-CmTqType *tq; /* message buffer */
-PFV func; /* function */
-#endif
{
/**/
{
/**/
-
U32
expire;
-
U32
entry, entry1;
+
uint32_t
expire;
+
uint32_t
entry, entry1;
S16 event;
CmTqType *tqEnt, *tqEnt1;
PTR cb;
CmTimer *tmp1;
S16 event;
CmTqType *tqEnt, *tqEnt1;
PTR cb;
CmTimer *tmp1;
-
VOLATILE U32
startTime = 0;
+
volatile uint32_t
startTime = 0;
- TRC2(cmPrcTmr)
/*starting Task*/
SStartTask(&startTime, PID_CM_PRC_TMR);
/*starting Task*/
SStartTask(&startTime, PID_CM_PRC_TMR);
@@
-213,8
+197,7
@@
PFV func; /* function */
++tqCp->nxtEnt;
expire = tqCp->nxtEnt;
++tqCp->nxtEnt;
expire = tqCp->nxtEnt;
- tqCp->tmrLen = 1;
- entry = (U32) (expire % (U32)(tqCp->tmrLen));
+ entry = (uint32_t) (expire % (uint32_t)(tqCp->tmrLen));
tqCp->tmp = (tqEnt = &tq[entry])->first;
while ((tmp1 = tqCp->tmp) != NULLP)
tqCp->tmp = (tqEnt = &tq[entry])->first;
while ((tmp1 = tqCp->tmp) != NULLP)
@@
-238,7
+221,7
@@
PFV func; /* function */
}
else
{
}
else
{
- entry1 = (
U32) (tmp1->tqExpire % (U32
)(tqCp->tmrLen));
+ entry1 = (
uint32_t) (tmp1->tqExpire % (uint32_t
)(tqCp->tmrLen));
tqEnt1 = &tq[entry1];
CM_RMV_TQCP(tqEnt, tmp1);
tmp1->entIdx = entry1;
tqEnt1 = &tq[entry1];
CM_RMV_TQCP(tqEnt, tmp1);
tmp1->entIdx = entry1;
@@
-249,7
+232,7
@@
PFV func; /* function */
/*stoping Task*/
SStopTask(startTime, PID_CM_PRC_TMR);
/*stoping Task*/
SStopTask(startTime, PID_CM_PRC_TMR);
-
RETVOID
;
+
return
;
} /* end of cmPrcTmr */
#endif /* SS_FAP */
} /* end of cmPrcTmr */
#endif /* SS_FAP */
@@
-261,29
+244,22
@@
PFV func; /* function */
*
* Desc: initialize timers
*
*
* Desc: initialize timers
*
-* Ret:
RETVOID
+* Ret:
void
*
* Notes: Connection Oriented Control
*
* File: cm_bdy5.c
*
*/
*
* Notes: Connection Oriented Control
*
* File: cm_bdy5.c
*
*/
-#ifdef ANSI
-PUBLIC Void cmInitTimers
+Void cmInitTimers
(
CmTimer *timers, /* timer list */
(
CmTimer *timers, /* timer list */
-
U8
max /* maximum tmrs */
+
uint8_t
max /* maximum tmrs */
)
)
-#else
-PUBLIC Void cmInitTimers(timers, max)
-CmTimer *timers; /* timer list */
-U8 max; /* maximum tmrs */
-#endif
{
CmTimer *tPtr;
{
CmTimer *tPtr;
- REG1
U8
i;
+ REG1
uint8_t
i;
- TRC2(cmInitTimers)
for (i = 0, tPtr = timers; i < max; i++, tPtr++)
{
for (i = 0, tPtr = timers; i < max; i++, tPtr++)
{
@@
-294,7
+270,7
@@
U8 max; /* maximum tmrs */
tPtr->prev = (struct cmTimer *)NULLP;
tPtr->ent2bUpd = FALSE;
}
tPtr->prev = (struct cmTimer *)NULLP;
tPtr->ent2bUpd = FALSE;
}
-
RETVOID
;
+
return
;
} /* end of cmInitTimers */
/*
} /* end of cmInitTimers */
/*
@@
-303,7
+279,7
@@
U8 max; /* maximum tmrs */
*
* Desc: Places Control Block on Timing Queue
*
*
* Desc: Places Control Block on Timing Queue
*
-* Ret:
RETVOID
+* Ret:
void
*
* Notes: None
*
*
* Notes: None
*
@@
-311,29
+287,20
@@
U8 max; /* maximum tmrs */
*
*/
*
*/
-#ifdef ANSI
-PUBLIC Void cmPlcCbTq
-(
-CmTmrArg *arg
-)
-#else
-PUBLIC Void cmPlcCbTq(arg)
-CmTmrArg *arg;
-#endif
+Void cmPlcCbTq(CmTmrArg *arg)
{
/*added FAP modifications*/
#ifdef SS_FAP
{
/*added FAP modifications*/
#ifdef SS_FAP
- REG1
U8
tmrNum;
+ REG1
uint8_t
tmrNum;
/* cm_bdy5_c_001.main_20 - Modification for SRegCfgTmr support */
/* cm_bdy5_c_001.main_20 - Modification for SRegCfgTmr support */
-
U32
ent;
-
U32
expire;
+
uint32_t
ent;
+
uint32_t
expire;
CmTimer **tmp;
CmTimer **tmp;
- TRC2(cmPlcCbTq)
expire = (arg->tqCp->nxtEnt + arg->wait);
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
expire = (arg->tqCp->nxtEnt + arg->wait);
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
- ent = (
U32)(expire % (U32
)(arg->tqCp->tmrLen));
+ ent = (
uint32_t)(expire % (uint32_t
)(arg->tqCp->tmrLen));
for (tmrNum = 0; tmrNum < arg->max; tmrNum++)
{
for (tmrNum = 0; tmrNum < arg->max; tmrNum++)
{
@@
-349,20
+316,19
@@
CmTmrArg *arg;
tmp = &((*tmp)->next);
*tmp = &arg->timers[tmrNum];
tmp = &((*tmp)->next);
*tmp = &arg->timers[tmrNum];
-
RETVOID
;
+
return
;
}
}
}
}
-
RETVOID
;
+
return
;
#else
#else
- REG1
U8
tmrNum;
-
U32
ent;
+ REG1
uint8_t
tmrNum;
+
uint32_t
ent;
CmTqType *tq;
CmTimer *target;
CmTqType *tq;
CmTimer *target;
- U32 expire;
- TRC2(cmPlcCbTq)
+ uint32_t expire;
expire = (arg->tqCp->nxtEnt + arg->wait);
expire = (arg->tqCp->nxtEnt + arg->wait);
- ent = (
U32)(expire % (U32
)(arg->tqCp->tmrLen));
+ ent = (
uint32_t)(expire % (uint32_t
)(arg->tqCp->tmrLen));
for (tmrNum = 0; tmrNum < arg->max; tmrNum++)
{
for (tmrNum = 0; tmrNum < arg->max; tmrNum++)
{
@@
-380,10
+346,10
@@
CmTmrArg *arg;
/* Place the timer block in the timer list */
CM_PLC_TQCP(tq, target);
/* Place the timer block in the timer list */
CM_PLC_TQCP(tq, target);
-
RETVOID
;
+
return
;
}
}
}
}
-
RETVOID
;
+
return
;
#endif
} /* end of cmPlcCbTq */
#endif
} /* end of cmPlcCbTq */
@@
-393,7
+359,7
@@
CmTmrArg *arg;
*
* Desc: Places Control Block on Timing Queue
*
*
* Desc: Places Control Block on Timing Queue
*
-* Ret:
RETVOID
+* Ret:
void
*
* Notes: None
*
*
* Notes: None
*
@@
-401,22
+367,13
@@
CmTmrArg *arg;
*
*/
*
*/
-#ifdef ANSI
-PUBLIC Void cmRstCbTq
-(
-CmTmrArg *arg
-)
-#else
-PUBLIC Void cmRstCbTq(arg)
-CmTmrArg *arg;
-#endif
+Void cmRstCbTq(CmTmrArg *arg)
{
{
- TRC2(cmRstCbTq)
arg->timers[arg->tNum].tqExpire = arg->tqCp->nxtEnt + arg->wait;
arg->timers[arg->tNum].ent2bUpd = TRUE;
arg->timers[arg->tNum].tqExpire = arg->tqCp->nxtEnt + arg->wait;
arg->timers[arg->tNum].ent2bUpd = TRUE;
-
RETVOID
;
+
return
;
} /* end of cmRstCbTq */
/*
} /* end of cmRstCbTq */
/*
@@
-425,7
+382,7
@@
CmTmrArg *arg;
*
* Desc: Removes control block from Timing Queue
*
*
* Desc: Removes control block from Timing Queue
*
-* Ret:
RETVOID
+* Ret:
void
*
* Notes: None
*
*
* Notes: None
*
@@
-433,31
+390,22
@@
CmTmrArg *arg;
*
*/
*
*/
-#ifdef ANSI
-PUBLIC Void cmRmvCbTq
-(
-CmTmrArg *arg
-)
-#else
-PUBLIC Void cmRmvCbTq(arg)
-CmTmrArg *arg;
-#endif
+Void cmRmvCbTq(CmTmrArg *arg)
{
/*Added FAP modifications*/
#ifdef SS_FAP
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
{
/*Added FAP modifications*/
#ifdef SS_FAP
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
-
U32
ent;
+
uint32_t
ent;
CmTimer *target;
CmTimer *tmp1;
CmTimer **tmp2;
CmTimer *target;
CmTimer *tmp1;
CmTimer **tmp2;
- TRC2(cmRmvCbTq)
target = &arg->timers[arg->tNum];
if (target->tmrEvnt != TMR_NONE)
{
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
target = &arg->timers[arg->tNum];
if (target->tmrEvnt != TMR_NONE)
{
/* cm_bdy5_c_002.113 - Modification for SRegCfgTmr support */
- ent = (
U32) (target->tqExpire % (U32
)(arg->tqCp->tmrLen));
+ ent = (
uint32_t) (target->tqExpire % (uint32_t
)(arg->tqCp->tmrLen));
tmp2 = &arg->tq[ent].first;
while ((tmp1 = *tmp2) != NULLP)
tmp2 = &arg->tq[ent].first;
while ((tmp1 = *tmp2) != NULLP)
@@
-477,19
+425,16
@@
CmTmrArg *arg;
tmp2 = &tmp1->next;
}
}
tmp2 = &tmp1->next;
}
}
-
RETVOID
;
+
return
;
#else
#else
-
U32
ent;
+
uint32_t
ent;
CmTimer *target;
CmTqType *tq;
CmTimer *target;
CmTqType *tq;
-
- TRC2(cmRmvCbTq)
-
target = &arg->timers[arg->tNum];
if (target->tmrEvnt != TMR_NONE)
{
target = &arg->timers[arg->tNum];
if (target->tmrEvnt != TMR_NONE)
{
- ent = (
U32
) (target->entIdx);
+ ent = (
uint32_t
) (target->entIdx);
tq = &arg->tq[ent];
/*
tq = &arg->tq[ent];
/*
@@
-506,7
+451,7
@@
CmTmrArg *arg;
target->cb = NULLP;
}
target->cb = NULLP;
}
-
RETVOID
;
+
return
;
#endif
} /* end of cmRmvCbTq */
#endif
} /* end of cmRmvCbTq */