Hi Vakul,

On 7/19/2018 7:16 AM, Vakul Garg wrote:
Zero-copy mode was left enabled even when zerocopy_from_iter() failed.
Set the zero-copy mode only when zerocopy_from_iter() succeeds. This
leads to removal of argument 'zc' of function decrypt_skb_update().
Function decrypt_skb_update() does not need to check whether
ctx->decrypted is set since it is never called if ctx->decrypted is
true.


This patch breaks our tls_device code for the following 2 reasons:
1. We need to disable zerocopy if the device decrypted the record, because decrypted data has to be copied to user buffers. 2. ctx->decrypted must be checked in decrypt_skb_update, because it might change after calling tls_device_decrypted.

Reply via email to