summaryrefslogtreecommitdiff
path: root/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb
diff options
context:
space:
mode:
authorMykyta Dorokhin <mykyta.dorokhin@globallogic.com>2016-09-15 21:15:53 +0300
committerMykyta Dorokhin <mykyta.dorokhin@globallogic.com>2016-09-15 21:15:53 +0300
commitd7368ef31b729511e9d630bbd935eb56dc15856f (patch)
tree5d9d18eadf3a831259bbf96ae7c35e67a5417ee8 /recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb
parentad4cb1501c9ac3c364f1b5cf26fdfb5283d9c8ba (diff)
downloadmeta-mlinux-d7368ef31b729511e9d630bbd935eb56dc15856f.tar.gz
meta-mlinux-d7368ef31b729511e9d630bbd935eb56dc15856f.tar.bz2
meta-mlinux-d7368ef31b729511e9d630bbd935eb56dc15856f.zip
mtp: disable usb serial gadget for the mtp hardware
Diffstat (limited to 'recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb')
-rw-r--r--recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb7
1 files changed, 6 insertions, 1 deletions
diff --git a/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb b/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb
index 3b547cb..6887089 100644
--- a/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb
+++ b/recipes-connectivity/usb-gadget-mode/usb-gadget-mode.bb
@@ -10,7 +10,7 @@ SECTION = "console/network"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
PV = "0.0.2"
-PR = "r2"
+PR = "r3"
SRC_URI = "\
file://usb-gadget.conf \
@@ -29,6 +29,11 @@ do_install() {
install -m 0755 ${WORKDIR}/usb-gadget ${D}${bindir}
}
+# disbale usb-gadget for mtp hardware
+do_install_append_mtp() {
+ sed -i 's/ENABLED="yes"/ENABLED="no"/g' ${D}${sysconfdir}/default/usb-gadget
+}
+
pkg_postinst_${PN}() {
test -n "$D" && opt="-r $D"
update-rc.d $opt usb-gadget defaults 50