openbmc / linux

OpenBMC Linux kernel source tree

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Device or resource busy issue with gadget driver.

edineshkumar opened this issue · comments

If redirected media instance was mounted in host machine, following shell command is failing by sh: write error: Device or resource busy.

cd /{gadget_path} ; echo > functions/mass_storage.usb0/lun.0/file

If the media instance was not mounted in host machine, then there is nothing issue. echo command is succeeded.

My need is, echo command should success in both (with/without mount) cases.

Anyone can suggest me to achieve this?