Rename Wld_i to _k_workload_i
Updating global variable's name to follow a consistent naming convention. Change accomplished with the following script: #!/bin/bash echo "Searching for ${1} to replace with ${2}" find ./ \( -name "*.[chs]" -o -name "sysgen.py" -o -name "*.kconf" \) \ ! -path "./host/src/genIdt/*" \ ! -path "*/outdir/*" | xargs sed -i 's/\b'${1}'\b/'${2}'/g'; Change-Id: I043f24f75c4f9bb6aa6358b1015519260d326d25 Signed-off-by: Yonattan Louise <yonattan.a.louise.mendoza@intel.com>
This commit is contained in:
parent
26874aabd6
commit
63ffb96a69
4 changed files with 10 additions and 10 deletions
|
@ -54,7 +54,7 @@ unsigned int _k_workload_t0 = 0x0;
|
|||
unsigned int _k_workload_t1 = 0x0;
|
||||
volatile unsigned int _k_workload_n0 = 0x0;
|
||||
volatile unsigned int _k_workload_n1 = 0x0;
|
||||
volatile unsigned int Wld_i = 0x0;
|
||||
volatile unsigned int _k_workload_i = 0x0;
|
||||
volatile unsigned int Wld_i0 = 0x0;
|
||||
volatile unsigned int WldTDelta = 0x0;
|
||||
volatile unsigned int WldT_start = 0x0;
|
||||
|
@ -72,7 +72,7 @@ extern uint32_t K_wl_scale;
|
|||
*
|
||||
* Perform idle task "dummy work".
|
||||
*
|
||||
* This routine increments Wld_i and checks it against _k_workload_n1. _k_workload_n1 is updated
|
||||
* This routine increments _k_workload_i and checks it against _k_workload_n1. _k_workload_n1 is updated
|
||||
* by the system tick handler, and both are kept in close synchronization.
|
||||
*
|
||||
* RETURNS: N/A
|
||||
|
@ -84,7 +84,7 @@ static void _WlLoop(void)
|
|||
volatile int x = 87654321;
|
||||
volatile int y = 4;
|
||||
|
||||
while (++Wld_i != _k_workload_n1) /* except for the calibration phase,
|
||||
while (++_k_workload_i != _k_workload_n1) /* except for the calibration phase,
|
||||
* this while loop should always be true.
|
||||
*/
|
||||
{
|
||||
|
@ -113,7 +113,7 @@ static void _WlLoop(void)
|
|||
|
||||
void wlMonitorCalibrate(void)
|
||||
{
|
||||
_k_workload_n0 = Wld_i = 0;
|
||||
_k_workload_n0 = _k_workload_i = 0;
|
||||
_k_workload_n1 = 1000;
|
||||
|
||||
_k_workload_t0 = timer_read();
|
||||
|
@ -121,7 +121,7 @@ void wlMonitorCalibrate(void)
|
|||
_k_workload_t1 = timer_read();
|
||||
|
||||
WldTDelta = _k_workload_t1 - _k_workload_t0;
|
||||
Wld_i0 = Wld_i;
|
||||
Wld_i0 = _k_workload_i;
|
||||
#ifdef WL_SCALE
|
||||
_k_workload_ref_time = (_k_workload_t1 - _k_workload_t0) >> (K_wl_scale);
|
||||
#else
|
||||
|
@ -141,7 +141,7 @@ void K_workload(struct k_args *P)
|
|||
unsigned int k, t;
|
||||
signed int iret;
|
||||
|
||||
k = (Wld_i - _k_workload_n0) * _k_workload_ref_time;
|
||||
k = (_k_workload_i - _k_workload_n0) * _k_workload_ref_time;
|
||||
#ifdef WL_SCALE
|
||||
t = (timer_read() - _k_workload_t0) >> (K_wl_scale);
|
||||
#else
|
||||
|
|
|
@ -46,7 +46,7 @@ extern unsigned int _k_workload_t0;
|
|||
extern unsigned int _k_workload_t1;
|
||||
extern volatile unsigned int _k_workload_n0;
|
||||
extern volatile unsigned int _k_workload_n1;
|
||||
extern volatile unsigned int Wld_i;
|
||||
extern volatile unsigned int _k_workload_i;
|
||||
extern volatile unsigned int Wld_i0;
|
||||
extern volatile unsigned int WldTDelta;
|
||||
extern volatile unsigned int WldT_start;
|
||||
|
|
|
@ -140,7 +140,7 @@ static inline void _WlMonitorUpdate(void)
|
|||
_k_workload_t0 = _k_workload_t1;
|
||||
_k_workload_t1 = timer_read();
|
||||
_k_workload_n0 = _k_workload_n1;
|
||||
_k_workload_n1 = Wld_i - 1;
|
||||
_k_workload_n1 = _k_workload_i - 1;
|
||||
_k_workload_ticks = _k_workload_slice;
|
||||
}
|
||||
#else
|
||||
|
|
|
@ -142,7 +142,7 @@ FUNC_NORETURN void K_swapper(int parameter1, /* not used */
|
|||
* Workload variable update in case of
|
||||
* power save mode
|
||||
*/
|
||||
extern volatile unsigned int Wld_i;
|
||||
extern volatile unsigned int _k_workload_i;
|
||||
extern volatile unsigned int Wld_i0;
|
||||
extern volatile unsigned int WldTDelta;
|
||||
extern volatile unsigned int WldT_start;
|
||||
|
@ -153,7 +153,7 @@ FUNC_NORETURN void K_swapper(int parameter1, /* not used */
|
|||
}
|
||||
if (_k_current_task->Ident == 0x00000000) {
|
||||
WldT_end = timer_read();
|
||||
Wld_i += (Wld_i0 * (WldT_end - WldT_start)) /
|
||||
_k_workload_i += (Wld_i0 * (WldT_end - WldT_start)) /
|
||||
WldTDelta;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue