| edition = "2023"; |
| |
| package milotic_tlbmc; |
| |
| // FRU associations derived from an entity configuration and the FRU table. |
| // To populate the FRU associations, we need to successfully probe the FRU and |
| // upstream/ downstream FRUs as expressed in the entity configuration. |
| message FruInfo { |
| string fru_key = 1; |
| bool is_sub_fru = 2 [default = false]; |
| } |
| |
| // Type of a port. |
| enum PortType { |
| PORT_TYPE_UNKNOWN = 0; |
| PORT_TYPE_UPSTREAM = 1; |
| PORT_TYPE_DOWNSTREAM = 2; |
| PORT_TYPE_CABLE_UPSTREAM = 3; |
| PORT_TYPE_CABLE_DOWNSTREAM = 4; |
| } |
| |
| // Port configuration derived from an entity configuration. |
| message PortConfig { |
| PortType port_type = 1; |
| string port_name = 2; |
| string port_label = 3; |
| } |
| |
| // Location type of the part. |
| // See LocationType in: |
| // https://www.dmtf.org/sites/default/files/standards/documents/DSP2046_2024.2.html |
| enum PartLocationType { |
| PART_LOCATION_TYPE_UNSPECIFIED = 0; |
| PART_LOCATION_TYPE_BACKPLANE = 1; |
| PART_LOCATION_TYPE_BAY = 2; |
| PART_LOCATION_TYPE_CONNECTOR = 3; |
| PART_LOCATION_TYPE_EMBEDDED = 4; |
| PART_LOCATION_TYPE_SLOT = 5; |
| PART_LOCATION_TYPE_SOCKET = 6; |
| } |
| |
| // Location context of a resource. |
| message LocationContext { |
| string devpath = 1; |
| repeated string logical_identifiers = 2; |
| PartLocationType location_type = 3; |
| } |
| |
| // FRU topology node derived from an entity configuration. |
| message TopologyConfigNode { |
| // Name of the node, typically the config name. |
| string name = 1; |
| // FRU key of the node, typically the key in the FRU table. |
| FruInfo fru_info = 2; |
| // Port config of the upstream port the FRU is supposed to be connected to. |
| PortConfig upstream_port_config = 3; |
| // Ports exposed by the FRU. |
| // These may be downstream or upstream of any connected FRU. |
| map<string, PortConfig> port_configs = 4; |
| // Config names of the sub FRUs. |
| repeated string sub_fru_config_names = 5; |
| // Port config of the upstream cable connection this is connected to. |
| PortConfig upstream_cable_port_config = 6; |
| // Downstream cable port configs this is connected to. |
| map<string, PortConfig> cable_port_configs = 7; |
| // Location context of the resource. |
| LocationContext location_context = 8; |
| // Root location code of the resource. |
| string root_chassis_location_code = 15; |
| // Parent object. |
| string parent_resource_id = 9; |
| // Child resource objects. |
| // TODO(b/409103531): Generalize associations in tlBMC data model. |
| repeated string children_chassis_ids = 10; |
| repeated string children_cable_ids = 11; |
| repeated string children_processor_ids = 12; |
| repeated string children_storage_ids = 13; |
| repeated string children_assembly_ids = 16; |
| // Whether the config in this node is supported by tlBMC query. If true, this |
| // node will not be returned in GetAllConfigNames() since this config is not |
| // supported by tlBMC at the moment. |
| bool not_owned_by_tlbmc = 14; |
| } |
| |
| // FRU topology derived from the entity configurations. |
| message TopologyConfig { |
| // Root node of the topology. |
| string root_node_name = 1; |
| // Map of config name to topology node. |
| map<string, TopologyConfigNode> topology_config_nodes = 2; |
| // Map of FRU key to config name. |
| map<string, string> fru_configs = 3; |
| } |