- Timestamp:
- Jun 24, 2011 8:57:35 AM (14 years ago)
- Location:
- trunk/src/VBox/Main
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Main/include/USBGetDevices.h
r37618 r37624 75 75 RT_C_DECLS_BEGIN 76 76 77 /**78 * Check whether a USB device tree root is usable79 * @param pcszRoot the path to the root of the device tree80 * @param fIsDeviceNodes whether this is a device node (or usbfs) tree81 * @note returns a pointer into a static array so it will stay valid82 */83 77 extern bool USBProxyLinuxCheckDeviceRoot(const char *pcszRoot, 84 78 bool fIsDeviceNodes); … … 91 85 #endif 92 86 93 /**94 * Selects the access method that will be used to access USB devices based on95 * what is available on the host and what if anything the user has specified96 * in the environment.97 * @returns iprt status value98 * @param pfUsingUsbfsDevices on success this will be set to true if99 * the prefered access method is USBFS-like and to100 * false if it is sysfs/device node-like101 * @param ppcszDevicesRoot on success the root of the tree of USBFS-like102 * device nodes will be stored here103 */104 87 extern int USBProxyLinuxChooseMethod(bool *pfUsingUsbfsDevices, 105 88 const char **ppcszDevicesRoot); 106 89 #ifdef UNIT_TEST 107 /**108 * Specify the list of devices that will appear to be available through109 * usbfs during unit testing (of USBProxyLinuxGetDevices)110 * @param pacszDeviceAddresses NULL terminated array of usbfs device addresses111 */112 90 extern void TestUSBSetAvailableUsbfsDevices(const char **pacszDeviceAddresses); 113 /**114 * Specify the list of files that access will report as accessible (at present115 * we only do accessible or not accessible) during unit testing (of116 * USBProxyLinuxGetDevices)117 * @param pacszAccessibleFiles NULL terminated array of file paths to be118 * reported accessible119 */120 91 extern void TestUSBSetAccessibleFiles(const char **pacszAccessibleFiles); 121 92 #endif 122 93 123 /**124 * Get the list of USB devices supported by the system. Should be freed using125 * @a deviceFree or something equivalent.126 * @param pcszDevicesRoot the path to the root of the device tree127 * @param fUseSysfs whether to use sysfs (or usbfs) for enumeration128 */129 94 extern PUSBDEVICE USBProxyLinuxGetDevices(const char *pcszDevicesRoot, 130 95 bool fUseSysfs); -
trunk/src/VBox/Main/src-server/linux/USBGetDevices.cpp
r37618 r37624 1481 1481 # define getDevicesFromUsbfs testGetUsbfsDevices 1482 1482 1483 /** 1484 * Specify the list of devices that will appear to be available through 1485 * usbfs during unit testing (of USBProxyLinuxGetDevices) 1486 * @param pacszDeviceAddresses NULL terminated array of usbfs device addresses 1487 */ 1483 1488 void TestUSBSetAvailableUsbfsDevices(const char **pacszDeviceAddresses) 1484 1489 { … … 1500 1505 # define access testAccess 1501 1506 1507 /** 1508 * Specify the list of files that access will report as accessible (at present 1509 * we only do accessible or not accessible) during unit testing (of 1510 * USBProxyLinuxGetDevices) 1511 * @param pacszAccessibleFiles NULL terminated array of file paths to be 1512 * reported accessible 1513 */ 1502 1514 void TestUSBSetAccessibleFiles(const char **pacszAccessibleFiles) 1503 1515 { … … 1656 1668 #endif 1657 1669 1670 /** 1671 * Check whether a USB device tree root is usable 1672 * @param pcszRoot the path to the root of the device tree 1673 * @param fIsDeviceNodes whether this is a device node (or usbfs) tree 1674 * @note returns a pointer into a static array so it will stay valid 1675 */ 1658 1676 bool USBProxyLinuxCheckDeviceRoot(const char *pcszRoot, bool fIsDeviceNodes) 1659 1677 { … … 1689 1707 #endif 1690 1708 1709 /** 1710 * Get the list of USB devices supported by the system. Should be freed using 1711 * @a deviceFree or something equivalent. 1712 * @param pcszDevicesRoot the path to the root of the device tree 1713 * @param fUseSysfs whether to use sysfs (or usbfs) for enumeration 1714 */ 1691 1715 PUSBDEVICE USBProxyLinuxGetDevices(const char *pcszDevicesRoot, 1692 1716 bool fUseSysfs)
Note:
See TracChangeset
for help on using the changeset viewer.