From patchwork Tue Jan 8 19:13:40 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 1947611 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id ACD27DFABE for ; Tue, 8 Jan 2013 18:54:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756975Ab3AHSyV (ORCPT ); Tue, 8 Jan 2013 13:54:21 -0500 Received: from mail.dev.rtsoft.ru ([213.79.90.226]:52193 "EHLO wasted.dev.rtsoft.ru" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1756957Ab3AHSyV (ORCPT ); Tue, 8 Jan 2013 13:54:21 -0500 X-Greylist: delayed 2462 seconds by postgrey-1.27 at vger.kernel.org; Tue, 08 Jan 2013 13:54:19 EST Received: from wasted.dev.rtsoft.ru (localhost.localdomain [127.0.0.1]) by wasted.dev.rtsoft.ru (8.14.4/8.14.4) with ESMTP id r08JDfXJ008178; Tue, 8 Jan 2013 22:13:41 +0300 Received: (from headless@localhost) by wasted.dev.rtsoft.ru (8.14.4/8.14.4/Submit) id r08JDfdg008177; Tue, 8 Jan 2013 22:13:41 +0300 X-Authentication-Warning: wasted.dev.rtsoft.ru: headless set sender to sshtylyov@ru.mvista.com using -f To: linux-usb@vger.kernel.org, balbi@ti.com Subject: [PATCH 2/2] omap2430: kill redundant assignments in omap2430_probe() Cc: gregkh@linuxfoundation.org, linux-omap@vger.kernel.org From: Sergei Shtylyov Organization: MontaVista Software LLC Date: Tue, 8 Jan 2013 22:13:40 +0300 MIME-Version: 1.0 Message-Id: <201301082213.41283.sshtylyov@ru.mvista.com> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org Commit 00a0b1d58af873d842580dcac55f3b156c3a4077 (usb: musb: omap: Add device tree support for omap musb glue) added assignments of the 'ret' variable to -ENOMEM on *some* error paths of the calls to devm_kzalloc(), while that variable was already pre-initialized for to that value, so these assignments were completely redundant. Kill them, fixing overindented string, while at it. Signed-off-by: Sergei Shtylyov --- This patch is atop of 'musb' branch of Felipe's tree. drivers/usb/musb/omap2430.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Index: usb/drivers/usb/musb/omap2430.c =================================================================== --- usb.orig/drivers/usb/musb/omap2430.c +++ usb/drivers/usb/musb/omap2430.c @@ -532,15 +532,13 @@ static int __devinit omap2430_probe(stru if (!pdata) { dev_err(&pdev->dev, "failed to allocate musb platfrom data\n"); - ret = -ENOMEM; goto err2; } data = devm_kzalloc(&pdev->dev, sizeof(*data), GFP_KERNEL); if (!data) { dev_err(&pdev->dev, - "failed to allocate musb board data\n"); - ret = -ENOMEM; + "failed to allocate musb board data\n"); goto err2; }