From patchwork Mon Oct 27 14:34:05 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frans Klaver X-Patchwork-Id: 403624 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2001:1868:205::9]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id F28FF14007D for ; Tue, 28 Oct 2014 01:35:56 +1100 (AEDT) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1XilNZ-0000Os-Pl; Mon, 27 Oct 2014 14:34:41 +0000 Received: from filter1.ibarracuda.nl ([83.247.7.10]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1XilNX-0000Fr-2Q for linux-mtd@lists.infradead.org; Mon, 27 Oct 2014 14:34:39 +0000 X-ASG-Debug-ID: 1414420455-0759e74a71ab99b0002-6YE7NY Received: from XSMCASSVR01.xsens-tech.local (rev-215.116.249.87.virtu.nl [87.249.116.215]) by filter1.ibarracuda.nl with ESMTP id dGatEg8rBd2Cta82 (version=TLSv1 cipher=AES128-SHA bits=128 verify=NO); Mon, 27 Oct 2014 15:34:15 +0100 (CET) X-Barracuda-Envelope-From: Frans.Klaver@xsens.com X-Barracuda-AUTH-User: xsenscom X-Barracuda-Apparent-Source-IP: 87.249.116.215 Received: from ci00147.xsens-tech.local (172.16.11.125) by XSMCASSVR01.xsens-tech.local (172.16.111.152) with Microsoft SMTP Server id 14.3.195.1; Mon, 27 Oct 2014 15:34:14 +0100 From: Frans Klaver To: Brian Norris Subject: [PATCH v2] mtd: omap: fix mtd devices not showing up Date: Mon, 27 Oct 2014 15:34:05 +0100 X-ASG-Orig-Subj: [PATCH v2] mtd: omap: fix mtd devices not showing up Message-ID: <1414420445-9020-1-git-send-email-frans.klaver@xsens.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1414416749-19598-1-git-send-email-frans.klaver@xsens.com> References: <1414416749-19598-1-git-send-email-frans.klaver@xsens.com> MIME-Version: 1.0 X-Originating-IP: [172.16.11.125] X-Barracuda-Connect: rev-215.116.249.87.virtu.nl[87.249.116.215] X-Barracuda-Start-Time: 1414420455 X-Barracuda-Encrypted: AES128-SHA X-Barracuda-URL: http://filter1.ibarracuda.nl:8000/cgi-mod/mark.cgi X-Virus-Scanned: by bsmtpd at ibarracuda.nl X-Barracuda-BRTS-Status: 1 X-Barracuda-Spam-Score: 0.00 X-Barracuda-Spam-Status: No, SCORE=0.00 using per-user scores of TAG_LEVEL=1000.0 QUARANTINE_LEVEL=1000.0 KILL_LEVEL=5.0 tests= X-Barracuda-Spam-Report: Code version 3.2, rules version 3.2.3.10961 Rule breakdown below pts rule name description ---- ---------------------- -------------------------------------------------- X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20141027_073439_271610_1BA4C963 X-CRM114-Status: UNSURE ( 9.48 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.0 (/) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (0.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- Cc: Frans Klaver , linux-omap@vger.kernel.org, linux-mtd@lists.infradead.org, =?UTF-8?q?Ezequiel=20Garc=C3=ADa?= , Roger Quadros X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Linux MTD discussion mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-mtd" Errors-To: linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org Since commit 6d178ef2fd5e ("mtd: nand: Move ELM driver and rename as omap_elm"), I don't have any mtd devices present on my am335x. This changes the link order of the omap_elm and omap2 objects, causing them to probe in the wrong order. To fix this, make elm_config defer probing until the omap_elm driver is actually loaded. Signed-off-by: Frans Klaver Acked-by: Roger Quadros --- drivers/mtd/nand/omap_elm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/nand/omap_elm.c b/drivers/mtd/nand/omap_elm.c index b4f61c7..0585310 100644 --- a/drivers/mtd/nand/omap_elm.c +++ b/drivers/mtd/nand/omap_elm.c @@ -115,7 +115,7 @@ int elm_config(struct device *dev, enum bch_ecc bch_type, if (!info) { dev_err(dev, "Unable to configure elm - device not probed?\n"); - return -ENODEV; + return -EPROBE_DEFER; } /* ELM cannot detect ECC errors for chunks > 1KB */ if (ecc_step_size > ((ELM_ECC_SIZE + 1) / 2)) {