You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by cc...@apache.org on 2016/07/15 04:30:01 UTC
[4/9] incubator-mynewt-core git commit: BLE Host - Move logging into
separate file.
BLE Host - Move logging into separate file.
Project: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/commit/621629d6
Tree: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/tree/621629d6
Diff: http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/diff/621629d6
Branch: refs/heads/develop
Commit: 621629d6782b5af120006a818f75f1d131f21f17
Parents: c487de2
Author: Christopher Collins <cc...@apache.org>
Authored: Thu Jul 14 12:02:57 2016 -0700
Committer: Christopher Collins <cc...@apache.org>
Committed: Thu Jul 14 21:26:09 2016 -0700
----------------------------------------------------------------------
net/nimble/host/include/host/ble_hs.h | 5 ++-
net/nimble/host/include/host/ble_hs_log.h | 39 +++++++++++++++++++++
net/nimble/host/src/ble_hs.c | 1 -
net/nimble/host/src/ble_hs_log.c | 47 ++++++++++++++++++++++++++
net/nimble/host/src/ble_hs_misc.c | 24 -------------
net/nimble/host/src/ble_hs_priv.h | 12 -------
net/nimble/host/src/ble_l2cap_sig.c | 2 +-
net/nimble/host/src/ble_sm_alg.c | 36 ++++++++++----------
net/nimble/host/src/ble_sm_cmd.c | 16 ++++-----
net/nimble/host/src/ble_sm_sc.c | 8 ++---
net/nimble/host/src/host_hci.c | 4 +--
net/nimble/host/src/host_hci_cmd.c | 2 +-
12 files changed, 124 insertions(+), 72 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/include/host/ble_hs.h
----------------------------------------------------------------------
diff --git a/net/nimble/host/include/host/ble_hs.h b/net/nimble/host/include/host/ble_hs.h
index 61900b6..dbc8a5b 100644
--- a/net/nimble/host/include/host/ble_hs.h
+++ b/net/nimble/host/include/host/ble_hs.h
@@ -25,9 +25,12 @@
#include "host/ble_gap.h"
#include "host/ble_gatt.h"
#include "host/ble_hs.h"
+#include "host/ble_hs_adv.h"
+#include "host/ble_hs_log.h"
#include "host/ble_hs_test.h"
-#include "host/ble_uuid.h"
+#include "host/ble_sm.h"
#include "host/ble_store.h"
+#include "host/ble_uuid.h"
#include "host/host_hci.h"
struct os_eventq;
struct os_event;
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/include/host/ble_hs_log.h
----------------------------------------------------------------------
diff --git a/net/nimble/host/include/host/ble_hs_log.h b/net/nimble/host/include/host/ble_hs_log.h
new file mode 100644
index 0000000..fd10ddb
--- /dev/null
+++ b/net/nimble/host/include/host/ble_hs_log.h
@@ -0,0 +1,39 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#ifndef H_BLE_HS_LOG_
+#define H_BLE_HS_LOG_
+
+#include "log/log.h"
+struct os_mbuf;
+
+extern struct log ble_hs_log;
+
+#define BLE_HS_LOG(lvl, ...) \
+ LOG_ ## lvl(&ble_hs_log, LOG_MODULE_NIMBLE_HOST, __VA_ARGS__)
+
+#define BLE_HS_LOG_ADDR(lvl, addr) \
+ BLE_HS_LOG(lvl, "%02x:%02x:%02x:%02x:%02x:%02x", \
+ (addr)[5], (addr)[4], (addr)[3], \
+ (addr)[2], (addr)[1], (addr)[0])
+
+void ble_hs_log_mbuf(const struct os_mbuf *om);
+void ble_hs_log_flat_buf(const void *data, int len);
+
+#endif
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_hs.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_hs.c b/net/nimble/host/src/ble_hs.c
index 8f3cd1b..e3f83f2 100644
--- a/net/nimble/host/src/ble_hs.c
+++ b/net/nimble/host/src/ble_hs.c
@@ -37,7 +37,6 @@
#define BLE_HS_MAX_EVS_IN_A_ROW 2
static struct log_handler ble_hs_log_console_handler;
-struct log ble_hs_log;
struct os_mempool g_hci_evt_pool;
static void *ble_hs_hci_evt_buf;
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_hs_log.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_hs_log.c b/net/nimble/host/src/ble_hs_log.c
new file mode 100644
index 0000000..3929483
--- /dev/null
+++ b/net/nimble/host/src/ble_hs_log.c
@@ -0,0 +1,47 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied. See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+#include "os/os.h"
+#include "host/ble_hs.h"
+
+struct log ble_hs_log;
+
+void
+ble_hs_log_mbuf(const struct os_mbuf *om)
+{
+ uint8_t u8;
+ int i;
+
+ for (i = 0; i < OS_MBUF_PKTLEN(om); i++) {
+ os_mbuf_copydata(om, i, 1, &u8);
+ BLE_HS_LOG(DEBUG, "0x%02x ", u8);
+ }
+}
+
+void
+ble_hs_log_flat_buf(const void *data, int len)
+{
+ const uint8_t *u8ptr;
+ int i;
+
+ u8ptr = data;
+ for (i = 0; i < len; i++) {
+ BLE_HS_LOG(DEBUG, "0x%02x ", u8ptr[i]);
+ }
+}
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_hs_misc.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_hs_misc.c b/net/nimble/host/src/ble_hs_misc.c
index b893cd3..616b0b5 100644
--- a/net/nimble/host/src/ble_hs_misc.c
+++ b/net/nimble/host/src/ble_hs_misc.c
@@ -45,30 +45,6 @@ ble_hs_misc_malloc_mempool(void **mem, struct os_mempool *pool,
return 0;
}
-void
-ble_hs_misc_log_mbuf(const struct os_mbuf *om)
-{
- uint8_t u8;
- int i;
-
- for (i = 0; i < OS_MBUF_PKTLEN(om); i++) {
- os_mbuf_copydata(om, i, 1, &u8);
- BLE_HS_LOG(DEBUG, "0x%02x ", u8);
- }
-}
-
-void
-ble_hs_misc_log_flat_buf(const void *data, int len)
-{
- const uint8_t *u8ptr;
- int i;
-
- u8ptr = data;
- for (i = 0; i < len; i++) {
- BLE_HS_LOG(DEBUG, "0x%02x ", u8ptr[i]);
- }
-}
-
/**
* Allocates an mbuf for use by the nimble host.
*/
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_hs_priv.h
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_hs_priv.h b/net/nimble/host/src/ble_hs_priv.h
index e6fe55e..bb78b5e 100644
--- a/net/nimble/host/src/ble_hs_priv.h
+++ b/net/nimble/host/src/ble_hs_priv.h
@@ -40,7 +40,6 @@
#include "ble_hs_id_priv.h"
#include "ble_uuid_priv.h"
#include "host/ble_hs.h"
-#include "log/log.h"
#include "nimble/nimble_opt.h"
#include "stats/stats.h"
struct ble_hs_conn;
@@ -62,7 +61,6 @@ extern STATS_SECT_DECL(ble_hs_stats) ble_hs_stats;
extern struct ble_hs_cfg ble_hs_cfg;
extern struct os_mbuf_pool ble_hs_mbuf_pool;
-extern struct log ble_hs_log;
extern const uint8_t ble_hs_misc_null_addr[6];
@@ -72,8 +70,6 @@ int ble_hs_tx_data(struct os_mbuf *om);
int ble_hs_misc_malloc_mempool(void **mem, struct os_mempool *pool,
int num_entries, int entry_size, char *name);
-void ble_hs_misc_log_mbuf(const struct os_mbuf *om);
-void ble_hs_misc_log_flat_buf(const void *data, int len);
int ble_hs_misc_conn_chan_find(uint16_t conn_handle, uint16_t cid,
struct ble_hs_conn **out_conn,
struct ble_l2cap_chan **out_chan);
@@ -94,14 +90,6 @@ struct os_mbuf *ble_hs_misc_pkthdr(void);
int ble_hs_misc_pullup_base(struct os_mbuf **om, int base_len);
-#define BLE_HS_LOG(lvl, ...) \
- LOG_ ## lvl(&ble_hs_log, LOG_MODULE_NIMBLE_HOST, __VA_ARGS__)
-
-#define BLE_HS_LOG_ADDR(lvl, addr) \
- BLE_HS_LOG(lvl, "%02x:%02x:%02x:%02x:%02x:%02x", \
- (addr)[5], (addr)[4], (addr)[3], \
- (addr)[2], (addr)[1], (addr)[0])
-
#if LOG_LEVEL <= LOG_LEVEL_DEBUG
#define BLE_HS_LOG_CMD(is_tx, cmd_type, cmd_name, conn_handle, \
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_l2cap_sig.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_l2cap_sig.c b/net/nimble/host/src/ble_l2cap_sig.c
index e75f06f..dd418f2 100644
--- a/net/nimble/host/src/ble_l2cap_sig.c
+++ b/net/nimble/host/src/ble_l2cap_sig.c
@@ -479,7 +479,7 @@ ble_l2cap_sig_rx(uint16_t conn_handle, struct os_mbuf **om)
STATS_INC(ble_l2cap_stats, sig_rx);
BLE_HS_LOG(DEBUG, "L2CAP - rxed signalling msg: ");
- ble_hs_misc_log_mbuf(*om);
+ ble_hs_log_mbuf(*om);
BLE_HS_LOG(DEBUG, "\n");
rc = ble_hs_misc_pullup_base(om, BLE_L2CAP_SIG_HDR_SZ);
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_sm_alg.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_sm_alg.c b/net/nimble/host/src/ble_sm_alg.c
index b8e8530..3aac60d 100644
--- a/net/nimble/host/src/ble_sm_alg.c
+++ b/net/nimble/host/src/ble_sm_alg.c
@@ -72,7 +72,7 @@ static void
ble_sm_alg_log_buf(const char *name, const uint8_t *buf, int len)
{
BLE_HS_LOG(DEBUG, " %s=", name);
- ble_hs_misc_log_flat_buf(buf, len);
+ ble_hs_log_flat_buf(buf, len);
BLE_HS_LOG(DEBUG, "\n");
}
@@ -166,13 +166,13 @@ ble_sm_alg_s1(uint8_t *k, uint8_t *r1, uint8_t *r2, uint8_t *out)
}
BLE_HS_LOG(DEBUG, "ble_sm_alg_s1()\n k=");
- ble_hs_misc_log_flat_buf(k, 16);
+ ble_hs_log_flat_buf(k, 16);
BLE_HS_LOG(DEBUG, "\n r1=");
- ble_hs_misc_log_flat_buf(r1, 16);
+ ble_hs_log_flat_buf(r1, 16);
BLE_HS_LOG(DEBUG, "\n r2=");
- ble_hs_misc_log_flat_buf(r2, 16);
+ ble_hs_log_flat_buf(r2, 16);
BLE_HS_LOG(DEBUG, "\n out=");
- ble_hs_misc_log_flat_buf(out, 16);
+ ble_hs_log_flat_buf(out, 16);
BLE_HS_LOG(DEBUG, "\n");
return 0;
@@ -189,18 +189,18 @@ ble_sm_alg_c1(uint8_t *k, uint8_t *r,
int rc;
BLE_HS_LOG(DEBUG, "ble_sm_alg_c1()\n k=");
- ble_hs_misc_log_flat_buf(k, 16);
+ ble_hs_log_flat_buf(k, 16);
BLE_HS_LOG(DEBUG, "\n r=");
- ble_hs_misc_log_flat_buf(r, 16);
+ ble_hs_log_flat_buf(r, 16);
BLE_HS_LOG(DEBUG, "\n iat=%d rat=%d", iat, rat);
BLE_HS_LOG(DEBUG, "\n ia=");
- ble_hs_misc_log_flat_buf(ia, 6);
+ ble_hs_log_flat_buf(ia, 6);
BLE_HS_LOG(DEBUG, "\n ra=");
- ble_hs_misc_log_flat_buf(ra, 6);
+ ble_hs_log_flat_buf(ra, 6);
BLE_HS_LOG(DEBUG, "\n preq=");
- ble_hs_misc_log_flat_buf(preq, 7);
+ ble_hs_log_flat_buf(preq, 7);
BLE_HS_LOG(DEBUG, "\n pres=");
- ble_hs_misc_log_flat_buf(pres, 7);
+ ble_hs_log_flat_buf(pres, 7);
/* pres, preq, rat and iat are concatenated to generate p1 */
p1[0] = iat;
@@ -209,7 +209,7 @@ ble_sm_alg_c1(uint8_t *k, uint8_t *r,
memcpy(p1 + 9, pres, 7);
BLE_HS_LOG(DEBUG, "\n p1=");
- ble_hs_misc_log_flat_buf(p1, sizeof p1);
+ ble_hs_log_flat_buf(p1, sizeof p1);
/* c1 = e(k, e(k, r XOR p1) XOR p2) */
@@ -228,7 +228,7 @@ ble_sm_alg_c1(uint8_t *k, uint8_t *r,
memset(p2 + 12, 0, 4);
BLE_HS_LOG(DEBUG, "\n p2=");
- ble_hs_misc_log_flat_buf(p2, sizeof p2);
+ ble_hs_log_flat_buf(p2, sizeof p2);
ble_sm_alg_xor_128(out_enc_data, p2, out_enc_data);
@@ -239,7 +239,7 @@ ble_sm_alg_c1(uint8_t *k, uint8_t *r,
}
BLE_HS_LOG(DEBUG, "\n out_enc_data=");
- ble_hs_misc_log_flat_buf(out_enc_data, 16);
+ ble_hs_log_flat_buf(out_enc_data, 16);
rc = 0;
@@ -257,11 +257,11 @@ ble_sm_alg_f4(uint8_t *u, uint8_t *v, uint8_t *x, uint8_t z,
int rc;
BLE_HS_LOG(DEBUG, "ble_sm_alg_f4()\n u=");
- ble_hs_misc_log_flat_buf(u, 32);
+ ble_hs_log_flat_buf(u, 32);
BLE_HS_LOG(DEBUG, "\n v=");
- ble_hs_misc_log_flat_buf(v, 32);
+ ble_hs_log_flat_buf(v, 32);
BLE_HS_LOG(DEBUG, "\n x=");
- ble_hs_misc_log_flat_buf(x, 16);
+ ble_hs_log_flat_buf(x, 16);
BLE_HS_LOG(DEBUG, "\n z=0x%02x\n", z);
/*
@@ -287,7 +287,7 @@ ble_sm_alg_f4(uint8_t *u, uint8_t *v, uint8_t *x, uint8_t z,
swap_in_place(out_enc_data, 16);
BLE_HS_LOG(DEBUG, " out_enc_data=");
- ble_hs_misc_log_flat_buf(out_enc_data, 16);
+ ble_hs_log_flat_buf(out_enc_data, 16);
BLE_HS_LOG(DEBUG, "\n");
return 0;
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_sm_cmd.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_sm_cmd.c b/net/nimble/host/src/ble_sm_cmd.c
index 3d506b2..5f5026f 100644
--- a/net/nimble/host/src/ble_sm_cmd.c
+++ b/net/nimble/host/src/ble_sm_cmd.c
@@ -226,7 +226,7 @@ void
ble_sm_pair_confirm_log(struct ble_sm_pair_confirm *cmd)
{
BLE_HS_LOG(DEBUG, "value=");
- ble_hs_misc_log_flat_buf(cmd->value, sizeof cmd->value);
+ ble_hs_log_flat_buf(cmd->value, sizeof cmd->value);
}
void
@@ -279,7 +279,7 @@ void
ble_sm_pair_random_log(struct ble_sm_pair_random *cmd)
{
BLE_HS_LOG(DEBUG, "value=");
- ble_hs_misc_log_flat_buf(cmd->value, sizeof cmd->value);
+ ble_hs_log_flat_buf(cmd->value, sizeof cmd->value);
}
void
@@ -388,7 +388,7 @@ void
ble_sm_enc_info_log(struct ble_sm_enc_info *cmd)
{
BLE_HS_LOG(DEBUG, "ltk=");
- ble_hs_misc_log_flat_buf(cmd->ltk, sizeof cmd->ltk);
+ ble_hs_log_flat_buf(cmd->ltk, sizeof cmd->ltk);
}
void
@@ -499,7 +499,7 @@ void
ble_sm_id_info_log(struct ble_sm_id_info *cmd)
{
BLE_HS_LOG(DEBUG, "irk=");
- ble_hs_misc_log_flat_buf(cmd->irk, sizeof cmd->irk);
+ ble_hs_log_flat_buf(cmd->irk, sizeof cmd->irk);
}
void
@@ -605,7 +605,7 @@ void
ble_sm_sign_info_log(struct ble_sm_sign_info *cmd)
{
BLE_HS_LOG(DEBUG, "sig_key=");
- ble_hs_misc_log_flat_buf(cmd->sig_key, sizeof cmd->sig_key);
+ ble_hs_log_flat_buf(cmd->sig_key, sizeof cmd->sig_key);
}
void
@@ -725,9 +725,9 @@ void
ble_sm_public_key_log(struct ble_sm_public_key *cmd)
{
BLE_HS_LOG(DEBUG, "x=");
- ble_hs_misc_log_flat_buf(cmd->x, sizeof cmd->x);
+ ble_hs_log_flat_buf(cmd->x, sizeof cmd->x);
BLE_HS_LOG(DEBUG, "y=");
- ble_hs_misc_log_flat_buf(cmd->y, sizeof cmd->y);
+ ble_hs_log_flat_buf(cmd->y, sizeof cmd->y);
}
void
@@ -786,7 +786,7 @@ void
ble_sm_dhkey_check_log(struct ble_sm_dhkey_check *cmd)
{
BLE_HS_LOG(DEBUG, "value=");
- ble_hs_misc_log_flat_buf(cmd->value, sizeof cmd->value);
+ ble_hs_log_flat_buf(cmd->value, sizeof cmd->value);
}
#endif
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/ble_sm_sc.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/ble_sm_sc.c b/net/nimble/host/src/ble_sm_sc.c
index bb92a19..c2980b6 100644
--- a/net/nimble/host/src/ble_sm_sc.c
+++ b/net/nimble/host/src/ble_sm_sc.c
@@ -153,10 +153,10 @@ ble_sm_sc_ensure_keys_generated(void)
}
BLE_HS_LOG(DEBUG, "our pubkey=");
- ble_hs_misc_log_flat_buf(&ble_sm_sc_pub_key, 64);
+ ble_hs_log_flat_buf(&ble_sm_sc_pub_key, 64);
BLE_HS_LOG(DEBUG, "\n");
BLE_HS_LOG(DEBUG, "our privkey=");
- ble_hs_misc_log_flat_buf(&ble_sm_sc_priv_key, 32);
+ ble_hs_log_flat_buf(&ble_sm_sc_priv_key, 32);
BLE_HS_LOG(DEBUG, "\n");
return 0;
@@ -363,7 +363,7 @@ ble_sm_sc_random_rx(struct ble_sm_proc *proc, struct ble_sm_result *res)
ble_sm_sc_responder_verifies_random(proc)) {
BLE_HS_LOG(DEBUG, "tk=");
- ble_hs_misc_log_flat_buf(proc->tk, 32);
+ ble_hs_log_flat_buf(proc->tk, 32);
BLE_HS_LOG(DEBUG, "\n");
rc = ble_sm_alg_f4(proc->pub_key_peer.x, ble_sm_sc_pub_key.u8,
@@ -646,7 +646,7 @@ ble_sm_dhkey_check_process(struct ble_sm_proc *proc,
}
BLE_HS_LOG(DEBUG, "tk=");
- ble_hs_misc_log_flat_buf(proc->tk, 32);
+ ble_hs_log_flat_buf(proc->tk, 32);
BLE_HS_LOG(DEBUG, "\n");
res->app_status = ble_sm_alg_f6(proc->mackey,
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/host_hci.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/host_hci.c b/net/nimble/host/src/host_hci.c
index ce483cd..86e77c5 100644
--- a/net/nimble/host/src/host_hci.c
+++ b/net/nimble/host/src/host_hci.c
@@ -707,7 +707,7 @@ host_hci_data_rx(struct os_mbuf *om)
BLE_HCI_DATA_HANDLE(hci_hdr.hdh_handle_pb_bc),
BLE_HCI_DATA_PB(hci_hdr.hdh_handle_pb_bc),
hci_hdr.hdh_len);
- ble_hs_misc_log_mbuf(om);
+ ble_hs_log_mbuf(om);
BLE_HS_LOG(DEBUG, "\n");
#endif
@@ -875,7 +875,7 @@ host_hci_data_tx(struct ble_hs_conn *connection, struct os_mbuf *om)
pb = BLE_HCI_PB_MIDDLE;
BLE_HS_LOG(DEBUG, "host_hci_data_tx(): ");
- ble_hs_misc_log_mbuf(frag);
+ ble_hs_log_mbuf(frag);
BLE_HS_LOG(DEBUG, "\n");
rc = ble_hs_tx_data(frag);
http://git-wip-us.apache.org/repos/asf/incubator-mynewt-core/blob/621629d6/net/nimble/host/src/host_hci_cmd.c
----------------------------------------------------------------------
diff --git a/net/nimble/host/src/host_hci_cmd.c b/net/nimble/host/src/host_hci_cmd.c
index 8787d5d..9dbb036 100644
--- a/net/nimble/host/src/host_hci_cmd.c
+++ b/net/nimble/host/src/host_hci_cmd.c
@@ -89,7 +89,7 @@ host_hci_cmd_send(uint8_t ogf, uint8_t ocf, uint8_t len, const void *cmddata)
BLE_HS_LOG(DEBUG, "host_hci_cmd_send: ogf=0x%02x ocf=0x%02x len=%d\n",
ogf, ocf, len);
- ble_hs_misc_log_flat_buf(host_hci_cmd_buf, len + BLE_HCI_CMD_HDR_LEN);
+ ble_hs_log_flat_buf(host_hci_cmd_buf, len + BLE_HCI_CMD_HDR_LEN);
BLE_HS_LOG(DEBUG, "\n");
rc = host_hci_cmd_transport(host_hci_cmd_buf);