FreeCalypso > hg > fc-magnetite
view src/g23m-aci/aci/psa_snds.c @ 685:3fb7384e820d
tpudrv12.h: FCDEV3B goes back to being itself
A while back we had the idea of a FreeCalypso modem family whereby our
current fcdev3b target would some day morph into fcmodem, with multiple
FC modem family products, potentially either triband or quadband, being
firmware-compatible with each other and with our original FCDEV3B. But
in light of the discovery of Tango modules that earlier idea is now being
withdrawn: instead the already existing Tango hw is being adopted into
our FreeCalypso family.
Tango cannot be firmware-compatible with triband OM/FCDEV3B targets
because the original quadband RFFE on Tango modules is wired in TI's
original Leonardo arrangement. Because this Leonardo/Tango way is now
becoming the official FreeCalypso way of driving quadband RFFEs thanks
to the adoption of Tango into our FC family, our earlier idea of
extending FIC's triband RFFE control signals with TSPACT5 no longer makes
much sense - we will probably never produce any new hardware with that
once-proposed arrangement. Therefore, that triband-or-quadband FCFAM
provision is being removed from the code base, and FCDEV3B goes back to
being treated the same way as CONFIG_TARGET_GTAMODEM for RFFE control
purposes.
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 24 Sep 2020 21:03:08 +0000 |
parents | 53929b40109c |
children |
line wrap: on
line source
/* +----------------------------------------------------------------------------- | Project : | Modul : +----------------------------------------------------------------------------- | Copyright 2002 Texas Instruments Berlin, AG | All rights reserved. | | This file is confidential and a trade secret of Texas | Instruments Berlin, AG | The receipt of or possession of this file does not convey | any rights to reproduce or disclose its contents or to | manufacture, use, or sell anything it may describe, in | whole, or in part, without the specific written consent of | Texas Instruments Berlin, AG. +----------------------------------------------------------------------------- | Purpose : This module defines the signalling functions of the | protocol stack adapter for the registration part of | the SNDCP entity. +----------------------------------------------------------------------------- */ #if defined (GPRS) && defined (DTI) #ifndef PSA_SNDS_C #define PSA_SNDS_C #endif #include "aci_all.h" /*==== INCLUDES ===================================================*/ #include "aci.h" #include "dti.h" /* functionality of the dti library */ #include "aci_cmh.h" #include "ati_cmd.h" #include "aci_cmd.h" #include "aci_mem.h" #include "aci.h" #include "dti_conn_mng.h" #include "dti_cntrl_mng.h" #include "gaci.h" #include "gaci_cmh.h" #include "psa.h" #include "psa_sm.h" #include "cmh.h" #include "cmh_sm.h" #if defined(FF_WAP) || defined(FF_GPF_TCPIP) #include "wap_aci.h" #include "psa_tcpip.h" #endif /*==== CONSTANTS ==================================================*/ /*==== TYPES ======================================================*/ /*==== EXPORT =====================================================*/ /*==== VARIABLES ==================================================*/ /*==== FUNCTIONS ==================================================*/ /* +-------------------------------------------------------------------+ | PROJECT : GPRS (8441) MODULE : PSA_SMS | | STATE : finished ROUTINE : psaSNDCP_Dti_Req | +-------------------------------------------------------------------+ PURPOSE : Request of setting or removing the DTI user plane.. */ GLOBAL void psa_sn_dti_req( T_DTI_CONN_LINK_ID link_id, T_DTI_ENTITY_ID peer, U8 dti_conn ) { T_PDP_CONTEXT_INTERNAL *p_pdp_context_node = pdp_context_find_node_from_cid(work_cids[cid_pointer]); /* Issue 27457 */ #ifdef _SIMULATION_ U8 *dti_neighbor = NULL; #endif #if defined (FF_WAP) || defined (FF_GPF_TCPIP) U8 cid = PDP_CONTEXT_CID_OMITTED; U8 nsapi; #endif U8 dti_direction = NAS_HOME; PALLOC (sn_dti_req, SN_DTI_REQ); TRACE_FUNCTION("psa_sn_dti_req()"); #ifdef _SIMULATION_ ACI_MALLOC(dti_neighbor, NAS_SIZE_ENTITY_NAME); #endif if (dti_conn EQ NAS_CONNECT_DTI) { switch ( peer ) { case DTI_ENTITY_PPPS: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), PPP_NAME); #else sn_dti_req->dti_neighbor = (ULONG)PPP_NAME; #endif dti_direction = NAS_HOME; p_pdp_context_node->internal_data.entity_id = peer; p_pdp_context_node->internal_data.link_id = link_id; break; #ifdef TI_DUAL_MODE case DTI_ENTITY_SNDCP: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), SNDCP_NAME); #else sn_dti_req->dti_neighbor = (ULONG)SNDCP_NAME; #endif dti_direction = NAS_HOME; break; #endif /* TI_DUAL_MODE */ #ifdef FF_TCP_IP case DTI_ENTITY_AAA: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), RIV_NAME); #else sn_dti_req->dti_neighbor = (ULONG)RIV_NAME; #endif dti_direction = NAS_NEIGHBOR; p_pdp_context_node->internal_data.entity_id = peer; p_pdp_context_node->internal_data.link_id = link_id; break; #endif /* FF_TCP_IP */ case DTI_ENTITY_IP: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), IP_NAME); #else sn_dti_req->dti_neighbor = (ULONG)IP_NAME; #endif dti_direction = NAS_NEIGHBOR; p_pdp_context_node->internal_data.link_id = link_id; break; case DTI_ENTITY_SIM: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), SIM_NAME); #else sn_dti_req->dti_neighbor = (ULONG)SIM_NAME; #endif dti_direction = NAS_NEIGHBOR; p_pdp_context_node->internal_data.link_id = link_id; break; case DTI_ENTITY_PKTIO: #ifdef _SIMULATION_ strcpy((char*)(dti_neighbor), PKTIO_NAME); #else sn_dti_req->dti_neighbor = (ULONG)PKTIO_NAME; #endif dti_direction = NAS_HOME; p_pdp_context_node->internal_data.entity_id = peer; p_pdp_context_node->internal_data.link_id = link_id; break; #ifdef FF_GPF_TCPIP case DTI_ENTITY_TCPIP: sn_dti_req->dti_neighbor = (ULONG)TCPIP_NAME; dti_direction = NAS_NEIGHBOR; break; #endif /* FF_GPF_TCPIP */ } /* Copy the neighbor name (incl. the zero termination). */ #ifdef _SIMULATION_ memcpy( &sn_dti_req->dti_neighbor, dti_neighbor, strlen((const char *)dti_neighbor) + 1 ); ACI_MFREE( dti_neighbor ); #endif sn_dti_req->dti_direction = dti_direction; sn_dti_req->dti_conn = NAS_CONNECT_DTI; } else /* if (dti_conn == SNDCP_CONNECT_DTI) */ { sn_dti_req->dti_conn = NAS_DISCONNECT_DTI; } sn_dti_req->dti_linkid = link_id; sn_dti_req->nsapi = (U8)CID_TO_NSAPI( gaci_get_cid_over_link_id( link_id ) ); #if defined (FF_WAP) || defined (FF_GPF_TCPIP) nsapi = sn_dti_req->nsapi; #endif PSEND(hCommSNDCP, sn_dti_req); #if defined (FF_WAP) || defined (FF_GPF_TCPIP) if ( (Wap_Call) AND (dti_conn EQ NAS_CONNECT_DTI) ) /* TC ACISAT 530 */ { cid = (U8)NSAPI_TO_CID( nsapi ); if ( (get_state_over_cid( cid ) EQ PDP_CONTEXT_STATE_DEFINED ) OR (get_state_over_cid( cid ) EQ PDP_CONTEXT_STATE_ATTACHING) OR (get_state_over_cid( cid ) EQ PDP_CONTEXT_STATE_DEACTIVATE_NORMAL) ) //// pinghua DCM_OPEN_CLOSE patch 20080429 start { cmhSM_activate_context(); } else if ( (get_state_over_cid( cid ) EQ PDP_CONTEXT_STATE_ACTIVATED)) { char c_ip_address[16]; UBYTE* ip_address; TRACE_EVENT("No PDP Context Found to Activate"); ip_address = p_pdp_context_node->internal_data.pdp_address_allocated.ip_address.ipv4_addr.a4; sprintf (c_ip_address, "%03u.%03u.%03u.%03u", ip_address[0], ip_address[1], ip_address[2], ip_address[3] ); psaTCPIP_Configure( NULL, (UBYTE*) c_ip_address, NULL, NULL, NULL, 1500, cmhSM_IP_activate_cb ); } } #endif /* FF_WAP */ } #endif /* GPRS */