ipsec: fixed chaining ops after add footer and icv
In case there is no free space in first buffer for ICV and footer,
additional buffer will be added, but esp_encrypt will stay in single
buffer mode.
The issue happens for the following payload sizes:
- TCP packets with payload 1992
- ICMP packets with payload 2004
This fix moves the single/chained buffer ops selection to after
esp_add_footer_and_icv call.
Type: fix
Signed-off-by: Fan Zhang <[email protected]>
Signed-off-by: PiotrX Kleski <[email protected]>
Change-Id: Ic5ceba418f738933f96edb3e489ca2d149033b79