cleanup: Bluetooth/A2DP code cleanup
This commit is contained in:
1 parent
18eb48e5df
commit
121f3f2081
6 files changed
+29
-178
No files matched your search
@@ -31,19 +31,10 @@ namespace Drivers::USB::Bluetooth::L2cap {
|
||||
// 3=security-block, 4=no-resources). 0xFFFF = none received yet.
|
||||
static volatile uint16_t g_lastConnRspResult = 0xFFFF;
|
||||
|
||||
// Diagnostic: how many incoming AVDTP connection requests the remote has
|
||||
// made (tells us whether the headset wants to initiate the audio channel).
|
||||
static volatile uint16_t g_incomingAvdtpReqs = 0;
|
||||
|
||||
// Channel table
|
||||
static ChannelInfo g_channels[MAX_CHANNELS] = {};
|
||||
static uint16_t g_nextCid = CID_DYNAMIC_START;
|
||||
|
||||
// Signaling response tracking
|
||||
static volatile bool g_sigResponseReady = false;
|
||||
static uint8_t g_sigResponseBuf[64] = {};
|
||||
static uint32_t g_sigResponseLen = 0;
|
||||
|
||||
// =========================================================================
|
||||
// Helpers
|
||||
// =========================================================================
|
||||
@@ -154,7 +145,6 @@ namespace Drivers::USB::Bluetooth::L2cap {
|
||||
|
||||
// Accept connections for AVDTP, SDP, and AVRCP control
|
||||
if (psm == PSM_AVDTP || psm == PSM_SDP || psm == PSM_AVCTP) {
|
||||
if (psm == PSM_AVDTP) g_incomingAvdtpReqs++;
|
||||
auto* ch = AllocChannel(psm);
|
||||
if (ch) {
|
||||
ch->RemoteCid = srcCid;
|
||||
@@ -565,8 +555,4 @@ namespace Drivers::USB::Bluetooth::L2cap {
|
||||
return g_lastConnRspResult;
|
||||
}
|
||||
|
||||
uint16_t IncomingAvdtpReqCount() {
|
||||
return g_incomingAvdtpReqs;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in new issue
Block a user