Loading system/gd/hci/Android.bp +0 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,6 @@ filegroup { "le_scanning_manager.cc", "le_scanning_reassembler.cc", "link_key.cc", "msft.cc", "remote_name_request.cc", "uuid.cc", "vendor_specific_event_manager.cc", Loading system/gd/hci/msft.cc +2 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ #if TARGET_FLOSS #include "hci/msft.h" #include <bluetooth/log.h> Loading Loading @@ -352,3 +353,4 @@ void MsftExtensionManager::SetScanningCallback(ScanningCallback* callbacks) { } // namespace hci } // namespace bluetooth #endif system/gd/hci/msft.h +2 −0 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ * limitations under the License. */ #pragma once #if TARGET_FLOSS #include "hci/hci_packets.h" #include "hci/le_scanning_callback.h" Loading Loading @@ -60,3 +61,4 @@ class MsftExtensionManager : public bluetooth::Module { } // namespace hci } // namespace bluetooth #endif system/gd/rust/topshim/gatt/gatt_ble_scanner_shim.cc +15 −0 Original line number Diff line number Diff line Loading @@ -252,6 +252,8 @@ void BleScannerIntf::ScanFilterEnable(bool enable) { scanner_intf_->ScanFilterEnable(enable, base::Bind(&BleScannerIntf::OnEnableCallback, base::Unretained(this))); } #if TARGET_FLOSS bool BleScannerIntf::IsMsftSupported() { return scanner_intf_->IsMsftSupported(); } Loading @@ -272,6 +274,17 @@ void BleScannerIntf::MsftAdvMonitorEnable(uint32_t call_id, bool enable) { enable, base::Bind(&BleScannerIntf::OnMsftAdvMonitorEnableCallback, base::Unretained(this), call_id)); } #else bool BleScannerIntf::IsMsftSupported() { return false; } void BleScannerIntf::MsftAdvMonitorAdd(uint32_t, const RustMsftAdvMonitor&) {} void BleScannerIntf::MsftAdvMonitorRemove(uint32_t, uint8_t) {} void BleScannerIntf::MsftAdvMonitorEnable(uint32_t, bool) {} #endif void BleScannerIntf::SetScanParameters( uint8_t scanner_id, uint8_t scan_type, Loading Loading @@ -365,6 +378,7 @@ void BleScannerIntf::OnFilterConfigCallback( rusty::gdscan_filter_config_callback(filter_index, filt_type, avbl_space, action, btm_status); } #if TARGET_FLOSS void BleScannerIntf::OnMsftAdvMonitorAddCallback(uint32_t call_id, uint8_t monitor_handle, uint8_t status) { rusty::gdscan_msft_adv_monitor_add_callback(call_id, monitor_handle, status); } Loading @@ -376,6 +390,7 @@ void BleScannerIntf::OnMsftAdvMonitorRemoveCallback(uint32_t call_id, uint8_t st void BleScannerIntf::OnMsftAdvMonitorEnableCallback(uint32_t call_id, uint8_t status) { rusty::gdscan_msft_adv_monitor_enable_callback(call_id, status); } #endif void BleScannerIntf::OnPeriodicSyncStarted( int, Loading system/gd/rust/topshim/gatt/gatt_ble_scanner_shim.h +2 −0 Original line number Diff line number Diff line Loading @@ -180,9 +180,11 @@ class BleScannerIntf : public ScanningCallbacks { void OnFilterParamSetupCallback(uint8_t scanner_id, uint8_t avbl_space, uint8_t action_type, uint8_t btm_status); void OnFilterConfigCallback( uint8_t filt_index, uint8_t filt_type, uint8_t avbl_space, uint8_t action, uint8_t btm_status); #if TARGET_FLOSS void OnMsftAdvMonitorAddCallback(uint32_t call_id, uint8_t monitor_handle, uint8_t status); void OnMsftAdvMonitorRemoveCallback(uint32_t call_id, uint8_t status); void OnMsftAdvMonitorEnableCallback(uint32_t call_id, uint8_t status); #endif BleScannerInterface* scanner_intf_; }; Loading Loading
system/gd/hci/Android.bp +0 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,6 @@ filegroup { "le_scanning_manager.cc", "le_scanning_reassembler.cc", "link_key.cc", "msft.cc", "remote_name_request.cc", "uuid.cc", "vendor_specific_event_manager.cc", Loading
system/gd/hci/msft.cc +2 −0 Original line number Diff line number Diff line Loading @@ -13,6 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ #if TARGET_FLOSS #include "hci/msft.h" #include <bluetooth/log.h> Loading Loading @@ -352,3 +353,4 @@ void MsftExtensionManager::SetScanningCallback(ScanningCallback* callbacks) { } // namespace hci } // namespace bluetooth #endif
system/gd/hci/msft.h +2 −0 Original line number Diff line number Diff line Loading @@ -14,6 +14,7 @@ * limitations under the License. */ #pragma once #if TARGET_FLOSS #include "hci/hci_packets.h" #include "hci/le_scanning_callback.h" Loading Loading @@ -60,3 +61,4 @@ class MsftExtensionManager : public bluetooth::Module { } // namespace hci } // namespace bluetooth #endif
system/gd/rust/topshim/gatt/gatt_ble_scanner_shim.cc +15 −0 Original line number Diff line number Diff line Loading @@ -252,6 +252,8 @@ void BleScannerIntf::ScanFilterEnable(bool enable) { scanner_intf_->ScanFilterEnable(enable, base::Bind(&BleScannerIntf::OnEnableCallback, base::Unretained(this))); } #if TARGET_FLOSS bool BleScannerIntf::IsMsftSupported() { return scanner_intf_->IsMsftSupported(); } Loading @@ -272,6 +274,17 @@ void BleScannerIntf::MsftAdvMonitorEnable(uint32_t call_id, bool enable) { enable, base::Bind(&BleScannerIntf::OnMsftAdvMonitorEnableCallback, base::Unretained(this), call_id)); } #else bool BleScannerIntf::IsMsftSupported() { return false; } void BleScannerIntf::MsftAdvMonitorAdd(uint32_t, const RustMsftAdvMonitor&) {} void BleScannerIntf::MsftAdvMonitorRemove(uint32_t, uint8_t) {} void BleScannerIntf::MsftAdvMonitorEnable(uint32_t, bool) {} #endif void BleScannerIntf::SetScanParameters( uint8_t scanner_id, uint8_t scan_type, Loading Loading @@ -365,6 +378,7 @@ void BleScannerIntf::OnFilterConfigCallback( rusty::gdscan_filter_config_callback(filter_index, filt_type, avbl_space, action, btm_status); } #if TARGET_FLOSS void BleScannerIntf::OnMsftAdvMonitorAddCallback(uint32_t call_id, uint8_t monitor_handle, uint8_t status) { rusty::gdscan_msft_adv_monitor_add_callback(call_id, monitor_handle, status); } Loading @@ -376,6 +390,7 @@ void BleScannerIntf::OnMsftAdvMonitorRemoveCallback(uint32_t call_id, uint8_t st void BleScannerIntf::OnMsftAdvMonitorEnableCallback(uint32_t call_id, uint8_t status) { rusty::gdscan_msft_adv_monitor_enable_callback(call_id, status); } #endif void BleScannerIntf::OnPeriodicSyncStarted( int, Loading
system/gd/rust/topshim/gatt/gatt_ble_scanner_shim.h +2 −0 Original line number Diff line number Diff line Loading @@ -180,9 +180,11 @@ class BleScannerIntf : public ScanningCallbacks { void OnFilterParamSetupCallback(uint8_t scanner_id, uint8_t avbl_space, uint8_t action_type, uint8_t btm_status); void OnFilterConfigCallback( uint8_t filt_index, uint8_t filt_type, uint8_t avbl_space, uint8_t action, uint8_t btm_status); #if TARGET_FLOSS void OnMsftAdvMonitorAddCallback(uint32_t call_id, uint8_t monitor_handle, uint8_t status); void OnMsftAdvMonitorRemoveCallback(uint32_t call_id, uint8_t status); void OnMsftAdvMonitorEnableCallback(uint32_t call_id, uint8_t status); #endif BleScannerInterface* scanner_intf_; }; Loading