From patchwork Sun Jan 21 19:05:14 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: 10177053 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 6E2B3601E7 for ; Sun, 21 Jan 2018 19:06:19 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5C60720174 for ; Sun, 21 Jan 2018 19:06:19 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 50D9F26E3C; Sun, 21 Jan 2018 19:06:19 +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 E6B8820174 for ; Sun, 21 Jan 2018 19:06:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751282AbeAUTGG (ORCPT ); Sun, 21 Jan 2018 14:06:06 -0500 Received: from mout.web.de ([212.227.17.11]:59969 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751004AbeAUTGF (ORCPT ); Sun, 21 Jan 2018 14:06:05 -0500 Received: from [192.168.1.3] ([77.181.34.161]) by smtp.web.de (mrweb101 [213.165.67.124]) with ESMTPSA (Nemesis) id 0Lz376-1eqJR43wwK-014Fvm; Sun, 21 Jan 2018 20:05:15 +0100 To: linux-input@vger.kernel.org, Daniel Mack , Dmitry Torokhov , =?UTF-8?B?R8O8bnRlciBSw7Zjaw==?= Cc: LKML , kernel-janitors@vger.kernel.org From: SF Markus Elfring Subject: [PATCH] Input: eeti_ts: Delete an error message for a failed memory allocation in eeti_ts_probe() Message-ID: Date: Sun, 21 Jan 2018 20:05:14 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 Content-Language: en-GB X-Provags-ID: V03:K0:NwsVBZwt6DOi2IuKSewCJfuvbfHx2WHuh/bzocoj0DdWf684Vtn 50+GxjzOzO0Mg8yckxVaUYieHb4Z2IFN88a6LHCx/ee6okdw8YurMFEpse28KZ92NlKzdU1 QpjyKa84VW3kl09Svt5hC60vIlU3vWL0R1ubBHtUTHs7BytPhVizcqbD/ezxJdBvZwfvagQ WX7lk4MrSYhi8Lc9mMfaA== X-UI-Out-Filterresults: notjunk:1; V01:K0:VBT48x73Fjc=:EkFaQ1d/aNYSF+JGGz5M7k /pRK8aaYI1P4o9EXCr0byOf9dEWQ0SHDjua/A9Z6MC1essccZnM/xTJ9hC/97ZpRhlF0pwU7j rhWfhAUrZyybPnGT1wGwDhvGLco5H5kFOthdR+3jCfFB7cKMUluluZgOnlcJFTCm+iEOY8RPa VpUWcbKtGM733Y4moqWOOR9JpA2JhFivBuHJUAYWUmDvG7VE/v8hbvPFVpTeji+CNZBUKwhgF Zqt29cH9DRJjZ4NcR3xM5r4tmY2LDHZL+znTXJ0i1clV/2H75tl9fxnVrnWJJ9yMrD0TEx+4J mof8UOpOJmS2B61D40Ckf+v2XITthvE4HDoijK5EZd4SuH0frgnKRt4h7tCgNbEoey3UbQdwZ cQoVMKfqx8fjb5iuwNtAht+PFWCG0Teqwi8B2bITjxTvOVuL89nYHAbYr4BJC2R77lVdAIn94 jnJnoeqlDp5a2i937N+dVfWXjeraUF3aEFtpUR6tptOx6jeBZlZia5bVV/UA45QwBjuDFYe4u 1UV1dPHQF/Lvqrx9Yx2CCz8KEzmU3IzcE/LWYGJWiZY6mdNE3VkeMpwdX88XXXd5RLOR97OJY 9w3nbygaZoUkdNamV9auZHpfApniv90XqIzA05sKDkhc79K6uFbEs9q5ZeSzygPtlubPRXB6M Mw6IASukQXWU8iITElI2GQtZAH47uN6halIPsis40DPyrckStrh5I4H6TNUhuwhM8nVVjyT1Y rz03dAT8VDWdo4VsclIqcd5y7Eim0uvT0E2eoOlhik+S9S5uD0DlSNZk4j6orBs6Cc1gBQVRK Tx6pqQyZ0/vsUPwe+B9gXmxi87xBWgD3PvAO2dHZQ0o+4m5OfE= Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Markus Elfring Date: Sun, 21 Jan 2018 20:00:03 +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/touchscreen/eeti_ts.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/input/touchscreen/eeti_ts.c b/drivers/input/touchscreen/eeti_ts.c index 2facad75eb6d..337f171e0f86 100644 --- a/drivers/input/touchscreen/eeti_ts.c +++ b/drivers/input/touchscreen/eeti_ts.c @@ -161,10 +161,8 @@ static int eeti_ts_probe(struct i2c_client *client, */ eeti = devm_kzalloc(dev, sizeof(*eeti), GFP_KERNEL); - if (!eeti) { - dev_err(dev, "failed to allocate driver data\n"); + if (!eeti) return -ENOMEM; - } input = devm_input_allocate_device(dev); if (!input) {