| 619 | } |
| 620 | |
| 621 | static void |
| 622 | create_aead_gph(uint32_t cryptlen, uint16_t ivlen, uint32_t authlen, |
| 623 | struct gphdr *gph) |
| 624 | { |
| 625 | int auth_only_len; |
| 626 | union { |
| 627 | struct { |
| 628 | #if RTE_BYTE_ORDER == RTE_BIG_ENDIAN |
| 629 | uint16_t iv_offset : 8; |
| 630 | uint16_t auth_offset : 8; |
| 631 | #else |
| 632 | uint16_t auth_offset : 8; |
| 633 | uint16_t iv_offset : 8; |
| 634 | #endif |
| 635 | }; |
| 636 | uint16_t value; |
| 637 | } param3; |
| 638 | |
| 639 | gph->param0 = rte_cpu_to_be_16(cryptlen); |
| 640 | gph->param1 = rte_cpu_to_be_16(authlen); |
| 641 | |
| 642 | auth_only_len = authlen - cryptlen; |
| 643 | gph->param2 = rte_cpu_to_be_16(ivlen + auth_only_len); |
| 644 | |
| 645 | param3.iv_offset = 0; |
| 646 | param3.auth_offset = ivlen; |
| 647 | gph->param3 = rte_cpu_to_be_16(param3.value); |
| 648 | } |
| 649 | |
| 650 | static int |
| 651 | process_cipher_auth_data(struct nitrox_softreq *sr) |
no outgoing calls
no test coverage detected