linux-spi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Gerhard Sittig <gsi-ynQEQJNshbs@public.gmane.org>
To: Mark Brown <broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
Cc: linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linaro-kernel-cunTk1MwBs8s++Sfvej+rw@public.gmane.org,
	Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
Subject: Re: [PATCH] spi: Fix handling of cs_change in core implementation
Date: Mon, 31 Mar 2014 09:45:29 +0200	[thread overview]
Message-ID: <20140331074529.GE2775@book.gsilab.sittig.org> (raw)
In-Reply-To: <1396139265-28900-1-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>

On Sun, 2014-03-30 at 00:27 +0000, Mark Brown wrote:
> 
> From: Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
> 
> The core implementation of cs_change didn't follow the documentation
> which says that cs_change in the middle of the transfer means to briefly
> deassert chip select, instead it followed buggy drivers which change the
> polarity of chip select.  Use a delay of 10us between deassert and
> reassert simply from pulling numbers out of a hat.
> 
> Reported-by: Gerhard Sittig <gsi-ynQEQJNshbs@public.gmane.org>
> Signed-off-by: Mark Brown <broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>

The change looks good to me.  The resulting behaviour now is what
the documentation suggests (brief deassertion of the CS signal).
The previous inversion was unexpected.

The delay between deassertion and re-assertion looks good, too.
It allows for propagation of the change through the hardware.
Those who need longer pauses still can construct individual
messages.  There's probably no need to change the boolean
"cs_change" into a numerical "deassertion pause length" spec.


virtually yours
Gerhard Sittig
-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr. 5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80  Email: office-ynQEQJNshbs@public.gmane.org
--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2014-03-31  7:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-30  0:27 [PATCH] spi: Fix handling of cs_change in core implementation Mark Brown
     [not found] ` <1396139265-28900-1-git-send-email-broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2014-03-31  7:45   ` Gerhard Sittig [this message]
     [not found]     ` <20140331074529.GE2775-kDjWylLy9wD0K7fsECOQyeGNnDKD8DIp@public.gmane.org>
2014-03-31 17:17       ` Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140331074529.GE2775@book.gsilab.sittig.org \
    --to=gsi-ynqeqjnshbs@public.gmane.org \
    --cc=broonie-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
    --cc=broonie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org \
    --cc=linaro-kernel-cunTk1MwBs8s++Sfvej+rw@public.gmane.org \
    --cc=linux-spi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).