diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup index 517227d4a63..f27d77df512 100644 --- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup +++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-cleanup @@ -6,7 +6,7 @@ cd /sys/kernel/config/usb_gadget cd adb -echo "" > UDC || true +echo -n "" > UDC || true killall adbd || true diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup index e44d1bacbe3..dbd71151510 100644 --- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup +++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-setup @@ -23,8 +23,8 @@ mkdir configs/c.1 mkdir functions/ffs.usb0 mkdir strings/0x409 mkdir configs/c.1/strings/0x409 -echo 0x18d1 > idVendor -echo 0xd002 > idProduct +echo -n 0x18d1 > idVendor +echo -n 0xd002 > idProduct echo "$serial" > strings/0x409/serialnumber echo "$manufacturer" > strings/0x409/manufacturer echo "$model" > strings/0x409/product diff --git a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start index ca6c3df2753..d67878fef9a 100644 --- a/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start +++ b/meta-oe/recipes-devtools/android-tools/android-tools-conf-configfs/android-gadget-start @@ -4,4 +4,4 @@ set -e sleep 3 -ls /sys/class/udc/ > /sys/kernel/config/usb_gadget/adb/UDC +ls /sys/class/udc/ | xargs echo -n > /sys/kernel/config/usb_gadget/adb/UDC