Loading system/bta/hh/bta_hh_le.cc 100644 → 100755 +49 −62 Original line number Diff line number Diff line Loading @@ -66,10 +66,9 @@ static const uint16_t bta_hh_uuid_to_rtp_type[BTA_LE_HID_RTP_UUID_MAX][2] = { static void bta_hh_gattc_callback(tBTA_GATTC_EVT event, tBTA_GATTC* p_data); static void bta_hh_le_add_dev_bg_conn(tBTA_HH_DEV_CB* p_cb, bool check_bond); // TODO(jpawlowski): uncomment when fixed // static void bta_hh_process_cache_rpt (tBTA_HH_DEV_CB *p_cb, // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache, // uint8_t num_rpt); static void bta_hh_process_cache_rpt(tBTA_HH_DEV_CB* p_cb, tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache, uint8_t num_rpt); #if (BTA_HH_DEBUG == TRUE) static const char* bta_hh_le_rpt_name[4] = {"UNKNOWN", "INPUT", "OUTPUT", Loading Loading @@ -1001,14 +1000,12 @@ void bta_hh_security_cmpl(tBTA_HH_DEV_CB* p_cb, APPL_TRACE_DEBUG("bta_hh_security_cmpl no reports loaded, try to load"); /* start loading the cache if not in stack */ // TODO(jpawlowski): cache storage is broken, fix it // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache; // uint8_t num_rpt = 0; // if ((p_rpt_cache = bta_hh_le_co_cache_load(p_cb->addr, &num_rpt, // p_cb->app_id)) != NULL) // { // bta_hh_process_cache_rpt(p_cb, p_rpt_cache, num_rpt); // } tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache; uint8_t num_rpt = 0; if ((p_rpt_cache = bta_hh_le_co_cache_load(p_cb->addr, &num_rpt, p_cb->app_id)) != NULL) { bta_hh_process_cache_rpt(p_cb, p_rpt_cache, num_rpt); } } /* discovery has been done for HID service */ if (p_cb->app_id != 0 && p_cb->hid_srvc.in_use) { Loading Loading @@ -1576,9 +1573,11 @@ void bta_hh_le_input_rpt_notify(tBTA_GATTC_NOTIFY* p_data) { app_id = p_dev_cb->app_id; p_rpt = bta_hh_le_find_report_entry(p_dev_cb, p_dev_cb->hid_srvc.srvc_inst_id, p_char->uuid.As16Bit(), p_char->value_handle); const gatt::Service* p_svc = BTA_GATTC_GetOwningService(p_dev_cb->conn_id, p_char->value_handle); p_rpt = bta_hh_le_find_report_entry( p_dev_cb, p_svc->handle, p_char->uuid.As16Bit(), p_char->value_handle); if (p_rpt == NULL) { APPL_TRACE_ERROR( "%s: notification received for Unknown Report, uuid: %s, handle: " Loading Loading @@ -2165,52 +2164,40 @@ void bta_hh_le_hid_read_rpt_clt_cfg(const RawAddress& bd_addr, uint8_t rpt_id) { * Parameters: * ******************************************************************************/ // TODO(jpawlowski): uncomment when fixed // static void bta_hh_process_cache_rpt (tBTA_HH_DEV_CB *p_cb, // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache, // uint8_t num_rpt) // { // uint8_t i = 0; // tBTA_HH_LE_RPT *p_rpt; // if (num_rpt != 0) /* no cache is found */ // { // p_cb->hid_srvc.in_use = true; // /* set the descriptor info */ // p_cb->hid_srvc.descriptor.dl_len = // p_cb->dscp_info.descriptor.dl_len; // p_cb->hid_srvc.descriptor.dsc_list = // p_cb->dscp_info.descriptor.dsc_list; // for (; i <num_rpt; i ++, p_rpt_cache ++) // { // if ((p_rpt = bta_hh_le_find_alloc_report_entry (p_cb, // p_rpt_cache->srvc_inst_id, // p_rpt_cache->rpt_uuid, // p_rpt_cache->char_inst_id, // p_rpt_cache->prop)) == NULL) // { // APPL_TRACE_ERROR("bta_hh_process_cache_rpt: allocation report // entry failure"); // break; // } // else // { // p_rpt->rpt_type = p_rpt_cache->rpt_type; // p_rpt->rpt_id = p_rpt_cache->rpt_id; // if (p_rpt->uuid == GATT_UUID_HID_BT_KB_INPUT || // p_rpt->uuid == GATT_UUID_HID_BT_MOUSE_INPUT || // (p_rpt->uuid == GATT_UUID_HID_REPORT && p_rpt->rpt_type // == BTA_HH_RPTT_INPUT)) // { // p_rpt->client_cfg_value = // GATT_CLT_CONFIG_NOTIFICATION; // } // } // } // } // } static void bta_hh_process_cache_rpt(tBTA_HH_DEV_CB* p_cb, tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache, uint8_t num_rpt) { uint8_t i = 0; tBTA_HH_LE_RPT* p_rpt; if (num_rpt != 0) /* no cache is found */ { p_cb->hid_srvc.in_use = true; /* set the descriptor info */ p_cb->hid_srvc.descriptor.dl_len = p_cb->dscp_info.descriptor.dl_len; p_cb->hid_srvc.descriptor.dsc_list = p_cb->dscp_info.descriptor.dsc_list; for (; i < num_rpt; i++, p_rpt_cache++) { if ((p_rpt = bta_hh_le_find_alloc_report_entry( p_cb, p_rpt_cache->srvc_inst_id, p_rpt_cache->rpt_uuid, p_rpt_cache->char_inst_id)) == NULL) { APPL_TRACE_ERROR( "bta_hh_process_cache_rpt: allocation report entry failure"); break; } else { p_rpt->rpt_type = p_rpt_cache->rpt_type; p_rpt->rpt_id = p_rpt_cache->rpt_id; if (p_rpt->uuid == GATT_UUID_HID_BT_KB_INPUT || p_rpt->uuid == GATT_UUID_HID_BT_MOUSE_INPUT || (p_rpt->uuid == GATT_UUID_HID_REPORT && p_rpt->rpt_type == BTA_HH_RPTT_INPUT)) { p_rpt->client_cfg_value = GATT_CLT_CONFIG_NOTIFICATION; } } } } } #endif system/gd/Android.bp +17 −8 Original line number Diff line number Diff line Loading @@ -135,6 +135,7 @@ cc_binary { ":BluetoothFacade_hci_hal", ":BluetoothFacade_hci_layer", ":BluetoothFacade_l2cap_layer", ":BluetoothFacade_neighbor", ":BluetoothFacade_security_layer", ], generated_headers: [ Loading Loading @@ -397,8 +398,9 @@ filegroup { "facade/common.proto", "facade/rootservice.proto", "hal/facade.proto", "hci/facade.proto", "hci/facade/facade.proto", "hci/facade/le_advertising_manager_facade.proto", "neighbor/facade/facade.proto", "l2cap/classic/facade.proto", "security/facade.proto", ], Loading @@ -421,12 +423,14 @@ genrule { "facade/rootservice.pb.h", "hal/facade.grpc.pb.h", "hal/facade.pb.h", "hci/facade.grpc.pb.h", "hci/facade.pb.h", "hci/facade/facade.grpc.pb.h", "hci/facade/facade.pb.h", "hci/facade/le_advertising_manager_facade.grpc.pb.h", "hci/facade/le_advertising_manager_facade.pb.h", "l2cap/classic/facade.grpc.pb.h", "l2cap/classic/facade.pb.h", "neighbor/facade/facade.grpc.pb.h", "neighbor/facade/facade.pb.h", "security/facade.grpc.pb.h", "security/facade.pb.h", ], Loading @@ -449,12 +453,14 @@ genrule { "facade/rootservice.pb.cc", "hal/facade.grpc.pb.cc", "hal/facade.pb.cc", "hci/facade.grpc.pb.cc", "hci/facade.pb.cc", "hci/facade/facade.grpc.pb.cc", "hci/facade/facade.pb.cc", "hci/facade/le_advertising_manager_facade.grpc.pb.cc", "hci/facade/le_advertising_manager_facade.pb.cc", "l2cap/classic/facade.grpc.pb.cc", "l2cap/classic/facade.pb.cc", "neighbor/facade/facade.grpc.pb.cc", "neighbor/facade/facade.pb.cc", "security/facade.grpc.pb.cc", "security/facade.pb.cc", ], Loading @@ -474,6 +480,7 @@ genrule { "touch $(genDir)/hci/cert/__init__.py; " + "touch $(genDir)/l2cap/classic/__init__.py; " + "touch $(genDir)/l2cap/classic/cert/__init__.py; " + "touch $(genDir)/neighbor/facade/__init__.py; " + "touch $(genDir)/security/__init__.py; ", srcs: [ ":BluetoothFacadeProto", Loading @@ -490,15 +497,17 @@ genrule { "hal/__init__.py", "hal/facade_pb2_grpc.py", "hal/facade_pb2.py", "hci/__init__.py", "hci/facade_pb2_grpc.py", "hci/facade_pb2.py", "hci/facade/__init__.py", "hci/facade/facade_pb2_grpc.py", "hci/facade/facade_pb2.py", "hci/facade/le_advertising_manager_facade_pb2_grpc.py", "hci/facade/le_advertising_manager_facade_pb2.py", "l2cap/classic/__init__.py", "l2cap/classic/facade_pb2_grpc.py", "l2cap/classic/facade_pb2.py", "neighbor/facade/__init__.py", "neighbor/facade/facade_pb2_grpc.py", "neighbor/facade/facade_pb2.py", "hci/cert/__init__.py", "hci/cert/api_pb2_grpc.py", "hci/cert/api_pb2.py", Loading system/gd/cert/cert_testcases_facade_only +3 −0 Original line number Diff line number Diff line CertSelfTest SimpleHalTest DirectHciTest LeAdvertisingManagerTest SimpleSecurityTest NeighborTest system/gd/cert/gd_device.py +8 −4 Original line number Diff line number Diff line Loading @@ -14,11 +14,14 @@ # See the License for the specific language governing permissions and # limitations under the License. import logging from facade import rootservice_pb2_grpc as facade_rootservice_pb2_grpc from gd_device_base import GdDeviceBase, GdDeviceConfigError, replace_vars from hal import facade_pb2_grpc as hal_facade_pb2_grpc from hci import facade_pb2_grpc as hci_facade_pb2_grpc from hci.facade import facade_pb2_grpc as hci_facade_pb2_grpc from hci.facade import le_advertising_manager_facade_pb2_grpc from neighbor.facade import facade_pb2_grpc as neighbor_facade_pb2_grpc from l2cap.classic import facade_pb2_grpc as l2cap_facade_pb2_grpc from security import facade_pb2_grpc as security_facade_pb2_grpc Loading Loading @@ -52,6 +55,7 @@ def get_instances_with_configs(configs): for config in configs: resolved_cmd = [] for entry in config["cmd"]: logging.debug(entry) resolved_cmd.append(replace_vars(entry, config)) devices.append( GdDevice(config["grpc_port"], config["grpc_root_server_port"], Loading @@ -72,12 +76,12 @@ class GdDevice(GdDeviceBase): self.hal = hal_facade_pb2_grpc.HciHalFacadeStub(self.grpc_channel) self.controller_read_only_property = facade_rootservice_pb2_grpc.ReadOnlyPropertyStub( self.grpc_channel) self.hci = hci_facade_pb2_grpc.AclManagerFacadeStub(self.grpc_channel) self.hci_classic_security = hci_facade_pb2_grpc.ClassicSecurityManagerFacadeStub( self.grpc_channel) self.hci = hci_facade_pb2_grpc.HciLayerFacadeStub(self.grpc_channel) self.l2cap = l2cap_facade_pb2_grpc.L2capClassicModuleFacadeStub( self.grpc_channel) self.hci_le_advertising_manager = le_advertising_manager_facade_pb2_grpc.LeAdvertisingManagerFacadeStub( self.grpc_channel) self.neighbor = neighbor_facade_pb2_grpc.NeighborFacadeStub( self.grpc_channel) self.security = security_facade_pb2_grpc.SecurityModuleFacadeStub( self.grpc_channel) system/gd/facade/grpc_root_server.cc +6 −3 Original line number Diff line number Diff line Loading @@ -22,8 +22,10 @@ #include "facade/rootservice.grpc.pb.h" #include "grpc/grpc_module.h" #include "hal/facade.h" #include "hci/facade.h" #include "hci/facade/facade.h" #include "hci/facade/le_advertising_manager_facade.h" #include "l2cap/classic/facade.h" #include "neighbor/facade/facade.h" #include "os/log.h" #include "os/thread.h" #include "security/facade.h" Loading Loading @@ -56,8 +58,9 @@ class RootFacadeService : public ::bluetooth::facade::RootFacade::Service { break; case BluetoothModule::HCI: modules.add<::bluetooth::facade::ReadOnlyPropertyServerModule>(); modules.add<::bluetooth::hci::AclManagerFacadeModule>(); modules.add<::bluetooth::hci::ClassicSecurityManagerFacadeModule>(); modules.add<::bluetooth::hci::facade::HciLayerFacadeModule>(); modules.add<::bluetooth::hci::facade::LeAdvertisingManagerFacadeModule>(); modules.add<::bluetooth::neighbor::facade::NeighborFacadeModule>(); break; case BluetoothModule::L2CAP: modules.add<::bluetooth::facade::ReadOnlyPropertyServerModule>(); Loading Loading
system/bta/hh/bta_hh_le.cc 100644 → 100755 +49 −62 Original line number Diff line number Diff line Loading @@ -66,10 +66,9 @@ static const uint16_t bta_hh_uuid_to_rtp_type[BTA_LE_HID_RTP_UUID_MAX][2] = { static void bta_hh_gattc_callback(tBTA_GATTC_EVT event, tBTA_GATTC* p_data); static void bta_hh_le_add_dev_bg_conn(tBTA_HH_DEV_CB* p_cb, bool check_bond); // TODO(jpawlowski): uncomment when fixed // static void bta_hh_process_cache_rpt (tBTA_HH_DEV_CB *p_cb, // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache, // uint8_t num_rpt); static void bta_hh_process_cache_rpt(tBTA_HH_DEV_CB* p_cb, tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache, uint8_t num_rpt); #if (BTA_HH_DEBUG == TRUE) static const char* bta_hh_le_rpt_name[4] = {"UNKNOWN", "INPUT", "OUTPUT", Loading Loading @@ -1001,14 +1000,12 @@ void bta_hh_security_cmpl(tBTA_HH_DEV_CB* p_cb, APPL_TRACE_DEBUG("bta_hh_security_cmpl no reports loaded, try to load"); /* start loading the cache if not in stack */ // TODO(jpawlowski): cache storage is broken, fix it // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache; // uint8_t num_rpt = 0; // if ((p_rpt_cache = bta_hh_le_co_cache_load(p_cb->addr, &num_rpt, // p_cb->app_id)) != NULL) // { // bta_hh_process_cache_rpt(p_cb, p_rpt_cache, num_rpt); // } tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache; uint8_t num_rpt = 0; if ((p_rpt_cache = bta_hh_le_co_cache_load(p_cb->addr, &num_rpt, p_cb->app_id)) != NULL) { bta_hh_process_cache_rpt(p_cb, p_rpt_cache, num_rpt); } } /* discovery has been done for HID service */ if (p_cb->app_id != 0 && p_cb->hid_srvc.in_use) { Loading Loading @@ -1576,9 +1573,11 @@ void bta_hh_le_input_rpt_notify(tBTA_GATTC_NOTIFY* p_data) { app_id = p_dev_cb->app_id; p_rpt = bta_hh_le_find_report_entry(p_dev_cb, p_dev_cb->hid_srvc.srvc_inst_id, p_char->uuid.As16Bit(), p_char->value_handle); const gatt::Service* p_svc = BTA_GATTC_GetOwningService(p_dev_cb->conn_id, p_char->value_handle); p_rpt = bta_hh_le_find_report_entry( p_dev_cb, p_svc->handle, p_char->uuid.As16Bit(), p_char->value_handle); if (p_rpt == NULL) { APPL_TRACE_ERROR( "%s: notification received for Unknown Report, uuid: %s, handle: " Loading Loading @@ -2165,52 +2164,40 @@ void bta_hh_le_hid_read_rpt_clt_cfg(const RawAddress& bd_addr, uint8_t rpt_id) { * Parameters: * ******************************************************************************/ // TODO(jpawlowski): uncomment when fixed // static void bta_hh_process_cache_rpt (tBTA_HH_DEV_CB *p_cb, // tBTA_HH_RPT_CACHE_ENTRY *p_rpt_cache, // uint8_t num_rpt) // { // uint8_t i = 0; // tBTA_HH_LE_RPT *p_rpt; // if (num_rpt != 0) /* no cache is found */ // { // p_cb->hid_srvc.in_use = true; // /* set the descriptor info */ // p_cb->hid_srvc.descriptor.dl_len = // p_cb->dscp_info.descriptor.dl_len; // p_cb->hid_srvc.descriptor.dsc_list = // p_cb->dscp_info.descriptor.dsc_list; // for (; i <num_rpt; i ++, p_rpt_cache ++) // { // if ((p_rpt = bta_hh_le_find_alloc_report_entry (p_cb, // p_rpt_cache->srvc_inst_id, // p_rpt_cache->rpt_uuid, // p_rpt_cache->char_inst_id, // p_rpt_cache->prop)) == NULL) // { // APPL_TRACE_ERROR("bta_hh_process_cache_rpt: allocation report // entry failure"); // break; // } // else // { // p_rpt->rpt_type = p_rpt_cache->rpt_type; // p_rpt->rpt_id = p_rpt_cache->rpt_id; // if (p_rpt->uuid == GATT_UUID_HID_BT_KB_INPUT || // p_rpt->uuid == GATT_UUID_HID_BT_MOUSE_INPUT || // (p_rpt->uuid == GATT_UUID_HID_REPORT && p_rpt->rpt_type // == BTA_HH_RPTT_INPUT)) // { // p_rpt->client_cfg_value = // GATT_CLT_CONFIG_NOTIFICATION; // } // } // } // } // } static void bta_hh_process_cache_rpt(tBTA_HH_DEV_CB* p_cb, tBTA_HH_RPT_CACHE_ENTRY* p_rpt_cache, uint8_t num_rpt) { uint8_t i = 0; tBTA_HH_LE_RPT* p_rpt; if (num_rpt != 0) /* no cache is found */ { p_cb->hid_srvc.in_use = true; /* set the descriptor info */ p_cb->hid_srvc.descriptor.dl_len = p_cb->dscp_info.descriptor.dl_len; p_cb->hid_srvc.descriptor.dsc_list = p_cb->dscp_info.descriptor.dsc_list; for (; i < num_rpt; i++, p_rpt_cache++) { if ((p_rpt = bta_hh_le_find_alloc_report_entry( p_cb, p_rpt_cache->srvc_inst_id, p_rpt_cache->rpt_uuid, p_rpt_cache->char_inst_id)) == NULL) { APPL_TRACE_ERROR( "bta_hh_process_cache_rpt: allocation report entry failure"); break; } else { p_rpt->rpt_type = p_rpt_cache->rpt_type; p_rpt->rpt_id = p_rpt_cache->rpt_id; if (p_rpt->uuid == GATT_UUID_HID_BT_KB_INPUT || p_rpt->uuid == GATT_UUID_HID_BT_MOUSE_INPUT || (p_rpt->uuid == GATT_UUID_HID_REPORT && p_rpt->rpt_type == BTA_HH_RPTT_INPUT)) { p_rpt->client_cfg_value = GATT_CLT_CONFIG_NOTIFICATION; } } } } } #endif
system/gd/Android.bp +17 −8 Original line number Diff line number Diff line Loading @@ -135,6 +135,7 @@ cc_binary { ":BluetoothFacade_hci_hal", ":BluetoothFacade_hci_layer", ":BluetoothFacade_l2cap_layer", ":BluetoothFacade_neighbor", ":BluetoothFacade_security_layer", ], generated_headers: [ Loading Loading @@ -397,8 +398,9 @@ filegroup { "facade/common.proto", "facade/rootservice.proto", "hal/facade.proto", "hci/facade.proto", "hci/facade/facade.proto", "hci/facade/le_advertising_manager_facade.proto", "neighbor/facade/facade.proto", "l2cap/classic/facade.proto", "security/facade.proto", ], Loading @@ -421,12 +423,14 @@ genrule { "facade/rootservice.pb.h", "hal/facade.grpc.pb.h", "hal/facade.pb.h", "hci/facade.grpc.pb.h", "hci/facade.pb.h", "hci/facade/facade.grpc.pb.h", "hci/facade/facade.pb.h", "hci/facade/le_advertising_manager_facade.grpc.pb.h", "hci/facade/le_advertising_manager_facade.pb.h", "l2cap/classic/facade.grpc.pb.h", "l2cap/classic/facade.pb.h", "neighbor/facade/facade.grpc.pb.h", "neighbor/facade/facade.pb.h", "security/facade.grpc.pb.h", "security/facade.pb.h", ], Loading @@ -449,12 +453,14 @@ genrule { "facade/rootservice.pb.cc", "hal/facade.grpc.pb.cc", "hal/facade.pb.cc", "hci/facade.grpc.pb.cc", "hci/facade.pb.cc", "hci/facade/facade.grpc.pb.cc", "hci/facade/facade.pb.cc", "hci/facade/le_advertising_manager_facade.grpc.pb.cc", "hci/facade/le_advertising_manager_facade.pb.cc", "l2cap/classic/facade.grpc.pb.cc", "l2cap/classic/facade.pb.cc", "neighbor/facade/facade.grpc.pb.cc", "neighbor/facade/facade.pb.cc", "security/facade.grpc.pb.cc", "security/facade.pb.cc", ], Loading @@ -474,6 +480,7 @@ genrule { "touch $(genDir)/hci/cert/__init__.py; " + "touch $(genDir)/l2cap/classic/__init__.py; " + "touch $(genDir)/l2cap/classic/cert/__init__.py; " + "touch $(genDir)/neighbor/facade/__init__.py; " + "touch $(genDir)/security/__init__.py; ", srcs: [ ":BluetoothFacadeProto", Loading @@ -490,15 +497,17 @@ genrule { "hal/__init__.py", "hal/facade_pb2_grpc.py", "hal/facade_pb2.py", "hci/__init__.py", "hci/facade_pb2_grpc.py", "hci/facade_pb2.py", "hci/facade/__init__.py", "hci/facade/facade_pb2_grpc.py", "hci/facade/facade_pb2.py", "hci/facade/le_advertising_manager_facade_pb2_grpc.py", "hci/facade/le_advertising_manager_facade_pb2.py", "l2cap/classic/__init__.py", "l2cap/classic/facade_pb2_grpc.py", "l2cap/classic/facade_pb2.py", "neighbor/facade/__init__.py", "neighbor/facade/facade_pb2_grpc.py", "neighbor/facade/facade_pb2.py", "hci/cert/__init__.py", "hci/cert/api_pb2_grpc.py", "hci/cert/api_pb2.py", Loading
system/gd/cert/cert_testcases_facade_only +3 −0 Original line number Diff line number Diff line CertSelfTest SimpleHalTest DirectHciTest LeAdvertisingManagerTest SimpleSecurityTest NeighborTest
system/gd/cert/gd_device.py +8 −4 Original line number Diff line number Diff line Loading @@ -14,11 +14,14 @@ # See the License for the specific language governing permissions and # limitations under the License. import logging from facade import rootservice_pb2_grpc as facade_rootservice_pb2_grpc from gd_device_base import GdDeviceBase, GdDeviceConfigError, replace_vars from hal import facade_pb2_grpc as hal_facade_pb2_grpc from hci import facade_pb2_grpc as hci_facade_pb2_grpc from hci.facade import facade_pb2_grpc as hci_facade_pb2_grpc from hci.facade import le_advertising_manager_facade_pb2_grpc from neighbor.facade import facade_pb2_grpc as neighbor_facade_pb2_grpc from l2cap.classic import facade_pb2_grpc as l2cap_facade_pb2_grpc from security import facade_pb2_grpc as security_facade_pb2_grpc Loading Loading @@ -52,6 +55,7 @@ def get_instances_with_configs(configs): for config in configs: resolved_cmd = [] for entry in config["cmd"]: logging.debug(entry) resolved_cmd.append(replace_vars(entry, config)) devices.append( GdDevice(config["grpc_port"], config["grpc_root_server_port"], Loading @@ -72,12 +76,12 @@ class GdDevice(GdDeviceBase): self.hal = hal_facade_pb2_grpc.HciHalFacadeStub(self.grpc_channel) self.controller_read_only_property = facade_rootservice_pb2_grpc.ReadOnlyPropertyStub( self.grpc_channel) self.hci = hci_facade_pb2_grpc.AclManagerFacadeStub(self.grpc_channel) self.hci_classic_security = hci_facade_pb2_grpc.ClassicSecurityManagerFacadeStub( self.grpc_channel) self.hci = hci_facade_pb2_grpc.HciLayerFacadeStub(self.grpc_channel) self.l2cap = l2cap_facade_pb2_grpc.L2capClassicModuleFacadeStub( self.grpc_channel) self.hci_le_advertising_manager = le_advertising_manager_facade_pb2_grpc.LeAdvertisingManagerFacadeStub( self.grpc_channel) self.neighbor = neighbor_facade_pb2_grpc.NeighborFacadeStub( self.grpc_channel) self.security = security_facade_pb2_grpc.SecurityModuleFacadeStub( self.grpc_channel)
system/gd/facade/grpc_root_server.cc +6 −3 Original line number Diff line number Diff line Loading @@ -22,8 +22,10 @@ #include "facade/rootservice.grpc.pb.h" #include "grpc/grpc_module.h" #include "hal/facade.h" #include "hci/facade.h" #include "hci/facade/facade.h" #include "hci/facade/le_advertising_manager_facade.h" #include "l2cap/classic/facade.h" #include "neighbor/facade/facade.h" #include "os/log.h" #include "os/thread.h" #include "security/facade.h" Loading Loading @@ -56,8 +58,9 @@ class RootFacadeService : public ::bluetooth::facade::RootFacade::Service { break; case BluetoothModule::HCI: modules.add<::bluetooth::facade::ReadOnlyPropertyServerModule>(); modules.add<::bluetooth::hci::AclManagerFacadeModule>(); modules.add<::bluetooth::hci::ClassicSecurityManagerFacadeModule>(); modules.add<::bluetooth::hci::facade::HciLayerFacadeModule>(); modules.add<::bluetooth::hci::facade::LeAdvertisingManagerFacadeModule>(); modules.add<::bluetooth::neighbor::facade::NeighborFacadeModule>(); break; case BluetoothModule::L2CAP: modules.add<::bluetooth::facade::ReadOnlyPropertyServerModule>(); Loading