ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
February 2012
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
22 participants
577 discussions
Start a n
N
ew thread
[cgutman] 55365: [USBEHCI] - Wait 20 milliseconds after enabling power for the port to stabilize
by cgutman@svn.reactos.org
Author: cgutman Date: Wed Feb 1 11:22:43 2012 New Revision: 55365 URL:
http://svn.reactos.org/svn/reactos?rev=55365&view=rev
Log: [USBEHCI] - Wait 20 milliseconds after enabling power for the port to stabilize Modified: branches/usb-bringup-trunk/drivers/usb/usbehci_new/hardware.cpp Modified: branches/usb-bringup-trunk/drivers/usb/usbehci_new/hardware.cpp URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbehci_new/hardware.cpp [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbehci_new/hardware.cpp [iso-8859-1] Wed Feb 1 11:22:43 2012 @@ -957,11 +957,30 @@ { if (m_Capabilities.HCSParams.PortPowerControl) { + ULONG Value; + LARGE_INTEGER Timeout; + // // enable port power // - ULONG Value = EHCI_READ_REGISTER_ULONG(EHCI_PORTSC + (4 * PortId)) | EHCI_PRT_POWER; + Value = EHCI_READ_REGISTER_ULONG(EHCI_PORTSC + (4 * PortId)) | EHCI_PRT_POWER; EHCI_WRITE_REGISTER_ULONG(EHCI_PORTSC, Value); + + // + // delay is 20 ms + // + Timeout.QuadPart = 20; + DPRINT1("Waiting %d milliseconds for port power up\n", Timeout.LowPart); + + // + // convert to 100 ns units (absolute) + // + Timeout.QuadPart *= -10000; + + // + // perform the wait + // + KeDelayExecutionThread(KernelMode, FALSE, &Timeout); } } return STATUS_SUCCESS;
12 years, 10 months
1
0
0
0
[janderwald] 55364: [HIDPARSE] - Use report value when report item bitcount > 1 [KBDHID] - Print raw report - KBDHID starts to receive normal keys and modifier keys
by janderwald@svn.reactos.org
Author: janderwald Date: Wed Feb 1 10:36:19 2012 New Revision: 55364 URL:
http://svn.reactos.org/svn/reactos?rev=55364&view=rev
Log: [HIDPARSE] - Use report value when report item bitcount > 1 [KBDHID] - Print raw report - KBDHID starts to receive normal keys and modifier keys Modified: branches/usb-bringup-trunk/drivers/hid/kbdhid/kbdhid.c branches/usb-bringup-trunk/lib/drivers/hidparser/api.c branches/usb-bringup-trunk/lib/drivers/hidparser/hidparser.c Modified: branches/usb-bringup-trunk/drivers/hid/kbdhid/kbdhid.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/hid/k…
============================================================================== --- branches/usb-bringup-trunk/drivers/hid/kbdhid/kbdhid.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/hid/kbdhid/kbdhid.c [iso-8859-1] Wed Feb 1 10:36:19 2012 @@ -93,6 +93,15 @@ KeSetEvent(&DeviceExtension->ReadCompletionEvent, 0, 0); return STATUS_MORE_PROCESSING_REQUIRED; } + + // + // print out raw report + // + ASSERT(DeviceExtension->ReportLength >= 9); + DPRINT1("[KBDHID] ReadCompletion %02x %02x %02x %02x %02x %02x %02x %02x %02x\n", DeviceExtension->Report[0], DeviceExtension->Report[1], DeviceExtension->Report[2], + DeviceExtension->Report[3], DeviceExtension->Report[4], DeviceExtension->Report[5], + DeviceExtension->Report[6], DeviceExtension->Report[7], DeviceExtension->Report[8]); + /* get current usages */ ButtonLength = DeviceExtension->UsageListLength; Modified: branches/usb-bringup-trunk/lib/drivers/hidparser/api.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/lib/drivers/h…
============================================================================== --- branches/usb-bringup-trunk/lib/drivers/hidparser/api.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/lib/drivers/hidparser/api.c [iso-8859-1] Wed Feb 1 10:36:19 2012 @@ -455,7 +455,20 @@ // // store usage and page // - UsageAndPage[ItemCount].Usage = (ReportItem->UsageMinimum & 0xFFFF); + if (ReportItem->BitCount == 1) + { + // + // use usage minimum + // + UsageAndPage[ItemCount].Usage =(ReportItem->UsageMinimum & 0xFFFF); + } + else + { + // + // use value from control + // + UsageAndPage[ItemCount].Usage = (USHORT)Data; + } UsageAndPage[ItemCount].UsagePage = CurrentUsagePage; } ItemCount++; @@ -691,13 +704,14 @@ // // invalid lookup or no scan code available // + DPRINT1("No Scan code for Usage %x\n", Usage); return HIDPARSER_STATUS_I8042_TRANS_UNKNOWN; } // // FIXME: translate modifier states // - + DPRINT1("Usage %x ScanCode %x\n", Usage, ScanCode); HidParser_DispatchKey((PCHAR)&ScanCode, KeyAction, InsertCodesProcedure, InsertCodesContext); // Modified: branches/usb-bringup-trunk/lib/drivers/hidparser/hidparser.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/lib/drivers/h…
============================================================================== --- branches/usb-bringup-trunk/lib/drivers/hidparser/hidparser.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/lib/drivers/hidparser/hidparser.c [iso-8859-1] Wed Feb 1 10:36:19 2012 @@ -683,9 +683,8 @@ else { // - // invalid page + // invalid page / end of usage list page // - DPRINT1("[HIDPARSE] Error unexpected usage page %x\n", ChangedUsageList[Index].UsagePage); return HIDP_STATUS_I8042_TRANS_UNKNOWN; }
12 years, 10 months
1
0
0
0
[zguo] 55363: Merge r55012 adding Wine3D control panel as per Amine's request.
by zguo@svn.reactos.org
Author: zguo Date: Wed Feb 1 04:58:00 2012 New Revision: 55363 URL:
http://svn.reactos.org/svn/reactos?rev=55363&view=rev
Log: Merge r55012 adding Wine3D control panel as per Amine's request. Added: branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/ (props changed) - copied from r55012, trunk/reactos/dll/cpl/wined3dcfg/ Modified: branches/ros-branch-0_3_14/ (props changed) branches/ros-branch-0_3_14/dll/cpl/ (props changed) branches/ros-branch-0_3_14/dll/cpl/CMakeLists.txt branches/ros-branch-0_3_14/dll/cpl/cpl.rbuild branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/lang/ (props changed) branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/resources/ (props changed) Propchange: branches/ros-branch-0_3_14/ ------------------------------------------------------------------------------ --- svn:mergeinfo (original) +++ svn:mergeinfo Wed Feb 1 04:58:00 2012 @@ -11,3 +11,4 @@ /branches/shell32_new-bringup:51893-53652,53661,53700 /branches/tcp-rewrite-branch:48720,48840-48841,49424-49426,49454 /branches/wlan-bringup:54809-54998 +/trunk/reactos:55012 Propchange: branches/ros-branch-0_3_14/dll/cpl/ ------------------------------------------------------------------------------ --- svn:ignore (original) +++ svn:ignore Wed Feb 1 04:58:00 2012 @@ -1,7 +1,8 @@ -GNUmakefile -*.vcproj -*.user *.cbp *.ncb +*.sln *.suo -*.sln +*.user +*.vcproj +GNUmakefile +wined3dcfg Modified: branches/ros-branch-0_3_14/dll/cpl/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_14/dll/cpl/CMake…
============================================================================== --- branches/ros-branch-0_3_14/dll/cpl/CMakeLists.txt [iso-8859-1] (original) +++ branches/ros-branch-0_3_14/dll/cpl/CMakeLists.txt [iso-8859-1] Wed Feb 1 04:58:00 2012 @@ -18,3 +18,4 @@ add_subdirectory(telephon) add_subdirectory(timedate) add_subdirectory(usrmgr) +add_subdirectory(wined3dcfg) Modified: branches/ros-branch-0_3_14/dll/cpl/cpl.rbuild URL:
http://svn.reactos.org/svn/reactos/branches/ros-branch-0_3_14/dll/cpl/cpl.r…
============================================================================== --- branches/ros-branch-0_3_14/dll/cpl/cpl.rbuild [iso-8859-1] (original) +++ branches/ros-branch-0_3_14/dll/cpl/cpl.rbuild [iso-8859-1] Wed Feb 1 04:58:00 2012 @@ -55,4 +55,7 @@ <directory name="usrmgr"> <xi:include href="usrmgr/usrmgr.rbuild" /> </directory> +<directory name="wined3dcfg"> + <xi:include href="wined3dcfg/wined3dcfg.rbuild" /> +</directory> </group> Propchange: branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/ ------------------------------------------------------------------------------ --- bugtraq:logregex (added) +++ bugtraq:logregex Wed Feb 1 04:58:00 2012 @@ -1,0 +1,2 @@ +([Ii]ssue|[Bb]ug)s? #?(\d+)(,? ?#?(\d+))*(,? ?(and |or )?#?(\d+))? +(\d+) Propchange: branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/ ------------------------------------------------------------------------------ bugtraq:message = See issue #%BUGID% for more details. Propchange: branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/ ------------------------------------------------------------------------------ bugtraq:url =
http://www.reactos.org/bugzilla/show_bug.cgi?id=%BUGID%
Propchange: branches/ros-branch-0_3_14/dll/cpl/wined3dcfg/ ------------------------------------------------------------------------------ tsvn:logminsize = 10
12 years, 10 months
1
0
0
0
[jimtabor] 55362: [User32] - Attempt to fix the font leak when switching applications. Tested with other applications other than Acrobat Reader since it crashes when installing. See bug 5314.
by jimtabor@svn.reactos.org
Author: jimtabor Date: Wed Feb 1 03:09:57 2012 New Revision: 55362 URL:
http://svn.reactos.org/svn/reactos?rev=55362&view=rev
Log: [User32] - Attempt to fix the font leak when switching applications. Tested with other applications other than Acrobat Reader since it crashes when installing. See bug 5314. Modified: trunk/reactos/dll/win32/user32/controls/appswitch.c Modified: trunk/reactos/dll/win32/user32/controls/appswitch.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/appswitch.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/appswitch.c [iso-8859-1] Wed Feb 1 03:09:57 2012 @@ -192,6 +192,7 @@ int i; HBRUSH hBrush; HPEN hPen; + HFONT dcFont; COLORREF cr; int nch = GetWindowTextW(windowList[selectedWindow], windowText, 1023); @@ -230,7 +231,7 @@ DrawIcon(dialogDC, xpos, ypos, hIcon); } - SelectObject(dialogDC, dialogFont); + dcFont = SelectObject(dialogDC, dialogFont); SetTextColor(dialogDC, GetSysColor(COLOR_BTNTEXT)); SetBkColor(dialogDC, GetSysColor(COLOR_BTNFACE)); @@ -239,6 +240,7 @@ textRC.right = totalW - 8; textRC.bottom = totalH - 8; DrawTextW(dialogDC, windowText, nch, &textRC, DT_CENTER|DT_END_ELLIPSIS); + SelectObject(dialogDC, dcFont); } EndPaint(hWnd, &paint); }
12 years, 10 months
1
0
0
0
[janderwald] 55361: [HIDUSB] - Add support function to detect when the boot protocol is still active
by janderwald@svn.reactos.org
Author: janderwald Date: Wed Feb 1 03:02:25 2012 New Revision: 55361 URL:
http://svn.reactos.org/svn/reactos?rev=55361&view=rev
Log: [HIDUSB] - Add support function to detect when the boot protocol is still active Modified: branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.c branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.h Modified: branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/hid/h…
============================================================================== --- branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.c [iso-8859-1] Wed Feb 1 03:02:25 2012 @@ -1269,7 +1269,7 @@ URB_FUNCTION_CLASS_INTERFACE, sizeof(struct _URB_CONTROL_VENDOR_OR_CLASS_REQUEST), 0, - HID_REPORT_DESCRIPTOR_TYPE, + 0, USB_SET_IDLE_REQUEST, // HID_SET_IDLE 0, 0, @@ -1296,6 +1296,76 @@ } +NTSTATUS +Hid_GetProtocol( + IN PDEVICE_OBJECT DeviceObject) +{ + PHID_USB_DEVICE_EXTENSION HidDeviceExtension; + PHID_DEVICE_EXTENSION DeviceExtension; + PURB Urb; + NTSTATUS Status; + UCHAR Protocol[1]; + + // + // get device extension + // + DeviceExtension = (PHID_DEVICE_EXTENSION)DeviceObject->DeviceExtension; + HidDeviceExtension = (PHID_USB_DEVICE_EXTENSION)DeviceExtension->MiniDeviceExtension; + + // + // allocate urb + // + Urb = ExAllocatePool(NonPagedPool, sizeof(struct _URB_CONTROL_VENDOR_OR_CLASS_REQUEST)); + if (!Urb) + { + // + // no memory + // + return STATUS_INSUFFICIENT_RESOURCES; + } + + // + // zero urb + // + RtlZeroMemory(Urb, sizeof(struct _URB_CONTROL_VENDOR_OR_CLASS_REQUEST)); + + // + // format urb + // + UsbBuildVendorRequest(Urb, + URB_FUNCTION_CLASS_INTERFACE, + sizeof(struct _URB_CONTROL_VENDOR_OR_CLASS_REQUEST), + USBD_TRANSFER_DIRECTION_IN, + 0, + USB_GET_PROTOCOL_REQUEST, + 0, + 0, + Protocol, + NULL, + 1, + NULL); + Protocol[0] = 0xFF; + // + // dispatch urb + // + Status = Hid_DispatchUrb(DeviceObject, Urb); + + // + // free urb + // + ExFreePool(Urb); + + // + // print status + // + DPRINT1("Status %x Protocol %x\n", Status, Protocol[0] & 0xFF); + + // + // assert when boot protocol is still active + // + ASSERT(Protocol[0] == 0x1); + return Status; +} NTSTATUS Hid_PnpStart( @@ -1404,6 +1474,7 @@ // Hid_SetIdle(DeviceObject); + Hid_GetProtocol(DeviceObject); // // move to next descriptor Modified: branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.h URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/hid/h…
============================================================================== --- branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.h [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/hid/hidusb/hidusb.h [iso-8859-1] Wed Feb 1 03:02:25 2012 @@ -84,3 +84,5 @@ IN PURB Urb); #define USB_SET_IDLE_REQUEST 0xA +#define USB_GET_PROTOCOL_REQUEST 0x3 +
12 years, 10 months
1
0
0
0
[janderwald] 55360: [USBOHCI] - Fix bugs in HandleClassEndpoint, HandleClassInterface which always set direction device to host instead of relying to the transfer flags provided - Allow setup packe...
by janderwald@svn.reactos.org
Author: janderwald Date: Wed Feb 1 02:36:53 2012 New Revision: 55360 URL:
http://svn.reactos.org/svn/reactos?rev=55360&view=rev
Log: [USBOHCI] - Fix bugs in HandleClassEndpoint, HandleClassInterface which always set direction device to host instead of relying to the transfer flags provided - Allow setup packets w/o a data stage Modified: branches/usb-bringup-trunk/drivers/usb/usbohci/hub_controller.cpp branches/usb-bringup-trunk/drivers/usb/usbohci/usb_device.cpp Modified: branches/usb-bringup-trunk/drivers/usb/usbohci/hub_controller.cpp URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbohci/hub_controller.cpp [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbohci/hub_controller.cpp [iso-8859-1] Wed Feb 1 02:36:53 2012 @@ -1660,11 +1660,20 @@ // // initialize setup packet // - CtrlSetup.bmRequestType.B = 0xa2; //FIXME: Const. + CtrlSetup.bmRequestType.B = 0x22; //FIXME: Const. CtrlSetup.bRequest = Urb->UrbControlVendorClassRequest.Request; CtrlSetup.wValue.W = Urb->UrbControlVendorClassRequest.Value; CtrlSetup.wIndex.W = Urb->UrbControlVendorClassRequest.Index; CtrlSetup.wLength = Urb->UrbControlVendorClassRequest.TransferBufferLength; + + if (Urb->UrbControlVendorClassRequest.TransferFlags & USBD_TRANSFER_DIRECTION_IN) + { + // + // data direction is device to host + // + CtrlSetup.bmRequestType.B |= 0x80; + } + // // issue request @@ -1729,23 +1738,22 @@ DPRINT1("Value %x\n", Urb->UrbControlVendorClassRequest.Value); DPRINT1("Index %x\n", Urb->UrbControlVendorClassRequest.Index); - if (Urb->UrbControlVendorClassRequest.TransferBufferLength == 0) - { - // - // FIXME: support requests w/o data stage - //; - ASSERT(FALSE); - return STATUS_SUCCESS; - } - // // initialize setup packet // - CtrlSetup.bmRequestType.B = 0xa1; + CtrlSetup.bmRequestType.B = 0x21; CtrlSetup.bRequest = Urb->UrbControlVendorClassRequest.Request; CtrlSetup.wValue.W = Urb->UrbControlVendorClassRequest.Value; CtrlSetup.wIndex.W = Urb->UrbControlVendorClassRequest.Index; CtrlSetup.wLength = Urb->UrbControlVendorClassRequest.TransferBufferLength; + + if (Urb->UrbControlVendorClassRequest.TransferFlags & USBD_TRANSFER_DIRECTION_IN) + { + // + // data direction is device to host + // + CtrlSetup.bmRequestType.B |= 0x80; + } // // issue request Modified: branches/usb-bringup-trunk/drivers/usb/usbohci/usb_device.cpp URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbohci/usb_device.cpp [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbohci/usb_device.cpp [iso-8859-1] Wed Feb 1 02:36:53 2012 @@ -858,27 +858,35 @@ OUT PVOID Buffer) { NTSTATUS Status; - PMDL Mdl; - - // - // allocate mdl - // - Mdl = IoAllocateMdl(Buffer, BufferLength, FALSE, FALSE, 0); - - // - // HACK HACK HACK: assume the buffer is build from non paged pool - // - MmBuildMdlForNonPagedPool(Mdl); + PMDL Mdl = NULL; + + if (BufferLength) + { + // + // allocate mdl + // + Mdl = IoAllocateMdl(Buffer, BufferLength, FALSE, FALSE, 0); + if (!Mdl) + return STATUS_INSUFFICIENT_RESOURCES; + + // + // HACK HACK HACK: assume the buffer is build from non paged pool + // + MmBuildMdlForNonPagedPool(Mdl); + } // // commit setup packet // Status = CommitSetupPacket(SetupPacket, 0, BufferLength, Mdl); - // - // free mdl - // - IoFreeMdl(Mdl); + if (Mdl != NULL) + { + // + // free mdl + // + IoFreeMdl(Mdl); + } // // done
12 years, 10 months
1
0
0
0
[janderwald] 55359: [USBCCGP] - Fix multiple bugs while selecting configuration - Silence traces
by janderwald@svn.reactos.org
Author: janderwald Date: Wed Feb 1 01:44:21 2012 New Revision: 55359 URL:
http://svn.reactos.org/svn/reactos?rev=55359&view=rev
Log: [USBCCGP] - Fix multiple bugs while selecting configuration - Silence traces Modified: branches/usb-bringup-trunk/drivers/usb/usbccgp/descriptor.c branches/usb-bringup-trunk/drivers/usb/usbccgp/pdo.c branches/usb-bringup-trunk/drivers/usb/usbccgp/usbccgp.h Modified: branches/usb-bringup-trunk/drivers/usb/usbccgp/descriptor.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbccgp/descriptor.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbccgp/descriptor.c [iso-8859-1] Wed Feb 1 01:44:21 2012 @@ -356,7 +356,7 @@ // // allocate urb // - Urb = AllocateItem(NonPagedPool, sizeof(struct _URB_SELECT_INTERFACE)); + Urb = AllocateItem(NonPagedPool, GET_SELECT_INTERFACE_REQUEST_SIZE(DeviceExtension->InterfaceList[InterfaceIndex].InterfaceDescriptor->bNumEndpoints)); if (!Urb) { // @@ -369,11 +369,6 @@ // now prepare interface urb // UsbBuildSelectInterfaceRequest(Urb, GET_SELECT_INTERFACE_REQUEST_SIZE(DeviceExtension->InterfaceList[InterfaceIndex].InterfaceDescriptor->bNumEndpoints), DeviceExtension->ConfigurationHandle, DeviceExtension->InterfaceList[InterfaceIndex].InterfaceDescriptor->bInterfaceNumber, DeviceExtension->InterfaceList[InterfaceIndex].InterfaceDescriptor->bAlternateSetting); - - // - // copy interface information structure back - as offset for SelectConfiguration / SelectInterface request do differ - // - RtlCopyMemory(&Urb->UrbSelectInterface.Interface, DeviceExtension->InterfaceList[InterfaceIndex].Interface, DeviceExtension->InterfaceList[InterfaceIndex].Interface->Length); // // now select the interface Modified: branches/usb-bringup-trunk/drivers/usb/usbccgp/pdo.c URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbccgp/pdo.c [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbccgp/pdo.c [iso-8859-1] Wed Feb 1 01:44:21 2012 @@ -611,11 +611,12 @@ { PIO_STACK_LOCATION IoStack; PPDO_DEVICE_EXTENSION PDODeviceExtension; - PURB Urb; + PURB Urb, NewUrb; PUSBD_INTERFACE_INFORMATION InterfaceInformation; ULONG InterfaceInformationCount, Index, InterfaceIndex; PUSBD_INTERFACE_LIST_ENTRY Entry; ULONG NeedSelect, FoundInterface; + NTSTATUS Status; // // get current stack location @@ -720,7 +721,8 @@ NeedSelect = FALSE; if (Entry->InterfaceDescriptor->bAlternateSetting == InterfaceInformation->AlternateSetting) { - for(InterfaceIndex = 0; InterfaceIndex < Entry->InterfaceDescriptor->bNumEndpoints; InterfaceIndex++) + + for(InterfaceIndex = 0; InterfaceIndex < InterfaceInformation->NumberOfPipes; InterfaceIndex++) { if (InterfaceInformation->Pipes[InterfaceIndex].MaximumTransferSize != Entry->Interface->Pipes[InterfaceIndex].MaximumTransferSize) { @@ -744,16 +746,61 @@ // // interface is already selected // + RtlCopyMemory(InterfaceInformation, Entry->Interface, min(InterfaceInformation->Length, Entry->Interface->Length)); + } + else + { + // + // select interface + // + DPRINT1("Selecting InterfaceIndex %lu AlternateSetting %lu NumberOfPipes %lu\n", InterfaceInformation->InterfaceNumber, InterfaceInformation->AlternateSetting, InterfaceInformation->NumberOfPipes); ASSERT(InterfaceInformation->Length == Entry->Interface->Length); - RtlCopyMemory(InterfaceInformation, Entry->Interface, Entry->Interface->Length); - } - else - { - // - // FIXME select interface - // - UNIMPLEMENTED - ASSERT(FALSE); + + // + // build urb + // + NewUrb = AllocateItem(NonPagedPool, GET_SELECT_INTERFACE_REQUEST_SIZE(InterfaceInformation->NumberOfPipes)); + if (!NewUrb) + { + // + // no memory + // + return STATUS_INSUFFICIENT_RESOURCES; + } + + // + // now prepare interface urb + // + UsbBuildSelectInterfaceRequest(NewUrb, GET_SELECT_INTERFACE_REQUEST_SIZE(InterfaceInformation->NumberOfPipes), PDODeviceExtension->ConfigurationHandle, InterfaceInformation->InterfaceNumber, InterfaceInformation->AlternateSetting); + + // + // now select the interface + // + Status = USBCCGP_SyncUrbRequest(PDODeviceExtension->NextDeviceObject, NewUrb); + DPRINT1("SelectInterface Status %x\n", Status); + + // + // did it succeeed + // + if (NT_SUCCESS(Status)) + { + // + // update configuration info + // + ASSERT(Entry->Interface->Length == NewUrb->UrbSelectInterface.Interface.Length); + ASSERT(InterfaceInformation->Length == NewUrb->UrbSelectInterface.Interface.Length); + RtlCopyMemory(Entry->Interface, &NewUrb->UrbSelectInterface.Interface, NewUrb->UrbSelectInterface.Interface.Length); + + // + // update provided interface information + // + RtlCopyMemory(InterfaceInformation, Entry->Interface, Entry->Interface->Length); + } + + // + // free urb + // + FreeItem(NewUrb); } // Modified: branches/usb-bringup-trunk/drivers/usb/usbccgp/usbccgp.h URL:
http://svn.reactos.org/svn/reactos/branches/usb-bringup-trunk/drivers/usb/u…
============================================================================== --- branches/usb-bringup-trunk/drivers/usb/usbccgp/usbccgp.h [iso-8859-1] (original) +++ branches/usb-bringup-trunk/drivers/usb/usbccgp/usbccgp.h [iso-8859-1] Wed Feb 1 01:44:21 2012 @@ -2,7 +2,7 @@ #define USBEHCI_H__ #include <ntddk.h> -#define YDEBUG +#define NDEBUG #include <debug.h> #include <initguid.h> #include <hubbusif.h>
12 years, 10 months
1
0
0
0
← Newer
1
...
55
56
57
58
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
Results per page:
10
25
50
100
200