diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2013-10-07 03:33:29 -0700 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2013-10-07 03:33:29 -0700 |
commit | 39a1ae8a883e40e410e15b5665e33c7d146c30a4 (patch) | |
tree | 56c8277669649a05cd4e7ba31791f2c336c77ded /tools/hciconfig.c | |
parent | 402bc399db452982da179f8d1fab40891f8373c4 (diff) | |
download | bluez-39a1ae8a883e40e410e15b5665e33c7d146c30a4.tar.gz |
tools: Fix hciconfig device information printout for AMP controllers
Diffstat (limited to 'tools/hciconfig.c')
-rw-r--r-- | tools/hciconfig.c | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/tools/hciconfig.c b/tools/hciconfig.c index cee163f53..c06b50704 100644 --- a/tools/hciconfig.c +++ b/tools/hciconfig.c @@ -1868,18 +1868,22 @@ static void print_dev_info(int ctl, struct hci_dev_info *di) printf("\tTX bytes:%d acl:%d sco:%d commands:%d errors:%d\n", st->byte_tx, st->acl_tx, st->sco_tx, st->cmd_tx, st->err_tx); - if (all && !hci_test_bit(HCI_RAW, &di->flags) && - (bacmp(&di->bdaddr, BDADDR_ANY) || (di->type & 0x30))) { + if (all && !hci_test_bit(HCI_RAW, &di->flags)) { print_dev_features(di, 0); - print_pkt_type(di); - print_link_policy(di); - print_link_mode(di); - if (hci_test_bit(HCI_UP, &di->flags)) { - cmd_name(ctl, di->dev_id, NULL); - cmd_class(ctl, di->dev_id, NULL); - cmd_version(ctl, di->dev_id, NULL); + if (((di->type & 0x30) >> 4) == HCI_BREDR) { + print_pkt_type(di); + print_link_policy(di); + print_link_mode(di); + + if (hci_test_bit(HCI_UP, &di->flags)) { + cmd_name(ctl, di->dev_id, NULL); + cmd_class(ctl, di->dev_id, NULL); + } } + + if (hci_test_bit(HCI_UP, &di->flags)) + cmd_version(ctl, di->dev_id, NULL); } printf("\n"); |