USB Mass storage driver
The current IRIX USB implementation is limited to a small subset of of USB classes, and very few devices. There are three main approaches to USB on IRIX.
The first approach is to write a separate USB software stack from the bottom up. This means developing a PCI device driver that recognises and supports a particular USB card, code to manage USB Request Blocks (URBs) and implement USB class drivers. Just one of these items is a huge undertaking.
The second approach would be port the Linux Kernel USB software stack to IRIX this would have the effect of sucking in the rest of the Linux kernel that the USB software stack relies on and bloating the resultant frankenstien system into a unmanageable mess..
A final, common and successful approach is to give up and stick a Linux box somewhere on the network and use that for all USB devices.
For some additional insight into what USB devices work <or don't> under IRIX, it'd probably be worth taking a look inside of the IRIX Kernel Hardware Inventory file - /usr/include/sys/invent.h <my references are to the IRIX 6.5.30 version of the file - the invent.h found in earlier IRIX revisions may be different>.
invent.h recognizes only four USB device classes, the root hub/controller, USB hubs, human interface devices, and the graphics compositor (used to composite multiple VPros into a single output), while the at-large USB specification includes a significantly larger list of device classes. To further muddy the water, invent.h also includes a note that mentions the listed classes might not match those defined in the at-large USB specification.
invent.h also includes a list of specific types of devices <that fall within each of the invent.h defined classes> and mentions these use data generated by the USB device to identify which class they belong in. Since the USB spec lists a number of device classes, this might the source of problems when a USB device is attached that doesn't define itself as belonging to one of the classes implicitly listed by invent.h. That need not be quite as dire as it sounds, in spite of the lack of an invent.h USB audio device class, the Griffin iMic USB audio device works under IRIX.
Device types include an OHCI root hub <the USB PCI controller - practical experience has shown this to be limited to certain TI OHCI chipsets>, human interface device <HID> keyboards, HID mice, and HID tablets. There's a mention that no USB hub types have been specifically defined <my Origin 300 shipped from the factory with an SIIG USB SlimHub 2.0, but in that particular case the USB controller is in the L2, which runs embedded PPC linux>.
If anyone feels like designing it.. Neko's O2 Cat girl with a USB trident might be something to work with.
Running GenToo Linux "LiveCD" on an Octane the card pictured worked with several device possibly even a USB thumb drive.
Project on github
mapping in hardware graph
find /hw/unknown/pci/vendor/0x1106/device/ /hw/unknown/pci/vendor/0x1106/device/ /hw/unknown/pci/vendor/0x1106/device/0x3038 /hw/unknown/pci/vendor/0x1106/device/0x3038/instance /hw/unknown/pci/vendor/0x1106/device/0x3038/instance/170 /hw/unknown/pci/vendor/0x1106/device/0x3038/instance/178 /hw/unknown/pci/vendor/0x1106/device/0x3104 /hw/unknown/pci/vendor/0x1106/device/0x3104/instance /hw/unknown/pci/vendor/0x1106/device/0x3104/instance/187
from the PCI database 0x1106 is VIA technologies and 0x3038 is USB and 0x3104 is "USB 2.0 Enhanced Host Controller"
The purpose of the userland driver is to explore and prototype for the device from user space without causing the IRIX system to panic and crash.
The IRIX APIs provision for user space programs to be able to respond to interrupts. so this may be useful for understanding whats is handed back when device events such as something being plugged into a USB port or a read request completing.
VIA vt6212 documentation
Appears to be non existant and the company appeared to be unhelpful when details were requested.
PCI configuration space
- Writing UNIX device drivers ISBN 0-201-52374-4 (A SVR3 and SCO System V/386 orientated book but quite readable for concepts)
- Writing Device Drivers: Tutorial and Reference, ISBN 1-55558-141-2 (This is a Digital UNIX device driver book, but some concepts carry).
- PCI Spec 2.2 ppage 264.
Base class 0c Sub class 03 Interfaces 00, 10, 80
- Magic Garden Explained ISBN 0-13-098136-9
- USB Mass Storage ISBN 1-931448-04-3
- USB Complete 4th Ed. ISBN 978-931-448-08-6
- "PCI Demystified", Doug Abbott. ebook or dead tree version. ISBN 1-878707-78-7
Appendix A.. Class 0c, Sub class 03 (USB),
- PCI System Architecture (Mindshare series) ISBN 0-201-30974-2
- USB System Architecture, 2nd Ed. (Mindshare Inc) ISBN 0-201-30975-0
00 Universal Host Controller specification 10 Open HCI specification 80 No specific programming interface FE USB device, not controller
- Device Driver writers guide. SGI docs PDF @ techpubs.sgi.com ( IRIX® Device Driver Programmer's Guide, document number: 007-0911-210 )
** PCI from user land example
- Enhanced Host Controller Interface Specification for Universal Serial Bus Intel Corp http://www.intel.com/technology/usb/download/ehci-r10.pdf
Current version of the driver
- Check out the latest version from <<repository>>
- tarball <<here>>
#!/usr/nekoware/bin/bash cp vt6212.o /var/sysgen/boot/ autoconfig # reboot # ml reg -m vt6212.o -p vt6212 # ml ld -m vt6212.o -p vt6212
Current versions of the userspace driver and test harnesses
Share your opinion