Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 756c0bd9 authored by Henri Chataing's avatar Henri Chataing
Browse files

RootCanal: Configure the default LE vendor capabilities

Configure the capabilities with version v1.0, and all
additional features disabled.

Test: None
Change-Id: I8e8823e345ecd2494ec39b71dce890a0e22daaba
parent b824bb38
Loading
Loading
Loading
Loading
+24 −1
Original line number Diff line number Diff line
@@ -107,7 +107,30 @@ struct ControllerProperties {

  // Vendor Information.
  // Provide parameters returned by vendor specific commands.
  std::vector<uint8_t> le_vendor_capabilities{};
  // The format is specified for the Android Bluetooth stack:
  // https://source.android.com/docs/core/connect/bluetooth/hci_requirements#vendor-specific-capabilities
  std::vector<uint8_t> le_vendor_capabilities{
      8,  // max_advt_instances
      0,  // offloaded_resolution_of_private_address
      0,
      0,  // total_scan_results_storage
      0,  // max_irk_list_sz
      0,  // filtering_support
      0,  // max_filter
      0,  // activity_energy_info_support
      1,
      0,  // version_supported v1.0
      0,
      0,  // total_num_of_advt_tracked
      0,  // extended_scan_support
      0,  // debug_logging_supported
      0,  // le_address_generation_offloading_support
      0, 0, 0,
      0,  // A2DP_source_offload_capability_mask
      0,  // bluetooth_quality_report_support
      0, 0, 0,
      0,  // dynamic_audio_buffer_support
  };
};

}  // namespace rootcanal
+1 −2
Original line number Diff line number Diff line
@@ -2757,8 +2757,7 @@ void DualModeController::LeVendorCap(CommandView command) {
  auto command_view = gd_hci::LeGetVendorCapabilitiesView::Create(
      gd_hci::VendorCommandView::Create(command));
  ASSERT(command_view.IsValid());
  vector<uint8_t> caps = properties_.le_vendor_capabilities;
  if (caps.size() == 0) {
  if (properties_.le_vendor_capabilities.size() == 0) {
    SendCommandCompleteUnknownOpCodeEvent(
        static_cast<uint16_t>(OpCode::LE_GET_VENDOR_CAPABILITIES));
    return;