From patchwork Sun Aug 9 07:29:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe JAILLET X-Patchwork-Id: 1342575 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=vger.kernel.org (client-ip=23.128.96.18; helo=vger.kernel.org; envelope-from=linux-tegra-owner@vger.kernel.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=wanadoo.fr Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by ozlabs.org (Postfix) with ESMTP id 4BPW2X51cZz9sRN for ; Sun, 9 Aug 2020 17:29:56 +1000 (AEST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726412AbgHIH3z (ORCPT ); Sun, 9 Aug 2020 03:29:55 -0400 Received: from smtp06.smtpout.orange.fr ([80.12.242.128]:48196 "EHLO smtp.smtpout.orange.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726097AbgHIH3z (ORCPT ); Sun, 9 Aug 2020 03:29:55 -0400 Received: from localhost.localdomain ([93.22.150.139]) by mwinf5d64 with ME id DKVq2300630hzCV03KVqWt; Sun, 09 Aug 2020 09:29:53 +0200 X-ME-Helo: localhost.localdomain X-ME-Auth: Y2hyaXN0b3BoZS5qYWlsbGV0QHdhbmFkb28uZnI= X-ME-Date: Sun, 09 Aug 2020 09:29:53 +0200 X-ME-IP: 93.22.150.139 From: Christophe JAILLET To: balbi@kernel.org, gregkh@linuxfoundation.org, thierry.reding@gmail.com, jonathanh@nvidia.com, nkristam@nvidia.com, yuehaibing@huawei.com, heikki.krogerus@linux.intel.com Cc: linux-usb@vger.kernel.org, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-janitors@vger.kernel.org, Christophe JAILLET Subject: [PATCH] usb: gadget: tegra-xudc: Avoid GFP_ATOMIC where it is not needed Date: Sun, 9 Aug 2020 09:29:48 +0200 Message-Id: <20200809072948.743269-1-christophe.jaillet@wanadoo.fr> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Sender: linux-tegra-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-tegra@vger.kernel.org There is no need to use GFP_ATOMIC here. It is a probe function, no spinlock is taken. Signed-off-by: Christophe JAILLET Acked-by: Thierry Reding Reviewed-by: JC Kuo --- drivers/usb/gadget/udc/tegra-xudc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/gadget/udc/tegra-xudc.c b/drivers/usb/gadget/udc/tegra-xudc.c index d6ff68c06911..9aa4815c1c59 100644 --- a/drivers/usb/gadget/udc/tegra-xudc.c +++ b/drivers/usb/gadget/udc/tegra-xudc.c @@ -3733,7 +3733,7 @@ static int tegra_xudc_probe(struct platform_device *pdev) unsigned int i; int err; - xudc = devm_kzalloc(&pdev->dev, sizeof(*xudc), GFP_ATOMIC); + xudc = devm_kzalloc(&pdev->dev, sizeof(*xudc), GFP_KERNEL); if (!xudc) return -ENOMEM;