HiKey960: Set driver_match_existing_only to 0 to enable gadget mode to work on usb-c hotplug am: f80ca2ba9c
am: 91535c5109
Change-Id: Id6af763d2eb07408a57416309613b4b726dec479
diff --git a/init.common.usb.rc b/init.common.usb.rc
index f198a8b..16054ba 100644
--- a/init.common.usb.rc
+++ b/init.common.usb.rc
@@ -3,6 +3,7 @@
mkdir /config/usb_gadget/g1 0770 shell shell
mkdir /config/usb_gadget/g1/strings/0x409 0770 shell shell
write /config/usb_gadget/g1/bcdUSB 0x0200
+ write /config/usb_gadget/g1/driver_match_existing_only 0
write /config/usb_gadget/g1/idVendor 0x18d1
write /config/usb_gadget/g1/bcdDevice 0x0223
write /config/usb_gadget/g1/strings/0x409/serialnumber ${ro.serialno}
diff --git a/init.recovery.common.rc b/init.recovery.common.rc
index c9cb590..40245d7 100644
--- a/init.recovery.common.rc
+++ b/init.recovery.common.rc
@@ -13,6 +13,7 @@
on init
mount configfs none /config
mkdir /config/usb_gadget/g1 0770 shell shell
+ write /config/usb_gadget/g1/driver_match_existing_only 0
write /config/usb_gadget/g1/idVendor 0x18d1
write /config/usb_gadget/g1/idProduct 0xd001
mkdir /config/usb_gadget/g1/strings/0x409 0770