--- sangam-atm-1.0.orig/dsl_hal_api.c 2007-03-07 04:13:06.000000000 +0100 +++ sangam-atm-1.0/dsl_hal_api.c 2009-12-17 19:39:11.092420102 +0100 @@ -254,15 +254,15 @@ * of phyEnableDisableWord & phyControlWord to avoid changing API struct * which may cause change required to application data structure. ******************************************************************************/ -#include -#include -#include +#include "dev_host_interface.h" +#include "dsl_hal_register.h" +#include "dsl_hal_support.h" #ifndef NO_ADV_STATS -#include +#include "dsl_hal_logtable.h" #endif -#include +#include "dsl_hal_version.h" // UR8_MERGE_START CQ11054 Jack Zhang static unsigned int highprecision_selected = 0; //By default we use low precision for backward compt. @@ -958,9 +958,6 @@ int dslhal_api_pollTrainingStatus(tidsl_ /*char *tmp;*/ DEV_HOST_dspOamSharedInterface_t *pdspOamSharedInterface, dspOamSharedInterface; -#if SWTC - DEV_HOST_tcHostCommDef_t TCHostCommDef; -#endif dgprintf(5,"dslhal_api_pollTrainingStatus\n"); pdspOamSharedInterface = (DEV_HOST_dspOamSharedInterface_t *) ptidsl->pmainAddr; @@ -971,17 +968,6 @@ int dslhal_api_pollTrainingStatus(tidsl_ dgprintf(1,"dslhal_support_blockRead failed\n"); return DSLHAL_ERROR_BLOCK_READ; } -#if SWTC - dspOamSharedInterface.tcHostComm_p =(DEV_HOST_tcHostCommDef_t *) dslhal_support_byteSwap32((unsigned int)dspOamSharedInterface.tcHostComm_p); - - rc = dslhal_support_blockRead((PVOID)dspOamSharedInterface.tcHostComm_p, - &TCHostCommDef, sizeof(DEV_HOST_tcHostCommDef_t)); - if (rc) - { - dgprintf(1,"dslhal_support_blockRead failed\n"); - return DSLHAL_ERROR_BLOCK_READ; - } -#endif rc = dslhal_support_processTrainingState(ptidsl); if(rc) @@ -1025,9 +1011,6 @@ int dslhal_api_handleTrainingInterrupt(t /*char *tmp;*/ DEV_HOST_dspOamSharedInterface_t *pdspOamSharedInterface, dspOamSharedInterface; -#if SWTC - DEV_HOST_tcHostCommDef_t TCHostCommDef; -#endif dgprintf(6,"dslhal_api_handleTrainingInterrupt\n"); pdspOamSharedInterface = (DEV_HOST_dspOamSharedInterface_t *) ptidsl->pmainAddr; rc = dslhal_support_blockRead(pdspOamSharedInterface, &dspOamSharedInterface, @@ -1037,17 +1020,6 @@ int dslhal_api_handleTrainingInterrupt(t dgprintf(1,"dslhal_support_blockRead failed\n"); return DSLHAL_ERROR_BLOCK_READ; } -#if SWTC - dspOamSharedInterface.tcHostComm_p =(DEV_HOST_tcHostCommDef_t *) dslhal_support_byteSwap32((unsigned int)dspOamSharedInterface.tcHostComm_p); - - rc = dslhal_support_blockRead((PVOID)dspOamSharedInterface.tcHostComm_p, - &TCHostCommDef, sizeof(DEV_HOST_tcHostCommDef_t)); - if (rc) - { - dgprintf(1,"dslhal_support_blockRead failed\n"); - return DSLHAL_ERROR_BLOCK_READ; - } -#endif if(intrSource & MASK_BITFIELD_INTERRUPTS) { @@ -1705,27 +1677,15 @@ void dslhal_api_gatherStatistics(tidsl_t /* Get ATM Stats for both US and DS for Channel 0*/ ptidsl->AppData.usAtm_count[0] = dslhal_support_byteSwap32(usAtmStats0.goodCount); ptidsl->AppData.usIdle_count[0] = dslhal_support_byteSwap32(usAtmStats0.idleCount); -#if SWTC - ptidsl->AppData.usPdu_count[0] = dslhal_support_byteSwap32(usAtmStats0.pduCount); -#endif ptidsl->AppData.dsGood_count[0] = dslhal_support_byteSwap32(dsAtmStats0.goodCount); ptidsl->AppData.dsIdle_count[0] = dslhal_support_byteSwap32(dsAtmStats0.idleCount); -#if SWTC - ptidsl->AppData.dsPdu_count[0] = dslhal_support_byteSwap32(dsAtmStats0.pduCount); -#endif ptidsl->AppData.dsBadHec_count[0] = dslhal_support_byteSwap32((dsAtmStats0.badHecCount)); ptidsl->AppData.dsOVFDrop_count[0] = dslhal_support_byteSwap32((dsAtmStats0.ovflwDropCount)); /* Get ATM Stats for both US and DS for Channel 1*/ ptidsl->AppData.usAtm_count[1] = dslhal_support_byteSwap32(usAtmStats1.goodCount); ptidsl->AppData.usIdle_count[1] = dslhal_support_byteSwap32(usAtmStats1.idleCount); -#if SWTC - ptidsl->AppData.usPdu_count[1] = dslhal_support_byteSwap32(usAtmStats1.pduCount); -#endif ptidsl->AppData.dsGood_count[1] = dslhal_support_byteSwap32(dsAtmStats1.goodCount); ptidsl->AppData.dsIdle_count[1] = dslhal_support_byteSwap32(dsAtmStats1.idleCount); -#if SWTC - ptidsl->AppData.dsPdu_count[1] = dslhal_support_byteSwap32(dsAtmStats1.pduCount); -#endif ptidsl->AppData.dsBadHec_count[1] = dslhal_support_byteSwap32((dsAtmStats1.badHecCount)); ptidsl->AppData.dsOVFDrop_count[1] = dslhal_support_byteSwap32((dsAtmStats1.ovflwDropCount));