Received: by 2002:a05:6a10:1a4d:0:0:0:0 with SMTP id nk13csp3077782pxb; Thu, 10 Feb 2022 11:43:02 -0800 (PST) X-Google-Smtp-Source: ABdhPJwCurGMgL2TvUhq+i4bSVokay+HWL+eqk0djmJ2wrEcW5iyntMhrVz5n8Ue5sv0Zk5p9mX9 X-Received: by 2002:a17:907:94cd:: with SMTP id dn13mr6668909ejc.580.1644522182491; Thu, 10 Feb 2022 11:43:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644522182; cv=none; d=google.com; s=arc-20160816; b=hAtOxX+k6lIjyvFUYjiLIO8C7OLiScn4YlM0HeemxUnGhhvI4J6GCKcNUo9u0EP3MW 0CBGiIuVjgnkfY9igY+RGVeZQ8Jk5SSP6wgvjAtpcCLJOYctZLPoLdVEdGTnBTwjVbxJ CH1Ew2yRAL540Bi9MSQTy/drPaDtAO5h7v6RrkK0616iztxbgRFZJsnSja/VyAkDP9Mx 1STjTOGnpu0hdbXJOhPAqP9s92xVyeGUensGlfdM3n8+Dk/48lZBTawTqL8uCdzHWbYI iQ8J4354WauHQEldp5xkS5C6GgnpnBLhQjcp6LaG5V4RBL86QCLQQLJe4838NRIxQWxZ qLZQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=MuDFPWudQJ0Bu2GOjXbY7nMMi/fJxwN0O/SJ5vYvn7c=; b=nq0PMw3H69u8lnXdR/Ie0bkuzChK1lNU+wB7QAmzADR6CUHWHswHYcArDydrlhakTo b6TKK3WODPWiYW1Z1qcRy/kscfbM/rAPC9nevnBRHn8UGAv6MFtcb5eCICydnYOz9f3f kndC13/9aeWkIkqA/u1lY+Q8570UgC6ms9rdfswWdO0/hUTIKUmWDTHGoMXkyns3GHMB aTqyeUZTMHFpYeNspuRYTaqqQcu7ZQdTymwTDgd0vM8tLl8UTTRiEJfbLMmUe2XIws4T ZKJIjqxgEDtwFxgvgXAyIySqHvd7bCj/AqEW83N/mWv61Gxi+pZlluSY+c3550YszmI/ BINA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=l5QTW9HA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id du1si1797438ejc.978.2022.02.10.11.42.35; Thu, 10 Feb 2022 11:43:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=l5QTW9HA; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 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 S243868AbiBJP5v (ORCPT + 99 others); Thu, 10 Feb 2022 10:57:51 -0500 Received: from mxb-00190b01.gslb.pphosted.com ([23.128.96.19]:47586 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243856AbiBJP5t (ORCPT ); Thu, 10 Feb 2022 10:57:49 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B3C68A1; Thu, 10 Feb 2022 07:57:50 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 5016B61C77; Thu, 10 Feb 2022 15:57:50 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A1F27C004E1; Thu, 10 Feb 2022 15:57:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1644508669; bh=5a0H2dZ8NHiNHJT624T80SiJuLxas7HwdA6coL6AIJs=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=l5QTW9HAsjdNi2/UJAjlx35fw12/TB6rehsgpGyA/+E6Hn1gKWbB1N+CEWkh1nBnp BUVdN2oxaXOSDxP5412EVZVOenYKjNYbdKDjqJpMibv7wLM2E9A38mLdhDTE9wCX47 HlPbwNrR1DuiCdxIex0X/w27aNXiVBiog8QoMTy/VRgCl55o3+RGlQ+5FM1duFd8vT xgOziHICD2DdyUby81ZtD4PxmGDOAy131tQEXNkREdG8c6YhNOUnf4w8olyIjGyF6n 9A1oumOfvHxJ/0W17r0vniRtCmu3154LSptFLt539HPQFLk2D6Qgc14jqWeqjS82Uq KKiyYZsdIvq0w== Date: Thu, 10 Feb 2022 15:57:45 +0000 From: Mark Brown To: "Zhou, Yun" Cc: "linux-spi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "Xue, Ying" Subject: Re: =?utf-8?B?5Zue5aSN?= =?utf-8?Q?=3A?= [PATCH] spi: disable chipselect after complete transfer Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="YiQuSH9yRC2LqOqw" Content-Disposition: inline In-Reply-To: X-Cookie: Only God can make random selections. X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --YiQuSH9yRC2LqOqw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Feb 10, 2022 at 03:41:41PM +0000, Zhou, Yun wrote: Please don't top post, reply in line with needed context. This allows readers to readily follow the flow of conversation and understand what you are talking about and also helps ensure that everything in the discussion is being addressed. > I am sorry that I can not agree with you. > If there are multiple messages, and each message only has one xfer, > and the cs_change of each xfer is 1, during the transmission of the > messages, the CS will keep active even until at the end. This must be > unreasonable. This is not something that most drivers are expected to use, cs_change should only be being used at all for very unusual hardware and it should be used even less frequently for the last transfer in a message. It is fragile and anyone using it really needs to know what they're doing but the feature is there. > I can't understand why it have to keep CS active after the > transmission is completed. Could you please explain this in detail? The feature predates me working on the SPI stack, the obvious examples would be a device that doesn't actually use chip select where you want to avoid all chip select changes or if you need to do some other actions in the middle of a SPI transaction for some reason (which would need a bunch of system level considerations to actually be safe/sensible like making sure you're not sharing the SPI bus). Please fix your mail client to word wrap within paragraphs at something substantially less than 80 columns. Doing this makes your messages much easier to read and reply to. --YiQuSH9yRC2LqOqw Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmIFNfgACgkQJNaLcl1U h9AQQAf/ZYZzgXlybdG4bmNaHaYY6Cr0wodK4VZNJVP7SilnxhpMEOGIrIed8Wct D3O1mkLf6+qEMFfNQEab0cn9K/etC2aZIzJ0r32uHIkAyXdBTqlgc8nMdv4mlxiy kUaJlaqbndbwyTO0qDtJ36ivojXQMMhotL74z4yd+AGTZvR45qYI0+8ulgRAj2tq VMdCPGXVvXN84zDdGoPSwzdex5aFgw/HNkrFLRyQICTOZ9+pjRfR0S/vQbWYqLk2 GM32zJ7q0DLYDV2U5+JqPnDvEEPtzjnUW+2MtIwRvfrOqtqYZQp5WBRrE7ouHZsi A4JOaFntUJChwkfupM1fU8NV3QFasw== =4awE -----END PGP SIGNATURE----- --YiQuSH9yRC2LqOqw--