userlibandfileserver/fileserver/shostmassstorage/server/protocol/cscsiprotocol.cpp
changeset 33 0173bcd7697c
parent 31 56f325a607ea
child 62 4a8fed1c0ef6
equal deleted inserted replaced
31:56f325a607ea 33:0173bcd7697c
   258         }
   258         }
   259 
   259 
   260 	TLba lastLba;
   260 	TLba lastLba;
   261 	TUint32 blockLength;
   261 	TUint32 blockLength;
   262 
   262 
   263 	TInt err = iSbcInterface->ReadCapacity10L(lastLba, blockLength);
   263     // Retry ReadCapacity10L if stalled
       
   264     TInt stallCounter = 4;
       
   265     TInt err = KErrNone;
       
   266     do
       
   267         {
       
   268         err = iSbcInterface->ReadCapacity10L(lastLba, blockLength);
       
   269         } while (err == KErrCommandStalled && stallCounter-- > 0);
       
   270 
       
   271 
   264     if (err)
   272     if (err)
   265         {
   273         {
   266         if (err == KErrCommandFailed)
   274         if (err == KErrCommandFailed)
   267             {
   275             {
   268             // Clear sense error
   276             // Clear sense error