Commit a7da99f4 authored by Tomasz Wlostowski's avatar Tomasz Wlostowski Committed by Alessandro Rubini

softpll: fix incorrect sign in ptracker sign wraparound check

parent fe7251ba
......@@ -33,19 +33,18 @@ void ptracker_start(struct spll_ptracker_state *s)
s->avg_count = 0;
spll_enable_tagger(s->id, 1);
spll_enable_tagger(spll_n_chan_ref, 1);
}
int ptrackers_update(struct spll_ptracker_state *ptrackers, int tag,
int source)
{
const int adj_tab[16] = { /* psign */
/* 0 - 1/4 */ 0, 0, 0, (1<<HPLL_N),
/* 0 - 1/4 */ 0, 0, 0, -(1<<HPLL_N),
/* 1/4 - 1/2 */ 0, 0, 0, 0,
/* 1/2 - 3/4 */ 0, 0, 0, 0,
/* 3/4 - 1 */ (1<<HPLL_N), 0, 0, 0};
if (source > spll_n_chan_ref)
return 0;
if(source == spll_n_chan_ref)
{
tag_ref = tag;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment