34 #include "safec_lib.h"
35 #ifdef USE_MoCA_PROFILE
46 updateCallback MoCAClientReqHandler::mUpdateCallback = NULL;
47 int MoCAClientReqHandler::curNumOfDevices[10] = {0,};
48 int MoCAClientReqHandler::numOfMocaMeshEntries = 0;
50 msgHandler* MoCAClientReqHandler::getInstance()
58 void MoCAClientReqHandler::reset()
60 MoCAInterface::getLock();
61 memset(curNumOfDevices,0,
sizeof(curNumOfDevices));
62 numOfMocaMeshEntries = 0;
63 MoCAInterface::releaseLock();
77 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s] Entering..\n", __FUNCTION__, __FILE__);
78 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
94 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s] Entering..\n", __FUNCTION__, __FILE__);
96 MoCAInterface::closeInstance();
102 MoCADevice::closeInstance();
104 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s] Exiting..\n", __FUNCTION__, __FILE__);
123 int ret = NOT_HANDLED;
124 const char *pSetting;
125 const char *pSubSetting;
127 int subInstanceNumber;
128 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s:%d] Found string as %s\n", __FUNCTION__, __FILE__, __LINE__, stMsgData->
paramName);
130 "Device.MoCA.Interface",&pSetting,instanceNumber))
133 MoCAInterface::getLock();
139 MoCAInterface::releaseLock();
143 if (strcasecmp(pSetting,
"Enable") == 0)
147 else if (strcasecmp(pSetting,
"Alias") == 0)
151 else if (strcasecmp(pSetting,
"LowerLayers") == 0)
155 else if (strcasecmp(pSetting,
"PreferredNC") == 0)
159 else if (strcasecmp(pSetting,
"PrivacyEnabledSetting") == 0)
163 else if (strcasecmp(pSetting,
"FreqCurrentMaskSetting") == 0)
167 else if (strcasecmp(pSetting,
"KeyPassphrase") == 0)
171 else if (strcasecmp(pSetting,
"TxPowerLimit") == 0)
175 else if (strcasecmp(pSetting,
"PowerCntlPhyTarget") == 0)
179 else if (strcasecmp(pSetting,
"BeaconPowerLimit") == 0)
186 stMsgData->
faultCode = fcAttemptToSetaNonWritableParameter;
187 RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,
"[%s] Failed, since Attempt To Set a NonWritable Parameter \"%s\"\n", __FUNCTION__, stMsgData->
paramName);
194 MoCAInterface::releaseLock();
212 int ret = NOT_HANDLED;
213 const char *pSetting;
214 const char *pSubSetting;
216 int subInstanceNumber;
217 RDK_LOG(RDK_LOG_TRACE1,LOG_TR69HOSTIF,
"[%s:%s:%d] Found string as %s\n", __FUNCTION__, __FILE__, __LINE__, stMsgData->
paramName);
218 MoCAInterface::getLock();
219 if(strcasecmp(stMsgData->
paramName,
"Device.MoCA.InterfaceNumberOfEntries") == 0)
223 else if(matchComponent(stMsgData->
paramName,
224 "Device.MoCA.Interface",&pSetting,instanceNumber))
229 = MoCAInterfaceStats::getInstance();
232 = MoCAInterfaceQoSFlowStats::getInstance();
234 = MoCAInterfaceAssociatedDevice::getInstance();
237 = X_RDKCENTRAL_COM_MeshTable::getInstance(instanceNumber);
241 MoCAInterface::releaseLock();
245 if (strcasecmp(pSetting,
"Enable") == 0)
249 else if (strcasecmp(pSetting,
"Status") == 0)
253 else if (strcasecmp(pSetting,
"Alias") == 0)
257 else if (strcasecmp(pSetting,
"Name") == 0)
261 else if (strcasecmp(pSetting,
"LastChange") == 0)
265 else if (strcasecmp(pSetting,
"LowerLayers") == 0)
269 else if (strcasecmp(pSetting,
"Upstream") == 0)
273 else if (strcasecmp(pSetting,
"MACAddress") == 0)
277 else if (strcasecmp(pSetting,
"FirmwareVersion") == 0)
281 else if (strcasecmp(pSetting,
"MaxBitRate") == 0)
285 else if (strcasecmp(pSetting,
"MaxIngressBW") == 0)
289 else if (strcasecmp(pSetting,
"MaxEgressBW") == 0)
293 else if (strcasecmp(pSetting,
"HighestVersion") == 0)
297 else if (strcasecmp(pSetting,
"CurrentVersion") == 0)
301 else if (strcasecmp(pSetting,
"NetworkCoordinator") == 0)
305 else if (strcasecmp(pSetting,
"NodeID") == 0)
309 else if (strcasecmp(pSetting,
"MaxNodes") == 0)
313 else if (strcasecmp(pSetting,
"PreferredNC") == 0)
317 else if (strcasecmp(pSetting,
"BackupNC") == 0)
321 else if (strcasecmp(pSetting,
"PrivacyEnabledSetting") == 0)
325 else if (strcasecmp(pSetting,
"PrivacyEnabled") == 0)
329 else if (strcasecmp(pSetting,
"FreqCapabilityMask") == 0)
333 else if (strcasecmp(pSetting,
"FreqCurrentMaskSetting") == 0)
337 else if (strcasecmp(pSetting,
"FreqCurrentMask") == 0)
341 else if (strcasecmp(pSetting,
"CurrentOperFreq") == 0)
345 else if (strcasecmp(pSetting,
"LastOperFreq") == 0)
349 else if (strcasecmp(pSetting,
"KeyPassphrase") == 0)
353 else if (strcasecmp(pSetting,
"TxPowerLimit") == 0)
357 else if (strcasecmp(pSetting,
"PowerCntlPhyTarget") == 0)
361 else if (strcasecmp(pSetting,
"BeaconPowerLimit") == 0)
365 else if (strcasecmp(pSetting,
"NetworkTabooMask") == 0)
369 else if (strcasecmp(pSetting,
"NodeTabooMask") == 0)
373 else if (strcasecmp(pSetting,
"TxBcastRate") == 0)
377 else if (strcasecmp(pSetting,
"TxBcastPowerReduction") == 0)
381 else if (strcasecmp(pSetting,
"QAM256Capable") == 0)
385 else if (strcasecmp(pSetting,
"PacketAggregationCapability") == 0)
389 else if (strcasecmp(pSetting,
"AssociatedDeviceNumberOfEntries") == 0)
393 else if (strcasecmp(pSetting,
"X_RDKCENTRAL-COM_MeshTableNumberOfEntries") == 0)
397 else if (strcasecmp(pSetting,
"X_RDKCENTRAL-COM_PrimaryChannelFreq") == 0)
401 else if (strcasecmp(pSetting,
"X_RDKCENTRAL-COM_SecondaryChannelFreq") == 0)
405 else if (strcasecmp(pSetting,
"X_RDKCENTRAL-COM_TurboMode") == 0)
409 else if (strcasecmp(pSetting,
"X_RDKCENTRAL-COM_NodePowerState") == 0)
413 else if (strcasecmp(pSetting,
"Stats.BytesSent") == 0)
417 else if (strcasecmp(pSetting,
"Stats.BytesReceived") == 0)
421 else if (strcasecmp(pSetting,
"Stats.PacketsSent") == 0)
425 else if (strcasecmp(pSetting,
"Stats.PacketsReceived") == 0)
429 else if (strcasecmp(pSetting,
"Stats.ErrorsSent") == 0)
433 else if (strcasecmp(pSetting,
"Stats.ErrorsReceived") == 0)
437 else if (strcasecmp(pSetting,
"Stats.UnicastPacketsSent") == 0)
441 else if (strcasecmp(pSetting,
"Stats.UnicastPacketsReceived") == 0)
445 else if (strcasecmp(pSetting,
"Stats.DiscardPacketsSent") == 0)
449 else if (strcasecmp(pSetting,
"Stats.DiscardPacketsReceived") == 0)
453 else if (strcasecmp(pSetting,
"Stats.MulticastPacketsSent") == 0)
457 else if (strcasecmp(pSetting,
"Stats.MulticastPacketsReceived") == 0)
461 else if (strcasecmp(pSetting,
"Stats.BroadcastPacketsSent") == 0)
465 else if (strcasecmp(pSetting,
"Stats.BroadcastPacketsReceived") == 0)
469 else if (strcasecmp(pSetting,
"Stats.UnknownProtoPacketsReceived") == 0)
473 else if (strcasecmp(pSetting,
"QoS.EgressNumFlows") == 0)
477 else if (strcasecmp(pSetting,
"QoS.IngressNumFlows") == 0)
481 else if (strcasecmp(pSetting,
"QoS.FlowStatsNumberOfEntries") == 0)
485 else if (matchComponent(pSetting,
"QoS.FlowStats",
486 &pSubSetting,subInstanceNumber))
488 if (strcasecmp(pSubSetting,
"FlowID") == 0)
490 ret = pIfaceQoSFS->
get_FlowID(stMsgData,subInstanceNumber);
492 else if(strcasecmp(pSubSetting,
"PacketDA") == 0)
494 ret = pIfaceQoSFS->
get_PacketDA(stMsgData,subInstanceNumber);
496 else if(strcasecmp(pSubSetting,
"MaxRate") == 0)
498 ret = pIfaceQoSFS->
get_MaxRate(stMsgData,subInstanceNumber);
500 else if(strcasecmp(pSubSetting,
"MaxBurstSize") == 0)
504 else if(strcasecmp(pSubSetting,
"LeaseTime") == 0)
506 ret = pIfaceQoSFS->
get_LeaseTime(stMsgData,subInstanceNumber);
508 else if(strcasecmp(pSubSetting,
"LeaseTimeLeft") == 0)
512 else if(strcasecmp(pSubSetting,
"FlowPackets") == 0)
518 stMsgData->
faultCode = fcInvalidParameterName;
523 else if(matchComponent(pSetting,
"AssociatedDevice",
524 &pSubSetting,subInstanceNumber))
526 if (strcasecmp(pSubSetting,
"MACAddress") == 0)
530 else if(strcasecmp(pSubSetting,
"NodeID") == 0)
532 ret = pIfaceAsstDev->
get_NodeID(stMsgData,subInstanceNumber);
534 else if(strcasecmp(pSubSetting,
"PreferredNC") == 0)
538 else if(strcasecmp(pSubSetting,
"HighestVersion") == 0)
542 else if(strcasecmp(pSubSetting,
"PHYTxRate") == 0)
544 ret = pIfaceAsstDev->
get_PHYTxRate(stMsgData,subInstanceNumber);
546 else if(strcasecmp(pSubSetting,
"PHYRxRate") == 0)
548 ret = pIfaceAsstDev->
get_PHYRxRate(stMsgData,subInstanceNumber);
550 else if(strcasecmp(pSubSetting,
"TxPowerControlReduction") == 0)
554 else if(strcasecmp(pSubSetting,
"RxPowerLevel") == 0)
558 else if(strcasecmp(pSubSetting,
"TxBcastRate") == 0)
562 else if(strcasecmp(pSubSetting,
"RxBcastPowerLevel") == 0)
566 else if(strcasecmp(pSubSetting,
"TxPackets") == 0)
568 ret = pIfaceAsstDev->
get_TxPackets(stMsgData,subInstanceNumber);
570 else if(strcasecmp(pSubSetting,
"RxPackets") == 0)
572 ret = pIfaceAsstDev->
get_RxPackets(stMsgData,subInstanceNumber);
574 else if(strcasecmp(pSubSetting,
"RxErroredAndMissedPackets") == 0)
578 else if(strcasecmp(pSubSetting,
"QAM256Capable") == 0)
582 else if(strcasecmp(pSubSetting,
"PacketAggregationCapability") == 0)
586 else if(strcasecmp(pSubSetting,
"RxSNR") == 0)
588 ret = pIfaceAsstDev->
get_RxSNR(stMsgData,subInstanceNumber);
590 else if(strcasecmp(pSubSetting,
"Active") == 0)
592 ret = pIfaceAsstDev->
get_Active(stMsgData,subInstanceNumber);
596 stMsgData->
faultCode = fcInvalidParameterName;
600 else if(matchComponent(pSetting,
"X_RDKCENTRAL-COM_MeshTable", &pSubSetting, subInstanceNumber))
602 if(strcasecmp(pSubSetting,
"MeshTxNodeId") == 0)
606 else if(strcasecmp(pSubSetting,
"MeshRxNodeId") == 0)
610 else if(strcasecmp(pSubSetting,
"MeshPHYTxRate") == 0)
614 else if(strcasecmp(pSubSetting,
"BondedChannel") == 0)
616 ret = pIfaceMeshTableDev->get_BondedChannel(stMsgData,subInstanceNumber);
621 stMsgData->
faultCode = fcInvalidParameterName;
627 stMsgData->
faultCode = fcInvalidParameterName;
633 stMsgData->
faultCode = fcInvalidParameterName;
636 MoCAInterface::releaseLock();
639 int MoCAClientReqHandler::handleGetAttributesMsg(
HOSTIF_MsgData_t *stMsgData)
641 int ret = NOT_HANDLED;
642 int instanceNumber = 0;
643 MoCAInterface::getLock();
649 MoCAInterface::releaseLock();
653 GHashTable* notifyhash = pIface->getNotifyHash();
654 if(notifyhash != NULL)
656 int* notifyvalue = (
int*) g_hash_table_lookup(notifyhash,stMsgData->
paramName);
658 stMsgData->
paramtype = hostIf_IntegerType;
665 MoCAInterface::releaseLock();
669 int MoCAClientReqHandler::handleSetAttributesMsg(
HOSTIF_MsgData_t *stMsgData)
671 int ret = NOT_HANDLED;
672 int instanceNumber = 0;
673 MoCAInterface::getLock();
679 MoCAInterface::releaseLock();
682 GHashTable* notifyhash = pIface->getNotifyHash();
683 if(notifyhash != NULL)
686 notifyValuePtr = (
int*) malloc(1 *
sizeof(
int));
692 notifyKey = (
char*) malloc(
sizeof(
char)*strlen(stMsgData->
paramName)+1);
693 if(NULL != notifyValuePtr)
702 g_hash_table_insert(notifyhash,notifyKey,notifyValuePtr);
708 RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,
"[%s:%s:%d] MoCAClientReqHandler Not able to allocate Notify pointer %s\n", __FUNCTION__, __FILE__, __LINE__, stMsgData->
paramName);
714 RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,
"[%s:%s:%d] MoCAClientReqHandler Not able to get notifyhash %s\n", __FUNCTION__, __FILE__, __LINE__, stMsgData->
paramName);
716 MoCAInterface::releaseLock();
720 void MoCAClientReqHandler::registerUpdateCallback(updateCallback cb)
722 mUpdateCallback = cb;
725 void MoCAClientReqHandler::checkForUpdates()
731 char tmp_buff[TR69HOSTIFMGR_MAX_PARAM_LEN];
732 MoCAInterface::getLock();
740 memset(&msgData,0,
sizeof(msgData));
741 memset(tmp_buff,0,TR69HOSTIFMGR_MAX_PARAM_LEN);
745 char tmp[TR69HOSTIFMGR_MAX_PARAM_LEN] =
"";
746 sprintf(tmp_buff,
"Device.MoCA.Interface.%d.%s",index,
"AssociatedDevice");
747 while(curNumOfDevices[index] > tmpNoDev)
749 sprintf(tmp,
"%s.%d.",tmp_buff,tmpNoDev);
753 while(curNumOfDevices[index] < tmpNoDev)
755 sprintf(tmp,
"%s.",tmp_buff);
757 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s]Sending ADD Event for params: [%s] \n", __FILE__, __FUNCTION__ ,tmp);
760 curNumOfDevices[index] = get_int(msgData.
paramValue);
763 memset(&msgData,0,
sizeof(msgData));
764 memset(tmp_buff,0,TR69HOSTIFMGR_MAX_PARAM_LEN);
768 char tmp[TR69HOSTIFMGR_MAX_PARAM_LEN] =
"";
769 sprintf(tmp_buff,
"Device.MoCA.Interface.%d.%s",index,
"X_RDKCENTRAL-COM_MeshTable");
770 while(numOfMocaMeshEntries > tmpNoDev)
772 sprintf(tmp,
"%s.%d.",tmp_buff,tmpNoDev);
776 while(numOfMocaMeshEntries < tmpNoDev)
778 sprintf(tmp,
"%s.",tmp_buff);
780 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s]Sending ADD Event for params: [%s] \n", __FILE__, __FUNCTION__ ,tmp);
783 numOfMocaMeshEntries = get_int(msgData.
paramValue);
788 #ifdef HAVE_VALUE_CHANGE_EVENT
789 int instanceNumber = 0;
790 GHashTable* notifyhash;
795 notifyhash = pIface->getNotifyHash();
799 RDK_LOG(RDK_LOG_ERROR,LOG_TR69HOSTIF,
"[%s:%s] Unable to get Device MoCA Client Instance\n", __FUNCTION__, __FILE__);
803 if(NULL != notifyhash)
805 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] NotifyHash is available before Ghash iterator \n", __FILE__, __FUNCTION__ );
806 GHashTableIter notifyHashIterator;
808 gpointer notifyEnable;
810 const char *pSetting;
812 const char *positionAfterSubInstanceNumber = 0;
813 const char *positionAfterInstanceNumber = 0;
814 g_hash_table_iter_init (¬ifyHashIterator, notifyhash);
815 while (g_hash_table_iter_next (¬ifyHashIterator, ¶mName, ¬ifyEnable))
817 int* isNotifyEnabled = (
int *)notifyEnable;
819 if(matchComponent((
const char*)paramName,
"Device.MoCA.Interface",&pSetting,instanceNumber))
821 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface matched n pSetting is: [%s] and instance Number [%d] \n", __FILE__, __FUNCTION__,pSetting,instanceNumber);
831 char *buff =(
char*)malloc(strlen(pSetting)+1);
833 rc=strcpy_s(buff,(strlen(pSetting)+1),pSetting);
838 int subInstanceNumber;
839 const char *pSubSetting = (
char*)malloc(strlen(pSetting)+1);
840 if(matchComponent((
const char*)buff,
"QoS.FlowStats",&pSubSetting,subInstanceNumber))
842 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface.%d.QoS.FlowStats matched n pSubSetting is: [%s] and subInstanceNumber [%d] \n", __FILE__, __FUNCTION__,instanceNumber,pSubSetting,subInstanceNumber);
844 memset(&msgData,subInstanceNumber,
sizeof(msgData));
846 if(strcasecmp(pSubSetting,
"FlowID")==0)
848 pIfaceQoSFS->
get_FlowID(&msgData,subInstanceNumber,&bChanged);
851 if(mUpdateCallback && (*isNotifyEnabled == 1))
857 else if(strcasecmp(pSubSetting,
"PacketDA")==0)
859 pIfaceQoSFS->
get_PacketDA(&msgData,subInstanceNumber,&bChanged);
862 if(mUpdateCallback && (*isNotifyEnabled == 1))
868 else if(strcasecmp(pSubSetting,
"MaxRate")==0)
870 pIfaceQoSFS->
get_MaxRate(&msgData,subInstanceNumber,&bChanged);
873 if(mUpdateCallback && (*isNotifyEnabled == 1))
879 else if(strcasecmp(pSubSetting,
"MaxBurstSize")==0)
884 if(mUpdateCallback && (*isNotifyEnabled == 1))
890 else if(strcasecmp(pSubSetting,
"LeaseTime")==0)
892 pIfaceQoSFS->
get_LeaseTime(&msgData,subInstanceNumber,&bChanged);
895 if(mUpdateCallback && (*isNotifyEnabled == 1))
901 else if(strcasecmp(pSubSetting,
"LeaseTimeLeft")==0)
906 if(mUpdateCallback && (*isNotifyEnabled == 1))
912 else if(strcasecmp(pSubSetting,
"FlowPackets")==0)
917 if(mUpdateCallback && (*isNotifyEnabled == 1))
924 else if(matchComponent((
const char*)buff,
"AssociatedDevice",&pSubSetting,subInstanceNumber))
926 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface.%d.AssociatedDevice matched n subInstanceNumber is: [%d] and pSubSetting is [%s] \n", __FILE__, __FUNCTION__,instanceNumber,subInstanceNumber,pSubSetting);
928 memset(&msgData,0,
sizeof(msgData));
930 if(strcasecmp(pSubSetting,
"MACAddress")==0)
932 pIfaceAsstDev->
get_MACAddress(&msgData,subInstanceNumber,&bChanged);
935 if(mUpdateCallback && (*isNotifyEnabled == 1))
941 else if(strcasecmp(pSubSetting,
"NodeID")==0)
943 pIfaceAsstDev->
get_NodeID(&msgData,subInstanceNumber,&bChanged);
946 if(mUpdateCallback && (*isNotifyEnabled == 1))
952 else if(strcasecmp(pSubSetting,
"PreferredNC")==0)
957 if(mUpdateCallback && (*isNotifyEnabled == 1))
963 else if(strcasecmp(pSubSetting,
"HighestVersion")==0)
968 if(mUpdateCallback && (*isNotifyEnabled == 1))
974 else if(strcasecmp(pSubSetting,
"PHYTxRate")==0)
976 pIfaceAsstDev->
get_PHYTxRate(&msgData,subInstanceNumber,&bChanged);
979 if(mUpdateCallback && (*isNotifyEnabled == 1))
985 else if(strcasecmp(pSubSetting,
"PHYRxRate")==0)
987 pIfaceAsstDev->
get_PHYRxRate(&msgData,subInstanceNumber,&bChanged);
990 if(mUpdateCallback && (*isNotifyEnabled == 1))
996 else if(strcasecmp(pSubSetting,
"TxPowerControlReduction")==0)
1001 if(mUpdateCallback && (*isNotifyEnabled == 1))
1007 else if(strcasecmp(pSubSetting,
"RxPowerLevel")==0)
1012 if(mUpdateCallback && (*isNotifyEnabled == 1))
1018 else if(strcasecmp(pSubSetting,
"TxBcastRate")==0)
1023 if(mUpdateCallback && (*isNotifyEnabled == 1))
1029 else if(strcasecmp(pSubSetting,
"RxBcastPowerLevel")==0)
1034 if(mUpdateCallback && (*isNotifyEnabled == 1))
1040 else if(strcasecmp(pSubSetting,
"TxPackets")==0)
1042 pIfaceAsstDev->
get_TxPackets(&msgData,subInstanceNumber,&bChanged);
1045 if(mUpdateCallback && (*isNotifyEnabled == 1))
1051 else if(strcasecmp(pSubSetting,
"RxPackets")==0)
1053 pIfaceAsstDev->
get_RxPackets(&msgData,subInstanceNumber,&bChanged);
1056 if(mUpdateCallback && (*isNotifyEnabled == 1))
1062 else if(strcasecmp(pSubSetting,
"RxErroredAndMissedPackets")==0)
1067 if(mUpdateCallback && (*isNotifyEnabled == 1))
1073 else if(strcasecmp(pSubSetting,
"QAM256Capable")==0)
1078 if(mUpdateCallback && (*isNotifyEnabled == 1))
1084 else if(strcasecmp(pSubSetting,
"PacketAggregationCapability")==0)
1089 if(mUpdateCallback && (*isNotifyEnabled == 1))
1095 else if(strcasecmp(pSubSetting,
"RxSNR")==0)
1097 pIfaceAsstDev->
get_RxSNR(&msgData,subInstanceNumber,&bChanged);
1100 if(mUpdateCallback && (*isNotifyEnabled == 1))
1106 else if(strcasecmp(pSubSetting,
"Active")==0)
1108 pIfaceAsstDev->
get_Active(&msgData,subInstanceNumber,&bChanged);
1111 if(mUpdateCallback && (*isNotifyEnabled == 1))
1119 else if(strncmp(buff,
"Stats",5)==0)
1121 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface.%d.Stats matched pSetting is[%s] \n", __FILE__, __FUNCTION__,instanceNumber,pSetting);
1123 memset(&msgData,0,
sizeof(msgData));
1125 if(strcmp(buff,
"Stats.BytesSent")==0)
1130 if(mUpdateCallback && (*isNotifyEnabled == 1))
1136 else if (strcmp(buff,
"Stats.BytesReceived")==0)
1141 if(mUpdateCallback && (*isNotifyEnabled == 1))
1147 else if (strcmp(buff,
"Stats.PacketsSent")==0)
1152 if(mUpdateCallback && (*isNotifyEnabled == 1))
1158 else if (strcmp(buff,
"Stats.PacketsReceived")==0)
1163 if(mUpdateCallback && (*isNotifyEnabled == 1))
1169 else if (strcmp(buff,
"Stats.ErrorsSent")==0)
1174 if(mUpdateCallback && (*isNotifyEnabled == 1))
1180 else if (strcmp(buff,
"Stats.ErrorsReceived")==0)
1185 if(mUpdateCallback && (*isNotifyEnabled == 1))
1191 else if (strcmp(buff,
"Stats.UnicastPacketsSent")==0)
1196 if(mUpdateCallback && (*isNotifyEnabled == 1))
1202 else if (strcmp(buff,
"Stats.UnicastPacketsReceived")==0)
1207 if(mUpdateCallback && (*isNotifyEnabled == 1))
1213 else if (strcmp(buff,
"Stats.DiscardPacketsSent")==0)
1218 if(mUpdateCallback && (*isNotifyEnabled == 1))
1224 else if (strcmp(buff,
"Stats.DiscardPacketsReceived")==0)
1229 if(mUpdateCallback && (*isNotifyEnabled == 1))
1235 else if (strcmp(buff,
"Stats.MulticastPacketsSent")==0)
1240 if(mUpdateCallback && (*isNotifyEnabled == 1))
1246 else if (strcmp(buff,
"Stats.MulticastPacketsReceived")==0)
1251 if(mUpdateCallback && (*isNotifyEnabled == 1))
1257 else if (strcmp(buff,
"Stats.BroadcastPacketsSent")==0)
1262 if(mUpdateCallback && (*isNotifyEnabled == 1))
1268 else if (strcmp(buff,
"Stats.BroadcastPacketsReceived")==0)
1273 if(mUpdateCallback && (*isNotifyEnabled == 1))
1279 else if (strcmp(buff,
"Stats.UnknownProtoPacketsReceived")==0)
1284 if(mUpdateCallback && (*isNotifyEnabled == 1))
1291 else if(strncmp(buff,
"QoS",3)==0)
1293 RDK_LOG(RDK_LOG_DEBUG,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface.%d.QoS matched n pSetting is [%s] \n", __FILE__, __FUNCTION__,instanceNumber,pSetting);
1295 memset(&msgData,0,
sizeof(msgData));
1297 if(strcmp(buff,
"QoS.EgressNumFlows")==0)
1302 if(mUpdateCallback && (*isNotifyEnabled == 1))
1308 else if (strcmp(buff,
"QoS.IngressNumFlows")==0)
1313 if(mUpdateCallback && (*isNotifyEnabled == 1))
1319 else if (strcmp(buff,
"QoS.FlowStatsNumberOfEntries")==0)
1324 if(mUpdateCallback && (*isNotifyEnabled == 1))
1333 memset(&msgData,0,
sizeof(msgData));
1335 if(strcmp(pSetting,
"Enable")==0)
1337 mocaIface->get_Enable(&msgData,&bChanged);
1340 if(mUpdateCallback && (*isNotifyEnabled == 1))
1346 else if(strcmp(pSetting,
"Status")==0)
1348 mocaIface->get_Status(&msgData,&bChanged);
1351 if(mUpdateCallback && (*isNotifyEnabled == 1))
1357 else if(strcmp(pSetting,
"Alias")==0)
1359 mocaIface->get_Alias(&msgData,&bChanged);
1362 if(mUpdateCallback && (*isNotifyEnabled == 1))
1368 else if(strcmp(pSetting,
"Name")==0)
1370 mocaIface->get_Name(&msgData,&bChanged);
1373 if(mUpdateCallback && (*isNotifyEnabled == 1))
1379 else if(strcmp(pSetting,
"LastChange")==0)
1381 mocaIface->get_LastChange(&msgData,&bChanged);
1384 if(mUpdateCallback && (*isNotifyEnabled == 1))
1390 else if(strcmp(pSetting,
"LowerLayers")==0)
1392 mocaIface->get_LowerLayers(&msgData,&bChanged);
1395 if(mUpdateCallback && (*isNotifyEnabled == 1))
1401 else if(strcmp(pSetting,
"Upstream")==0)
1403 mocaIface->get_Upstream(&msgData,&bChanged);
1406 if(mUpdateCallback && (*isNotifyEnabled == 1))
1412 else if(strcmp(pSetting,
"MACAddress")==0)
1414 mocaIface->get_MACAddress(&msgData,&bChanged);
1417 if(mUpdateCallback && (*isNotifyEnabled == 1))
1423 else if(strcmp(pSetting,
"FirmwareVersion")==0)
1425 mocaIface->get_FirmwareVersion(&msgData,&bChanged);
1428 if(mUpdateCallback && (*isNotifyEnabled == 1))
1434 else if(strcmp(pSetting,
"MaxBitRate")==0)
1436 mocaIface->get_MaxBitRate(&msgData,&bChanged);
1439 if(mUpdateCallback && (*isNotifyEnabled == 1))
1445 else if(strcmp(pSetting,
"MaxIngressBW")==0)
1447 mocaIface->get_MaxIngressBW(&msgData,&bChanged);
1450 if(mUpdateCallback && (*isNotifyEnabled == 1))
1456 else if(strcmp(pSetting,
"MaxEgressBW")==0)
1458 mocaIface->get_MaxEgressBW(&msgData,&bChanged);
1461 if(mUpdateCallback && (*isNotifyEnabled == 1))
1467 else if(strcmp(pSetting,
"HighestVersion")==0)
1469 mocaIface->get_HighestVersion(&msgData,&bChanged);
1472 if(mUpdateCallback && (*isNotifyEnabled == 1))
1478 else if(strcmp(pSetting,
"CurrentVersion")==0)
1480 mocaIface->get_CurrentVersion(&msgData,&bChanged);
1483 if(mUpdateCallback && (*isNotifyEnabled == 1))
1489 else if(strcmp(pSetting,
"NetworkCoordinator")==0)
1491 mocaIface->get_NetworkCoordinator(&msgData,&bChanged);
1494 if(mUpdateCallback && (*isNotifyEnabled == 1))
1500 else if(strcmp(pSetting,
"NodeID")==0)
1502 mocaIface->get_NodeID(&msgData,&bChanged);
1505 if(mUpdateCallback && (*isNotifyEnabled == 1))
1511 else if(strcmp(pSetting,
"MaxNodes")==0)
1513 mocaIface->get_MaxNodes(&msgData,&bChanged);
1516 if(mUpdateCallback && (*isNotifyEnabled == 1))
1522 else if(strcmp(pSetting,
"PreferredNC")==0)
1524 mocaIface->get_PreferredNC(&msgData,&bChanged);
1527 if(mUpdateCallback && (*isNotifyEnabled == 1))
1533 else if(strcmp(pSetting,
"BackupNC")==0)
1535 mocaIface->get_BackupNC(&msgData,&bChanged);
1538 if(mUpdateCallback && (*isNotifyEnabled == 1))
1544 else if(strcmp(pSetting,
"PrivacyEnabledSetting")==0)
1546 mocaIface->get_PrivacyEnabledSetting(&msgData,&bChanged);
1549 if(mUpdateCallback && (*isNotifyEnabled == 1))
1555 else if(strcmp(pSetting,
"PrivacyEnabled")==0)
1557 mocaIface->get_PrivacyEnabled(&msgData,&bChanged);
1560 if(mUpdateCallback && (*isNotifyEnabled == 1))
1566 else if(strcmp(pSetting,
"FreqCapabilityMask")==0)
1568 mocaIface->get_FreqCapabilityMask(&msgData,&bChanged);
1572 if(mUpdateCallback && (*isNotifyEnabled == 1))
1579 else if(strcmp(pSetting,
"FreqCurrentMaskSetting")==0)
1581 mocaIface->get_FreqCurrentMaskSetting(&msgData,&bChanged);
1584 if(mUpdateCallback && (*isNotifyEnabled == 1))
1590 else if(strcmp(pSetting,
"FreqCurrentMask")==0)
1592 mocaIface->get_FreqCurrentMask(&msgData,&bChanged);
1595 if(mUpdateCallback && (*isNotifyEnabled == 1))
1601 else if(strcmp(pSetting,
"CurrentOperFreq")==0)
1603 mocaIface->get_CurrentOperFreq(&msgData,&bChanged);
1606 if(mUpdateCallback && (*isNotifyEnabled == 1))
1612 else if(strcmp(pSetting,
"LastOperFreq")==0)
1614 mocaIface->get_LastOperFreq(&msgData,&bChanged);
1617 if(mUpdateCallback && (*isNotifyEnabled == 1))
1623 else if(strcmp(pSetting,
"KeyPassphrase")==0)
1625 mocaIface->get_KeyPassphrase(&msgData,&bChanged);
1628 if(mUpdateCallback && (*isNotifyEnabled == 1))
1634 else if(strcmp(pSetting,
"TxPowerLimit")==0)
1636 mocaIface->get_TxPowerLimit(&msgData,&bChanged);
1639 if(mUpdateCallback && (*isNotifyEnabled == 1))
1645 else if(strcmp(pSetting,
"PowerCntlPhyTarget")==0)
1647 mocaIface->get_PowerCntlPhyTarget(&msgData,&bChanged);
1650 if(mUpdateCallback && (*isNotifyEnabled == 1))
1656 else if(strcmp(pSetting,
"BeaconPowerLimit")==0)
1658 mocaIface->get_BeaconPowerLimit(&msgData,&bChanged);
1661 if(mUpdateCallback && (*isNotifyEnabled == 1))
1667 else if(strcmp(pSetting,
"NetworkTabooMask")==0)
1669 mocaIface->get_NetworkTabooMask(&msgData,&bChanged);
1672 if(mUpdateCallback && (*isNotifyEnabled == 1))
1678 else if(strcmp(pSetting,
"NodeTabooMask")==0)
1680 mocaIface->get_NodeTabooMask(&msgData,&bChanged);
1683 if(mUpdateCallback && (*isNotifyEnabled == 1))
1689 else if(strcmp(pSetting,
"TxBcastRate")==0)
1691 mocaIface->get_TxBcastRate(&msgData,&bChanged);
1694 if(mUpdateCallback && (*isNotifyEnabled == 1))
1700 else if(strcmp(pSetting,
"TxBcastPowerReduction")==0)
1702 mocaIface->get_TxBcastPowerReduction(&msgData,&bChanged);
1705 if(mUpdateCallback && (*isNotifyEnabled == 1))
1711 else if(strcmp(pSetting,
"QAM256Capable")==0)
1713 mocaIface->get_QAM256Capable(&msgData,&bChanged);
1716 if(mUpdateCallback && (*isNotifyEnabled == 1))
1722 else if(strcmp(pSetting,
"PacketAggregationCapability")==0)
1724 mocaIface->get_PacketAggregationCapability(&msgData,&bChanged);
1727 if(mUpdateCallback && (*isNotifyEnabled == 1))
1738 RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface couldn't get mocaIface instance else of (mocaIface)\n",__FILE__, __FUNCTION__);
1744 RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,
"[%s:%s] Device.MoCA.Interface is NOT MATCHED \n",__FILE__, __FUNCTION__);
1750 RDK_LOG(RDK_LOG_INFO,LOG_TR69HOSTIF,
"[%s:%s] Couldn't get #####notifyhash###### instance \n", __FILE__, __FUNCTION__);
1754 MoCAInterface::releaseLock();