From patchwork Fri Jun 24 02:26:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: chris@lapa.com.au X-Patchwork-Id: 9196403 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 5F17760871 for ; Fri, 24 Jun 2016 02:27:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4A3672847E for ; Fri, 24 Jun 2016 02:27:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3B82428487; Fri, 24 Jun 2016 02:27:15 +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.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID 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 C0AA12847E for ; Fri, 24 Jun 2016 02:27:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752365AbcFXC0x (ORCPT ); Thu, 23 Jun 2016 22:26:53 -0400 Received: from mail-pf0-f196.google.com ([209.85.192.196]:34417 "EHLO mail-pf0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752337AbcFXC0s (ORCPT ); Thu, 23 Jun 2016 22:26:48 -0400 Received: by mail-pf0-f196.google.com with SMTP id 66so7995839pfy.1 for ; Thu, 23 Jun 2016 19:26:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lapa-com-au.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=AdWNhRe1quTJlf/c3Ih1I3wmfyovWOxVwfq6vyoiUCQ=; b=ApazdNXUAfVixayoDq5PKLK547hH99AfGdfsbtRop5BeqEF0TO2dTRAZDf6tgHXmW4 Pvol9bgtWnakNPSD9Gie+SEqwymuFQQS01PrqnRJn2tAyMSQmpzeZyoPB6T/pGg1jH+H yDtbiyWQxIdnlvcY84aYpWckfzuMAXoVIrBA2KhP7CUfCVX5CnMXHrYw7CnAEfCDXeDW 6lQBJPYYNqInXfLcDhioECaiiOqDZF/7SvPA6j+flkh39WBqJKSm8GLzpY/6oDIz4JvG BewYjTWNN77EGEinWdLgKLz1ccY+ea7HB9oqBDVrL/VtYrZygKJN3ve6dPvsi4sDabBS hQng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=AdWNhRe1quTJlf/c3Ih1I3wmfyovWOxVwfq6vyoiUCQ=; b=SA1+DaDJNypeWO7HAH7hbrfNoSFnE6rKFyzFTgFGA+9OqFiKvcLE1tFmeEhjM0qEM2 bxPMI21CwajMb9oo15PLhe+tex2sDXc4x0fjqe9fgqMW5be9oAZTl+jPYQqOTshmwIE+ mG555C7s0BHbHZMrqoQ/Irjy+0mEyYCtA1WJ5sepmh4A5NkqZEFjRJEBFkM2NjjnIO3w ga1ln1SiPrp3t5ONUEe4aslF3DpIJ+DYM6klE0NA0rXFpyj3as8pbKNP/O8lKg7SO2jR fTc398/I1j0byW1d/OTYi5Jguo8Om4qJC6uMR4RUYcLod1SGunnPobl7PIyi0fyMbQgI FgpQ== X-Gm-Message-State: ALyK8tKwlNYWijyytLzh5a0lD1zWPpLlp1Rr843zNiDnPzYLuo+/EGYYRGd6pXKmktHi4A== X-Received: by 10.98.48.198 with SMTP id w189mr2785420pfw.125.1466735207506; Thu, 23 Jun 2016 19:26:47 -0700 (PDT) Received: from bbb-dev.management.cpd (163.164.70.115.static.exetel.com.au. [115.70.164.163]) by smtp.gmail.com with ESMTPSA id y63sm3094614pfb.13.2016.06.23.19.26.43 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 23 Jun 2016 19:26:47 -0700 (PDT) From: Chris Lapa X-Google-Original-From: Chris Lapa To: k.kozlowski@samsung.com, dwmw2@infradead.org, dbaryshkov@gmail.com, sre@kernel.org, mark.rutland@arm.com, robh+dt@kernel.org Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, Chris Lapa Subject: [PATCH v5 6/7] max8903: remove unnecessary 'out of memory' error message. Date: Fri, 24 Jun 2016 12:26:11 +1000 Message-Id: <1466735172-13372-7-git-send-email-chris@cpdesign.com.au> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1466735172-13372-1-git-send-email-chris@cpdesign.com.au> References: <1464849897-21527-3-git-send-email-chris@lapa.com.au> <1466735172-13372-1-git-send-email-chris@cpdesign.com.au> In-Reply-To: <1464849897-21527-3-git-send-email-chris@lapa.com.au> References: <1464849897-21527-3-git-send-email-chris@lapa.com.au> Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Chris Lapa Remove the 'out of memory' error message as it is printed by the core. Signed-off-by: Chris Lapa Reviewed-by: Krzysztof Kozlowski --- drivers/power/max8903_charger.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/power/max8903_charger.c b/drivers/power/max8903_charger.c index 643a87a..9453bbf 100644 --- a/drivers/power/max8903_charger.c +++ b/drivers/power/max8903_charger.c @@ -304,10 +304,8 @@ static int max8903_probe(struct platform_device *pdev) } data = devm_kzalloc(dev, sizeof(struct max8903_data), GFP_KERNEL); - if (data == NULL) { - dev_err(dev, "Cannot allocate memory.\n"); + if (!data) return -ENOMEM; - } data->pdata = pdev->dev.platform_data; data->dev = dev;