bluetooth: remove warnings
Remove unused variables and commented out some unused APIs.
Test: pass
Change-Id: Ic191997d7db25277776417fd0069241ee01529e0
diff --git a/bluetooth/1.0/default/hci_protocol.cc b/bluetooth/1.0/default/hci_protocol.cc
index cd709b4..bb1e36b 100644
--- a/bluetooth/1.0/default/hci_protocol.cc
+++ b/bluetooth/1.0/default/hci_protocol.cc
@@ -22,23 +22,6 @@
#include <fcntl.h>
#include <utils/Log.h>
-namespace {
-
-const size_t preamble_size_for_type[] = {
- 0, HCI_COMMAND_PREAMBLE_SIZE, HCI_ACL_PREAMBLE_SIZE, HCI_SCO_PREAMBLE_SIZE,
- HCI_EVENT_PREAMBLE_SIZE};
-const size_t packet_length_offset_for_type[] = {
- 0, HCI_LENGTH_OFFSET_CMD, HCI_LENGTH_OFFSET_ACL, HCI_LENGTH_OFFSET_SCO,
- HCI_LENGTH_OFFSET_EVT};
-
-size_t HciGetPacketLengthForType(HciPacketType type, const uint8_t* preamble) {
- size_t offset = packet_length_offset_for_type[type];
- if (type != HCI_PACKET_TYPE_ACL_DATA) return preamble[offset];
- return (((preamble[offset + 1]) << 8) | preamble[offset]);
-}
-
-} // namespace
-
namespace android {
namespace hardware {
namespace bluetooth {
diff --git a/bluetooth/1.0/default/test/mct_protocol_unittest.cc b/bluetooth/1.0/default/test/mct_protocol_unittest.cc
index 5751a5e..0a6e9eb 100644
--- a/bluetooth/1.0/default/test/mct_protocol_unittest.cc
+++ b/bluetooth/1.0/default/test/mct_protocol_unittest.cc
@@ -41,11 +41,8 @@
static char sample_data1[100] = "A point is that which has no part.";
static char sample_data2[100] = "A line is breadthless length.";
-static char sample_data3[100] = "The ends of a line are points.";
static char acl_data[100] =
"A straight line is a line which lies evenly with the points on itself.";
-static char sco_data[100] =
- "A surface is that which has length and breadth only.";
static char event_data[100] = "The edges of a surface are lines.";
MATCHER_P3(HidlVecMatches, preamble, preamble_length, payload, "") {