cxgb4/ch_ktls: fix call_kern.cocci warnings
Subsystems (3)
PATCH 1/1 cxgb4/ch_ktls: fix call_kern.cocci warnings
From: kernel test robot <[email protected]>
drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c:1592:22-32: ERROR: function chcr_end_part_handler called on line 1885 inside lock on line 1822 but uses GFP_KERNEL
Find functions that refer to GFP_KERNEL but are called with locks held.
Semantic patch information:
The proposed change of converting the GFP_KERNEL is not necessarily the correct one. It may be desired to unlock the lock, or to not call the function under the lock in the first place.
Generated by: scripts/coccinelle/locks/call_kern.cocci
---
Hello,
Please check on this. Normally, it relates to the call site of the function.
julia
url: https://github.com/0day-ci/linux/commits/Rohit-Maheshwari/cxgb4-ch_ktls-Fixes-in-nic-tls-code/20201023-133301 base: https://git.kernel.org/pub/scm/linux/kernel/git/davem/net.git 18ded910b589839e38a51623a179837ab4cc3789
:::::: branch date: 3 hours ago
:::::: commit date: 3 hours ago
Please take the patch only if it's a positive warning. Thanks!
chcr_ktls.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/chelsio/inline_crypto/ch_ktls/chcr_ktls.c +1 -1
@@ -1589,7 +1589,7 @@ static int chcr_end_part_handler(struct/* TAG needs to be calculated so, need to send complete record, * free the original skb and send a new one. */ - nskb =alloc_skb (0 ,GFP_KERNEL ); + nskb =alloc_skb (0 ,GFP_ATOMIC );if (!nskb) {dev_kfree_skb_any (skb);return NETDEV_TX_BUSY ;