Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Multiple streams in UASP(USB Attached SCSI Protocol)

Posted on 2012-12-26
11
Medium Priority
?
644 Views
Last Modified: 2014-03-31
Dear experts,
I have 1 question about how to process multiple streams in UASP(USB attached SCSI Protocol) and maybe you can help me to clarify it. Thanks in advance...

As we know UASP is based on USB 3.0 Bulk Stream and built on top of it. We can imagine multiple streams with different Stream ID share the same pipe(communication pathway) and streams are transferred via host/device multiplexing...

My question is:Assume there are 2 streams(ID = 1 and 2) then the processing sequence might be: (we can assume these 2 streams are successfully processed without any error !)

Scenario 1:
- stream 1 is selected and then process stream 1 "until all data is processed"...
- then stream 2 is selected and process stream 2 "until all data is processed"...

Scenario 2: stream 1/2 will be divided into multiple sub-streams and the processing sequence is:
- process part of stream 1
- process part of stream 2
- process part of stream 1
- process part of stream 2
- (... multiplexing until all these 2 streams are completed... )

which one is correct ? or there is another scenario ?

* That is, the selected stream is always processed until it is completed then another stream can be selected, it is correct ?
stream.jpg
0
Comment
Question by:liaoo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
11 Comments
 
LVL 47

Accepted Solution

by:
David earned 2000 total points
ID: 38722680
#1, but it is not quite that simple ... There are 3 round trips for any SCSI command, and each trip must be completed before the next one.    Now I am simplifying everything, and if you were a developer you need to read the full spec at the T10.org or the usb.org site.   But found this summary that may give you enough to answer the question sufficiently...


http://www.usb.org/developers/presentations/pres0410/2-4_SSUSB_DevCon_UASP_Stevens.pdf
0
 

Author Comment

by:liaoo
ID: 38722994
First thanks for your comments. After reviewing this document I have below questions and maybe you can help me to clarify them...

(1) I think the "3 round-trip" you said means: one round-trip for sending CBW, one for accessing data, and the last is for receiving status. Am I right ?

(2) If (1) is right, then as this doc said, I think: UASP provides a modest increase in bus utilization and eliminates much of the round trip time because this time is hidden behind queuing(storage driver is a queuing model now). Am I right ?

(3) There is only one example in this doc describing the behavior of multiple commands(one Read + one Write). If we consider only the data part then I found below:
- (H2D) IN ACK (for IN)
- (H2D) DP (for OUT)
- (D2H) DP (for IN)
- (H2D) DP (for OUT)
- (H2D) IN ACK (for IN)
- (D2H) ACK (for OUT)
.....

There are 2 streams in above example and it seems that device can:
- select stream ID(for write) and do DMA transfer
- select stream ID(for read)  and do DMA transfer
- select stream ID(for write) and do DMA transfer
- select stream ID(for read)  and do DMA transfer

Thus I can conclude that the Data IN/OUT streams are divided into multiple DPs and these DPs are transferred concurrently and can be interleaved(Stream ID is multiplexed...)

This brings me a question about (One Write+One Write) case:

Can I say that the DPs transferred in this Data-OUT pipe looks like below:
- select stream ID(for write 1) and do DMA transfer
- select stream ID(for write 2)  and do DMA transfer
- select stream ID(for write 1) and do DMA transfer
- select stream ID(for write 2) and do DMA transfer
- ...

Am I correct ?

Thanks !
ex.jpg
0
 
LVL 47

Assisted Solution

by:David
David earned 2000 total points
ID: 38723725
#1 & #2 are yes, as for #3, I've never had the need to look at that scenario with a protocol analyzer so can't answer with authority.  The work I do professionally is at the CDB level.  So I suggest downloading the 500+ page official specs at the usb.org site and getting the definitive answer to the last one.   Sorry, don't know that one off top of my head.
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:liaoo
ID: 38725707
Thanks for your comments ! Maybe the best way is to setup the platform which can activate UASP then use USB protocol analyzer to trace the behavior...^_^
0
 
LVL 47

Expert Comment

by:David
ID: 38725726
USB protocol analyzers are the way to go, and are relatively inexpensive.
0
 

Author Comment

by:liaoo
ID: 38730875
I think I have to take time setting up the testing environment and figuring out the logging information...
0
 
LVL 71

Expert Comment

by:Qlemo
ID: 39958736
I've requested that this question be deleted for the following reason:

Not enough information to confirm an answer.
0
 
LVL 47

Expert Comment

by:David
ID: 39958737
I object - the question was answered, followup was answered, and then the "what is the best way" was answered.  The last comment from author was nothing more than a comment saying, "I think I have to take time setting up the testing environment and figuring out the logging information..."

There were no open issues, question was answered.
0

Featured Post

Take our survey for a chance to win!

As a valued customer of Targus, we’d like to ask you a few questions about us. As thanks, you will be automatically entered for a chance to win a $500 VISA gift card. To enter, just complete the survey by September 15, 2017.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article outlines why you need to choose a backup solution that protects your entire environment – including your VMware ESXi and Microsoft Hyper-V virtualization hosts – not just your virtual machines.
Compliance and data security require steps be taken to prevent unauthorized users from copying data.  Here's one method to prevent data theft via USB drives (and writable optical media).
This video teaches viewers how to encrypt an external drive that requires a password to read and edit the drive. All tasks are done in Disk Utility. Plug in the external drive you wish to encrypt: Make sure all previous data on the drive has been …
This Micro Tutorial will teach you how to reformat your flash drive. Sometimes your flash drive may have issues carrying files so this will completely restore it to manufacturing settings. Make sure to backup all files before reformatting. This w…

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question