xfrm: split the delete and free operations
The xfrm_state_delete is supposed to run atomically. On the other
hand, the deletion of the state from the hardware can't be done
atomically.
The destruction of xfrm_state is already separated to a 'delete'
operation, that removes the state from the data structures, and a
'free' operation. The free operation is called from a separate
garbage collection task.
By letting the offload device register on the free operation, we
give it an option to delete the state in non-atomic context.
Acked-by: Ilan Tayari <ilant@mellanox.com>
Signed-off-by: Guy Shapiro <guysh@mellanox.com>
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
2 files changed