linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: dwalker@codeaurora.org (Daniel Walker)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] serial: DCC(JTAG) serial and console emulation support
Date: Wed, 06 Oct 2010 09:40:43 -0700	[thread overview]
Message-ID: <1286383243.22265.124.camel@m0nster> (raw)
In-Reply-To: <alpine.LFD.2.00.1010061207090.3107@xanadu.home>

On Wed, 2010-10-06 at 12:22 -0400, Nicolas Pitre wrote:
> On Wed, 6 Oct 2010, Daniel Walker wrote:
> 
> > On Wed, 2010-10-06 at 11:47 -0400, Nicolas Pitre wrote:
> > 
> > > It is the wrong fix nevertheless.  And in this case it isn't a question 
> > > of opinion.
> > 
> > I'm not saying your wrong, I'm sure you know more about it than I do. I
> > was just letting you know why I added it .
> 
> Sure.  However it is best to _understand_ why such things may apparently 
> fix things.  In this case it would have been by accident, and the code 
> could be broken again with a different gcc version.
> 
> Adding "cc" in the clobber list is needed only when the asm code is 
> modifying the condition flags.
> 
> I'd suggest you look at the disassembly difference with and without it. 
> My guess is that the whole thing gets optimized away as there is no 
> dependencies to be dependent on, in which case the proper fix would be 
> to mark it with "volatile".

Are you saying it's not needed for either the __dcc_putchar or
__dcc_getchar ?

With __dcc_getchar() Jeff O. (who is CC'd) discovered that the assembly
was setup in a way that assumed the condition bits were not touched, but
since they did get touched we ended up missing a branch in dcc_rx_chars
for checking if "tty" is set. Since we're branching in the assembly I'm
assuming we must be setting condition bits with the mrc instruction. 

So for __dcc_getchar it seems like it for sure is need .. 

For  __dcc_putchar I add "cc" also because again we're branching, so I'm
assuming we're also setting condition bits.

Daniel


-- 
Sent by an consultant of the Qualcomm Innovation Center, Inc.
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora
Forum.

  reply	other threads:[~2010-10-06 16:40 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-05 19:07 [PATCH] serial: DCC(JTAG) serial and console emulation support Daniel Walker
2010-10-06  2:55 ` Nicolas Pitre
2010-10-06 13:48   ` Daniel Walker
2010-10-06 14:22     ` Nicolas Pitre
2010-10-06 14:49       ` Daniel Walker
2010-10-06 15:21         ` Nicolas Pitre
2010-10-06 15:33           ` Daniel Walker
2010-10-06 15:47             ` Nicolas Pitre
2010-10-06 15:54               ` Daniel Walker
2010-10-06 16:22                 ` Nicolas Pitre
2010-10-06 16:40                   ` Daniel Walker [this message]
2010-10-06 17:02                     ` Nicolas Pitre
2010-10-06 17:07                       ` Daniel Walker
2010-10-07 21:27 ` Tony Lindgren
2010-10-07 21:58   ` Daniel Walker
2010-10-08  1:28     ` Nicolas Pitre
2010-10-08 20:35       ` Tony Lindgren
2010-10-08 20:59         ` Tony Lindgren
2010-10-08 21:27         ` Nicolas Pitre
2010-10-08 20:36     ` Tony Lindgren
2010-10-08  1:25   ` Nicolas Pitre
2010-10-08 20:32     ` Tony Lindgren
2010-10-08 20:58       ` Tony Lindgren
2010-10-08 21:28         ` Nicolas Pitre
2010-10-08 21:25       ` Nicolas Pitre
2010-10-08 21:49         ` Tony Lindgren
2010-10-09  0:57           ` Nicolas Pitre
2010-10-13 15:21 ` Arnd Bergmann
2010-10-13 16:17   ` Daniel Walker
2010-10-13 17:44     ` Arnd Bergmann
2010-10-13 18:08       ` Daniel Walker
2010-10-13 19:45         ` Arnd Bergmann
2010-10-13 19:52           ` Daniel Walker
2010-10-13 20:10             ` Arnd Bergmann
2010-10-13 20:24               ` Daniel Walker
2010-10-13 20:44                 ` Nicolas Pitre
2010-10-13 20:49                   ` Daniel Walker
2010-10-13 22:51                     ` Nicolas Pitre
2010-10-13 23:26                       ` Russell King - ARM Linux
2010-10-13 23:41                         ` Nicolas Pitre
2010-10-13 19:55         ` Nicolas Pitre
2010-10-13 20:00           ` Daniel Walker
2010-10-13 20:27             ` Nicolas Pitre
2010-10-13 20:47               ` Daniel Walker
2010-10-13 22:05                 ` Daniel Walker

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=1286383243.22265.124.camel@m0nster \
    --to=dwalker@codeaurora.org \
    --cc=linux-arm-kernel@lists.infradead.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).