Bluetooth: L2CAP: remove commented-out assert

This assert cannot be turned on, as `pdu` will be NULL sometimes. This
is okay, it just means that the current channel doesn't have anything to
send and that we should probably try another one.

Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
This commit is contained in:
Jonathan Rico 2024-08-16 08:44:19 +02:00 committed by Henrik Brix Andersen
commit cbb62333aa

View file

@ -903,11 +903,15 @@ struct net_buf *l2cap_data_pull(struct bt_conn *conn,
*/ */
struct net_buf *pdu = k_fifo_peek_head(&lechan->tx_queue); struct net_buf *pdu = k_fifo_peek_head(&lechan->tx_queue);
/* We don't have anything to send for the current channel. We could
* however have something to send on another channel that is attached to
* the same ACL connection. Re-trigger the TX processor: it will call us
* again and this time we will select another channel to pull data from.
*/
if (!pdu) { if (!pdu) {
bt_tx_irq_raise(); bt_tx_irq_raise();
return NULL; return NULL;
} }
/* __ASSERT(pdu, "signaled ready but no PDUs in the TX queue"); */
if (bt_buf_has_view(pdu)) { if (bt_buf_has_view(pdu)) {
LOG_ERR("already have view on %p", pdu); LOG_ERR("already have view on %p", pdu);