Commit graph

438 commits

Author SHA1 Message Date
Cameron Gutman 812ea7c71a [PCI]
- Add forgotten line

svn path=/branches/usb-bringup-trunk/; revision=55542
2012-02-11 06:56:10 +00:00
Cameron Gutman f896aeba5e [ACPI]
- Fix incorrect maximum bound for resource requirements
- Handle PCI buses manually
[HAL]
- Don't hang if the IRP_MN_QUERY_INTERFACE is received
[INF]
- Misc fixes

svn path=/branches/usb-bringup-trunk/; revision=55541
2012-02-11 06:25:16 +00:00
Cameron Gutman ec01d86009 [PCI]
- Set device command flags when starting the PCI device PDO

svn path=/branches/usb-bringup-trunk/; revision=55540
2012-02-11 05:47:56 +00:00
Cameron Gutman 66246c5c2d [PCIX]
- Ignore invalid extended capabilities pointer
- Don't hang on unimplemented IRPs that we actually use

svn path=/branches/usb-bringup-trunk/; revision=55539
2012-02-11 05:15:25 +00:00
Johannes Anderwald 6ced7570a0 [USBEHCI]
- Store configuration index in the setup packet
- Perform retrieving the configuration request before storing the configuration details. Perform the same action for the select interface request
- EHCI now supports selecting configuration & interface on devices with more than one configuration (previously only one configuration was supported)
- Code has not yet been tested, as no available usb device has such feature

svn path=/branches/usb-bringup-trunk/; revision=55536
2012-02-11 02:10:20 +00:00
Johannes Anderwald 3a5a6bf017 [USBSTOR]
- Read Capacity cmd length is 10 bytes

svn path=/branches/usb-bringup-trunk/; revision=55531
2012-02-10 21:42:42 +00:00
Johannes Anderwald 1ecef805ff [USBEHCI]
- Partly revert 55516, as the memory bug got fixed

svn path=/branches/usb-bringup-trunk/; revision=55530
2012-02-10 20:15:39 +00:00
Cameron Gutman 4c47e234d1 [CLASS2]
- Fix boot from HDD with USB drive present
- Fix USB drive failure with no HDD present

svn path=/branches/usb-bringup-trunk/; revision=55526
2012-02-10 17:14:39 +00:00
Johannes Anderwald 6c4befe209 [USBEHCI] [USBOHCI]
- Don't corrupt memory when a queue head / transfer descriptor is freed
- How did this work before...

svn path=/branches/usb-bringup-trunk/; revision=55525
2012-02-10 16:28:35 +00:00
Johannes Anderwald 147eeaf010 [USB-BRINGUP-TRUNK]
- Rename usbehci & usbhub

svn path=/branches/usb-bringup-trunk/; revision=55524
2012-02-10 11:58:11 +00:00
Johannes Anderwald b5c9d47586 [USBHUB]
- Fix mingw build

svn path=/branches/usb-bringup-trunk/; revision=55521
2012-02-09 21:37:37 +00:00
Johannes Anderwald d54653187b [USBEHCI]
- Revert 55515, 55502, 55491, 55490, 55489 as it breaks mass storage support in VBox + Vmware

svn path=/branches/usb-bringup-trunk/; revision=55516
2012-02-09 19:11:13 +00:00
Johannes Anderwald 08ec4cc76d [EHCI]
- Try fix bulk transfers #1

svn path=/branches/usb-bringup-trunk/; revision=55515
2012-02-09 16:06:34 +00:00
Johannes Anderwald 42ff9c13c0 [USBHUB]
- Ignore error when the device provides a string descriptor but no contents
- Fixes installation of cheap usb devices

svn path=/branches/usb-bringup-trunk/; revision=55514
2012-02-09 15:33:09 +00:00
Johannes Anderwald 00f2bd907d [EHCI]
- Add back old implementation for testing purposes (if'd out)
- Display more status field of queue head / transfer descriptor
- Dump queue head when a halted queue is detected
- Display data toggle status

svn path=/branches/usb-bringup-trunk/; revision=55502
2012-02-08 22:06:00 +00:00
Cameron Gutman 4b30c8402f [USBHUB]
- Don't wait for the work item to complete in the SCE completion handler
- Use an event to signal the completion of a reset and wait for that event during IRP_MN_START_DEVICE handling so devices are enumerated synchronously which allows USB boot devices to be enumerated

svn path=/branches/usb-bringup-trunk/; revision=55493
2012-02-08 15:50:52 +00:00
Johannes Anderwald 0913187636 [USBEHCI]
- Fix a few bulk transfer bugs
- Enable interrupt completion on last interrupt 
- Increment transferred offset 
- Mass storage device now gets further (passing SRB_FUNCTION_CLAIM_DEVICE)

svn path=/branches/usb-bringup-trunk/; revision=55491
2012-02-08 01:10:36 +00:00
Johannes Anderwald d1da088aa8 [USBEHCI]
- Merge hub controller from usbohci
- Partly implement AbortPipe request
- Implement resetting data toggle in HandleSyncResetAndClearStall

svn path=/branches/usb-bringup-trunk/; revision=55490
2012-02-07 22:20:46 +00:00
Johannes Anderwald 133cb2712c [USBEHCI]
- Rewrite the transfer descriptor handling
- Take into account the direction of the pid
- Revert previously added hacks 
- Support now more than one transfer descriptor for control transfers
- Include the bulk transfers in one queue head which should speed up operation
- Store data toggle in usb endpoint structure
- Mass storage devices now passes the control status phase on real hw and enters bulk operation stage

svn path=/branches/usb-bringup-trunk/; revision=55489
2012-02-07 21:48:05 +00:00
Johannes Anderwald 4009376a99 [USBEHCI]
- Fix data toggle misuse
- EHCI host error is now fixed
- Fixed by the Haiku dev Michael Lotz

svn path=/branches/usb-bringup-trunk/; revision=55484
2012-02-07 16:46:19 +00:00
Johannes Anderwald 0ecb2a6706 [USBEHCI]
- Don't set NumberOfTransaction 0x3 for the async queue head(Haiku doesnt do it too)
- Also don't set maximum packet length or interrupt on complete
- Stop the async / periodic schedules after acquiring ownership from os (ported from the Pedigree OS)
- Remove unused structs from header 
- Allocate device descriptor from start of a page to prevent alignment issues
- Clear halted bit in the queue overlay transaction layer (usb_queue.cpp:507)
- Always set the alternative and next pointers in BuildControlTransferQueueHead
- Use data the toggle in the transfer requests
- Start using toggle in bulk requests, invert data toggle after each descriptor
- EHCI controller still reports error 0xA / 0xB which is USB Error Interrupt + Frame List Rollover + [USB Interrupt]
- Errors need to be researched more, though the control transfers results appear o.k.
- Tested in real hw + ros stack with USB Mass Storage Device
- Currently hangs after first completed CDB/Data/CSW block

svn path=/branches/usb-bringup-trunk/; revision=55483
2012-02-07 16:18:56 +00:00
Cameron Gutman 27a04819e7 [USBEHCI]
- Wait for periodic scheduling to start
- Increase the wait interval for asynchronous scheduling to start

svn path=/branches/usb-bringup-trunk/; revision=55477
2012-02-07 02:22:34 +00:00
Cameron Gutman ec95123297 [USBOHCI]
- Enable bus master on OHCI controllers if it's not set by default

svn path=/branches/usb-bringup-trunk/; revision=55476
2012-02-07 01:59:18 +00:00
Amine Khaldi 60e9668112 [CLASSPNP]
* Rename class.spec to classpnp.spec and adjust the build files accordingly.
[DISK_NEW]
* Fix the build files (cmake and rbuild).
* Fix InitSafeBootMode use.
* Add disk_new to build.

svn path=/branches/usb-bringup-trunk/; revision=55475
2012-02-06 22:48:17 +00:00
Johannes Anderwald 99a3cc7d54 [DISK]
- Add more structures to ntdddisk.h
- Fix more compile errors in disk_new
- disk_new builds but fails to link as classpnp import lib is broken

svn path=/branches/usb-bringup-trunk/; revision=55451
2012-02-06 08:15:21 +00:00
Cameron Gutman 385ddbfd32 [USBEHCI]
- Implement ResetController and call it before setting up the controller
- Don't disable 64-bit addressing until the BIOS gives up control of the controller
- Comment out manually clearing the SMI interrupt and the BIOS owned flag by request of janderwald
- EHCI no longer hangs for me on real hardware during controller initialization

svn path=/branches/usb-bringup-trunk/; revision=55450
2012-02-06 07:41:20 +00:00
Johannes Anderwald 2f6346e3cf [DISK_NEW]
- Fix compilation of new disk driver 
- Patch by Alex Ionescu

svn path=/branches/usb-bringup-trunk/; revision=55447
2012-02-06 06:50:19 +00:00
Johannes Anderwald cf494ea401 [HIDCLASS]
- Check if attaching to device stack failed. In that case fail the request
[HIDUSB]
- Always set SupriseRemovalOk
[USBCCGP] [HIDCLASS] [USBHUB] [USBSTOR]
- Check if the pdo is still in the pdo list. Only call IoDeleteDevice in that case

svn path=/branches/usb-bringup-trunk/; revision=55429
2012-02-05 15:36:00 +00:00
Pierre Schweitzer 82848d85df [MOUNTMGR]
Implement DeleteRemoteDatabaseEntry

svn path=/branches/usb-bringup-trunk/; revision=55422
2012-02-04 22:01:12 +00:00
Cameron Gutman 6e3fa77024 [USBD]
- Add and fix missing exports
- Add UNIMPLEMENTED to unimplemented functions
- Fix completely broken USBD_GetPdoRegistryParameter (which wasn't even exported because somebody made a typo and couldn't figure it out)
- My Linksys USB300M driver now loads but it runs into some unimplemented code paths in usbehci

svn path=/branches/usb-bringup-trunk/; revision=55416
2012-02-04 18:39:09 +00:00
Johannes Anderwald 9f4adfb8ee [USBOHCI]
- Revert 55411

svn path=/branches/usb-bringup-trunk/; revision=55412
2012-02-04 15:04:27 +00:00
Johannes Anderwald 80c665d2ac [HIDCLASS]
- Remove PDO from pdo list when it is destroyed
- Handle IRP_MN_QUERY_REMOVE_DEVICE, IRP_MN_CANCEL_STOP_DEVICE, IRP_MN_QUERY_STOP_DEVICE, IRP_MN_CANCEL_REMOVE_DEVICE
[HIDUSB]
- Add driver unload routine
[MOUHID]
- Wait for completion of pending irp
[USBHUB]
- Remove pdo from PDO list
- Handle IRP_MN_QUERY_DEVICE_RELATIONS
- Add stub driver unload routine
[USBOHCI]
- handle IRP_MN_REMOVE for FDO
- remove ASSERT

svn path=/branches/usb-bringup-trunk/; revision=55411
2012-02-04 14:10:18 +00:00
Cameron Gutman 3bc323077a [HIVESYS]
- Add HID devices to the critical device database
- Fixes issues with mouse/keyboard not working until new device wizards are dismissed (USB drives work too)
[UMPNPMGR]
- Fix install failure after the kernel detects a critical device
[NTOSKRNL]
- Finally enable the proper IopResetDevice code
- Driver updating without a reboot for running devices is supported now (if someone will write the GUI)
[USBEHCI][USBOHCI]
- Fix removal bugs

svn path=/branches/usb-bringup-trunk/; revision=55401
2012-02-03 23:34:21 +00:00
Cameron Gutman e7484d185a [PCI][HIDCLASS][HIDUSB][KBDHID][MOUHID][USBCCGP][USBOHCI][USBEHCI][USBHUB][USBSTOR]
- Handle query remove IRPs
- Fix some other removal bugs

svn path=/branches/usb-bringup-trunk/; revision=55399
2012-02-03 22:59:53 +00:00
Johannes Anderwald 9eed4afb3d [USBCCGP]
- Remove hack of forwarding pdo requests to lower device object of fdo
- Implement handling of reset port and cycle port
- IOCTL_INTERNAL_USB_RESET_PORT /  IOCTL_INTERNAL_USB_CYCLE_PORT now need to be implemented in usbhub

svn path=/branches/usb-bringup-trunk/; revision=55396
2012-02-03 16:03:42 +00:00
Johannes Anderwald fb0e8c40ac [USBOHCI]
- Fix mingw build

svn path=/branches/usb-bringup-trunk/; revision=55395
2012-02-03 15:55:04 +00:00
Johannes Anderwald c2d96ce7ff [USBOHCI]
- Implement reseting pipe and clear pipe stall

svn path=/branches/usb-bringup-trunk/; revision=55394
2012-02-03 14:47:18 +00:00
Johannes Anderwald 690f71f605 [USBOHCI]
- Fix build

svn path=/branches/usb-bringup-trunk/; revision=55393
2012-02-03 13:02:45 +00:00
Johannes Anderwald 71b5a853dc [USBOHCI]
- Don't hardcode the device speed

svn path=/branches/usb-bringup-trunk/; revision=55392
2012-02-03 11:29:03 +00:00
Johannes Anderwald 8e66575f08 [USBOHCI]
- Consider device speed when building the device endpoint descriptor

svn path=/branches/usb-bringup-trunk/; revision=55390
2012-02-03 11:02:37 +00:00
Johannes Anderwald 4cbccecd5c [USBOHCI]
- Check if the transfer descriptors reported errors and propagate the error in the urb status field
- OHCI now reports error which the class driver are handling
- Allocate device descriptor from non paged pool to prevent possible alignment problems
- Fix checking of completed transfer descriptors
- Fix double freeing of descriptors
- Cleanup endpoints when the halted bit is set by the host controllers
- Check for the endpoint direction in the data descriptor
- Setup descriptor needs buffer rounding set

svn path=/branches/usb-bringup-trunk/; revision=55389
2012-02-03 09:52:29 +00:00
Johannes Anderwald b1587061be [EHCI]
- Explictely clear bios owned flag and remove all SMI interrupts

svn path=/branches/usb-bringup-trunk/; revision=55387
2012-02-02 23:35:56 +00:00
Johannes Anderwald dbbb319a35 [USBEHCI]
- Check for bios ownership
- Acquire ownership if bios owns it
- Verify ownership

svn path=/branches/usb-bringup-trunk/; revision=55386
2012-02-02 23:09:53 +00:00
Johannes Anderwald 7626aedc3b [USBEHCI]
- Use constants instead of hardcoding register offsets. Taken from Haiku
- Elements in HCSP-PORTROUTE are 4 bit entries instead

svn path=/branches/usb-bringup-trunk/; revision=55385
2012-02-02 22:18:58 +00:00
Johannes Anderwald 59de50814d [USBSTOR]
- Add sanity checks
- Check if device needs CDB padding and return error in that case

svn path=/branches/usb-bringup-trunk/; revision=55381
2012-02-02 19:37:38 +00:00
Cameron Gutman 087dfd04c9 [USBOHCI]
- Fix device enumeration on boot

svn path=/branches/usb-bringup-trunk/; revision=55380
2012-02-02 18:29:30 +00:00
Johannes Anderwald 28ae797644 [HIDCLASS]
- Also store the HID_DEVICE_UP format in the hardware id list

svn path=/branches/usb-bringup-trunk/; revision=55378
2012-02-02 18:10:11 +00:00
Cameron Gutman b6406a158e [HIDCLASS]
- Ignore failure to register a device interface during 1st stage setup

svn path=/branches/usb-bringup-trunk/; revision=55375
2012-02-02 17:42:55 +00:00
Johannes Anderwald 820049768b [USBCCGP]
- Remove hacks used for broken usbd driver
- Implement IRP_MN_REMOVE for FDO & PDO

svn path=/branches/usb-bringup-trunk/; revision=55372
2012-02-02 10:17:14 +00:00
Johannes Anderwald aa485d63fd [USBD]
- In 2012 a long protected natural resource for bugs was shutdown due to popular usb device support demand
- Fix length check in USBD_ParseDescriptors. (PLONG)Descriptor + TotalLength is not the length of the configuration descriptor but twice the configuration descriptor
- Reset found variable in the loop. This fixes finding of interfaces which are not the first one in the configuration descriptor
- Again moving to next usb descriptor was broken. UsbDeviceDescriptor = UsbDeviceDescriptor + UsbDeviceDescriptor->bLength does not move to the next but to next XX descriprors specified by bLength
- Introduced in rev 17382 (14/08/2005)
 

svn path=/branches/usb-bringup-trunk/; revision=55370
2012-02-01 16:59:13 +00:00