1a008c1ca04871386830f511ee4b47299b92b01f |
|
31-Jul-2015 |
Nick Kralevich <nnk@google.com> |
UsbDeviceManager: fix b/21429947 regression (try #2) As discussed in b/21429947 (commit 674019065bceb4150190bfb1aa63cda9de0a8560), MTP must always be enabled, even if access to the underlying MTP data is disabled. Otherwise, Android will not enumerate on the USB bus, and won't receive notifications from the kernel about USB state changes. This effectively prevents using MTP functionality on user builds, or on userdebug/eng builds with adb turned off. Always ensure that MTP is the default driver mode. Move the DISALLOW_USB_FILE_TRANSFER filtering of mUsbDataUnlocked from setting time to the time we post the sticky broadcast. Remove isUsbDataUnlocked(). It essentially duplicates data in the sticky broadcast. Bug: 22447614 Bug: 21429947 Change-Id: I9d0d94cadbf6db6281ebd77bfb7162f9d06520c2
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
76c4c6668a1486bc003ab0c585bb1f41d16e27a7 |
|
07-Jul-2015 |
Jeff Brown <jeffbrown@google.com> |
Add USB port manager. Add some new internal APIs to enumerate USB Type C ports, query their status, determine whether they support changing power or data roles, and doing so. The API also adds a new ACTION_USB_PORT_CHANGED broadcast for port state changes. The implementation includes a mechanism for simulating the behavior of the USB stack. See 'adb shell dumpsys usb -h' for details. Note that the underlying kernel driver interface is still subject to change but its behavior has been encapsulated as much as possible. Bug: 21615151 Change-Id: I0c853ae179248a4550b3e60d02a7a7e65e4546b2
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
460a146eb8f827e4e70f2dd93d1ba852d0feb06b |
|
01-Jul-2015 |
Jeff Brown <jeffbrown@google.com> |
Clean up USB Manager and fix ADB. Moved functions which parse the USB functions list into one common place on UsbManager. Deleted the no longer supported USB_FUNCTION_MASS_STORAGE. Ensured that the UserManager.DISALLOW_USB_FILE_TRANSFER rule is consistently applied during user switch and when changing the current USB functions and make sure it only affects MTP and PTP. Collapsed the boot completed and user switched receivers to ensure consistent ordering of side-effects. Validate the list of functions passed to setCurrentFunction() so that the separation of concerns is clearer. It was somewhat ambiguous as to whether functions such as ADB could / should be enabled through that interface. Improved the docs for clarity. Fixed a bunch of broken stuff related to the USB config persistent property (list of default functions) that could cause ADB and other functions to not work at all. Added new failsafes to ensure that we reliably get back into a happy state. Bug: 22206076 Change-Id: I02915ddfce7193a8f67a14f0d76bab22fc575dfa
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
674019065bceb4150190bfb1aa63cda9de0a8560 |
|
10-Jun-2015 |
Nick Kralevich <nnk@google.com> |
Fix USB access control when adb is disabled. When adb is disabled, the default usb mode would be "none", which would turn off the driver and prevent UsbDeviceManager from receiving any new USB connect / disconnect messages. This prevents the user from ever enabling MTP and sharing data when adb is turned off. As discussed in bug 21429947, we work around this problem by keeping the USB driver in MTP mode most of the time, so that we continue to receive USB connect / disconnect messages. To avoid leaking confidential user photos, this change introduces an unlocked state. Setting the mtp enabled function is now decoupled from exposing data on the USB connection. Only if MTP is enabled and USB data has been unlocked is confidential user data allowed to be shared. Bug: 21429947 Change-Id: Iefb5c7e22dc4962bf5226f2ed3d0155b5c7b413c
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
fcf10f7c12cb3107bdfedce6f76a8c866d154f3c |
|
13-May-2015 |
Nick Kralevich <nnk@google.com> |
Modify how USB connections are handled. * Introduce a new "charger only" mode. In this mode, MTP is disabled, and no file transfers can occur. * Make charger only mode the default. * Modify "persist.sys.usb.config" so it now only holds the adb status. * Make the USB settings non-persistent. Unplugging the USB connection will reset the device back to "charger only" mode. * Fixup wording per UI guidelines. TODO: Re-implement MDM restrictions for USB / MTP access controls. Bug: 18905620 Change-Id: I99a50d9132a81e98187f431166fd9fef4d437e4f
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
d9c7f2456957a5610cbbca1b2e31aa7b3574c50d |
|
10-May-2015 |
Nick Kralevich <nnk@google.com> |
UsbManager / UsbService / UsbDeviceManager: delete unused code These functions are never called. Change-Id: Ic436e1036bed717d2c64701fddd9a810abb9443e
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
cd7a17c645761ac0b64c75346b159dd30cbcb01c |
|
22-Dec-2012 |
Benoit Goby <benoit@android.com> |
UsbDebuggingManager: Add interface to clear secure adb keys This is called from Settings that has a button to clear secure adb public keys installed on the device. Change-Id: I63ef499c049766ef13ea6cb0594ed6719f35e5f3
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
fc3f24b4b60c10e0d3f41f70df37e11ea311cc2c |
|
02-Oct-2012 |
Jeff Sharkey <jsharkey@android.com> |
Make USB services multi-user aware. USB settings are now isolated per-user, since they revolve around installed packages. User-specific settings are returned based on calling user, or referenced by UserHandle passed to SystemUI. Each settings Context is wrapped as a specific user, so all broadcasts are sent correctly. Upgrades any existing USB settings to OWNER. Physical events, like new devices, are routed to the currently active user. Switch to using AtomicFile when persisting settings. Bug: 7244888 Change-Id: I8a723ad3d55ac1bff99276c5f3a3f5e8f013432f
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
4e68bd420b6cfdbeadb5e69aa6448665b2da762b |
|
26-Apr-2012 |
Benoit Goby <benoit@android.com> |
Add UsbDebuggingManager and UsbDebuggingActivity The UsbDebuggingManager listens to adbd requests and displays a dialog when the public key authentification fails, for the user to confirm if it wants to allow USB debugging from the attached host. If the user chooses to always allow USB debugging, the UsbDebuggingManager writes the public key to adbd's config file so that the public key authenfication succeeds next time. Change-Id: I115c828331d8e326c380844ee33915d5dff22260
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
f59717ddb5ef324ee3fdb12b83e7d1b709793d28 |
|
22-Jun-2011 |
Mike Lockwood <lockwood@android.com> |
Combine UsbManager.setPrimaryFunction and setDefaultFunction Due to the property trigger on persist.sys.usb.config, setting the default function also sets the current function. Now we combine both of these methods into setCurrentFunction, which has a "makeDefault" option to make the new function the default. This change should eliminate some problems with setting properties due to multiple property triggers happening at the same time. Change-Id: I9851299e9c2ee20475eada1a8104c0d50bf5a9e1 Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
02e4569b5f126ca916a7473117ddd17d4f2ccbbb |
|
14-Jun-2011 |
Mike Lockwood <lockwood@android.com> |
USB: Support for new USB gadget drivers Change-Id: Id08df50acb873a94f4765a991ee6a6f5b898ddf5 Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
62cfeeb821afb2f3d3b78ad93caa13408cd26eac |
|
12-Mar-2011 |
Mike Lockwood <lockwood@android.com> |
USB: minor cleanup work Bug: 4067029 Change-Id: Icd8f912ab8732b5f770a217b9b3731092597ce02 Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
c6f23e8521dedac7a07119031913235be3ca37c3 |
|
09-Mar-2011 |
Mike Lockwood <lockwood@android.com> |
Change UsbManager.requestPermission to only grant permission temporarily If the user approves an application to access a USB device or accessory without choosing it as the default application, then permission is granted only until the device or accessory is disconnected. Only applications chosen as the default choice have permissions assigned persistently. BUG: 4061035 Change-Id: Ic4f6271a91b2fc56bbeef82c579e26d88c63ae56 Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
3a68b8338b431eb15d28e92f06452efbbda9493e |
|
08-Mar-2011 |
Mike Lockwood <lockwood@android.com> |
USB: Add API and dialog for apps to request permissions for USB devices and accessories New APIs: UsbManager.hasPermission returns true if the caller has permission for the given device or accessory UsbManager.requestPermission poses a dialog to allow the user to give the caller permission for the device or accessory. Result is returned via a PendingIntent. No dialog is displayed if the caller already has permission. Also moved UsbResolverActivity to SystemUI package BUG: 4069037 Change-Id: I93be769501a8776b49ac26e468af19f8fa2114c9
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|
c4308f01c965571dc2354107c3574df113e397ee |
|
01-Mar-2011 |
Mike Lockwood <lockwood@android.com> |
Move USB framework support from android.hardware to android.hardware.usb package Change-Id: I00fd4f0caaa4aebe48f71c576bb211b5f38bf88d Signed-off-by: Mike Lockwood <lockwood@android.com>
/frameworks/base/core/java/android/hardware/usb/IUsbManager.aidl
|