Decoding packet layers