Received: by 10.223.176.46 with SMTP id f43csp970195wra; Wed, 24 Jan 2018 08:37:13 -0800 (PST) X-Google-Smtp-Source: AH8x227AA8Wsse9C5xpeEaTwUaX0mejRYkHyKWysJkZr+zXLKC4ALaEl4VpODkTcw3Y+MLqnknpM X-Received: by 2002:a17:902:858c:: with SMTP id e12-v6mr4735297plo.237.1516811833843; Wed, 24 Jan 2018 08:37:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1516811833; cv=none; d=google.com; s=arc-20160816; b=eryP4TDYua2yxDxPNvLXVNOA4lQ1Xy4J5Y2EOQ87Jwc0kdmHxOLmrqv9mW/OKAfWs4 fFguRbzaeCZKo1GlEed49l07PPYTslEeU8isEBv7EzPa9ImHiTAoazCCeJzclpyxjNz+ Pr6f2VfaFyLdA1Dm3tg5i3dbc+x0sM/iJlqiY+/BTmlWvSlJwoIYcwcOobATt3ACsO7B 7rBz14d2GNiCPfRWla03PkgrgOq7wgK5qLLZZXTWCghe1JAnAhg8MT4yAuCL1y3hNCRh ADaN4zDcxC88pax0ihT7h28xOvVkbsBffkFVJM5aLTh2r+XNxt9DlSSgXyCI5B6TBRYW wm2Q== 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:in-reply-to:mime-version:user-agent:date :message-id:references:cc:to:from:subject:arc-authentication-results; bh=QQ5qp2zpaMdPuWyAMzRrzSMmrBzXw6zrGJ4sPdntkco=; b=jljX5GIMd7/JhkCWM10+M7wJMapNXzQLIhgCHU/xoQOzH8oKCuB9aSMjOUbjIuQjTq vnw8u4EcYIGG/oXyLuYH3bYO9o12snyrazS8+6YPK69Ihg8ridgjM+6TUJ8YRwIyfeyp eas3zLwjX6F+vTpjfKd4+gUuvvhzXk721LGIq9q9uJIxxbcIDIYfNKd0q1lyQC6U+JOq dOUUZONIrCa1eJBnd8JDeOOhEJivxdjLF/tT+yeySOWpqDyUV7Gjs1ipgZdB/523CLoS EDThyz4MS3hmYLD5nvUGwOv/wvunbaPqeOcB9GPmb67XDOxJwx8K8tUE5Mlk8BjBnl1M udjA== 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 q9si3126210pfk.189.2018.01.24.08.36.59; Wed, 24 Jan 2018 08:37:13 -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 S964903AbeAXQfA (ORCPT + 99 others); Wed, 24 Jan 2018 11:35:00 -0500 Received: from mout.web.de ([212.227.15.3]:61630 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964855AbeAXQey (ORCPT ); Wed, 24 Jan 2018 11:34:54 -0500 Received: from [192.168.1.2] ([77.181.242.198]) by smtp.web.de (mrweb001 [213.165.67.108]) with ESMTPSA (Nemesis) id 0MdLcJ-1eNgND1GbL-00ITuc; Wed, 24 Jan 2018 17:34:52 +0100 Subject: [PATCH 1/3] Input: apbps2: Delete an error message for a failed memory allocation in apbps2_of_probe() From: SF Markus Elfring To: linux-input@vger.kernel.org, Dmitry Torokhov Cc: LKML , kernel-janitors@vger.kernel.org References: <50013a33-b7ca-fce1-9769-bfe3db850a8a@users.sourceforge.net> Message-ID: Date: Wed, 24 Jan 2018 17:34:51 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: <50013a33-b7ca-fce1-9769-bfe3db850a8a@users.sourceforge.net> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K0:SC8qfQahCTQIUJRv2iO+vrF87DCntQtzRhvdl+DIZWJl7QkX8zH 3MM7DGzzUCh1MEF7NyNgqgXkDYq2BJ8OC+nY1hQzUKcDBv4qey/HPH3ujsnFLeY3x39t6OQ hkmM8+A/Una8Q11i8VRsyDhfXU+K1yAJS83oQmzvvQVBvtHcPWrb131uXjtsMdnLJeUwZ1E sx0o5gN/a6Ikto36WfZ7Q== X-UI-Out-Filterresults: notjunk:1;V01:K0:TTkCPDEYaqY=:WkT6g6peS5DQ4ZhjeWZf5e 3M3P5EiZmDjLvMFq9rt8EJn+eG9UXua+G6ZJPo7yM+xg4OgtfYQOm+3P5nO0mz+ffyOF+PPks /p1xB/YCHmovEYSFJS377B/bgAcbdDAAqJB4jTqLpl3fblE3qKI3GYmXmLVTy3YoOw20kM2Pi +t5HzZsY5HqpYRTqMmBDHXFHB6zaUy9D6d7ep3jzXBomSWG4icl/ind27B+7Cky/qqBD8APo+ tpFbdJtxbXKu0RbtgmqL6OgZNfobH9NY1BuWIRKuO1zVXMyYOL1thb15ga0GPkc9RFOqgVkhK i0bihdwu/J87g0fKAxuZkAhUi+V02B6dsIniYsFvlZ4LORhKLZHW44lGGb6e97+zyi/TglYIq 0W0/qbySLHmUJfaLWDX+DiJtFNHTMmIUi73EP6HDbgPh1MLOUnVx/wuJIHRwki1g5TbGtzyGk AtJaqi5zYiUSrIQ36jESOwuwv8HAOZvyI8mEpwqghZTvnr5S+Hm+bfApFggtjRdsxLoxkTawc lgqP288uLmY4M7lQPXyfcjtCdYTJlEhTF8WxHGiqWvIEl1VIIEHpUW4yEwwLztT98B7sOkBaO jdhJK72IQYviZ5BFxVs3VxhCy0VuFmdzr7KG9nLtsZ/6CAL+bTwOeTzMKwuZC1xPsrcZRzuOY v9VX2K0eMPoZt+Lkq0LrIyYrkjZRiigmT+7NIICKJHWje7toUFbj/SdcstRrT36TZo3OO4kNw ZM7UTJ8Np9r4hhVqmb/i7CPm66dNki5ZUlTa6Fa5fNxPZ8Zx/IqU207SsjVLzkOyJI6R9pRqy Dk98TPJHqt6zqhoHPjofGfNx2q9tGk3GSW3O/gXif/jgHjNiPs= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Markus Elfring Date: Wed, 24 Jan 2018 16:43:04 +0100 Omit an extra message for a memory allocation failure in this function. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring --- drivers/input/serio/apbps2.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/input/serio/apbps2.c b/drivers/input/serio/apbps2.c index 45d4e08ca4f8..9b75c4e1bc13 100644 --- a/drivers/input/serio/apbps2.c +++ b/drivers/input/serio/apbps2.c @@ -140,10 +140,8 @@ static int apbps2_of_probe(struct platform_device *ofdev) struct resource *res; priv = devm_kzalloc(&ofdev->dev, sizeof(*priv), GFP_KERNEL); - if (!priv) { - dev_err(&ofdev->dev, "memory allocation failed\n"); + if (!priv) return -ENOMEM; - } /* Find Device Address */ res = platform_get_resource(ofdev, IORESOURCE_MEM, 0); -- 2.16.1