Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp1977245pxa; Mon, 24 Aug 2020 01:07:30 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwgjIRRKfj4TeVlxB1fhHslko63masvA5ktXsmEmY1Rosq1LoZJvtzshCg3NE+KJ6ie0uda X-Received: by 2002:a17:906:57d9:: with SMTP id u25mr3706287ejr.543.1598256450655; Mon, 24 Aug 2020 01:07:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598256450; cv=none; d=google.com; s=arc-20160816; b=XpNaPZ41FXMkpLVhFk5o0hIiCeOQ37eWit6Rt75NjuqsCYVlxZDur4g8HZbjUcZfAR c84+YRt2S92U1wwtecxNPZbcINXzWv7efpf9+C9zIoXBgJ6dc1uMWDITuTCUJ+xst6B0 cWrHIYHt3vO1fSNonpxKd807cYJlkYeypgkJ1nJKx6ASZOzDDvuIBwXe5nZ5hoHAl+0c O1GKRxk4ZLarnXqP2+sEPw1/gcZiJ4PXrzhQxBzoTYjur3lDxrzDjMscjYnNZWeKQga9 A8ce+7EWh/dDY+a6rfk6l6DQTzUnvB0eibfw9vgHukUtaDt0I/Ijej7T+r5WU6AwQBv1 CJow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=V5cRwNga3XaQ0dq/Qjf9kPplvijVg03N+QRbQX8bWAc=; b=z7f4MER+L8UrfZu/5f752ASmSFMojFdP6jxK489D8jBlDNS2S5xmG8kZErXk4sb7Nj E+bH2aGHAudvkLCFP7/khLRhs/y1hv8vpfVNz+xaGf8xlBOu0EJDJT9L/cnHG6bBYAkR 3kwNHMH/Bv6SqBSBJW/Wgr2q5FcXpNSvWm+XY8Ddiuf1uDXbKUe9lS4+vWj3B8n5U+Fm RTr6fH1XbsB/MKBCqZqyTQWNLGTjlFOmwFmDB0NOqfvPKK695un+r3jBMyQWQp8WcKu0 e+l7x8eIm0ZfS3qEgFlR6jSGu3ikTqmQNQ9QgERWgFDnD9kgOYZy4/fmzc177WOZl6LE +5DA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n13si283925eje.128.2020.08.24.01.07.07; Mon, 24 Aug 2020 01:07:30 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726113AbgHXIEF (ORCPT + 99 others); Mon, 24 Aug 2020 04:04:05 -0400 Received: from inva020.nxp.com ([92.121.34.13]:58348 "EHLO inva020.nxp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726354AbgHXIDy (ORCPT ); Mon, 24 Aug 2020 04:03:54 -0400 Received: from inva020.nxp.com (localhost [127.0.0.1]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id 36C311A0309; Mon, 24 Aug 2020 10:03:53 +0200 (CEST) Received: from invc005.ap-rdc01.nxp.com (invc005.ap-rdc01.nxp.com [165.114.16.14]) by inva020.eu-rdc02.nxp.com (Postfix) with ESMTP id AAF581A02FC; Mon, 24 Aug 2020 10:03:48 +0200 (CEST) Received: from 10.192.242.69 (shlinux2.ap.freescale.net [10.192.224.44]) by invc005.ap-rdc01.nxp.com (Postfix) with ESMTP id D7F11402D2; Mon, 24 Aug 2020 10:03:42 +0200 (CEST) From: Shengjiu Wang To: timur@kernel.org, nicoleotsuka@gmail.com, Xiubo.Lee@gmail.com, festevam@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, alsa-devel@alsa-project.org, lgirdwood@gmail.com Cc: linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH RESEND] ASoC: fsl_sai: Add -EPROBE_DEFER check for regmap init Date: Mon, 24 Aug 2020 15:58:07 +0800 Message-Id: <1598255887-1391-1-git-send-email-shengjiu.wang@nxp.com> X-Mailer: git-send-email 2.7.4 X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Regmap initialization may return -EPROBE_DEFER for clock may not be ready, so check -EPROBE_DEFER error type before start another Regmap initialization. Signed-off-by: Shengjiu Wang Acked-by: Nicolin Chen --- sound/soc/fsl/fsl_sai.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/fsl/fsl_sai.c b/sound/soc/fsl/fsl_sai.c index f6969a5d49e3..62c5fdb678fc 100644 --- a/sound/soc/fsl/fsl_sai.c +++ b/sound/soc/fsl/fsl_sai.c @@ -959,7 +959,7 @@ static int fsl_sai_probe(struct platform_device *pdev) "bus", base, &fsl_sai_regmap_config); /* Compatible with old DTB cases */ - if (IS_ERR(sai->regmap)) + if (IS_ERR(sai->regmap) && PTR_ERR(sai->regmap) != -EPROBE_DEFER) sai->regmap = devm_regmap_init_mmio_clk(&pdev->dev, "sai", base, &fsl_sai_regmap_config); if (IS_ERR(sai->regmap)) { -- 2.27.0