diff -r 630d2f34d719 -r 07a122eea281 telephonyserverplugins/simatktsy/src/CSatNotifyOpenChannel.cpp --- a/telephonyserverplugins/simatktsy/src/CSatNotifyOpenChannel.cpp Tue Aug 31 16:23:08 2010 +0300 +++ b/telephonyserverplugins/simatktsy/src/CSatNotifyOpenChannel.cpp Wed Sep 01 12:40:21 2010 +0100 @@ -1,4 +1,4 @@ -// Copyright (c) 2005-2010 Nokia Corporation and/or its subsidiary(-ies). +// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies). // All rights reserved. // This component and the accompanying materials are made available // under the terms of "Eclipse Public License v1.0" @@ -20,12 +20,6 @@ //INCLUDES - -#include "OstTraceDefinitions.h" -#ifdef OST_TRACE_COMPILER_IN_USE -#include "CSatNotifyOpenChannelTraces.h" -#endif - #include // Etel SAT IPC definitions #include "CSatTsy.h" // Tsy class header #include "CSatNotifyOpenChannel.h" // Class header @@ -33,6 +27,7 @@ #include "CBerTlv.h" // Ber Tlv data handling #include "TTlv.h" // TTlv class #include "CSatDataPackage.h" // Parameter packing +#include "TfLogger.h" // For TFLOGSTRING #include "TSatUtility.h" // Utilities #include "CSatTsyReqHandleStore.h" // Request handle class #include "cmmmessagemanagerbase.h" // Message manager class for forwarding req. @@ -47,13 +42,13 @@ CSatNotificationsTsy* aNotificationsTsy ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_NEWL_1, "CSAT: CSatNotifyOpenChannel::NewL"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::NewL"); CSatNotifyOpenChannel* const satNotifyOpenChannel = new ( ELeave ) CSatNotifyOpenChannel( aNotificationsTsy ); CleanupStack::PushL( satNotifyOpenChannel ); satNotifyOpenChannel->ConstructL(); CleanupStack::Pop( satNotifyOpenChannel ); - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_NEWL_2, "CSAT: CSatNotifyOpenChannel::NewL, end of method"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::NewL, end of method"); return satNotifyOpenChannel; } @@ -67,7 +62,7 @@ // None ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_DTOR_1, "CSAT: CSatNotifyOpenChannel::~CSatNotifyOpenChannel"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::~CSatNotifyOpenChannel"); } // ----------------------------------------------------------------------------- @@ -94,7 +89,7 @@ // None ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_CONSTRUCTL_1, "CSAT: CSatNotifyOpenChannel::ConstructL"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::ConstructL"); } // ----------------------------------------------------------------------------- @@ -109,7 +104,7 @@ const TDataPackage& aPackage ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_NOTIFY_1, "CSAT: CSatNotifyOpenChannel::Notify"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::Notify"); // Save data pointers to client side for completion iOpenBaseChannelV2Pckg = reinterpret_cast( aPackage.Des1n() ); @@ -139,7 +134,7 @@ const TTsyReqHandle aTsyReqHandle ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_CANCELNOTIFICATION_1, "CSAT: CSatNotifyOpenChannel::CancelNotification"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CancelNotification"); // Reset the request handle TTsyReqHandle reqHandle = iNotificationsTsy->iSatReqHandleStore-> @@ -166,7 +161,7 @@ TInt aErrorCode ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_1, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL"); TInt ret( KErrNone ); // Unpack parameters @@ -209,7 +204,9 @@ { case KBipCsdBearer: { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_2, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Command not supported: Csd Bearer"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Command not supported: \ + Csd Bearer"); // Buffer size iBufferSize = bufferSize.GetLongInfo( ETLV_BufferSize ); @@ -217,7 +214,8 @@ iBearerType = RSat::ECSDBearer; iBearer = bearerDescription.GetData( ETLV_BearerParameters ); - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_3, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, BipCsdBearer "); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, BipCsdBearer "); CreateTerminalRespL( pCmdNumber, RSat::KCmdBeyondMeCapabilities, KNullDesC16 ); ret = KErrCorrupt; @@ -274,7 +272,8 @@ default: { // Bearer not supported (RFU) - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_4, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Bearer not supported"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Bearer not supported"); // Required values missing iBearer.FillZ( 1 ); iBufferSize = 0; @@ -289,7 +288,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_5, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, required values missing"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL,\ + required values missing"); // Required values missing iBearer.FillZ( 1 ); iBufferSize = 0; @@ -358,14 +358,16 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_6, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Alpha ID is NULL"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Alpha ID is NULL"); openChannelV2->iAlphaId.iStatus = RSat::EAlphaIdNull; } } // Alpha id not present else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_7, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Alpha ID not present"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL,\ + Alpha ID not present"); openChannelV2->iAlphaId.iStatus = RSat::EAlphaIdNotPresent; } @@ -409,7 +411,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_8, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Protocol not present"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL,\ + Protocol not present"); openChannelV2->iSimMeInterface.iTransportProto = RSat::EProtocolNotPresent; } @@ -484,7 +487,8 @@ } default: { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_9, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Address not set"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Address not set"); openChannelV2->iDestinationAddress.iType = RSat::EAddressNotSet; break; @@ -538,7 +542,9 @@ } default: { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_10, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Address not set"); + TFLOGSTRING("CSAT:\ + CSatNotifyOpenChannel::\ + CompleteNotifyL, Address not set"); openCsChannelV2.iLocalAddress.iType = RSat::EAddressNotSet; } @@ -552,7 +558,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_11, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Address not present"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Address not present"); openCsChannelV2.iLocalAddress.iType = RSat::EAddressNotPresent; } @@ -584,7 +591,9 @@ } default: { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_12, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Address not set"); + TFLOGSTRING("CSAT: \ + CSatNotifyOpenChannel::\ + CompleteNotifyL, Address not set"); openGprsChannelV4.iLocalAddress.iType = RSat::EAddressNotSet; } @@ -599,7 +608,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_13, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Address not present"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Address not present"); openGprsChannelV4.iLocalAddress.iType = RSat::EAddressNotPresent; } @@ -608,7 +618,8 @@ } default: { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_14, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Unknown Bearer type"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::\ + CompleteNotifyL, Unknown Bearer type"); break; } @@ -618,7 +629,8 @@ } // if ( KErrNone == ret ) else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_15, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Error when parsing Bearer data"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL,\ + Error when parsing Bearer data"); } } // if ( KErrNone == aErrorCode ) else @@ -631,7 +643,8 @@ else { // Request not on, returning response immediately - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_COMPLETENOTIFYL_16, "CSAT: CSatNotifyOpenChannel::CompleteNotifyL, Request not ongoing"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::CompleteNotifyL, \ + Request not ongoing"); // additional info must be provided with KMeUnableToProcessCmd TBuf16<1> additionalInfo; additionalInfo.Append( RSat::KNoSpecificMeProblem ); @@ -654,7 +667,7 @@ TDes8* aRsp ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_TERMINALRESPONSEL_1, "CSAT: CSatNotifyOpenChannel::TerminalResponseL"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::TerminalResponseL"); TInt ret( KErrNone ); @@ -666,7 +679,8 @@ TUint8 pCmdNumber( rspV2.PCmdNumber() ); - OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_TERMINALRESPONSEL_2, "CSAT: CSatNotifyOpenChannel::TerminalResponseL, General result: %d", rspV2.iGeneralResult); + TFLOGSTRING2("CSAT: CSatNotifyOpenChannel::TerminalResponseL, \ + General result: %d", rspV2.iGeneralResult); // Check that general result value is valid if ( ( RSat::KSuccess != rspV2.iGeneralResult ) @@ -689,7 +703,8 @@ && ( RSat::KAccessTechUnableProcessCmd != rspV2.iGeneralResult ) && ( RSat::KFramesError != rspV2.iGeneralResult ) ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_TERMINALRESPONSEL_3, "CSAT: CSatNotifyOpenChannel::TerminalResponseL, Invalid General Result"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::TerminalResponseL, \ + Invalid General Result"); // Invalid general result ret = KErrCorrupt; } @@ -703,7 +718,8 @@ // Check the length of additional info if ( rspV2.iAdditionalInfo.Length() <= 0 ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_TERMINALRESPONSEL_4, "CSAT: CSatNotifyOpenChannel::TerminalResponseL, Invalid Additional Info"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::TerminalResponseL, \ + Invalid Additional Info"); // Invalid additional info field ret = KErrCorrupt; } @@ -726,7 +742,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_TERMINALRESPONSEL_5, "CSAT: CSatNotifyOpenChannel::TerminalResponseL, Invalid Additional Info type"); + TFLOGSTRING("CSAT: CSatNotifyOpenChannel::TerminalResponseL, \ + Invalid Additional Info type"); ret = KErrCorrupt; } @@ -756,7 +773,7 @@ const TDesC16& aAdditionalInfo ) { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_CREATETERMINALRESPL_1, "CSAT: CSatMessHandler::CreateTerminalRespL"); + TFLOGSTRING("CSAT: CSatMessHandler::CreateTerminalRespL"); // Create and append response data TTlv tlvSpecificData; // Create General Result TLV here @@ -783,7 +800,8 @@ // Successful result: could/must provide an additional info byte if ( aAdditionalInfo.Length() > 0 ) { - OstTraceDef1(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_CREATETERMINALRESPL_2, "CSAT: CSatMessHandler::CreateTerminalRespL, Unsuccessful result: aAddtionalInfo: %d", aAdditionalInfo[0]); + TFLOGSTRING2("CSAT: CSatMessHandler::CreateTerminalRespL,\ + Unsuccessful result: aAddtionalInfo: %d", aAdditionalInfo[0]); tlvSpecificData.AddByte( static_cast( aAdditionalInfo[0] ) ); } } @@ -797,7 +815,8 @@ } else { - OstTraceDef0(OST_TRACE_CATEGORY_DEBUG, TRACE_INTERNALS, CSATNOTIFYOPENCHANNEL_CREATETERMINALRESPL_3, "CSAT: CSatMessHandler::CreateTerminalRespL: No Bearer Description data available"); + TFLOGSTRING("CSAT: CSatMessHandler::CreateTerminalRespL: \ + No Bearer Description data available"); } // Append Buffer Size