target/fw/layer1: correctly initialize afc_retries
authorSteve Markgraf <steve@steve-m.de>
Mon, 25 Oct 2010 16:05:04 +0000 (18:05 +0200)
committerSylvain Munaut <tnt@246tNt.com>
Mon, 25 Oct 2010 18:59:24 +0000 (20:59 +0200)
Otherwise, when it reached AFC_RETRY_COUNT, no new FB0 tasks
were scheduled, and you needed to restart the phone in order to
successfully sync to a cell

Signed-off-by: Steve Markgraf <steve@steve-m.de>
src/target/firmware/layer1/prim_fbsb.c

index c8c9a86..5177651 100644 (file)
@@ -549,6 +549,7 @@ void l1s_fbsb_req(uint8_t base_fn, struct l1ctl_fbsb_req *req)
        /* clear initial frequency error */
        fbs.initial_freq_err = 0;
        fbs.fb_retries = 0;
+       fbs.afc_retries = 0;
 
        /* Make sure we start at a 'center' AFCDAC output value */
        afc_reset();