summaryrefslogtreecommitdiffstats
path: root/drivers/watchdog/sp5100_tco.c
diff options
context:
space:
mode:
authorJakub Kicinski <jakub.kicinski@netronome.com>2020-01-10 13:36:55 +0100
committerDavid S. Miller <davem@davemloft.net>2020-01-10 20:18:15 +0100
commit5c5d22a750d4bcf35e9539dccec397b0edcce176 (patch)
tree728fb2d0b6e72573d77d9c739c0915c29c3820eb /drivers/watchdog/sp5100_tco.c
parentMerge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/jkirshe... (diff)
downloadlinux-5c5d22a750d4bcf35e9539dccec397b0edcce176.tar.xz
linux-5c5d22a750d4bcf35e9539dccec397b0edcce176.zip
net/tls: avoid spurious decryption error with HW resync
When device loses sync mid way through a record - kernel has to re-encrypt the part of the record which the device already decrypted to be able to decrypt and authenticate the record in its entirety. The re-encryption piggy backs on the decryption routine, but obviously because the partially decrypted record can't be authenticated crypto API returns an error which is then ignored by tls_device_reencrypt(). Commit 5c5ec6685806 ("net/tls: add TlsDecryptError stat") added a statistic to count decryption errors, this statistic can't be incremented when we see the expected re-encryption error. Move the inc to the caller. Reported-and-tested-by: David Beckett <david.beckett@netronome.com> Fixes: 5c5ec6685806 ("net/tls: add TlsDecryptError stat") Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com> Reviewed-by: Simon Horman <simon.horman@netronome.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/watchdog/sp5100_tco.c')
0 files changed, 0 insertions, 0 deletions