1. 22 May, 2011 1 commit
    • Jeffrey Lee's avatar
      Add the ability to build the USB drivers as HAL-compatible static libraries · 4ca937fd
      Jeffrey Lee authored
      Detail:
        build/Makefile, build/OBJEHCIDriver, build/OBJOHCIDriver, build/OBJUSBDriver - Modified makefiles to build the HAL libs during the export libs phase
        build/!MkHAL,fd7 - Handy script for building the HAL libs
        build/Hdr/usbhal - Header containing definitions for the assembler code. Also gets exported so that HALs know how much workspace to reserve.
        build/c/usbhal - HAL version of usbmodule.c & port.c. Also contains the keyboard scan code, adapted from the code in the Tungsten HAL.
        build/s/porthal - Assembler versions of some port.c routines that were easier to do in assembler than C
        build/s/halheap - OS_Heap code that's been adapted for use in the HAL. Could easily be changed into a standalone library instead of being part of the HAL USB libs. Supports memory-efficient allocation of aligned blocks.
        build/c/ehcihal - HAL version of ehcimodule.c. Currently only supports EHCI controllers exposed via HAL_USBControllerInfo (i.e. no PCI support)
        build/c/ehcimodule, build/c/ohcimodule, build/c/port - Moved riscos_irq_clear into port.c. Removed unused microtime() function.
        build/c/usbmouse - Strip out some debug-related code in non-debug builds
        build/Version - Updated version numbers
        dev/usb/c/ehci, dev/usb/h/ehcivar - Adapted to add support for the HAL build. Apart from the base changes, the code has also been tweaked to significantly reduce the amount of memory used at runtime by the HAL version of the driver.
        dev/usb/c/hid, dev/usb/c/uhub, dev/usb/c/usb, dev/usb/c/usb_quirks, dev/usb/c/usb_subr, dev/usb/c/usbdi, dev/usb/c/usbdi_util, dev/usb/c/usbroothub_subr - Changes to support HAL builds. Mainly disabling bits that won't work in the HAL or disabling bits for RISC OS in general if they weren't being used in the first place.
        dev/usb/c/ohci, dev/usb/h/ohcivar - Basic changes to support HAL builds. However HAL OHCI support is still incomplete.
        dev/usb/h/usb_port - Added support for the HAL build. Also tweaked logprintf definition to get rid of logprintf calls entirely in non-debug builds.
        dev/usb/h/usbdivar - Added support for the HAL build.
        dev/usb/h/usbhal - New header used by the HAL build. Gets included by every C file to ensure the compiler doesn't use sb, and contains structs/macros to allow access to the shared workspace.
      Admin:
        HAL & non-HAL builds tested on rev C2 BB, rev A2 BB-xM, rev C1 TouchBook.
        Non-HAL builds tested with Iyonix ROM softload.
        Needs latest Kernel source for OSEntries.h export.
      
      
      Version 0.59. Tagged as 'NetBSD-0_59'
      4ca937fd
  2. 01 Feb, 2011 1 commit
    • Jeffrey Lee's avatar
      Fix modules so resources don't get included twice in ROM builds · 32bcd2b5
      Jeffrey Lee authored
      Detail:
        A couple of the USB modules were including their resources both in the Messages module and within themselves, leading to wasted ROM space
        build/OBJOHCIDriver, build/OBJUSBDriver - Tweaked makefiles so that ohcimsgs.o and usbmsgs.o only get built/linked for RAM builds
        build/c/usbmodule - Fix erroneous attempt to free non-registered resource files in ROM builds
        Version - Increased OHCIDriver & USBDriver version numbers
      Admin:
        Tested with Iyonix ROM softload. Saves approx 48k of ROM space.
        Fixes bug #265
      
      
      Version 0.57. Tagged as 'NetBSD-0_57'
      32bcd2b5
  3. 23 Nov, 2010 1 commit
    • Jeffrey Lee's avatar
      Fix a few USBDriver bugs · 3c10a2b1
      Jeffrey Lee authored
      Detail:
        build/c/usbdi - Fix compiler warning in usbd_clear_endpoint_stall()
        build/c/usbmodule - Fix detach_device() to deregister any pending attach callback for the detaching device. Fixes crash seen when inserting 16GB USB stick into EHCI port of rev C2 beagleboard (a current surge or something causes the stick to immediately disconnect then reconnect, but the disconnect occurs before the initial attach callback)
        build/c/usbmodule - Fix device_initialise() to use a timeout of 0 if no timeout was specified in the DeviceFS special field
        build/c/usbmodule - Fix the new read_cb() buffer padding logic to only pad up to totalcount instead of filling the entire buffer
      Admin:
        Tested on rev C2 beagleboard.
        This seems to fix the problems that were preventing Steffen Huber's USB CD code from working properly.
      
      
      Version 0.56. Tagged as 'NetBSD-0_56'
      3c10a2b1
  4. 21 Jul, 2010 1 commit
    • Jeffrey Lee's avatar
      Update EHCI driver to NetBSD latest (as of 10/07/2010), improve DeviceFS interface · eb6607d0
      Jeffrey Lee authored
      Detail:
        EHCI driver update:
          dev/usb/c/ehci - Updated to latest NetBSD version, except for revisions 1.134 and 1.135 which are too invasive to merge in without updating the rest of the USB stack. This new version brings lots of bug fixes, and adds (untested on RISC OS) support for EHCI isochronous transfers.
          dev/usb/h/ehcivar - Updated to latest NetBSD version, except for the sc_bus splitting that was held back from the ehci.c update
          dev/usb/h/usb, dev/usb/h/usbdi, dev/usb/usbdivar - partial update to latest as required/possible
          dev/usb/c/usb_quirks, dev/usb/h/ehcireg, dev/usb/h/usb_mem, dev/usb/h/usb_quirks, dev/usb/h/usbhid, dev/usb/usbdevs, dev/usb/devlist2h.awk, dev/wscons/h/wsconsio, dev/wscons/h/wsmousevar - Updated to latest NetBSD versions
          dev/usb/c/usbroothub_subr, dev/usb/h/usbroothub_subr - New files brought in from NetBSD sources for use with new EHCI driver
          build/objehcidriver - Added usbroorhub_subr to EHCI driver
          dev/usb/h/usb_port - Added extra dummy functions as required by new EHCI driver
          dev/build/c/port - Added extra parameter to callout_init as required by new EHCI driver
        DeviceFS improvements:
          build/c/usbmodule - Added DeviceFSCallDevice_GetHandles2 as a replacement for Thomas Milius's backwards-incompatible GetHandles changes. Added DeviceFSCallDevice_GetSetOptions call to control RX padding and TX force-short-xfer features. These features can also be controlled at endpoint creation time by new fields in the filename. Also fixed packet padding to not fill the buffer with garbage or potentially crash when the padded area is more than one packet in length.
        New bus registration API:
          Changes made to the data structures that are shared between the modules means that new checks are needed to ensure USB modules with incompatible APIs are not used with one another.
          build/h/usbdivar - Since this seems to be the file containing the main structures that are shared, it now has a #define at the top indicating the first version of the USBDriver module that implemented the data structures within. This version number is used to check that the driver modules are compatible.
          build/cmhg/usbmodhead, build/h/usbdriver, build/c/usbmodule - Add a new SWI, USBDriver_Version, to return the version number of the USBDriver module. Used for both intra-stack API version checks and can be useful for external code that wants to query DeviceFS feature availability.
          build/c/usbmodule, build/c/ehcimodule, build/c/ohcimodule - Updated USBDriver_RegisterBus SWI and the code that calls it to pass the API version number (as defined in usbdivar.h) to USBDriver when attempting to reigster the bus. USBDriver then ensures the version matches that of itself, and if not refuses to allow the bus to register. EHCI & OHCI modules also check that USBDriver is new enough to implement this behaviour via the USBDriver_Version SWI.
        And finally:
          build/version - Incremented module version numbers.
          build/doc/usb - Updated with details of new features
      Admin:
        Tested in ROM softload on Iyonix & beagleboard. Beagleboard hub issues seem to be resolved, and there are no new bugs that I can see.
      
      
      Version 0.52. Tagged as 'NetBSD-0_52'
      eb6607d0
  5. 28 Feb, 2010 1 commit
    • Jeffrey Lee's avatar
      Fix USBDriver's handling of PointerV. Increase module version numbers/dates. · c5f29964
      Jeffrey Lee authored
      Detail:
        build/c/usbmouse - USBDriver's PointerReason_Request handler now correctly restores the IRQ state to that of the caller, instead of unconditionally enabling IRQs. It also correctly intercepts the vector instead of passing it on to other claimants.
        build/Version - This fake VersionNum file hasn't been touched in a long time, leading to some newer versions of the USB modules being released with version numbers identical to their predecessors. This has now been fixed, so that each module has had its version increased by 0.01 and date increased to that of the last (functional) change.
      Admin:
        Tested on rev C2 beagleboard
      
      
      Version 0.50. Tagged as 'NetBSD-0_50'
      c5f29964
  6. 22 Feb, 2006 1 commit
    • John Ballance's avatar
      Replaced ep resync mechanism in usb_subr · 49639dac
      John Ballance authored
      Detail:
      	in recent work endpoint resync mechanism in usb_subr
      	was removed to re-align better with current NetBSD
      	sources.. however without the mechanism Epson
      	scanners fail to do repeat scans/
      Admin:	Castle added IP
      
      
      Version 0.46. Tagged as 'NetBSD-0_46'
      49639dac
  7. 05 Jan, 2006 1 commit
  8. 31 Dec, 2005 1 commit
  9. 05 Dec, 2005 1 commit
  10. 05 Jun, 2005 1 commit
    • John Ballance's avatar
      Fixed abort seen with some KVMs and ps2 adaptors in relation to !HID · 5f9b6d9d
      John Ballance authored
      Detail:
      	Devices with HID kbd and mouse in separate interfaces were
      	not being correctly 'forgotten' when the device was claimed
      	by a 3rd party App (!HID). This was because a re-entrancy issue
      	led to the second claimed i/f being removed before the first
      	was fully removed.
      	This led to a muddle in the dev->subdevs array. Solution was to
      	unlink it from the subdevs array before 'detaching' it,
      	instead of after.
      Admin:
      	Castle added IP. Tested at Castle. Will be initially released via
      	the beta test site.
      
      
      Version 0.41. Tagged as 'NetBSD-0_41'
      5f9b6d9d
  11. 18 May, 2005 1 commit
    • John Ballance's avatar
      several changes and nullpointer bug fixes · 49da0634
      John Ballance authored
      Detail:
      	Includes several bug fixes and null pointer traps.
      	Rhenium version reviewed and reset should be improved.
      Admin:
      	Tested in rhenium desktop build and iyonix build at castle
         	Castle added IP
      
      
      Version 0.40. Tagged as 'NetBSD-0_40'
      49da0634
  12. 24 Apr, 2005 1 commit
    • John Ballance's avatar
      Update of NetBSD elements (except c.ohci) to track NetBSD current from mid April 2005. · 8f8a1be7
      John Ballance authored
      	Inclusion of Mods to c.ehci (from Dan) to correctly handle low
      	speed interrupt devices beyond USB2 hubs (i.e. keyboards and mice).
      	Mod to EHCI resetting in service call handler to better cope with
      	USBDriver being restarted 'underneath' it.
      Detail:
      Admin:
      	Castle, Dan Ellis, NetBSD added IP. Tested at Castle. Will be
      	beta tested at this revision level before full release.
      
      
      Version 0.39. Tagged as 'NetBSD-0_39'
      8f8a1be7
  13. 05 Mar, 2005 1 commit
  14. 24 Feb, 2005 1 commit
    • John Ballance's avatar
      2 specific changes to USBDriver module · 6a08f2c6
      John Ballance authored
              Added (and fixed code underlying) to give periodic
              explore of USB busses (cf NetBSD).
              Added USBDisover command to let user provoke this too.
              Reworked USB device number allocation to roll
              around at 999 to avoid field overflow in
              a number of places.
      Detail:
      Admin:  castle added IP. to be beta tested on beta test site
      
      
      Version 0.37. Tagged as 'NetBSD-0_37'
      6a08f2c6
  15. 23 Feb, 2005 1 commit
    • John Ballance's avatar
      An increased delay caused havoc with chicony keyboards in the field · ec61c0b1
      John Ballance authored
      Detail:
              USB_PORT_RESET_DELAY had been increased from 100 to 200ms in previous
              version. This was OK for most devices, and beneficial for some, BUT
              killed the Chicony keyboards shipped with many iyonix.. Delay has
              been reverted to 100ms, and is now run time alterable via the
              USB$PortResetDelay sysvar. This problem did not show up in beta testing!
      
      Admin:  tested by JB with chicony.. delays up to around 160ms work with
              the chicony.
              Castle added IP
      
      Version 0.36. Tagged as 'NetBSD-0_36'
      ec61c0b1
  16. 18 Feb, 2005 1 commit
    • John Ballance's avatar
      changes and bug fixes that came to light following USB2 launch. · 85cb0bb5
      John Ballance authored
      Detail:
               - VarVal launching.. string length was incorrectly calculated.
               - USB VarVals now correctly cleared if device failed during
                 enumeration, after first SetVarVal call.
               - Triggercbs() modified to check interrupt context and be
                 refuse (quietly) to trigger callbacks if interrupts threaded
                 (result of possible issue .. but perhaps wise)
               - Added third QueryDelay variable, and an Info file to describe
                 what does what.
      Admin:
               checked at Castle.. due for extended check via beta test site
               before formal release.
      
               Castle + D Ellis added IP
      
      
      Version 0.35. Tagged as 'NetBSD-0_35'
      85cb0bb5
  17. 31 Jan, 2005 1 commit
  18. 21 Jan, 2005 1 commit
    • John Ballance's avatar
      Stack brought up to date with NetBSD sources as at 20050121. · af0b10a5
      John Ballance authored
              USB2 further debugged.
      Detail:
              Check in prior to second beta release. Improvements also to
              softloading of replacement modules.
      Admin:
              Checked with JB .. further crosschecking is still needed for rhenium.
              Castle/D Ellis added ip from NetBSD sources
      
      
      Version 0.33. Tagged as 'NetBSD-0_33'
      af0b10a5
  19. 03 Jan, 2005 1 commit
  20. 30 Dec, 2004 1 commit
    • John Ballance's avatar
      Update of EHCIDriver to current NetBSD, together with needed changes in both... · 480e14ee
      John Ballance authored
      Update of EHCIDriver to current NetBSD, together with needed changes in both OHCIDriver and USBDriver.
      
      Detail:
              Code may change before formal release .. will be beta released
              ... Entered to CVS to get new version numbers, and for
              the record.
      Admin:
              Castle/netbsd added IP .. will be tested more fully before
              formal release. Still to be verified on Rhenium.
      
      
      Version 0.31. Tagged as 'NetBSD-0_31'
      480e14ee
  21. 25 Nov, 2004 1 commit
  22. 12 Nov, 2004 1 commit
  23. 12 Aug, 2004 1 commit
    • John Ballance's avatar
      Extensive changes and bug fixes to usb and ohci .. · e9f0e9c8
      John Ballance authored
        'blocked' several holes that could cause freezes with awkward
        usb devices.  Added latest changes from Dan Ellis too , especially for USB2
      Detail:
       many
      Admin:
       Tested in ROM at Castle, and beta tested with users
      
      
      Version 0.28. Tagged as 'NetBSD-0_28'
      e9f0e9c8
  24. 30 Jun, 2004 1 commit
  25. 06 May, 2004 1 commit
    • Ben Avison's avatar
      New versions from John. · 833bc3d0
      Ben Avison authored
      Detail:
        * All modules will now rmkill/rmload more reliably
        * Keyboard driver disables kernel debounce on new enough kernels, needed
          for many PS2-USB adaptors, bar code scanners etc
        * Mouse driver will scroll wheel scroll any windows that do respond to
          scroll events, otherwise it issues PointerReason_WheelChange (9) to an
          external WimpScroll module
        * Several bugs and an interrupt hole resolved
      Admin:
        Tested at Framlingham.
      
      Version 0.25. Tagged as 'NetBSD-0_25'
      833bc3d0
  26. 21 Jan, 2004 1 commit
  27. 07 Jan, 2004 2 commits
  28. 16 Jun, 2003 1 commit
  29. 03 Jun, 2003 1 commit
  30. 23 May, 2003 1 commit
  31. 23 Apr, 2003 1 commit
  32. 15 Apr, 2003 1 commit
  33. 11 Apr, 2003 1 commit
  34. 10 Apr, 2003 1 commit
    • Kevin Bracey's avatar
      Fix for erratic behaviour after having unplugged hubs: TAILQ was being given... · 495f60f3
      Kevin Bracey authored
      Fix for erratic behaviour after having unplugged hubs: TAILQ was being given an entry which wasn't on its list, and the behaviour was to break the list and poke a zero into the reset vector!
      
      Also, some extra IFDEF's so that debug builds will work again.
      A few typos/spelling errors changed.
      
      Version 0.11. Tagged as 'NetBSD-0_11'
      495f60f3
  35. 08 Apr, 2003 1 commit
  36. 02 Mar, 2003 1 commit
    • Robert Sprowson's avatar
      Found a "busses" lingering in the messages file,also removed a \n which must... · f5d5a094
      Robert Sprowson authored
      Found a "busses" lingering in the messages file,also removed a \n which must have been copied from a printf somewhere.
      
      Old service call detail removed from c.port as it's defined in another
      file differently!
      USBDiscover is now only available for debugging purposes.
      Internationalised the mouse name (default is still "USB mouse").
      
      Version 0.08. Tagged as 'NetBSD-0_08'
      f5d5a094
  37. 22 Feb, 2003 1 commit
  38. 10 Feb, 2003 1 commit
  39. 07 Feb, 2003 1 commit
    • Dan Ellis's avatar
      Another fix to the previous buffer overrun fix,such that this time the command... · 7d316e9c
      Dan Ellis authored
      Another fix to the previous buffer overrun fix,such that this time the command aliases actually get executed now.
      
      Timing code changed to work round HAL call not returning the right value
      so temporarily wired to 2000000.
      Change to Makefile so ROM builds don't have annoying throwback windows
      popping up,this is now in the !Mk file.Also "-ff" function names away.
      
      Version 0.05. Tagged as 'NetBSD-0_05'
      7d316e9c