From patchwork Sun Jul 24 12:10:58 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Johan Hovold X-Patchwork-Id: 9244869 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 7679E60487 for ; Sun, 24 Jul 2016 12:12:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 66C5128066 for ; Sun, 24 Jul 2016 12:12:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5B542280CF; Sun, 24 Jul 2016 12:12:35 +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=unavailable 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 0437D27FBB for ; Sun, 24 Jul 2016 12:12:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752436AbcGXMMP (ORCPT ); Sun, 24 Jul 2016 08:12:15 -0400 Received: from mail-lf0-f67.google.com ([209.85.215.67]:34496 "EHLO mail-lf0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752368AbcGXMLx (ORCPT ); Sun, 24 Jul 2016 08:11:53 -0400 Received: by mail-lf0-f67.google.com with SMTP id l69so9811548lfg.1; Sun, 24 Jul 2016 05:11:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references; bh=/wsojyEek0MHOBF5hxHXyyP8Orp81EtdNmZu48MwIg0=; b=W7Qy/iPs4y88tpnt7f+0RtTX7/bBEAg8e9Xpj8NzVPPLXkZE/qebQqRVHWPGUA6cmZ d5ID4274DT4+QQ2ob2uhVcM2pANPMGA8sZ8L3KSUYCW6A9i84gHj1s3Yt70cgOLJmtdc 0OAuIM3sdV5eMuIXMLx1dYazv2rd3XDugK4NRm6jeXSOjtKSCDrO1q83ANWfpAmtPUht 8tmiCR+OYAW6ABsUQVYkAeyRY4UNUN3/jTYpb+ZDht+JXlfaAVn0XNpH/VFb9c4cU2sv QFx95GCIGHgNEM5QatYmO8AKPPJqOBNHl06RyVNgvX4ia5lj3kYsPJkX3A9vPJT/jU6Z N63A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=/wsojyEek0MHOBF5hxHXyyP8Orp81EtdNmZu48MwIg0=; b=DrsC6LkwvSANfBfpZ2onjg1OUrNej2XWgsORa46urNOUo2kmoVUbHUy8ZiYqNk+w3X kOaH8oFr4ULjtXsfB3vPYKEoRrLn006bJG81WxoHCqwAPEVeY5Tee/3gSrlaSfFXn/Qg HNz3wN6y8jMGpBF2MHPstZmheaHwqvkRZVHPKcBk0aeV6NYW7Kf7ILzodCcr83Kc9Z01 EBmWGtgy71VJAyg5p5Xv5dDeu+DzwibrF7+MdQcjQ1iBZ0sHlFczIw/vbwiHjrLB+hDB P6e2mC9GwF0cCaMM6JHvkmlSJHMFk77Oyqr4d5zS+gtflZCkigGnr89HQ2m0kGVBPjnw WV6g== X-Gm-Message-State: AEkoouu+YMP2jMsGmWXwfEB8bXpERMwofA6Q+C8yzYhDceFpxREbLqQBS/3/0azFqKkDDw== X-Received: by 10.25.219.198 with SMTP id t67mr5300405lfi.177.1469362310753; Sun, 24 Jul 2016 05:11:50 -0700 (PDT) Received: from xi.terra ([84.216.67.69]) by smtp.gmail.com with ESMTPSA id l70sm4611827lfe.28.2016.07.24.05.11.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Jul 2016 05:11:49 -0700 (PDT) Received: from johan by xi.terra with local (Exim 4.87) (envelope-from ) id 1bRIGA-0005EU-MJ; Sun, 24 Jul 2016 14:11:54 +0200 From: Johan Hovold To: Tony Lindgren Cc: =?UTF-8?q?Beno=C3=AEt=20Cousson?= , Rob Herring , Mark Rutland , Russell King , Roger Quadros , linux-omap@vger.kernel.org, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org, Johan Hovold Subject: [PATCH 1/3] memory: omap-gpmc: allow probe of child nodes to fail Date: Sun, 24 Jul 2016 14:10:58 +0200 Message-Id: <1469362260-20066-2-git-send-email-johan@kernel.org> X-Mailer: git-send-email 2.7.3 In-Reply-To: <1469362260-20066-1-git-send-email-johan@kernel.org> References: <1469362260-20066-1-git-send-email-johan@kernel.org> Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP A recent commit (inadvertently?) changed how failed probe of a gpmc child node was handled. Instead of proceeding with setting up any other children as before, a single error now aborts the whole process. This change broke networking on some Overo boards due to probe failing for an unrelated nand node. This second issue should obviously be fixed, but let's restore the old behaviour of allowing child-node probe to fail to avoid further similar breakage on other systems. Fixes: d2d00862dfbb ("memory: omap-gpmc: Support general purpose input for WAITPINs") Signed-off-by: Johan Hovold --- drivers/memory/omap-gpmc.c | 21 +++++++-------------- 1 file changed, 7 insertions(+), 14 deletions(-) diff --git a/drivers/memory/omap-gpmc.c b/drivers/memory/omap-gpmc.c index 15508df24e5d..73ec3200191e 100644 --- a/drivers/memory/omap-gpmc.c +++ b/drivers/memory/omap-gpmc.c @@ -2250,7 +2250,7 @@ static int gpmc_probe_dt(struct platform_device *pdev) return 0; } -static int gpmc_probe_dt_children(struct platform_device *pdev) +static void gpmc_probe_dt_children(struct platform_device *pdev) { int ret; struct device_node *child; @@ -2265,11 +2265,11 @@ static int gpmc_probe_dt_children(struct platform_device *pdev) else ret = gpmc_probe_generic_child(pdev, child); - if (ret) - return ret; + if (ret) { + dev_err(&pdev->dev, "failed to probe DT child '%s': %d\n", + child->name, ret); + } } - - return 0; } #else static int gpmc_probe_dt(struct platform_device *pdev) @@ -2277,9 +2277,8 @@ static int gpmc_probe_dt(struct platform_device *pdev) return 0; } -static int gpmc_probe_dt_children(struct platform_device *pdev) +static void gpmc_probe_dt_children(struct platform_device *pdev) { - return 0; } #endif @@ -2372,16 +2371,10 @@ static int gpmc_probe(struct platform_device *pdev) goto setup_irq_failed; } - rc = gpmc_probe_dt_children(pdev); - if (rc < 0) { - dev_err(gpmc->dev, "failed to probe DT children\n"); - goto dt_children_failed; - } + gpmc_probe_dt_children(pdev); return 0; -dt_children_failed: - gpmc_free_irq(gpmc); setup_irq_failed: gpmc_gpio_exit(gpmc); gpio_init_failed: