Received: by 10.223.176.5 with SMTP id f5csp2193673wra; Thu, 8 Feb 2018 09:53:55 -0800 (PST) X-Google-Smtp-Source: AH8x227/in3XN/K1CJyn5xcYfIjpAKeXSF6//hjpIRSlbzTW9TXcMIZWYEvsvlE9LlfODSet22Gl X-Received: by 2002:a17:902:8284:: with SMTP id y4-v6mr16127pln.194.1518112435036; Thu, 08 Feb 2018 09:53:55 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518112435; cv=none; d=google.com; s=arc-20160816; b=bvySLf0Jd2nq1y1YuG0VlOz6stAmdiOlWH3JBaU6T4hANTl3VFlYRAHjLr8fuaIy1B OBOX+F6I5oG68kUliJyi8mGD1jxzehj5y09NUKj18sT4asfM4Lpp7WcauacLPldNV/4T qj36z+VExR4sPyopF3eYt86BnCZTESiZFlhFZj4hX1TqBy4CuAkQBjkoWe0p8ljv1A1t 0aMDu4YtCk+YvJTcpaFqBvresTtIcAm0NuEh78OsD7x+vS7asoqti30Ok0aqTNIySLrv 9apPaaePxcRle3/Ttl42/EvS2K8QzhMunfXhnEffpI1os5PjbBRdLmbG2/n2slf4aNLM SOXA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:mime-version:user-agent:date:message-id:subject :from:cc:to:arc-authentication-results; bh=74DTapTGTNhNtGNu1oWliVPpnEMNL+zKQET409cYPzA=; b=Ag8a8gpgS07OrbqYPHH9eFE5wM8QRo8vQOahExG4DV8W6ogdTZweA8ctcz9Y09yC8r WguSMJ3niWDLXmXr6KcfUvMgKKTSW5618u4O8vrBjFvAbF5eNhcAcbL3O+/Z/RkjbbZH Mqeity7B5u094p8eUHiLv8HugD/UMcxygQWjETRd0lt9zsp0Iie2Di948Rc67Ss3Xhcb pm5IW9PAl/Vih8kYicWqWMQxaXllv0dT5pXF8sV7lReSZyVmCXcEBszDwHKqSiqbG2xd mX/sseG64xsVajq8ViOO8GEf82KrFv3z2EFd/uzjEMxvn2zbfUE/fzbQe2/Anwv3CTQ5 Q2Tw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=sourceforge.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e16-v6si265157pli.776.2018.02.08.09.53.40; Thu, 08 Feb 2018 09:53:55 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=sourceforge.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752361AbeBHRww (ORCPT + 99 others); Thu, 8 Feb 2018 12:52:52 -0500 Received: from mout.web.de ([212.227.15.3]:44531 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752229AbeBHRwr (ORCPT ); Thu, 8 Feb 2018 12:52:47 -0500 Received: from [192.168.1.2] ([78.49.237.151]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0Lzate-1eom4n420A-014kpr; Thu, 08 Feb 2018 18:52:12 +0100 To: dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, David Airlie , Inki Dae , Joonyoung Shim , Krzysztof Kozlowski , Kukjin Kim , Kyungmin Park , Seung-Woo Kim Cc: LKML , kernel-janitors@vger.kernel.org From: SF Markus Elfring Subject: [PATCH] drm/exynos: g2d: Delete an error message for a failed memory allocation in two functions Message-ID: Date: Thu, 8 Feb 2018 18:52:07 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Provags-ID: V03:K0:fQYMOc3XEJUDVzV3IYQC5KePaeztR3A9CeJ5xwfR8QYcsUf5ubr si67bxJUAE1g02ByDLLozjpG90N8u+/FIasO01cu4u3tBbbirpD8apFoGMvnkWsVkvPrxR3 RDJbMvrcBOJ5Z182EYl1vLnm+FqctmlooFZliTHKH2ADECjNFiEDbtozETyKofx2sNYu2R6 m5KqTqQ0RZ4NfYe6hB5tA== X-UI-Out-Filterresults: notjunk:1;V01:K0:OTx37NLgaGY=:cBTEvtLvVMUdASe6FLOUq0 X7Dn4eoEixOD/iUgFrfMEODlvYJf923xpz12StOlFsh0EtStGsN/3hmC3eCNPA6C4nwuPYsQS FtfOqnyrKeZ19L8P5G2cP3TiwJBL8P3GJgU2FNqpeY/ijS0c/i8yxsRGu07HoXs3v/51pzZqi RGJPh/XnKBmf5Uqla/54F/70GwiQWfSdC6crRdADJ5N98QQhxrkmBEkWgy4m0H00TDyaOMG0G ROs6RLRWSGK2mXUR/7J4BzD9ks0U/qKtPl5jIZuJbPmj/g0shlIQwls+k8bI9yCm3ij1ksmp5 NMZw43/RaSedpiCRduL/W2SN4tSNKoqBFWwqPzTyX3+9BV3uPs6g7OERfWd9ZdFHC24myyxCl gGOLTU6l9aTuvMaL8O63W7onISBDBAo7dm0keOp9f2nSENl7u1/b8le9JBEUhFgBe6PckVbRO lbxYxnwmsz8qNncMFcwM/OpO0YczcwQOBkAdbjzIgs6ukcFsBwbKOS7LcyXGanAdkuDA8TTyQ 9AFdZ7nQ8NRLK2Qudl+PlqxhkiBlYqllzxG6iZ+boFg9RBJBaVZBh2ioP7huAnOoEstye6l0A RXY/+CZfWMVAr2xAPvOMkuNDmadOPgYEubNSA+G9oeplgnZJH8bk+vaDVHnZj/V4BhG9pb6ra ansy7+G7UJxromUq4cyWXArKtku3vrCZXCzhK8YQKwFQA1H2YZkTrliMu0eU6X/N/Byqe7IhC svVWncEjGyfgjwyajIrwKNNKYYzlONqiNO3rQgg/brW8thXDcy9QhCCKz+opjAcMvU6fZ6r9J JfkbqCaPqYPcP8P3asnMO65YO3VkXxNpazLKwIBRe83zDPoUOM= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Markus Elfring Date: Thu, 8 Feb 2018 18:42:51 +0100 Omit an extra message for a memory allocation failure in these functions. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring --- drivers/gpu/drm/exynos/exynos_drm_g2d.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_g2d.c b/drivers/gpu/drm/exynos/exynos_drm_g2d.c index 2b8bf2dd6387..5eb0d3292525 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_g2d.c +++ b/drivers/gpu/drm/exynos/exynos_drm_g2d.c @@ -286,7 +286,6 @@ static int g2d_init_cmdlist(struct g2d_data *g2d) node = kcalloc(G2D_CMDLIST_NUM, sizeof(*node), GFP_KERNEL); if (!node) { - dev_err(dev, "failed to allocate memory\n"); ret = -ENOMEM; goto err; } @@ -1358,10 +1357,9 @@ int exynos_g2d_exec_ioctl(struct drm_device *drm_dev, void *data, return -EFAULT; runqueue_node = kmem_cache_alloc(g2d->runqueue_slab, GFP_KERNEL); - if (!runqueue_node) { - dev_err(dev, "failed to allocate memory\n"); + if (!runqueue_node) return -ENOMEM; - } + run_cmdlist = &runqueue_node->run_cmdlist; event_list = &runqueue_node->event_list; INIT_LIST_HEAD(run_cmdlist); -- 2.16.1