]> git.proxmox.com Git - mirror_edk2.git/blob - EdkModulePkg/Bus/Usb/UsbBus/Dxe/usbutil.h
Architecture rename
[mirror_edk2.git] / EdkModulePkg / Bus / Usb / UsbBus / Dxe / usbutil.h
1 /*++
2
3 Copyright (c) 2006, Intel Corporation
4 All rights reserved. This program and the accompanying materials
5 are licensed and made available under the terms and conditions of the BSD License
6 which accompanies this distribution. The full text of the license may be found at
7 http://opensource.org/licenses/bsd-license.php
8
9 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
10 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
11
12 Module Name:
13 usbutil.h
14
15 Abstract:
16
17 Helper functions for USB
18
19 Revision History
20
21
22 --*/
23
24 #ifndef _USB_UTIL_H
25 #define _USB_UTIL_H
26
27 //
28 // Following APIs are used to query Port Status
29 //
30 BOOLEAN
31 IsPortConnect (
32 IN UINT16 PortStatus
33 );
34
35 BOOLEAN
36 IsPortEnable (
37 IN UINT16 PortStatus
38 );
39
40 BOOLEAN
41 IsPortInReset (
42 IN UINT16 PortStatus
43 );
44
45 BOOLEAN
46 IsPortPowerApplied (
47 IN UINT16 PortStatus
48 );
49
50 BOOLEAN
51 IsPortLowSpeedDeviceAttached (
52 IN UINT16 PortStatus
53 );
54
55 BOOLEAN
56 IsPortSuspend (
57 IN UINT16 PortStatus
58 );
59
60 //
61 // Following APIs are used to query Port Change Status
62 //
63 BOOLEAN
64 IsPortConnectChange (
65 IN UINT16 PortChangeStatus
66 );
67
68 BOOLEAN
69 IsPortEnableDisableChange (
70 IN UINT16 PortChangeStatus
71 );
72
73 BOOLEAN
74 IsPortResetChange (
75 IN UINT16 PortChangeStatus
76 );
77
78 BOOLEAN
79 IsPortSuspendChange (
80 IN UINT16 PortChangeStatus
81 );
82
83 //
84 // Set device address;
85 //
86 EFI_STATUS
87 UsbSetDeviceAddress (
88 IN EFI_USB_IO_PROTOCOL *UsbIo,
89 IN UINT16 AddressValue,
90 OUT UINT32 *Status
91 );
92
93
94 #endif