os/kernelhwsrv/userlibandfileserver/fileserver/shostmassstorage/server/protocol/include/tscsiprimarycmds.inl
First public contribution.
1 // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
2 // All rights reserved.
3 // This component and the accompanying materials are made available
4 // under the terms of the License "Eclipse Public License v1.0"
5 // which accompanies this distribution, and is available
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // scsiprimarycommands.inl
23 /** Constructor for TEST UNIT READY request */
24 inline TScsiClientTestUnitReadyReq::TScsiClientTestUnitReadyReq()
25 : TScsiClientReq(ETestUnitReady)
31 /** constructor for SCSI REQUEST SENSE request */
32 inline TScsiClientRequestSenseReq::TScsiClientRequestSenseReq()
33 : TScsiClientReq(ERequestSense),
34 iAllocationLength(KResponseLength)
41 Set SCSI ALLOCATION LENGTH value.
43 @param aAllocationLength
45 inline void TScsiClientRequestSenseReq::SetAllocationLength(TAllocationLength aAllocationLength)
48 iAllocationLength = aAllocationLength;
52 inline TInt TScsiClientRequestSenseReq::EncodeRequestL(TDes8& aBuffer) const
55 __SCSIPRINT(_L("<-- SCSI REQUEST SENSE"));
56 TInt length = TScsiClientReq::EncodeRequestL(aBuffer);
58 aBuffer[4] = iAllocationLength;
63 /** Constructor for SCSI INQUIRY request */
64 inline TScsiClientInquiryReq::TScsiClientInquiryReq()
65 : TScsiClientReq(EInquiry),
68 iAllocationLength(KResponseLength)
75 Set SCSI ALLOCATION LENGTH value.
77 @param aAllocationLength
79 inline void TScsiClientInquiryReq::SetAllocationLength(TAllocationLength aAllocationLength)
82 iAllocationLength = aAllocationLength;
87 Set SCSI EVPD and PAGE CODE value.
89 @param aPageCode SCSI PAGE CODE value
91 inline void TScsiClientInquiryReq::SetEvpd(TUint8 aPageCode)
100 Set SCSI CmdDt and OPERATION CODE.
102 @param aOperationCode SCSI OPERATION CODE value
104 inline void TScsiClientInquiryReq::SetCmdDt(TUint8 aOperationCode)
108 iPage = aOperationCode;
112 inline TInt TScsiClientInquiryReq::EncodeRequestL(TDes8& aBuffer) const
115 __SCSIPRINT(_L("<-- SCSI INQUIRY"));
116 TInt length = TScsiClientReq::EncodeRequestL(aBuffer);
129 aBuffer[4] = iAllocationLength;
135 Constructor for SCSI INQUIRY response.
137 @param aPeripheralInfo Device perihpheral info data
139 inline TScsiClientInquiryResp::TScsiClientInquiryResp(TPeripheralInfo& aPeripheralInfo)
140 : iPeripheralInfo(aPeripheralInfo)
146 Constructor for SCSI PREVENT MEDIA REMOVAL request.
150 inline TScsiClientPreventMediaRemovalReq::TScsiClientPreventMediaRemovalReq(TPrevent aPrevent)
151 : TScsiClientReq(EPreventMediaRemoval),