esp_input() and esp_output() allocated a cryptop from the crypto layer,
then malloc'ed the xform_data the callback needs, and with ESN a third
buffer for the separate AAD. The callback freed all three. That is
two or three allocation pairs for every packet.
Put the three in one structure, allocated once per packet from a
dedicated UMA zone. The crypto layer provides crypto_initreq() and
crypto_destroyreq() for an embedded cryptop, as wg(4) and ktls use.
The AAD buffer is sized for the ESP header, the longest IV and the
high-order half of the sequence number, which is all the separate AAD
can hold.
No functional change intended.
MFC after: 2 weeks
Sponsored by: Rubicon Communications, LLC ("Netgate")