AnsweredAssumed Answered

UTP not receive MFGtool command since boot into linux kernel 4.1.15

Question asked by Wally Yeh on Oct 21, 2016
Latest reply on Oct 26, 2016 by Wally Yeh

Hi, Guys:

    I got an issue when upgrade our product's kernel from 3.0.35 to 4.1.15.

that is /dev/utp not recieve any "updater" command from MFGtools.


    in old 3.0.35 kernel, all I need to do is modprobe "g_file_storage" to initialize /dev/utp; then call "uuc" program to read /dev/utp.


    In kernel 4.1.15; I have to use configfs for /dev/utp initializing. but after "uuc" executed, nothing happened. I am wondering is I missed configure the configfs for usb_f_mass_gadget?


    I list my steps below:

/* load needed kernel modules */

modprobe libcomposite
modprobe usb_f_mass_storage


/* configure configfs for mass_storage function */

mkdir /tmp/configfs
mount none /tmp/configfs/ -t configfs

mkdir /tmp/configfs/usb_gadget/g1
echo "0x1d6b" > /tmp/configfs/usb_gadget/g1/idVendor
echo "0x0002" > /tmp/configfs/usb_gadget/g1/idProduct

mkdir /tmp/configfs/usb_gadget/g1/strings/0x409
echo 3 > /tmp/configfs/usb_gadget/g1/strings/0x409/manufacturer
echo 2 > /tmp/configfs/usb_gadget/g1/strings/0x409/product
echo 1 > /tmp/configfs/usb_gadget/g1/strings/0x409/serialnumber

mkdir /tmp/configfs/usb_gadget/g1/configs/c.1

mkdir /tmp/configfs/usb_gadget/g1/configs/c.1/strings/0x409

mkdir /tmp/configfs/usb_gadget/g1/functions/mass_storage.0

ln -s /tmp/configfs/usb_gadget/g1/functions/mass_storage.0 /tmp/configfs/usb_gadget/g1/configs/c.1


/* now call bind function in usb_f_mass_storage.ko, this will initialize /dev/utp device node */

echo "ci_hdrc.0" > /tmp/configfs/usb_gadget/g1/UDC


/* call uuc to listen /dev/utp */

sudo /usr/bin/uuc



    Does I missed anything important? please tell me what I missed, I'll be very appreciated.