Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp128858imj; Thu, 14 Feb 2019 16:57:07 -0800 (PST) X-Google-Smtp-Source: AHgI3Ia8lYARZt8kl2QCwK4hPKGXYyOr8rdj8Y/uhSYk9IVNVXBOSLZqfb1SB+sekyAWXj/GwvaG X-Received: by 2002:a63:9751:: with SMTP id d17mr2704540pgo.392.1550192227690; Thu, 14 Feb 2019 16:57:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550192227; cv=none; d=google.com; s=arc-20160816; b=BTWilEV6tlE6NxST0dBNp+bsTVl40GqvfVGtLyw39lgqGSkmVBnELrLN3RPExr/aDY cbMq4ysm5cjyt3z6Hq9vXRVyRj+ynxCgqboDqK7JUX6sHppPV8MOf8o0LQJkhlXGow+r UbWQC2i8rf2Iw6UIkTjlT+d12aaklPwbyD7Hgnr/ZFcasOPrvkdlZuDKiwrG94lzX5G+ 9FY+9KLOWYGfkANNU8asSpM5TFPCqbb0bSDaQZlCazm9EFUGQG3bufOJW9MUtrAMV1eV D1tgCjVRENst+NzIjLl4sUHwIPj3voOCEfEmxCyR2ACYxUQ3j7YpxrB3B9q7G4lSzyt2 JgXw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=VlohUSl7CbgD0V3avyam6oAfaF5ruPzbQYvmFgUX/HQ=; b=Dz0L2N0aLVV4+tKlAsvirtaEBGO6FW0pneK5K5MOCaOHDnuJ59hge+bwbCXUCk40EB u3ayCysMOer8JNcyOdiv2EbImZJ6E4AYsBv/5r81TghGWe8V9OJau3rw12n8tFJpoNhK HJoktLksMUCahTuxXRrnm1ac371ZMuRqDk4WjGF/M8/kdYWYAys7hiTkOifVKmTG5tJx rszTplnbgsiWyZrMKIcFiFzNNf4eYXearg8OvxyodziNixqykwA8qUh9Xr0SLwsZwFVk L4QOt/7Crq5LLTKlBbznZ5LLEbGgjgwxY5GVDpTrPf6SekoNIlpkLt30yujtImWPX0hT fZEA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w12si3862651pfn.95.2019.02.14.16.56.52; Thu, 14 Feb 2019 16:57:07 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2438840AbfBNQxU (ORCPT + 99 others); Thu, 14 Feb 2019 11:53:20 -0500 Received: from sauhun.de ([88.99.104.3]:54094 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1732639AbfBNQxT (ORCPT ); Thu, 14 Feb 2019 11:53:19 -0500 Received: from localhost (unknown [83.221.228.209]) by pokefinder.org (Postfix) with ESMTPSA id 444002C2817; Thu, 14 Feb 2019 17:53:17 +0100 (CET) Date: Thu, 14 Feb 2019 17:53:15 +0100 From: Wolfram Sang To: Sowjanya Komatineni Cc: thierry.reding@gmail.com, jonathanh@nvidia.com, mkarthik@nvidia.com, smohammed@nvidia.com, talho@nvidia.com, peda@axentia.se, digetx@gmail.com, linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org, linux-i2c@vger.kernel.org Subject: Re: [PATCH V19 5/7] i2c: tegra: Add DMA support Message-ID: <20190214165314.dczoxwkayras5cdr@ninjato> References: <1549998408-9137-1-git-send-email-skomatineni@nvidia.com> <1549998408-9137-5-git-send-email-skomatineni@nvidia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="fvm2hgq32qt7p7oz" Content-Disposition: inline In-Reply-To: <1549998408-9137-5-git-send-email-skomatineni@nvidia.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --fvm2hgq32qt7p7oz Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Feb 12, 2019 at 11:06:46AM -0800, Sowjanya Komatineni wrote: > This patch adds DMA support for Tegra I2C. >=20 > Tegra I2C TX and RX FIFO depth is 8 words. PIO mode is used for > transfer size of the max FIFO depth and DMA mode is used for > transfer size higher than max FIFO depth to save CPU overhead. >=20 > PIO mode needs full intervention of CPU to fill or empty FIFO's > and also need to service multiple data requests interrupt for the > same transaction. This adds delay between data bytes of the same > transfer when CPU is fully loaded and some slave devices has > internal timeout for no bus activity and stops transaction to > avoid bus hang. DMA mode is helpful in such cases. >=20 > DMA mode is also helpful for Large transfers during downloading or > uploading FW over I2C to some external devices. >=20 > Tegra210 and prior Tegra chips use APBDMA driver which is replaced > with GPCDMA on Tegra186 and Tegra194. > This patch uses has_apb_dma flag in hw_feature to differentiate > DMA driver change between Tegra chipset. >=20 > APBDMA driver is registered from module-init level and this patch > also has a change to register I2C driver at module-init level > rather than subsys-init to avoid deferring I2C probe till APBDMA > driver is registered. >=20 > Acked-by: Thierry Reding > Reviewed-by: Dmitry Osipenko > Tested-by: Dmitry Osipenko > Signed-off-by: Sowjanya Komatineni Not directly related to your code, but maybe someone is interested in fixing this rightful checkpatch comment somewhen later: WARNING: Avoid crashing the kernel - try using WARN_ON & recovery code rath= er than BUG() or BUG_ON() #332: FILE: drivers/i2c/busses/i2c-tegra.c:791: + BUG(); --fvm2hgq32qt7p7oz Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCAAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAlxlnPoACgkQFA3kzBSg KbbNOA/9EoHlFIaSVQ4ZqkVUQZf6r88V+QclrcLuuiVPC9DoP0faWi8wUN4IDHES tXjCRrAndBuqcb6wqOEv2b3cZPYTSg0iBDfSlENIpGjlUProkJ+HcQxAEh5lK1lh HwSjlfPfzu28BNvyQeR69c3/6gM56lqVS07EIQg9JCM+ouGVnIQHa1NLg8gf2jJV kTqO/MI+byye+ELjKHVHBpAf60zQ6hIfWLqBn9iuRgRGHQNx4Mks2ov17mAC85UN Kv8YnL6Sf/Aj6NAg+em/cFL+ReXGMeWJxJY4ENJW5IeCgmCDR/0uEr8iroTLy/3p OT2xLBEtF7f15ylTRBmfrdfrdnb3BoNmb7W3VBL9oQWmeJLPG2JFyMBR1GuDDJSg Bb9EeIXAPTxCrLYPWAMnpMDaBi4P6ozx8VjYasJRukGoNgg8PA5VCrxbHOq8bigV Bf4W8JTmyt1YT0Td9c0cWIE2qrwnTFHfyDPgIdQTkw68ArP0R8kOZjo8TH4sTQ+b kq85iZtpPoMA+t+zo3H+3YWv8yvXgGpPfCOVdclFa40b+F/g0Ouxdq0QxW/W4loi sFVHIMVe3NqlA2MB6u9DXRuwmeWvmHkVQepqKfFOdXPlqWR51wtZbf0IZVipXyoy t9WEOVE6KzBNhmahJ5KxSn+qVsp3d1KCNdmWWS9gDn8XLrik4PU= =t5RN -----END PGP SIGNATURE----- --fvm2hgq32qt7p7oz--