| // Copyright 2024 The Fuchsia Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| library fuchsia.hardware.ufs; |
| |
| const UIC_COMMAND_ARGUMENT_COUNT uint8 = 3; |
| |
| /// Defined in UFSHCI 3.0, Section 5.6.1: UICCMD - UIC Command. |
| type UicCommandOpcode = flexible enum : uint8 { |
| DME_GET = 0x01; |
| DME_SET = 0x02; |
| DME_PEER_GET = 0x03; |
| DME_PEER_SET = 0x04; |
| DME_POWERON = 0x10; |
| DME_POWEROFF = 0x11; |
| DME_ENABLE = 0x12; |
| DME_RESET = 0x14; |
| DME_END_PT_RST = 0x15; |
| DME_LINK_STARTUP = 0x16; |
| DME_HIBER_ENTER = 0x17; |
| DME_HIBER_EXIT = 0x18; |
| DME_TEST_MODE = 0x1A; |
| }; |
| |
| type UicCommand = struct { |
| /// Opcode of the UIC command to be dispatched to the local UIC layer. |
| opcode UicCommandOpcode; |
| /// Parameters (input and output) of the UIC command. |
| argument array<uint32, UIC_COMMAND_ARGUMENT_COUNT>; |
| }; |