1 /** @file 2 3 Copyright (c) 2015-2016, Linaro. All rights reserved. 4 Copyright (c) 2015-2016, Hisilicon Limited. All rights reserved. 5 6 This program and the accompanying materials 7 are licensed and made available under the terms and conditions of the BSD License 8 which accompanies this distribution. The full text of the license may be found at 9 http://opensource.org/licenses/bsd-license.php 10 11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 13 14 **/ 15 16 #ifndef __DW_USB_H__ 17 #define __DW_USB_H__ 18 19 // 20 // Protocol GUID 21 // 22 #define DW_USB_PROTOCOL_GUID { 0x109fa264, 0x7811, 0x4862, { 0xa9, 0x73, 0x4a, 0xb2, 0xef, 0x2e, 0xe2, 0xff }} 23 24 // 25 // Protocol interface structure 26 // 27 typedef struct _DW_USB_PROTOCOL DW_USB_PROTOCOL; 28 29 #define USB_HOST_MODE 0 30 #define USB_DEVICE_MODE 1 31 #define USB_CABLE_NOT_ATTACHED 2 32 33 typedef 34 EFI_STATUS 35 (EFIAPI *DW_USB_GET_SERIAL_NO) ( 36 OUT CHAR16 *SerialNo, 37 OUT UINT8 *Length 38 ); 39 40 typedef 41 EFI_STATUS 42 (EFIAPI *DW_USB_PHY_INIT) ( 43 IN UINT8 Mode 44 ); 45 46 struct _DW_USB_PROTOCOL { 47 DW_USB_GET_SERIAL_NO Get; 48 DW_USB_PHY_INIT PhyInit; 49 }; 50 51 extern EFI_GUID gDwUsbProtocolGuid; 52 53 #endif 54