Please check LTE security specification (33.401) to get more details on MAC-I calculation. There are parameters such as COUNT, BEARER ID, DIRECTION, MESSAGE are provided as input parameter to integrity algorithm along with the generated RRCint key and integrity function returns 32-bit MAC-I.