Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bluetooth: controller: Assert in data length update procedure #23069

Closed
cvinayak opened this issue Feb 25, 2020 · 0 comments · Fixed by #23061 or #23071
Closed

Bluetooth: controller: Assert in data length update procedure #23069

cvinayak opened this issue Feb 25, 2020 · 0 comments · Fixed by #23061 or #23071
Assignees
Labels
area: Bluetooth bug The issue is a bug, or the PR is fixing a bug priority: high High impact/importance bug
Milestone

Comments

@cvinayak
Copy link
Contributor

Describe the bug
Seen (both on real phone and in simulation) that the LLCP system can crash if a connection event was lost due to scheduling conflicts.

A slave device that both advertises and has a connection with a master phone. On the connection the master makes a PHY update followed by the save doing a length update. After the PHY update instant the master does a new length update. Unfortunately the master length update is placed at the connection event right after the PHY update, but the connection event that the PHY update is to take place is lost on the slave due to scheduling conflict with the advertiser role. Due to the lost event the LLCP machine has not been run prior to handling the length update on the slave and the LLCP machine is now in the wrong state.

ull_conn.c:4635 ull_conn_rx ASSERT(pdu_rx -->llctrl.opcode == PDU_DATA_LLCTRL_TYPE_LENGTH_RSP)

To Reproduce
(assuming the below build process, as the issue is reported by someone else)
Steps to reproduce the behavior:

  1. mkdir build; cd build
  2. cmake -DBOARD=board\nrf52_pca10040 ../samples/bluetooth/peripheral
  3. make
  4. See error

Expected behavior
No assertion

Impact
showstopper

Screenshots or console output
If applicable, add a screenshot (drag-and-drop an image), or console logs
(cut-and-paste text and put a code fence (```) before and after, to help
explain the issue.
image

Environment (please complete the following information):

  • OS: Linux
  • Toolchain: Zephyr SDK
  • Commit SHA or Version used: 58908aa

Additional context
Add any other context about the problem here. None

@cvinayak cvinayak added bug The issue is a bug, or the PR is fixing a bug priority: high High impact/importance bug area: Bluetooth labels Feb 25, 2020
@cvinayak cvinayak added this to the v2.2.0 milestone Feb 25, 2020
cvinayak added a commit to cvinayak/zephyr that referenced this issue Feb 25, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes zephyrproject-rtos#23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
cvinayak added a commit to cvinayak/zephyr that referenced this issue Feb 25, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes zephyrproject-rtos#23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
aescolar pushed a commit that referenced this issue Feb 25, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes #23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
jhedberg pushed a commit that referenced this issue Feb 28, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes #23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
hakehuang pushed a commit to hakehuang/zephyr that referenced this issue Mar 18, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes zephyrproject-rtos#23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
cvinayak added a commit to cvinayak/zephyr that referenced this issue Sep 23, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes zephyrproject-rtos#23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
nashif pushed a commit that referenced this issue Nov 17, 2020
Fix local initiated Data Length Update procedure from being
stalled when a remote initiates a procedure with instant.

Fixes #23069.

Signed-off-by: Vinayak Kariappa Chettimada <vich@nordicsemi.no>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Bluetooth bug The issue is a bug, or the PR is fixing a bug priority: high High impact/importance bug
Projects
None yet
2 participants