]> git.baikalelectronics.ru Git - kernel.git/commit
xfrm: Indicate xfrm_state offload errors
authorIlan Tayari <ilant@mellanox.com>
Sun, 30 Apr 2017 13:51:19 +0000 (16:51 +0300)
committerDavid S. Miller <davem@davemloft.net>
Mon, 1 May 2017 18:59:39 +0000 (14:59 -0400)
commitf6385b94656713003f3fd259924afa42c3ef3dce
tree310ad3247951c8e65add607f5f938f27171e2e21
parent6737db4c894153bce5fa00a4c196273e4c7a7bd7
xfrm: Indicate xfrm_state offload errors

Current code silently ignores driver errors when configuring
IPSec offload xfrm_state, and falls back to host-based crypto.

Fail the xfrm_state creation if the driver has an error, because
the NIC offloading was explicitly requested by the user program.

This will communicate back to the user that there was an error.

Fixes: 2ed61e84269f ("xfrm: Add an IPsec hardware offloading API")
Signed-off-by: Ilan Tayari <ilant@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/xfrm/xfrm_user.c