From patchwork Mon Jan 15 20:12:59 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 1886839 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=jb1iKJts; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.infradead.org (client-ip=198.137.202.133; helo=bombadil.infradead.org; envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4TDNvb4hdgz23dm for ; Tue, 16 Jan 2024 07:26:17 +1100 (AEDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=qFgcSrwidZMq/g2fZ2j7N4I+YM5z2h7YB8cVDTe1NzE=; b=jb1iKJtsdlKSjM LK8VYmYl+RhDSQhtaZOqyKHG54R+t4/8TKqXDxp3cuCqIW51cuPrL28CMtF2EIVTDj6IjqdcaWh4x 7GqmDYYAPrg7OYUI+p9HolJcC7V6l5bSHk4nvhkMo9Se70Zzr1s1Iq7V3JfM/uYQYcXisJLnhb/iB rC6Kag3986iF0T7MODHPf3OMTJkG6h65/1vjox6qzEL+w1i1VyoS5N4zcnwMUkB2hkK845z9+h+gz o/fxnFaPsKIyKQyh3JfTzfK5io25e3wnWCqMIfKfkyextwd1IPfBC7seLz+Ihn21IVW3PKh7Ck5rN ST5e8HNXj2JmZtMM4LIA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1rPTSW-00A8EN-2T; Mon, 15 Jan 2024 20:21:24 +0000 Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1rPTSS-00A8CW-2L for linux-mtd@lists.infradead.org; Mon, 15 Jan 2024 20:21:22 +0000 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rPTSG-0004kf-Uu; Mon, 15 Jan 2024 21:21:08 +0100 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPTSF-0005gi-HJ; Mon, 15 Jan 2024 21:21:07 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.96) (envelope-from ) id 1rPTSF-000N7t-1R; Mon, 15 Jan 2024 21:21:07 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Mark Brown , Geert Uytterhoeven Cc: linux-spi@vger.kernel.org, kernel@pengutronix.de, Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , Martin Blumenstingl , Jernej Skrabec , Nicolas Ferre , =?utf-8?q?Pali_Roh=C3=A1r?= , linux-mtd@lists.infradead.org Subject: [PATCH 13/33] mtd: rawnand: fsl_elbc: Let .probe retry if local bus is missing Date: Mon, 15 Jan 2024 21:12:59 +0100 Message-ID: <978d5107646800a2dfa3299e32e2587907d53a87.1705348269.git.u.kleine-koenig@pengutronix.de> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=926; i=u.kleine-koenig@pengutronix.de; h=from:subject:message-id; bh=s+JADGlY1hU/NStvmmbQ8XZ+UID1ILn7ThT9et4DuL4=; b=owEBbQGS/pANAwAKAY+A+1h9Ev5OAcsmYgBlpZHPCEJWc7vdLUmy8+BmgzzT8evOP0zLGbYWS ciV2KzQ93yJATMEAAEKAB0WIQQ/gaxpOnoeWYmt/tOPgPtYfRL+TgUCZaWRzwAKCRCPgPtYfRL+ TiVdB/wMSwEC76EmTubxnIK4QkQ+SGwLSbNrGj1gqo0OR0dGoYZmlUtZ4lJgy6bm7ZuExr1OOVZ +nD45sPyuvg6SusiCWNVHmV2Bs/wGWYC+rJogFEKVV1MGghznBcd7jFin7nnYU0ZA6J8MaLmlNA mNILzMZe1SuVNxrbE9VYubQh81lpfU8KVZx/GypYqzbNGLpxZkCZK06v59OSEYcWtmMNtL/KJX1 ZNIvStyr8BUpuLU4UCGrhkA498s3DA+igjki46e0RvjwKnPVPKYB9Z5lCwrut4FVJPrz+aJdpCH gLPB+jWx0B7KKeaqdtcMUayWjw5xqjIZcjLQlqeAH6grisdI X-Developer-Key: i=u.kleine-koenig@pengutronix.de; a=openpgp; fpr=0D2511F322BFAB1C1580266BE2DCDD9132669BD6 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-mtd@lists.infradead.org X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240115_122120_761291_DBE9E563 X-CRM114-Status: GOOD ( 13.24 ) X-Spam-Score: -2.3 (--) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__If_during_probe_fsl=5Flbc=5Fctrl=5Fdev?= =?unknown-8bit?q?_is_NULL_that_might_just_be?= =?unknown-8bit?q?_because_the_fsl=5Flbc_driver_didn=27t_bind_yet=2E_So_retur?= =?unknown-8bit?q?n_-EPROBE=5FDEFER_in_this?= =?unknown-8bit?q?_case_to_make_the_driver_core_retry_probing_later=2E_Signed?= =?unknown-8bit?q?-off-by=3A_Uwe_Kleine-K=C3=B6nig?= =?unknown-8bit?q?_=3Cu=2Ekleine-koenig=40pengutronix=2Ede=3E_---_drivers/mtd?= =?unknown-8bit?q?/nand/raw/fsl=5Felbc=5Fnand=2Ec?= =?unknown-8bit?q?_=7C_3_++-_1_file_changed=2C_2_insertions=28+=29=2C_1_delet?= =?unknown-8bit?q?ion=28-=29_?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=28-2=2E3_points=2C_5=2E0_re?= =?unknown-8bit?q?quired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_-2=2E3_RCVD=5FIN=5FDNSWL=5FMED______RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C?= =?unknown-8bit?q?_medium_trust?= =?unknown-8bit?b?IFsyYTBhOmVkYzA6MjpiMDE6MWQ6MDowOjEwNCBsaXN0ZWQgaW5d?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= X-BeenThere: linux-mtd@lists.infradead.org X-Mailman-Version: 2.1.34 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 If during probe fsl_lbc_ctrl_dev is NULL that might just be because the fsl_lbc driver didn't bind yet. So return -EPROBE_DEFER in this case to make the driver core retry probing later. Signed-off-by: Uwe Kleine-König --- drivers/mtd/nand/raw/fsl_elbc_nand.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/mtd/nand/raw/fsl_elbc_nand.c b/drivers/mtd/nand/raw/fsl_elbc_nand.c index 1e3a80f06f33..df6a0d5c86bb 100644 --- a/drivers/mtd/nand/raw/fsl_elbc_nand.c +++ b/drivers/mtd/nand/raw/fsl_elbc_nand.c @@ -869,7 +869,8 @@ static int fsl_elbc_nand_probe(struct platform_device *pdev) struct mtd_info *mtd; if (!fsl_lbc_ctrl_dev || !fsl_lbc_ctrl_dev->regs) - return -ENODEV; + return dev_err_probe(&pdev->dev, -EPROBE_DEFER, "lbc_ctrl_dev missing\n"); + lbc = fsl_lbc_ctrl_dev->regs; dev = fsl_lbc_ctrl_dev->dev;