Re: question about Template for f_mass_storage.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



hi:

2011/10/5 Alan Stern <stern@xxxxxxxxxxxxxxxxxxx>:
> On Wed, 5 Oct 2011, loody wrote:
>
>> hi:
>> I have some questions about this patch.
>
> What questions?  All you did was post a 100-KB message containing a
> giant patch.  That's a pretty inefficient use of email bandwidth.
My question is append at the end of letter as below, sorry for not
delete the patch before asking questions.

1. when below source will be executed? it seems the context will
always not be filled in.
( I temporarily remove that and program runs well.)
 if (req->status == 0 && req->context)
                ((fsg_routine_t) (req->context))(fsg);

 2. in following source code, it is possible process will fall in ***
 loop if the state in start_transfer be EMPTY, when queue failed,
 right?
 if that really happen, who or when the process will leave ***?

                start_transfer(fsg, fsg->bulk_out, bh->outreq,
                                &bh->outreq_busy, &bh->state);

                /* We will drain the buffer in software, which means we
                 * can reuse it for the next filling.  No need to advance
                 * next_buffhd_to_fill. */

                /* Wait for the CBW to arrive */
 ****       while (bh->state != BUF_STATE_FULL) {
                        rc = sleep_thread(fsg);
                        if (rc)
                                return rc;

 3. in http://www.mail-archive.com/linux-usb-devel@xxxxxxxxxxxxxxxxxxxxx/msg15529.html
, it mentioned about Scsi-backed Storage Gadget, I cannot find it in
the gadget file folder.Is that
 finally realized?

-
Regards,
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux