From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from metis.whiteo.stw.pengutronix.de (metis.whiteo.stw.pengutronix.de [185.203.201.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 727D2217733 for ; Thu, 19 Dec 2024 06:04:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.203.201.7 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734588291; cv=none; b=GKOosIrlW9fqniEMvgTkRqY1A94Av5puk/M4htxx2b9+Gr2pbZVlXY8icK0VFytXhbJw1jn8n9XHdvnYhkWOtqw6wvUOPjZUj01r5b+LiB020asIIjIY3VHEPY3ZBsxojGOTyQWmMfNcjvupOuSPyF96R5SyjP0FqU4VH79Q8B8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734588291; c=relaxed/simple; bh=pn+ohi5fnTPGN4sKYKRA7T/k8ngGNvyWkE+UH3+YLw0=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=bwQxXaRqZKsh2wdSeXaXh5si/cmfTpk+qbrM/yB5770Pt84O89LTVVAw8fgwM6XToZs8tFFFU6d5MB6zj9o0mVIRcz1/nT4Bybz0BQs0x+D1uEqme3Wc8tQCmgun1y9OJNsiz4ZMv4/6SRu2LJjjWSVKeIBCCUuCpkOvhnbxjUQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de; spf=pass smtp.mailfrom=pengutronix.de; arc=none smtp.client-ip=185.203.201.7 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pengutronix.de 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 1tO9eK-0001OQ-6X; Thu, 19 Dec 2024 07:04:40 +0100 Received: from pty.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::c5]) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1tO9eJ-0049jB-0g; Thu, 19 Dec 2024 07:04:39 +0100 Received: from ore by pty.whiteo.stw.pengutronix.de with local (Exim 4.96) (envelope-from ) id 1tO9eJ-008N5U-2p; Thu, 19 Dec 2024 07:04:39 +0100 Date: Thu, 19 Dec 2024 07:04:39 +0100 From: Oleksij Rempel To: Carlos Song Cc: andi.shyti@kernel.org, frank.li@nxp.com, kernel@pengutronix.de, shawnguo@kernel.org, s.hauer@pengutronix.de, festevam@gmail.com, linux-i2c@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Clark Wang , Ahmad Fatoum Subject: Re: [PATCH v5] i2c: imx: support DMA defer probing Message-ID: References: <20241218043541.143194-1-carlos.song@nxp.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20241218043541.143194-1-carlos.song@nxp.com> X-Sent-From: Pengutronix Hildesheim X-URL: http://www.pengutronix.de/ X-Accept-Language: de,en X-Accept-Content-Type: text/plain X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ore@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org On Wed, Dec 18, 2024 at 12:35:41PM +0800, Carlos Song wrote: > Return -EPROBE_DEFER when dma_request_slave_channel() because DMA driver > have not ready yet. > > Move i2c_imx_dma_request() before registering I2C adapter to avoid > infinite loop of .probe() calls to the same driver, see "e8c220fac415 > Revert "i2c: imx: improve the error handling in i2c_imx_dma_request()"" > and "Documentation/driver-api/driver-model/driver.rst". > > Use CPU mode to avoid stuck registering i2c adapter when DMA resources > are unavailable. > > Signed-off-by: Carlos Song > Signed-off-by: Clark Wang > Acked-by: Ahmad Fatoum Acked-by: Oleksij Rempel Thank you! -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |