bluetooth: remove warnings

Remove unused variables and commented out some unused APIs.

Test: pass
Change-Id: Ic191997d7db25277776417fd0069241ee01529e0
This commit is contained in:
Steven Moreland 2017-03-08 15:45:07 -08:00
parent 853a9b5feb
commit 90fc274838
2 changed files with 0 additions and 20 deletions

View file

@ -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 {

View file

@ -41,11 +41,8 @@ using hci::MctProtocol;
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, "") {