Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp1632583ybt; Mon, 15 Jun 2020 05:39:37 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzYI8Bx8PFAauLW5l7Ze9HrfdoFvEwA6fWbdUXpr0Wn+XC+OR+7NRNCfMrmWQj6xOw3j6LQ X-Received: by 2002:a17:906:cd05:: with SMTP id oz5mr27133829ejb.335.1592224777734; Mon, 15 Jun 2020 05:39:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1592224777; cv=none; d=google.com; s=arc-20160816; b=TLE3RP/Uw+IGzpdcQKbCLi0hLbUMw64SgHV3MQLh7AZQM9altV2NgCiyFJRHM7+A7x Yf2Dku5bfDViVO9wE570N+DOkwUlzlALoGo5G7l7SnI166yM4zEHfV8txw16kT3D0nnQ ZV2tXvNJsh1S8Zr/ihseeX77jf6KcdX3UTbmEXHOIe08fmplxIYCxRcjylzNEaPX1i9/ uf6SRaJgJB7ZOURmYxJvbJitj9gzDRmaKDKjLcBPR/Ys8CFo7vS+/GIwSm+BKJ1aKW6C OnsAddtJ5OwtWUG8BCoybNRGp1FgZhDSitzT1Ckw1Nzz+fIB17tGEuZoIPXQbwmCL4fT QoOg== 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:dkim-signature; bh=VP+SGhdJXmYQ18sJWN9cRjLBOW/fIdPB3hCE2nxVy/0=; b=b4qjYRtQYxGZKKsxTRdgEKSCrxXg+RYDuDaXt+cRTKrH4Xpx9Epam/C7Ff2+EeplRs YTmdcjh08kfZztTIEDSjlgDtlewZQF3kx5p9fFqmU+rwUMho3269UGrY9TL2bLotySz4 YXnfruaN4V4MiW1LbNHvq0O3juq0zdwtdro6gGwEfEPOl086HCzd1z9Yj/XoqIKAFMBY ephgu+Rv2/wD/T6mB0r5ihdTPoK/IOPpJWOmR18O+lTIyezqJU8GJyPs85lzGwzEi29e S72vuAccz6mI7sXcU17ed/sEv5l9291KqD/KWyOX0i3GSOg3StUKI/SOJArOLH1aJLSI kINw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=RnslLA8y; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r15si8475769ejs.733.2020.06.15.05.39.14; Mon, 15 Jun 2020 05:39:37 -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; dkim=pass header.i=@kernel.org header.s=default header.b=RnslLA8y; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729846AbgFOMf5 (ORCPT + 99 others); Mon, 15 Jun 2020 08:35:57 -0400 Received: from mail.kernel.org ([198.145.29.99]:52176 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728326AbgFOMf4 (ORCPT ); Mon, 15 Jun 2020 08:35:56 -0400 Received: from localhost (fw-tnat.cambridge.arm.com [217.140.96.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 67AC6206D7; Mon, 15 Jun 2020 12:35:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1592224555; bh=bK7xnMNO32LjNVdhxquamLIt4CNPuSKX3tUtMf1VOH0=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=RnslLA8y44+qEBt1UcgQpOlAoS8fYlwkJBrQqPZn/CI6GGftG9buwdzrJbOJ5EnV6 kkDadIVNUZkx2q1HkVr6dvQaX3OyUyGZDvUIKt5RJwzRE6jCYtR5dMfT2DDo7aHBSS Dc6jNSlFc5IMjIVoR/DDJkYX7gUPB8I8NlA3HNmk= Date: Mon, 15 Jun 2020 13:35:53 +0100 From: Mark Brown To: Robin Gong Cc: Vinod Koul , "shawnguo@kernel.org" , "s.hauer@pengutronix.de" , "festevam@gmail.com" , "robin.murphy@arm.com" , "matthias.schiffer@ew.tq-group.com" , "kernel@pengutronix.de" , dl-linux-imx , "linux-spi@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" Subject: Re: [PATCH v1 RFC 1/2] spi: introduce fallback to pio Message-ID: <20200615123553.GP4447@sirena.org.uk> References: <1591880310-1813-1-git-send-email-yibin.gong@nxp.com> <1591880310-1813-2-git-send-email-yibin.gong@nxp.com> <20200611134042.GG4671@sirena.org.uk> <20200612101357.GA5396@sirena.org.uk> <20200612141611.GI5396@sirena.org.uk> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="Zfao1/4IORAeFOVj" Content-Disposition: inline In-Reply-To: X-Cookie: Offer may end without notice. User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --Zfao1/4IORAeFOVj Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Jun 14, 2020 at 01:04:57PM +0000, Robin Gong wrote: > On 2020/06/12 22:16 Mark Brown wrote:=20 > > On Fri, Jun 12, 2020 at 01:48:41PM +0000, Robin Gong wrote: > > > On 2020/06/12 18:14 Mark Brown wrote: Please delete unneeded context from mails when replying. Doing this makes it much easier to find your reply in the message, helping ensure it won't be missed by people scrolling through the irrelevant quoted material. > > No, I mean that the reason the DMA transfer fails may be something that > > happens after we've started putting things on the bus - the bit about F= IFOs is > > just a random example of an error that could happen. > Sorry Mark for that I can't get your point... The bus error such as data = corrupt > seems not the spi core's business since it can only be caught in spi cont= roller > driver or upper level such as mtd driver (spi-nor) which know what's the = failure > happen at spi bus HW level or what's the correct data/message. In other w= ords, > spi core can't detect such error by transfer_one(). If we see an error in transfer_one() it could be from anything, we've no idea what happened on the bus - the controller may have got part way through the transfer before failing. > But despite of that case, do you think this patch is valid for transfer_o= ne() failue > in dma and fallback to pio? No, not unless we know that nothing went out on the bus. --Zfao1/4IORAeFOVj Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAl7naygACgkQJNaLcl1U h9AKiwf+K/TO3gWH9vQYkVSNuWGp+wzROetikqE2P9cbQxa+EuwVUJ5cU8EOCUJV jUiCbGsdl41kpqm98zYU5CZy2M5hvulcfdFOi19uGDGXn8VGNRYELhUG39RvKxSM w+toG6fA6tvkm2nDoiiKG3N9f7mH3DgLTRw5MX631cATsLhZ5jlZnxmZOx7RH1KG t3Cz7VEz/t4IK+HgEhk+s2Tr0fwioHjAuFuaor6s1CFkkxeRQ95bTqIJy/nLC8ws Y5B+i4ul0d3lL5HAx7kssr41wpo7Iy/gTaG8/EEecEtpXOt3bJjhOnwYYUJ4oD7t oKFeiaZtcsy2T2uo9sH/54P9RFN2KQ== =5gqF -----END PGP SIGNATURE----- --Zfao1/4IORAeFOVj--