LTE/IMS reference

            PDCP(Packet Data Convergence Protocol)



PDCP FUNCTION :
The main role of PDCP layer is-
Header Compression
In UMTS the only role of PDCP is header compression. But in LTE is look lot of jobs.

How PDCP does the Header Compression:-
How general compression happen? Taking “pattern”
If we have some data like-
101010101100001010101000011100010101011111001010010001010010011111100000011111100000000111000011111100
Assume that there are 2000 1&0 are there. How can we compressed? That is by finding out pattern.
For example,
100 bit pattern repeated for 20 times. What we do? We remove the 100 bits from everywhere from all 20 places. We put the 100 bit only in the header and in the header we note down where an all these are 100 bits are repeated. We note down the memory location of that where the pattern are repeated. Now, assume that we note down the memory location .For every memory we need 16 bits. So, header is containing that 100 bits + 20 memory location present i.e 20x16 bits. So total 100+320=420 bits. In original 100 bits in to 20 times means total 2000 bits. So 2000 bits have been decremented by 420 bits by noting down the repeated pattern and its positions in it header.
If we can find more and more pattern we can compress more because our file size or data size can reduce more.
But these kind of pattern and repetitions will happen a lot in data part.
But PDCP role is to compress IP header+ TCP header or IP header+ UDP header or may be IP header+ UDP header+ RTP header.
So, IP header minimum is 20 bytes.
       TCP header minimum is 20 bytes.
       UDP header minimum is 8
Header minimum byte.
       RTP is 12 bytes.

Supported header compression protocols

Why video  and pictures can not be compressed?

An Image generated by multiple pixels and every pixel is having different colour information. when we have a image which contains multiple pixels with different information and we never be able to find out the exact pattern. So, video or images cannot be compressed much. 

PDCP FUNCTION :-

CONTROL PLANE( NAS/RRC)
No compression/decompression because very less information is getting from RRC layer.
For NAS message the two level of ciphering/deciphering is happened. NAS itself means NAS won do the ciphering it and PDCP again ciphering it.
But for pure RRC message only PDCP will do the ciphering. This message will cipher only one.
(Why NAS message is cipher by two times?  Because there can be threat at between e-NB  to MME.)
Encryption for control plane message. Encryption means data is in to unknown format.  
Integrity protection is performed by PDCP layer for control plane messages.
USER PLANE( Application/SSLV3/TCP/IP)
Header compression/ decompression of IP header+ TCP header or IP header+ UDP header or may be IP header+ UDP header+ RTP header.
We are doing ciphering/deciphering of IP packet only at PDCP layer.
For application data presentation layer (SSLV3) will give end to end security.
Encryption for user plane message.
No integrity protection at PDCP level but user plane message integrity protection will be there but performed by RRC layer.

Common function of PDCP layer for user plane and control plane
Ciphering and deciphering is happened at the PDCP layer.
Reliability at the time of handovers will be done for control plane. Because in case of RRC, RRC will always working in only AM mode after connected state. Therefore reliability will always for control plane provided by PDCP that is useful at the time of handover.

But in case of user plane reliability will be provided for the application using AM mode.

PDCP layer/structure view :


When RLC is doing activity in either UM mode or AM mode then definitely PDCP doing activity but in order to configure RLC UM mode or AM mode that can be only after the RRC connection setup. At the time of RRC connection setup e-nodeB RRC is inform UE RRC that you configure your PDCP,RLC,MAC layer according to this configuration. Configuration will be done on that basis only it will work. Configuration is same on both the site.
So, ultimate point is mobile equipment can use common channel configuration whenever he want because he knows the common channel configuration. But we wanted to have or created to dedicated channel configuration that configuration must come from e-NB RRC. UM and AM mode are part of dedicated channels.
Now, PDCP even though it is working for UM mode or AM mode will do two different functions for this two layers.
For example, RLC is working in UM mode PDCP functions are different, when RLC is working in AM mode PDCP function are different. That means most of the PDCP activity will dependent on what mode RLC is working.

Why two layer  are must be linked with each other means why PDCP is working in two different RLC mode?  
The additional function that are present in AM mode. Additional function is PDCP maintaining sequence number in AM mode for taking care of reliability when he associated with RLC AM mode.
But RLC himself do the reliability why PDCP taking care of reliability?
RLC AM mode can maintain the reliability when mobile equipment in only one cell. When mobile equipment is moving from one cell to another cell, RLC context won’t be forwarded. So in the new cell RLC context will go back to the sequence no. zero(0). So, mobile equipment is moving or doing a handover RLC context is not getting to new e-NB. RLC cannot take care of reliability on its own. So, PDCP will take care for that because RLC context won’t get forwarded but PDCP context will get forwarded from one e-NB to another e-NB.
But why we send PDCP context, why not RLC at the time of handover?  
When PDCP send the data to RLC. RLC can divide the data into three pieces. RLC already sent one piece to the old e-NB. If  he send the next two pieces in to new e-NB(other cell). We have to combine one piece of data which is receive at old e-NB(old cell) another two pieces data received by the another e-NB(other cell).combine it and send the S-Gateway but who has to do this jobs?
RLC main duty is segmentation and concatenation of PDCP packet depending on MAC layer asking.
 So, can RLC combine the data from one e-NB and another data from other e-NB? RLC can’t do this jobs. So, instead of that we have to go for PDCP packet.
So, complete PDCP packet need to be forwarded to e-NB to mobile (downlink) or mobile to e-NB (uplink).
So, When RLC is in AM mode PDCP will give reliability but when RLC is in UM mode PDCP will not give reliability. When RLC in TM mode no PDCP (transparent).

The Packet Data Convergence Protocol supports the following functions:-
PDCP function:
Header compression and decompression of IP data flows using the ROHC protocol.
-  Transfer of data (user plane or control plane).
-  Maintenance of PDCP SNs.
-  In-sequence delivery of upper layer PDUs at re-establishment of lower layers à Handover
-  Duplicate elimination of lower layer SDUs at re-establishment of lower layers for radio bearers mapped on RLC AM.
Ciphering and deciphering of user plane data and control plane data.
-  Integrity protection and integrity verification of control plane data.
-  Timer based discard.
-  Duplicate discarding.

Explanation-
- When duplicate happen, assume that RLC have divided PDCP packets in to 10 pieces. Sent all the 10 pieces successfully to e-NB RLC. e-NB RLC got to know that this is the last piece till then he has to done reassembly and send the data to PDCP also but RLC have generated acknowledgement  sent that acknowledgement to mobile phone but before sending the acknowledgement to mobile, mobile move to another e-NB .So mobile did not received acknowledgement part. So what RLC will think? Because ack is not received, he think PDCP packet is not successfully sent to the other site. Once mobile goes to the new cell, he will start sending the PDCP packet entirely once again, because we are not maintaining the RLC SN when mobile goes to new cell. So whatever SN is maintaining previously in old cell by RLC that will be reset when mobile goes to new cell. So same PDCP packet can be transmitted twice that possibility is there but who has to identify that this is a duplicate. If RLC maintain the SN then he identify the duplicate packet but in this case PDCP is maintaining the SN, so PDCP identify the duplicate packet and he discard the packet.
- As soon as application generates some data .send it to PDCP layer.
 The sending PDCP layer will start the sending PDCP packet to RLC layer but it will started the timer along with it. Within the timer PDCP successfully sent the data to other site. But if it is taking lot of time for RLC to transmit the data then PDCP discard the packet.  

Handover-
Handover is performed when the UE moves from the coverage of one cell to the coverage of another cell.
ØSeamless Handover
ØLossless Handover


  
 









Integrity Protection-
Integrity protection done for control plane produce by RRC.
If we want to do integrity protection what is mandatory?
Something called as count value. So one of the parameter needed for integrity protection is count value.
But this count value is directly dependent on sequence number (SN) means PDCP SN in RLC AM mode.
So, if we have integrity protection for RRC messages, RRC should be working in AM mode.
Now what is count and what is SN?
PDCP count ------> is 32 bit value.
Now we won’t be sending the count value from one PDCP entity to other PDCP entity. So, only SN. So, SN will help getting to count value.
What is meaning of count? When PDCP is sending 10 packets the count value increases start from 1, will increment up to 10.But the whole concept theory is that we won’t  be sending the complete count value because if we send the count value i.e  32 bit big count value. One of the main advantage is PDCP is compressing header, we want to decrease the header sizes.
So, instead of count we will send SN. Normally SN starting portion of count.
For example, let us take SN is 5bit. So, what are the possible value we can have i.e ‘31’. We can start with ‘0’ up to ‘31’. So
SN is only be cycling between ‘0’ to ‘31’. But count value will never stop.
So, first time when we see, SN and count value will be same but SN is complete one round, will go back to zero (0). But count value will incrementing. Count will not a cycling parameter.
So, PDCP count value ----> 32 bit
SN is the starting portion of count (5 bit) ---> 0 to 31

So, count value is very important parameter for doing either ciphering or integrity protection but count value will maintain both sender and receiver.

The property of Hyper Frame Number (HFN) is ---->HFN will incremented by ‘1’ after PDCP SN is circled once.

The size of the HFN part in bits is equal to 32 minus the length of the PDCP SN (5bits/7bits 12 bits).

How integrity protection is done
For integrity protection there many parameter-
1) Count
2) Direction(uplink or downlink)
3) Radio bearer id
4) Integrity key
5) Messages  
6) Algorithm  


PDCP calculates MAC-I (Message Authentication Code for integrity protection) for RRC messages by using an algorithm by passing many input to it.
So, totally 5 input we are passing to algorithm but the twist is when we are sending the information from mobile equipment to
e-NB, we won’t be sending none of these information. Mobile and e-NB both having own integrity key. Similarly count value also.
So, when we are sending the PDCP message to e-NB, we send the PDCP message + MAC-I   to the other site.
Other guy received it, now other guy need to validate weather MAC-I is correct or not.
Other guy also maintaining count value, direction, radio bearer id, integrity key and he also know what the message he has received is.
So, e-NB also try to calculates the MAC-I. He will try to match this two MAC-I (One is received from mobile and other is own MAC-I). If both the MAC-I are matching, then message is perfect. There is no problem in the message. 

Ciphering-
For ciphering also many input will be taken.
1) Count value
2) Direction
3) RB ID
4) Ciphering key
5) Message
6) Ciphering algorithm

This 4 input is send to a ciphering algorithm. He will generate a ciphering stream.
So, we take this ciphering stream and do an X-OR operation with the message. That will actually form ciphered data.
If somebody want to decipher this data, they need ciphering stream. This ciphered data is send to the enodeB.
Example-
UE
Message    -------------> 10101001010010100001
Ciphering stream-----> 01010010010010010010
                                       -------------------------------------
                   X-OR-------> 11111011000000110011 (Ciphered data)

But how to decipher the data.
e-nodeB
Ciphered data--------> 11111011000000110011
Ciphering stream ---> 01010010010010010010
                                    ------------------------------------
                  X-OR------> 10101001010010100001 (Message)

So, both mobile and e-NB having same input like – count value, direction, radio bearer id and ciphering key.


PDCP has two type of information –
------> PDCP data PDUs
------> PDCP control PDUs

Data means anything is coming from higher layer that is RRC information or IP packets.
Everything will be consider data for PDCP.
Control means PDCP own control packets. Means PDCP sending the status report and ROHC feedback.
Status means what packet are received and what packet are missing.
The main duty ROHC is to help compression and decompression. UE site will done ROHC compression, e-NB site it must be decompressed. If decompressed is successful he will send a positive feedback but decompressed is failure then send negative feedback to the other guy such that other guy retransmit the data once again.
Control plane PDCP data PDU (RRC messages)  
Control plane PDCP means it is RRC messages.
Control PDCP means it is PDCP own control information (status report and ROHC feedback).
















User plane PDCP data PDU with long PDCP SN(12 bits)-


---->User plane PDCP data means IP packets.
No integrity protection but ciphering/deciphering, Compression/decompression is there.
D/C is set to ‘1’

User plane PDCP data PDU with short PDCP SN(7 bits):-


-------->D/C is set to ‘1’ and followed by 7 bit SN.


PDCP control PDU for interspersed ROHC feedback packet-







---------> Control PDU are two types. One is ROHC feedback and second one is PDCP status report.
D/C is set to ‘0’ meaning is control packet but we have to tell whether it is ROHC feedback packet or it is PDCP status packet. That is explain by PDU type. So, PDU type will tell whether it is feedback packet or status packet.
D/C ------> 1 bit length.
Control PDU
Data PDU

PDU type----> 3 bits length
                000- PDCP status report
                001- Interspersed ROHC feedback packet
                010-111 – Reserved
FMS -----> Length 12 bits.
                 PDCP SN of the first missing PDCP SDU.

Bitmap ----> length – Variable





PDCP control PDU for PDCP status report-


---------> D/C is set to ‘0’ because it is control PDU.
---------> PDU type is ‘000’ because status report
---------> FMS means this is first sequence no.
----------> Bit map means we have sent totally 32 PDCP packets starting from SN ‘1’.Each bit represent 1 SN. If sequence no. one packet is received successfully bit map will be ‘1’.else bit map will be ‘0’.   
Example:
Assume that PDCP sent 32 packets to the other side. Out of 32 packets 7,14, 15, 19, 25,31 are missing. So, how receiver guy send the status report ? 

  























Reviewed by LTE/IMS reference on March 12, 2018 Rating: 5

No comments:

Powered by Blogger.