JaydenH215 commented on issue #712: A case in ble_ll_sched_adv_reschedule
URL: https://github.com/apache/mynewt-nimble/issues/712#issuecomment-573572939
 
 
   > Yes, it may overlap the next_sch
   > 
   > and the procedure will judge whether it is overlapped it in the next 
iteration in this while loop, the procedure will go and find the right position 
until the end of the Q.
   > 
   > U can refer this doc.
   > https://wnnwoo.github.io/2020/01/05/nimble-scheduler/
   
   ```
       if (entry == end_overlap) {
           rand_ticks = (orig_start + max_delay_ticks) - sch->start_time;
           if (rand_ticks > max_delay_ticks) {
               /* No place for advertisement. */
               rc = -1;
           } else {
               if (next_sch == NULL) {
                   TAILQ_INSERT_TAIL(&g_ble_ll_sched_q, sch, link);
               } else {
                   TAILQ_INSERT_BEFORE(next_sch, sch, link);
               }
           }
           break;
       }
   ```
   
   But the latter condition should be true, it will 'break' and will not enter 
the while again.
   I have read your blog and thank you for sharing. I am also learning nimble 
and hope to make friends with you. 
   
   [https://jaydenh215.github.io/](https://jaydenh215.github.io/)
   
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to