From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wei Yongjun Subject: [PATCH] octeontx2-af: Use GFP_ATOMIC under spin lock Date: Thu, 25 Oct 2018 01:42:26 +0000 Message-ID: <1540431746-176759-1-git-send-email-weiyongjun1@huawei.com> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit Cc: Wei Yongjun , , To: Sunil Goutham , Linu Cherian , Geetha sowjanya , Jerin Jacob Return-path: Received: from szxga05-in.huawei.com ([45.249.212.191]:13690 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726204AbeJYKCe (ORCPT ); Thu, 25 Oct 2018 06:02:34 -0400 Sender: netdev-owner@vger.kernel.org List-ID: The function nix_update_mce_list() is called from nix_update_bcast_mce_list(), and a spin lock is held here, so we should use GFP_ATOMIC instead. Fixes: 4b05528ebf0c ("octeontx2-af: Update bcast list upon NIXLF alloc/free") Signed-off-by: Wei Yongjun --- drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c b/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c index 8890c95..a618e48 100644 --- a/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c +++ b/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c @@ -1294,7 +1294,7 @@ static int nix_update_mce_list(struct nix_mce_list *mce_list, return 0; /* Add a new one to the list, at the tail */ - mce = kzalloc(sizeof(*mce), GFP_KERNEL); + mce = kzalloc(sizeof(*mce), GFP_ATOMIC); if (!mce) return -ENOMEM; mce->idx = idx;