From 27235e023f150c3bc6d57b0a801d5ebad8719805 Mon Sep 17 00:00:00 2001 From: baohongde Date: Thu, 31 Jan 2019 11:47:41 +0800 Subject: [PATCH 1/2] components/bt: Fix crash when inquiry stop --- components/bt/lib | 2 +- components/esp32/ld/esp32.rom.ld | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/components/bt/lib b/components/bt/lib index 06c3f28c4..26421fbe8 160000 --- a/components/bt/lib +++ b/components/bt/lib @@ -1 +1 @@ -Subproject commit 06c3f28c442984328a8c8f7a38d3c60c7f863e0e +Subproject commit 26421fbe8f5d1f4f61c32e3b9f6c14839439ab2c diff --git a/components/esp32/ld/esp32.rom.ld b/components/esp32/ld/esp32.rom.ld index 14e177639..c1e3e94bc 100644 --- a/components/esp32/ld/esp32.rom.ld +++ b/components/esp32/ld/esp32.rom.ld @@ -89,6 +89,8 @@ PROVIDE ( esp_crc8 = 0x4005d144 ); PROVIDE ( _etext = 0x4000d66c ); PROVIDE ( ets_readySet_ = 0x3ffe01f0 ); PROVIDE ( ets_startup_callback = 0x3ffe0404 ); +PROVIDE ( rwip_coex_cfg = 0x3ff9914c ); +PROVIDE ( rwip_priority = 0x3ff99159 ); PROVIDE ( exc_cause_table = 0x3ff991d0 ); PROVIDE ( _exit_r = 0x4000bd28 ); PROVIDE ( free = 0x4000beb8 ); @@ -676,6 +678,9 @@ PROVIDE ( ld_sco_modify = 0x40031778 ); PROVIDE ( lm_cmd_cmp_send = 0x40051838 ); PROVIDE ( ld_sco_frm_cbk = 0x400349dc ); PROVIDE ( ld_acl_sniff_frm_cbk = 0x4003482c ); +PROVIDE ( ld_inq_end = 0x4003ab48 ); +PROVIDE ( ld_inq_sched = 0x4003aba4 ); +PROVIDE ( ld_inq_frm_cbk = 0x4003ae4c ); PROVIDE ( r_ld_acl_active_hop_types_get = 0x40036e10 ); PROVIDE ( r_ld_acl_afh_confirm = 0x40036d40 ); PROVIDE ( r_ld_acl_afh_prepare = 0x40036c84 ); From e87d05d81f12e4ee5b26a5a50860dcc741eba668 Mon Sep 17 00:00:00 2001 From: baohongde Date: Wed, 23 Jan 2019 18:04:01 +0800 Subject: [PATCH 2/2] components/bt: Add precautions for esp_vhci_host_send_packet --- components/bt/include/esp_bt.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/components/bt/include/esp_bt.h b/components/bt/include/esp_bt.h index b1dbc6467..b098c133d 100644 --- a/components/bt/include/esp_bt.h +++ b/components/bt/include/esp_bt.h @@ -326,8 +326,12 @@ bool esp_vhci_host_check_send_available(void); /** @brief esp_vhci_host_send_packet * host send packet to controller + * + * Should not call this function from within a critical section + * or when the scheduler is suspended. + * * @param data the packet point - *,@param len the packet length + * @param len the packet length */ void esp_vhci_host_send_packet(uint8_t *data, uint16_t len); @@ -453,11 +457,11 @@ void esp_bt_controller_wakeup_request(void); /** * @brief Manually clear scan duplicate list - * + * * Note that scan duplicate list will be automatically cleared when the maximum amount of device in the filter is reached * the amount of device in the filter can be configured in menuconfig. - * - * + * + * * @return * - ESP_OK : success * - other : failed