s a packet addressed to a specific user, it checks its database to determine if the address is active. If it is, GGSN uses its PDP context (containing SGSN address for tunneling) to forward the packet to the relevant SGSN. If the address is not active, the data are discarded. GGSN collects charging information based on usage of network resources. The GGSN corresponds to the GMSC in circuit-switched operation. The main function of GGSN is to handle interactions with external data net- work. It acts as a router hiding the GPRS network from the external net- work, typically the Internet. GGSN updates the location of the MS according to the information from SGSNs and routes packets to and from the SGSN, which serves the destination MS. Within the GPRS network, PDUs or packets are encapsulated at the originating GSN (either SGSN or GGSN) and decapsulated at the destina- tion GSN. In between the GSNs, IP tunneling is used to transfer PDUs. This means that a user data packet is inserted into an IP packet, which con- tains the IP address of the destination GSN (see Section 6.6.4). The GGSN maintains routing information used to tunnel packets to the SGSN that is currently serving the destination MS. All GPRS user-related data, needed by the SGSN to perform the routing and data transfer functionality, are stored within the GR/HLR. 5.7.2.3 The BSC is upgraded with a PCU, which supports all GPRS protocols and controls and manages most of the radio-related functions of GPRS. It splits up long LLC frames into short RLC frames for ratio transmission. The PCU's function is to set up, supervise, and disconnect packet-switched calls. It also supports cell change, radio resource configuration, and channel assign- ment. The BTS is merely relay equipment without protocol functions and it performs the modulation, demodulation, and channel measurements. The PCU may be located anywhere between the SGSN and the BTS [3]. 5.7.2.4 Border Gateway (BG) The BG is not specified by GPRS specifications and PLMN operators have to define its functi