@@ -332,7 +332,6 @@ static void _on_data(nimble_netif_conn_t *conn, struct ble_l2cap_event *event)
332332 ble_l2cap_recv_ready (event -> receive .chan , rxb );
333333}
334334
335- #ifdef MODULE_GNRC_IPV6
336335/**
337336 * @brief Sends a netapi notification for a connection event.
338337 *
@@ -351,7 +350,6 @@ static inline void _dispatch_connection_event(netapi_notify_t notify, uint8_t *a
351350 gnrc_netapi_notify (GNRC_NETTYPE_L2_DISCOVERY , GNRC_NETREG_DEMUX_CTX_ALL ,
352351 notify , & event , sizeof (netapi_notify_l2_connection_t ));
353352}
354- #endif /* MODULE_GNRC_IPV6 */
355353
356354static int _on_l2cap_client_evt (struct ble_l2cap_event * event , void * arg )
357355{
@@ -371,9 +369,9 @@ static int _on_l2cap_client_evt(struct ble_l2cap_event *event, void *arg)
371369 conn -> state |= NIMBLE_NETIF_L2CAP_CLIENT ;
372370 conn -> state &= ~NIMBLE_NETIF_CONNECTING ;
373371 _notify (handle , NIMBLE_NETIF_CONNECTED_MASTER , conn -> addr );
374- #ifdef MODULE_GNRC_IPV6
372+ #if IS_USED ( MODULE_GNRC_NETAPI_NOTIFY )
375373 _dispatch_connection_event (NETAPI_NOTIFY_L2_NEIGH_CONNECTED , conn -> addr );
376- #endif /* MODULE_GNRC_IPV6 */
374+ #endif /* MODULE_GNRC_NETAPI_NOTIFY */
377375 break ;
378376 case BLE_L2CAP_EVENT_COC_DISCONNECTED :
379377 assert (conn -> state & NIMBLE_NETIF_L2CAP_CLIENT );
@@ -429,9 +427,9 @@ static int _on_l2cap_server_evt(struct ble_l2cap_event *event, void *arg)
429427 }
430428
431429 _notify (handle , NIMBLE_NETIF_CONNECTED_SLAVE , conn -> addr );
432- #ifdef MODULE_GNRC_IPV6
430+ #if IS_USED ( MODULE_GNRC_NETAPI_NOTIFY )
433431 _dispatch_connection_event (NETAPI_NOTIFY_L2_NEIGH_CONNECTED , conn -> addr );
434- #endif /* MODULE_GNRC_IPV6 */
432+ #endif /* MODULE_GNRC_NETAPI_NOTIFY */
435433 break ;
436434 case BLE_L2CAP_EVENT_COC_DISCONNECTED :
437435 conn = nimble_netif_conn_from_gaphandle (event -> disconnect .conn_handle );
@@ -526,9 +524,9 @@ static int _on_gap_master_evt(struct ble_gap_event *event, void *arg)
526524 nimble_netif_conn_free (handle , addr );
527525 thread_flags_set (_netif_thread , FLAG_TX_NOTCONN );
528526 _notify (handle , type , addr );
529- #ifdef MODULE_GNRC_IPV6
527+ #if IS_USED ( MODULE_GNRC_NETAPI_NOTIFY )
530528 _dispatch_connection_event (NETAPI_NOTIFY_L2_NEIGH_DISCONNECTED , addr );
531- #endif /* MODULE_GNRC_IPV6 */
529+ #endif /* MODULE_GNRC_NETAPI_NOTIFY */
532530 break ;
533531 }
534532 case BLE_GAP_EVENT_CONN_UPDATE :
@@ -573,9 +571,9 @@ static int _on_gap_slave_evt(struct ble_gap_event *event, void *arg)
573571 nimble_netif_conn_free (handle , addr );
574572 thread_flags_set (_netif_thread , FLAG_TX_NOTCONN );
575573 _notify (handle , type , addr );
576- #ifdef MODULE_GNRC_IPV6
574+ #if IS_USED ( MODULE_GNRC_NETAPI_NOTIFY )
577575 _dispatch_connection_event (NETAPI_NOTIFY_L2_NEIGH_DISCONNECTED , addr );
578- #endif /* MODULE_GNRC_IPV6 */
576+ #endif /* MODULE_GNRC_NETAPI_NOTIFY */
579577 break ;
580578 }
581579 case BLE_GAP_EVENT_CONN_UPDATE :
0 commit comments