Permalink
Browse files

usb: Update android gadget for ICS compatibility

  • Loading branch information...
1 parent 600f988 commit 3b03eafb9a2a39438860eb0883a620771e3f27e4 @rmcc rmcc committed Feb 25, 2012
Showing with 8,094 additions and 5,187 deletions.
  1. +1 −1 arch/arm/configs/cyanogenmod_e0_defconfig
  2. +1 −1 arch/arm/mach-msm/include/mach/oem_rapi_client.h
  3. +1 −1 drivers/char/diag/Kconfig
  4. +17 −0 drivers/switch/switch_class.c
  5. +23 −418 drivers/usb/gadget/Kconfig
  6. +26 −50 drivers/usb/gadget/Makefile
  7. +885 −1,104 drivers/usb/gadget/android.c
  8. +120 −472 drivers/usb/gadget/composite.c
  9. +7 −7 drivers/usb/gadget/dbgp.c
  10. +23 −3 drivers/usb/gadget/dummy_hcd.c
  11. +7 −0 drivers/usb/gadget/epautoconf.c
  12. +792 −0 drivers/usb/gadget/f_accessory.c
  13. +285 −222 drivers/usb/gadget/f_acm.c
  14. +101 −184 drivers/usb/gadget/f_adb.c
  15. +3 −2 drivers/usb/gadget/f_audio.c
  16. +50 −116 drivers/usb/gadget/f_diag.c
  17. +4 −148 drivers/usb/gadget/f_ecm.c
  18. +6 −2 drivers/usb/gadget/f_eem.c
  19. +8 −0 drivers/usb/gadget/f_fs.c
  20. +26 −204 drivers/usb/gadget/f_mass_storage.c
  21. +198 −201 drivers/usb/gadget/f_mtp.c
  22. +1 −1 drivers/usb/gadget/f_ncm.c
  23. +1,170 −0 drivers/usb/gadget/f_novacom.c
  24. +862 −0 drivers/usb/gadget/f_racm.c
  25. +7 −23 drivers/usb/gadget/f_rmnet.h
  26. +14 −94 drivers/usb/gadget/f_rndis.c
  27. +2 −56 drivers/usb/gadget/f_serial.c
  28. +13 −42 drivers/usb/gadget/file_storage.c
  29. +78 −54 drivers/usb/gadget/g_ffs.c
  30. +16 −35 drivers/usb/gadget/gadget_chips.h
  31. +4 −3 drivers/usb/gadget/gmidi.c
  32. +6 −4 drivers/usb/gadget/hid.c
  33. +10 −8 drivers/usb/gadget/inode.c
  34. +428 −657 drivers/usb/gadget/langwell_udc.c
  35. +15 −14 drivers/usb/gadget/printer.c
  36. +625 −0 drivers/usb/gadget/rockhopper.c
  37. +7 −0 drivers/usb/gadget/rockhopper.h
  38. +6 −5 drivers/usb/gadget/s3c-hsotg.c
  39. +11 −54 drivers/usb/gadget/storage_common.c
  40. +19 −19 drivers/usb/gadget/u_bam.c
  41. +617 −0 drivers/usb/gadget/u_ctrl_hsic.c
  42. +961 −0 drivers/usb/gadget/u_data_hsic.c
  43. +22 −2 drivers/usb/gadget/u_ether.c
  44. +8 −3 drivers/usb/gadget/u_ether.h
  45. +0 −365 drivers/usb/gadget/u_lgeusb.c
  46. +0 −118 drivers/usb/gadget/u_lgeusb.h
  47. +0 −19 drivers/usb/gadget/u_rmnet.h
  48. +59 −130 drivers/usb/gadget/u_sdio.c
  49. +184 −24 drivers/usb/gadget/u_serial.c
  50. +1 −32 drivers/usb/gadget/u_serial.h
  51. +77 −122 drivers/usb/gadget/u_smd.c
  52. +18 −17 drivers/usb/gadget/webcam.c
  53. +3 −2 drivers/usb/gadget/zero.c
  54. +1 −41 include/linux/usb/android.h
  55. +0 −27 include/linux/usb/android_composite.h
  56. +8 −20 include/linux/usb/cdc.h
  57. +19 −36 include/linux/usb/composite.h
  58. +83 −0 include/linux/usb/f_accessory.h
  59. +29 −0 include/linux/usb/f_mtp.h
  60. +4 −4 include/linux/usb/gadget.h
  61. +40 −0 include/linux/usb/gadget_event.h
  62. +14 −14 include/linux/usb/otg.h
  63. +56 −0 include/linux/usb/otg_id.h
  64. +2 −0 include/linux/usb/rndis_host.h
  65. +3 −3 include/linux/usb/serial.h
  66. +5 −2 include/linux/usb/usbnet.h
  67. +2 −1 lge/factory/lg_diag_testmode.c
@@ -2094,7 +2094,7 @@ CONFIG_USB_GADGET_DUALSPEED=y
# CONFIG_USB_G_SERIAL is not set
# CONFIG_USB_MIDI_GADGET is not set
# CONFIG_USB_G_PRINTER is not set
-CONFIG_USB_ANDROID=y
+CONFIG_USB_G_ANDROID=y
CONFIG_USB_ANDROID_ACM=y
CONFIG_USB_ANDROID_ADB=y
CONFIG_USB_ANDROID_DIAG=y
@@ -60,7 +60,6 @@ enum {
LG_FW_MANUAL_TEST_MODE = LG_FW_RAPI_START + 8,
#ifdef CONFIG_LGE_SUPPORT_RAPI
LGE_RPC_HANDLE_REQUEST = LG_FW_RAPI_START + 9,
-#endif
#ifdef CONFIG_LGE_DLOAD_SRD
LG_FW_REQUEST_SRD_RPC = LG_FW_RAPI_START + 10, //kabjoo.choi
#endif
@@ -83,6 +82,7 @@ enum {
LG_FW_OEM_RAPI_CLIENT_SRD_COMMAND = LG_FW_RAPI_START+20, //send event
LG_FW_OEM_RAPI_CLIENT_SRD_COMMAND_WRITE, //send event
LG_FW_OEM_RAPI_CLIENT_SRD_COMMAND_SYNC,
+#endif
LG_MSG_UNIFIEDMSGTOOL_FROM_ARM11 = 200, //#ifdef LG_SMS_PC_TEST
#endif
@@ -3,7 +3,7 @@ menu "Diag Support"
config DIAG_CHAR
tristate "char driver interface and diag forwarding to/from modem"
default m
- depends on USB_ANDROID_DIAG || USB_FUNCTION_DIAG || USB_QCOM_MAEMO
+ depends on USB_G_ANDROID || USB_FUNCTION_DIAG || USB_QCOM_MAEMO
depends on ARCH_MSM
help
Char driver interface for diag user space and diag-forwarding to modem ARM and back.
@@ -32,6 +32,13 @@ static ssize_t state_show(struct device *dev, struct device_attribute *attr,
struct switch_dev *sdev = (struct switch_dev *)
dev_get_drvdata(dev);
+
+ if(!sdev)
+ {
+ return 0;
+ }
+
+
if (sdev->print_state) {
int ret = sdev->print_state(sdev, buf);
if (ret >= 0)
@@ -46,6 +53,16 @@ static ssize_t name_show(struct device *dev, struct device_attribute *attr,
struct switch_dev *sdev = (struct switch_dev *)
dev_get_drvdata(dev);
+
+
+
+ if(!sdev)
+ {
+ return 0;
+ }
+
+
+
if (sdev->print_name) {
int ret = sdev->print_name(sdev, buf);
if (ret >= 0)
Oops, something went wrong.

0 comments on commit 3b03eaf

Please sign in to comment.