| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
On some devices there is a slight delay between the creation of "/dev/bus"
and "/dev/bus/usb". Previously, the code assumed that both are created in the
same time which caused "watch_existing_subdirs" to fail and libusbhost to stop
working until the device is rebooted. The fix will setup an inotify event on the
creation of the "bus/usb" so it will not be missed once it's created.
Change-Id: I17f06dd167e61573307425e48898e12ebc954093
|
|
|
|
|
|
|
| |
Bug: 8469799
Change-Id: Ie10242dd05becd142cc84651d5e5795e4c02270d
Signed-off-by: Igor Murashkin <iam@google.com>
Signed-off-by: Adam Hampson <ahampson@google.com>
|
|
|
|
|
|
|
|
|
|
| |
due to limitations of the droidboot OS used for POS,
there's a need for a static libusbhost library.
this permits to include libusbhost in droidboot
Change-Id: I0f0c07817ad19b773b466b69fd6e997877d41b34
Signed-off-by: Guillaume Ranquet <guillaumex.ranquet@intel.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Modify libusbhost to expose the inotify watch descriptor to clients
This modification permits clients to add the watch descriptor to
their polling loop so that they don't have to use a dedicated
thread only for libusbhost.
Change-Id: I615bfcd56beab978135034b228d4d93337351eab
Signed-off-by: Guillaume Ranquet <guillaumex.ranquet@intel.com>
Signed-off-by: Luc Piguet-Lacroix <lucx.piguet-lacroix@intel.com>
|
|
|
|
|
|
|
|
| |
On some devices, /dev/bus/usb does not exist on boot, it is only created
when the otg port is in host mode. Use inotify to detect when /dev/bus/usb
is created and then start watching subdirectories.
Change-Id: Ic1472a5ea7a7118cdbb560cc7071ade9bcee753a
|
|
|
|
|
|
|
|
|
|
| |
When a new bus is added, check for existing devices in the bus
directory, since devices may have been added before calling
inotify_add_watch.
Also add missing inotify_rm_watch calls.
Change-Id: Ie69fc995a3e8b18431099b252be86f0054fe5531
|
|
|
|
|
| |
Bug: 5449033
Change-Id: I9244d927f14c750cd359ebffb1fc1c355a755d5a
|
|
|
|
|
|
|
|
|
| |
Otherwise the kernel will return an EINVAL error
Change-Id: I906472a4128eb26c5be7865142bc4a52464cf5f8
Bug: 4065217
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: I2cf189cee67c2efbcf919c8bae1447a6cb112f02
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
| |
Also clean up and add timeout to control request transfer
Change-Id: Ibc2d8ac64d0fa90e0a23e6225ce2c49b23bb0d97
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
|
|
|
| |
This can be used to ask the kernel to disconnect its driver for a device
so usb_device_claim_interface() can claim it instead.
Also increased size of descriptor buffer and added some debugging logs
Change-Id: I4945196d957fb8493716eb9b7e5463c06b168ef1
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
| |
Add new usb_request struct to replace usb_endpoint, which is no longer needed.
Change-Id: Ia3637b3431a3597caced41bfec677ef0b044a453
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
| |
This allows converting from unique IDs to USB device names
Change-Id: I8e3b300790c01383aed8e3d4f547b54bcb7c2cd4
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: I0c16cc4536c4ab700c33433c8a6323ade7cfc95d
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: Iefac9b31f900edb2dbd594f9eff9113b2038757d
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: Ic3a54e2a06f3b4fa72f99b64025a911fbf525daf
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
| |
We will use this for sharing USB file descriptors across address spaces via Binder
Change-Id: Iadbd3e0a4178f79d1d778fdfd5175f6fe0e2aaf5
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: Idce54fc26d0432d4dc46f605623c4960c0e8690f
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: If883f2690c4031b9ba4d5cf943b5bf5c13193bce
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: Ic91f99d1169fcdc00474dd6a870eb7e614128bc2
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
|
|
|
|
|
|
| |
discovery is done
This can be used to eliminate race conditions in clients that operate immediately
on the currently connected device list.
Signed-off-by: Mike Lockwood <lockwood@android.com>
Change-Id: I14954b9fcc84239950ead6bdc1a0a888882c2226
|
|
|
|
|
|
|
|
|
|
| |
monitors the bus
This is to allow using a thread that is capable of calling through JNI to Java code
to report USB device attached/removed events.
Change-Id: Ia58592607a2c1f4357b31072044f5db5617d7f5b
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
| |
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
| |
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: I977145f44131ec8b588dd274e0afbc563f3aa4c0
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
|
|
|
| |
Change-Id: Ibe4ce0551faca5d2d8bec0fbd21315a393b9f208
Signed-off-by: Mike Lockwood <lockwood@android.com>
|
|
Supports access to Linux usbdevfs on both device and Linux host.
Change-Id: Ie88a5193be3ee715792b10b34b3da32ffc4ca57b
Signed-off-by: Mike Lockwood <lockwood@android.com>
|