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

Commit 26c30db9 authored by Myles Watson's avatar Myles Watson
Browse files

HCI: Remove Create New Unit Key

Bug: 175422340
Test: cert/run
Tag: #gd-refactor
Change-Id: Idec5b4933a8e851bd194d9f93c6fdef8840e9c28
parent 46026ae8
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -788,7 +788,6 @@ struct Controller::impl {
      case OpCode::CONTROLLER_BQR:
        return vendor_capabilities_.bluetooth_quality_report_support_ == 0x01;
      // undefined in local_supported_commands_
      case OpCode::CREATE_NEW_UNIT_KEY:
      case OpCode::READ_LOCAL_SUPPORTED_COMMANDS:
        return true;
      case OpCode::NONE:
+0 −5
Original line number Diff line number Diff line
@@ -140,7 +140,6 @@ enum OpCode : 16 {
  FLUSH = 0x0C08,
  READ_PIN_TYPE = 0x0C09,
  WRITE_PIN_TYPE = 0x0C0A,
  CREATE_NEW_UNIT_KEY = 0x0C0B,
  READ_STORED_LINK_KEY = 0x0C0D,
  WRITE_STORED_LINK_KEY = 0x0C11,
  DELETE_STORED_LINK_KEY = 0x0C12,
@@ -1654,10 +1653,6 @@ packet WritePinTypeComplete : CommandComplete (command_op_code = WRITE_PIN_TYPE)
  status : ErrorCode,
}

packet CreateNewUnitKey : Command (op_code = CREATE_NEW_UNIT_KEY) {
  _payload_,  // placeholder (unimplemented)
}

enum ReadStoredLinkKeyReadAllFlag : 8 {
  SPECIFIED_BD_ADDR = 0x00,
  ALL = 0x01,
+1 −1
Original line number Diff line number Diff line
@@ -219,7 +219,7 @@ impl SupportedCommands {
    /// Check whether a given opcode is supported by the controller
    pub fn is_supported(&self, opcode: OpCode) -> bool {
        match opcode {
            OpCode::ReadLocalSupportedCommands | OpCode::CreateNewUnitKey => true,
            OpCode::ReadLocalSupportedCommands => true,
            _ => {
                let converted = OpCodeIndex::try_from(opcode);
                if converted.is_err() {
+0 −2
Original line number Diff line number Diff line
@@ -139,7 +139,6 @@
#define HCI_FLUSH (0x0008 | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_READ_PIN_TYPE (0x0009 | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_WRITE_PIN_TYPE (0x000A | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_CREATE_NEW_UNIT_KEY (0x000B | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_GET_MWS_TRANS_LAYER_CFG (0x000C | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_READ_STORED_LINK_KEY (0x000D | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
#define HCI_WRITE_STORED_LINK_KEY (0x0011 | HCI_GRP_HOST_CONT_BASEBAND_CMDS)
@@ -1089,7 +1088,6 @@ typedef struct {
#define HCI_FLUSH_SUPPORTED(x) ((x)[6] & 0x02)
#define HCI_READ_PIN_TYPE_SUPPORTED(x) ((x)[6] & 0x04)
#define HCI_WRITE_PIN_TYPE_SUPPORTED(x) ((x)[6] & 0x08)
#define HCI_CREATE_NEW_UNIT_KEY_SUPPORTED(x) ((x)[6] & 0x10)
#define HCI_READ_STORED_LINK_KEY_SUPPORTED(x) ((x)[6] & 0x20)
#define HCI_WRITE_STORED_LINK_KEY_SUPPORTED(x) ((x)[6] & 0x40)
#define HCI_DELETE_STORED_LINK_KEY_SUPPORTED(x) ((x)[6] & 0x80)