Commit 5220e7e
committed
nimble/ll: Fix race condition in aux scan
This fixes race condition in aux scan what was observed on Harmony.
During extended scan, the HCI Reset called, that stops the active
scan and clears the scan state machine. The scan stop itself,
if scan response is pending, and calls ble_ll_scan_aux_sched_remove
that pokes the active scan backup (from LL via event queue).
The problem is that the SM is cleared already when backoff is called,
which causes an assert in ble_ll_scan_req_backoff function.
This change ensures the ble_ll_scan_req_backoff is called from
ble_ll_reset() function context. ble_ll_reset is always called
from LL task context.1 parent 9de025c commit 5220e7e
2 files changed
+31
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
682 | 682 | | |
683 | 683 | | |
684 | 684 | | |
685 | | - | |
| 685 | + | |
686 | 686 | | |
687 | | - | |
688 | | - | |
689 | 687 | | |
690 | 688 | | |
691 | 689 | | |
| |||
701 | 699 | | |
702 | 700 | | |
703 | 701 | | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
704 | 717 | | |
705 | 718 | | |
706 | 719 | | |
| |||
710 | 723 | | |
711 | 724 | | |
712 | 725 | | |
713 | | - | |
714 | | - | |
| 726 | + | |
715 | 727 | | |
716 | 728 | | |
717 | 729 | | |
| |||
1766 | 1778 | | |
1767 | 1779 | | |
1768 | 1780 | | |
1769 | | - | |
| 1781 | + | |
| 1782 | + | |
| 1783 | + | |
| 1784 | + | |
| 1785 | + | |
| 1786 | + | |
| 1787 | + | |
| 1788 | + | |
| 1789 | + | |
| 1790 | + | |
| 1791 | + | |
| 1792 | + | |
| 1793 | + | |
1770 | 1794 | | |
1771 | 1795 | | |
1772 | 1796 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
942 | 942 | | |
943 | 943 | | |
944 | 944 | | |
945 | | - | |
946 | 945 | | |
| 946 | + | |
947 | 947 | | |
948 | 948 | | |
949 | 949 | | |
| |||
0 commit comments