summaryrefslogtreecommitdiff
path: root/src/drivers/usb/ehci_debug.h
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2014-02-09 23:35:39 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2014-02-12 21:55:56 +0100
commit8cde852ecf4dced16b342a2da31990e0caf8b92b (patch)
treef37df8457d5f2ccaca2ca959f41e2c2f45094c54 /src/drivers/usb/ehci_debug.h
parent411bf97c22dde9943b892a0969470d8b07b23e27 (diff)
downloadcoreboot-8cde852ecf4dced16b342a2da31990e0caf8b92b.tar.xz
usbdebug: Split to USB host/device
Top-level interface to console over USB mut not require low-level details of ECHI debug port internals. Change-Id: If3ca3b1f479e3f20976cd4abd8f5e682a58d5650 Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: http://review.coreboot.org/5197 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin <adurbin@google.com>
Diffstat (limited to 'src/drivers/usb/ehci_debug.h')
-rw-r--r--src/drivers/usb/ehci_debug.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/src/drivers/usb/ehci_debug.h b/src/drivers/usb/ehci_debug.h
index 462eb233cc..7cfac011e1 100644
--- a/src/drivers/usb/ehci_debug.h
+++ b/src/drivers/usb/ehci_debug.h
@@ -27,4 +27,26 @@ void usbdebug_disable(void);
void ehci_debug_hw_enable(void);
void ehci_debug_select_port(unsigned int port);
+
+#define DBGP_EP_VALID (1<<0)
+#define DBGP_EP_ENABLED (1<<1)
+#define DBGP_EP_BUSY (1<<2)
+#define DBGP_EP_STATMASK (DBGP_EP_VALID | DBGP_EP_ENABLED)
+
+struct dbgp_pipe
+{
+ u8 devnum;
+ u8 endpoint;
+ u8 pid;
+ u8 status;
+ int timeout;
+
+ u8 bufidx;
+ u8 buflen;
+ char buf[8];
+};
+
+void dbgp_put(struct dbgp_pipe *pipe);
+int dbgp_try_get(struct dbgp_pipe *pipe);
+
#endif /* _EHCI_DEBUG_H_ */