From patchwork Wed Sep 24 13:47:02 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kishon Vijay Abraham I X-Patchwork-Id: 37834 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f69.google.com (mail-la0-f69.google.com [209.85.215.69]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 96254204FF for ; Wed, 24 Sep 2014 13:56:15 +0000 (UTC) Received: by mail-la0-f69.google.com with SMTP id ty20sf5446547lab.8 for ; Wed, 24 Sep 2014 06:56:14 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe:content-type; bh=az1aVRPEDc7qK1X9am1CWvByNBOcDBfyJfdyn2Kf6iY=; b=ePD3cgyBcA5Mz/BroM3vidG8odbtNSlE5U4rcfAyaFkdOnggdt8pLXGngjQ9ilBb1p aEkYj+xmAwVwO7MrByQIEL8SKGFGRImSrlJiBQtn1EnuZSZrN5zPcfboSdJdNlKgL+jU sKMOjW800BOBd6zUmrZVVJ3Pqp/bLQ73+RpX2lrw7MFa4rgUQnTzXnpUO+rDoT1NgYtT hLQWqDpflh/NkSV7i/eScHqgr3maF0agYc/nCfG1QB8tmcI4Oc22QC7CZHOfMAts/Q/u wX/+aCrEvXplb50Jhz729OgD3e5DXhYLWbBHYFl2TIOIq0tL7d/a2m+zTOIz5hK3CMEZ EQgw== X-Gm-Message-State: ALoCoQnXeOdLmi/H+mprZDW7SZggOH7V+0cRtvYbkOvv3X3XrGzNJxS8Eh1iWtXAC3h3/ahQGvuI X-Received: by 10.180.24.225 with SMTP id x1mr1518363wif.2.1411566974386; Wed, 24 Sep 2014 06:56:14 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.37.170 with SMTP id z10ls157939laj.73.gmail; Wed, 24 Sep 2014 06:56:14 -0700 (PDT) X-Received: by 10.152.20.1 with SMTP id j1mr6501751lae.57.1411566974201; Wed, 24 Sep 2014 06:56:14 -0700 (PDT) Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com [209.85.217.181]) by mx.google.com with ESMTPS id 7si22916215lar.88.2014.09.24.06.56.14 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 24 Sep 2014 06:56:14 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.181 as permitted sender) client-ip=209.85.217.181; Received: by mail-lb0-f181.google.com with SMTP id b6so5384485lbj.26 for ; Wed, 24 Sep 2014 06:56:14 -0700 (PDT) X-Received: by 10.152.179.226 with SMTP id dj2mr6771428lac.40.1411566973866; Wed, 24 Sep 2014 06:56:13 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.130.169 with SMTP id of9csp586192lbb; Wed, 24 Sep 2014 06:56:13 -0700 (PDT) X-Received: by 10.68.57.198 with SMTP id k6mr8704531pbq.60.1411566972335; Wed, 24 Sep 2014 06:56:12 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id zm1si26276434pbc.201.2014.09.24.06.56.11 for ; Wed, 24 Sep 2014 06:56:12 -0700 (PDT) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753956AbaIXN4J (ORCPT + 27 others); Wed, 24 Sep 2014 09:56:09 -0400 Received: from bear.ext.ti.com ([192.94.94.41]:55795 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753426AbaIXNr3 (ORCPT ); Wed, 24 Sep 2014 09:47:29 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by bear.ext.ti.com (8.13.7/8.13.7) with ESMTP id s8ODlSTM005342; Wed, 24 Sep 2014 08:47:28 -0500 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id s8ODlSiY009388; Wed, 24 Sep 2014 08:47:28 -0500 Received: from dlep32.itg.ti.com (157.170.170.100) by DFLE72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.3.174.1; Wed, 24 Sep 2014 08:47:28 -0500 Received: from a0393678ub.india.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id s8ODlKDN015622; Wed, 24 Sep 2014 08:47:27 -0500 From: Kishon Vijay Abraham I To: CC: , Subject: [PATCH 04/22] phy: phy-omap-usb2: Remove unncessary site specific OOM messages Date: Wed, 24 Sep 2014 19:17:02 +0530 Message-ID: <1411566440-19169-5-git-send-email-kishon@ti.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1411566440-19169-1-git-send-email-kishon@ti.com> References: <1411566440-19169-1-git-send-email-kishon@ti.com> MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: kishon@ti.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.181 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , From: Peter Griffin The site specific OOM messages are unncessary, because they duplicate messages from the memory subsystem which include dump_stack(). Removing these superflous messages makes the kernel smaller. A discussion here http://patchwork.ozlabs.org/patch/324158/ found that all error paths from kzalloc will print a error message, and that any error path which maybe found which doesn't would be considered a bug in kzalloc. Signed-off-by: Peter Griffin Signed-off-by: Kishon Vijay Abraham I --- drivers/phy/phy-omap-usb2.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/phy/phy-omap-usb2.c b/drivers/phy/phy-omap-usb2.c index 93d7835..51c6f92 100644 --- a/drivers/phy/phy-omap-usb2.c +++ b/drivers/phy/phy-omap-usb2.c @@ -212,16 +212,12 @@ static int omap_usb2_probe(struct platform_device *pdev) phy_data = (struct usb_phy_data *)of_id->data; phy = devm_kzalloc(&pdev->dev, sizeof(*phy), GFP_KERNEL); - if (!phy) { - dev_err(&pdev->dev, "unable to allocate memory for USB2 PHY\n"); + if (!phy) return -ENOMEM; - } otg = devm_kzalloc(&pdev->dev, sizeof(*otg), GFP_KERNEL); - if (!otg) { - dev_err(&pdev->dev, "unable to allocate memory for USB OTG\n"); + if (!otg) return -ENOMEM; - } phy->dev = &pdev->dev;