On Thu, 18 Oct 2012, megha dey wrote: > While trying to copy some file(>400 MB) from PC to device in mass > storage mode,an I/O error is observed. > > From the bus trace, it is observed that vfs_sync() is taking a lot of > time when handing ALLOW_MEDIUM_REMOVAL.There is a similar problem > already discussed earlier,although with no concrete conclusion. > > http://comments.gmane.org/gmane.linux.usb.general/53896 > > Even after ~15 secs, we don�t send the Status to PC for the > ALLOW_MEDIUM_REMOVAL command. Since the vfs_sync command has not > returned, USB driver is not sending the status.PC is sending the next > command as it has not received the status for the previous command,and > this messes up the state diagram. > > Issue observed on kernel 3.4 with sandisk 2GB card. > > Dees the current mass storage driver (f_mass_storage.c) support such a > scenario,if not what would be the appropriate solution?
Yuping Luo posted a patch that was almost right: http://marc.info/?l=linux-usb&m=132024464410783&w=2 See http://marc.info/?l=linux-usb&m=132032964805789&w=2 for a description of what needed to be added to the patch. The patch was never fixed up and submitted. Would you like to update that patch and submit it? Alan Stern -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html