From a1c2e4fbd80e0da03cea56bb511a892d5a652394 Mon Sep 17 00:00:00 2001 From: BALATON Zoltan Date: Mon, 25 Aug 2014 13:08:08 +0000 Subject: Add USB OHCI + HID driver This driver is ported from CoreBoot's libpayload and fixed to work on big endian CPUs (tested on PPC with QEMU). It is enough to support a USB keyboard on an Apple Keylargo OHCI compliant USB host and makes OpenBIOS usable on qemu-system-ppc64 with mac99 machine type as well as allows to emulate PowerMac3,1 better. Signed-off-by: BALATON Zoltan Signed-off-by: Mark Cave-Ayland git-svn-id: svn://coreboot.org/openbios/trunk/openbios-devel@1316 f158a5a8-5612-0410-a976-696ce0be7e32 --- include/drivers/pci.h | 1 + include/drivers/usb.h | 8 ++++++++ 2 files changed, 9 insertions(+) create mode 100644 include/drivers/usb.h (limited to 'include') diff --git a/include/drivers/pci.h b/include/drivers/pci.h index 1f0af6c9..2eb5685d 100644 --- a/include/drivers/pci.h +++ b/include/drivers/pci.h @@ -188,6 +188,7 @@ extern const pci_arch_t *arch; #define PCI_DEVICE_ID_APPLE_UNI_N_PCI 0x001f #define PCI_DEVICE_ID_APPLE_UNI_N_AGP 0x0020 #define PCI_DEVICE_ID_APPLE_UNI_N_KEYL 0x0022 +#define PCI_DEVICE_ID_APPLE_KEYL_USB 0x003f #define PCI_DEVICE_ID_APPLE_U3_AGP 0x004b #define PCI_VENDOR_ID_SUN 0x108e diff --git a/include/drivers/usb.h b/include/drivers/usb.h new file mode 100644 index 00000000..143ed27b --- /dev/null +++ b/include/drivers/usb.h @@ -0,0 +1,8 @@ +#ifndef USB_H +#define USB_H + +int ob_usb_ohci_init(const char *path, uint32_t addr); +void ob_usb_hid_add_keyboard(const char *path); +int usb_exit(void); + +#endif /* USB_H */ -- cgit v1.2.1