shithub: riscv

Download patch

ref: 57fc95de3c52ed71a6cd478ae495d2bcaeab7204
parent: 1fe150f1ed46a8c1a65187b3088274e067493639
author: Keegan Saunders <keegan@undefinedbehaviour.org>
date: Sun Jan 7 16:10:57 EST 2024

arm64/qemu: add xhci usb

To use, add the QEMU XHCI PCI device:

	-device qemu-xhci,id=xhci -device usb-tablet,bus=xhci.0

--- a/sys/src/9/arm64/io.h
+++ b/sys/src/9/arm64/io.h
@@ -15,3 +15,5 @@
 };
 
 #define BUSUNKNOWN (-1)
+#define PCIWINDOW	0
+#define	PCIWADDR(x)	(PADDR(x)+PCIWINDOW)
--- a/sys/src/9/arm64/qemu
+++ b/sys/src/9/arm64/qemu
@@ -16,11 +16,13 @@
 	bridge	log
 	ip	arp chandial ip ipv6 ipaux iproute netlog nullmedium pktmedium inferno
 	uart
+	usb
 	rtc
 	pci	pci
 	sd
 
 link
+	usbxhcipci	pci usbxhci
 	ethervirtio10	pci
 	ethersink
 	ethermedium