From patchwork Wed Feb 14 20:42:26 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: SF Markus Elfring X-Patchwork-Id: 10219967 X-Patchwork-Delegate: herbert@gondor.apana.org.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CFA0E6055C for ; Wed, 14 Feb 2018 20:42:40 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BF3A724603 for ; Wed, 14 Feb 2018 20:42:40 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B352E27F8F; Wed, 14 Feb 2018 20:42:40 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 565EA24603 for ; Wed, 14 Feb 2018 20:42:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935300AbeBNUmj (ORCPT ); Wed, 14 Feb 2018 15:42:39 -0500 Received: from mout.web.de ([212.227.15.14]:33135 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932096AbeBNUmh (ORCPT ); Wed, 14 Feb 2018 15:42:37 -0500 Received: from [192.168.1.2] ([78.48.82.239]) by smtp.web.de (mrweb004 [213.165.67.108]) with ESMTPSA (Nemesis) id 0MDByG-1f0MgK2MrU-00GZPd; Wed, 14 Feb 2018 21:42:28 +0100 To: linux-crypto@vger.kernel.org, "David S. Miller" , Herbert Xu Cc: LKML , kernel-janitors@vger.kernel.org From: SF Markus Elfring Subject: [PATCH] crypto: bfin_crc: Delete an error message for a failed memory allocation in bfin_crypto_crc_probe() Message-ID: <1601995f-79fd-8365-5dd3-4438a3515c28@users.sourceforge.net> Date: Wed, 14 Feb 2018 21:42:26 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.6.0 MIME-Version: 1.0 Content-Language: en-US X-Provags-ID: V03:K0:JGbZ+Uw0/DP+vg7B39YPuPEEqCIHddZX8yAPjyJxFzF6by15Y2P xwzoUGvpWOKVU34PrScSTc6u7eVG4aG+w3Lhz1jSr0lOPROWJAqExi6aHdNwMqNIm+yBLub pnaKmQW6ixXrrPMWRWQeml9LCklCX+OP6JUUS6jaVPYEXg7B3luAIeW27+a8q+05eiMpMIp doFlZ1JseASNE3mCjN9gQ== X-UI-Out-Filterresults: notjunk:1; V01:K0:eYFTa0TV+e0=:0as+uoTIpc0NUJULbJIjbT C1iGKbZV1iz17oDJfPAABDUNhf5MRZ08xojHyYyqptLbPu9eHnK6gXm5vzx3kGCTkEg7yFokw /AAcpul+RC2PSmutRpQkk+K0dTWDH6i+mjZqSj98t77tnMbW/m1Is3M55YaYDryRz6sAShkEm GTnX8U8gAlkdwtDQrwK7Rx4wnAZnJYJD6Bjg0FMPZjyBA+T+6TabUtP9p7CYdqKEMCC5WLTVk 5fRCk2yF8dCNNkpNDPvDgJVcdUy79sTyoxjhLXrOn8xh8G5EF2NeN55vxVUEQTIN/VQpjz/K5 jbjZ8xUk2gXPJdgXADrAFtA24d79WmaPnPQdJvMOP+8uO7unAuq7IEdaIWatiqjmARCwHWyzS DZIZpdCOCHaLG16EqSLy9on3qeqGfTUIkvLAKuNtiUG3X5V+zPGUCq6/bQyRdwAoyQ/fG7VMv JqgYzAqQWRMfXAHnOhiX+jZoc0GgmI7ji9tjEXJi8LiSHEjieTWHbicbnQraxEi7UPqFSJ/bE FSv6HdKeZNSa6lBE4A11z3f8rs7OoVFniBjIR1IrdPzAL/WvkEXIXgoe0h2NnPs3bO1WlHMWr DX6zddluGAscIK7rCrg5XvEcBusKcuurvqIoq+YWzdwB3ANnPSSm0zxIzL935tuaLPCTlFsev +idBVL+vTgXFSxORPupNCOK/rtt/g55hUHyp5D0K9Ol0uyxzj9t0OF/aEhRK0TCbpl0GurzPF Su9CtUqWaFW+LgdHLTpzBDxRAg1cuzZV866DiCGsouujTDJk8TlWkJFVoS21b5liHK/kbINFu ftdH50hjsztn/pQg9+5zwrmRAG8Pa3Yyrzfq7rSWWhn3T24oE4= Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Elfring Date: Wed, 14 Feb 2018 21:34:54 +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/crypto/bfin_crc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/crypto/bfin_crc.c b/drivers/crypto/bfin_crc.c index a118b9bed669..7a1d6ed6d0b7 100644 --- a/drivers/crypto/bfin_crc.c +++ b/drivers/crypto/bfin_crc.c @@ -575,10 +575,8 @@ static int bfin_crypto_crc_probe(struct platform_device *pdev) int ret; crc = devm_kzalloc(dev, sizeof(*crc), GFP_KERNEL); - if (!crc) { - dev_err(&pdev->dev, "fail to malloc bfin_crypto_crc\n"); + if (!crc) return -ENOMEM; - } crc->dev = dev;