sbWindowsUSBDeviceUtils.h File Reference

Songbird Windows USB Device Utilities Definitions. More...

#include "sbUSBDeviceUtils.h"
#include <sbMemoryUtils.h>
#include <windows.h>
#include <cfgmgr32.h>
Include dependency graph for sbWindowsUSBDeviceUtils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  sbWinUSBDeviceRef
 

Functions

nsresult sbWinUSBDeviceOpenRef (DEVINST aDevInst, sbWinUSBDeviceRef *aDeviceInfo)
 
nsresult sbWinUSBDeviceCloseRef (sbWinUSBDeviceRef *aDeviceInfo)
 
nsresult sbWinUSBDeviceGetHubAndPort (DEVINST aDevInst, HANDLE *aHubFile, ULONG *aPortIndex)
 
nsresult sbWinUSBHubFindDevicePort (HANDLE aHubFile, DEVINST aDevInst, ULONG *aPortIndex)
 
nsresult sbWinUSBHubGetPortDriverKey (HANDLE aHubFile, ULONG aPortIndex, nsAString &aDriverKey)
 
nsresult sbWinUSBMSCGetLUN (DEVINST aDevInst, PRUint32 *aLUN)
 
 SB_AUTO_NULL_CLASS (sbAutoWinUSBDeviceRef, sbWinUSBDeviceRef *, sbWinUSBDeviceCloseRef(mValue))
 

Detailed Description

Songbird Windows USB Device Utilities Definitions.

Definition in file sbWindowsUSBDeviceUtils.h.

Function Documentation

SB_AUTO_NULL_CLASS ( sbAutoWinUSBDeviceRef  ,
sbWinUSBDeviceRef ,
sbWinUSBDeviceCloseRef(mValue)   
)
nsresult sbWinUSBDeviceCloseRef ( sbWinUSBDeviceRef aDeviceRef)

Close the USB device reference specified by aDeviceRef.

Parameters
aDeviceRefUSB device reference to close.

Definition at line 228 of file sbWindowsUSBDeviceUtils.cpp.

Here is the caller graph for this function:

nsresult sbWinUSBDeviceGetHubAndPort ( DEVINST  aDevInst,
HANDLE *  aHubFile,
ULONG *  aPortIndex 
)

Return in aHubFile and aPortIndex the USB device hub file and port index for the USB device specified by aDevInst.

Parameters
aDevInstDevice instance for which to get hub and port.
aHubFileReturned USB hub file for device.
aPortIndexReturned USB hub port index for device.

Definition at line 253 of file sbWindowsUSBDeviceUtils.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

nsresult sbWinUSBDeviceOpenRef ( DEVINST  aDevInst,
sbWinUSBDeviceRef aDeviceRef 
)

Open a USB device reference to the device specified by aDevInst and return the reference in aDeviceRef.

Parameters
aDevInstUSB device instance to open.
aDeviceRefReturned device reference.

Definition at line 197 of file sbWindowsUSBDeviceUtils.cpp.

Here is the call graph for this function:

nsresult sbWinUSBHubFindDevicePort ( HANDLE  aHubFile,
DEVINST  aDevInst,
ULONG *  aPortIndex 
)

Return in aPortIndex the USB hub index of the USB hub specified by aHubFile for the USB device specified by aDevInst.

Parameters
aHubFileUSB hub for which to find port.
aDevInstUSB device instance for which to find port.
aPortIndexReturned USB hub port index for device.

Definition at line 303 of file sbWindowsUSBDeviceUtils.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

nsresult sbWinUSBHubGetPortDriverKey ( HANDLE  aHubFile,
ULONG  aPortIndex,
nsAString &  aDriverKey 
)

Return in aDriverKey the driver key for the device attached to the port specified by aPortIndex of the USB hub specified by aHubFile. If no device is attached to the port, aDriverKey is set to void.

Parameters
aHubFileUSB hub for which to get port driver key.
aPortIndexIndex of USB hub port for which to get driver key.
aDriverKeyReturned USB hub port driver key.

Definition at line 376 of file sbWindowsUSBDeviceUtils.cpp.

Here is the caller graph for this function:

nsresult sbWinUSBMSCGetLUN ( DEVINST  aDevInst,
PRUint32 *  aLUN 
)

Return in aLUN the USB MSC LUN for the disk device specified by aDevInst.

Parameters
aDevInstDisk for which to get LUN.
aLUNReturned LUN.

Definition at line 446 of file sbWindowsUSBDeviceUtils.cpp.

Here is the call graph for this function: