RLCMAC: Add Rlcmac{Ul,Dl}Block unions to cover both Control + Data blocks
This commit is contained in:
parent
cf28881687
commit
efbc2fca24
|
@ -87,7 +87,7 @@ module RLCMAC_Types {
|
|||
with { extension "prototype(convert) decode(RAW)" };
|
||||
|
||||
type record UlMacCtrlHeader {
|
||||
MacPayloadType pt,
|
||||
MacPayloadType payload_type,
|
||||
BIT5 spare,
|
||||
boolean retry
|
||||
} with { variant (retry) "FIELDLENGTH(1)" };
|
||||
|
@ -152,7 +152,7 @@ module RLCMAC_Types {
|
|||
/* TS 44.060 10.2.2 */
|
||||
type record UlMacDataHeader {
|
||||
/* Octet 0 */
|
||||
MacPayloadType pt,
|
||||
MacPayloadType payload_type,
|
||||
uint4_t countdown,
|
||||
boolean stall_ind,
|
||||
boolean retry,
|
||||
|
@ -195,4 +195,32 @@ module RLCMAC_Types {
|
|||
external function enc_RlcmacUlDataBlock(in RlcmacUlDataBlock si) return octetstring;
|
||||
external function dec_RlcmacUlDataBlock(in octetstring stream) return RlcmacUlDataBlock;
|
||||
|
||||
type union RlcmacUlBlock {
|
||||
RlcmacUlDataBlock data,
|
||||
RlcmacUlCtrlBlock ctrl
|
||||
} with {
|
||||
variant "TAG(data, mac_hdr.payload_type = MAC_PT_RLC_DATA;
|
||||
ctrl, mac_hdr.payload_type = MAC_PT_RLCMAC_NO_OPT;
|
||||
ctrl, mac_hdr.payload_type = MAC_PT_RLCMAC_OPT)"
|
||||
};
|
||||
|
||||
external function enc_RlcmacUlBlock(in RlcmacUlBlock si) return octetstring
|
||||
with { extension "prototype(convert) encode(RAW)" };
|
||||
external function dec_RlcmacUlBlock(in octetstring stream) return RlcmacUlBlock
|
||||
with { extension "prototype(convert) decode(RAW)" };
|
||||
|
||||
type union RlcmacDlBlock {
|
||||
RlcmacDlDataBlock data,
|
||||
RlcmacDlCtrlBlock ctrl
|
||||
} with {
|
||||
variant "TAG(data, mac_hdr.mac_hdr.payload_type = MAC_PT_RLC_DATA;
|
||||
ctrl, mac_hdr.payload_type = MAC_PT_RLCMAC_NO_OPT;
|
||||
ctrl, mac_hdr.payload_type = MAC_PT_RLCMAC_OPT)"
|
||||
};
|
||||
|
||||
external function enc_RlcmacDlBlock(in RlcmacDlBlock si) return octetstring
|
||||
with { extension "prototype(convert) encode(RAW)" };
|
||||
external function dec_RlcmacDlBlock(in octetstring stream) return RlcmacDlBlock
|
||||
with { extension "prototype(convert) decode(RAW)" };
|
||||
|
||||
} with { encode "RAW"; variant "FIELDORDER(msb)" }
|
||||
|
|
Loading…
Reference in New Issue