From: Alistair Francis <alistair23@gmail.com>
To: "Philippe Mathieu-Daudé" <philmd@redhat.com>
Cc: "qemu-devel@nongnu.org Developers" <qemu-devel@nongnu.org>,
"Peter Maydell" <peter.maydell@linaro.org>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Alistair Francis" <alistair@alistair23.me>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>
Subject: Re: [Qemu-devel] [PATCH] hw/char/stm32f2xx_usart: Do not update data register when device is disabled
Date: Fri, 4 Jan 2019 11:47:43 -0800 [thread overview]
Message-ID: <CAKmqyKON+qf_+8sGYtaudLLcccdDz96SkiCNn_XztnJr8_m7bA@mail.gmail.com> (raw)
In-Reply-To: <8176371f-6dff-adee-84d1-5758ed74700c@redhat.com>
On Fri, Jan 4, 2019 at 10:31 AM Philippe Mathieu-Daudé
<philmd@redhat.com> wrote:
>
> On 1/4/19 7:20 PM, Philippe Mathieu-Daudé wrote:
> > When the device is disable, the internal circuitry keep the data
>
> "keep" -> "keeps"
>
> > register loaded and doesn't update it.
> >
> > Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Alistair
> > ---
> > hw/char/stm32f2xx_usart.c | 3 +--
> > 1 file changed, 1 insertion(+), 2 deletions(-)
> >
> > diff --git a/hw/char/stm32f2xx_usart.c b/hw/char/stm32f2xx_usart.c
> > index f3363a2952..10392c70e2 100644
> > --- a/hw/char/stm32f2xx_usart.c
> > +++ b/hw/char/stm32f2xx_usart.c
> > @@ -53,14 +53,13 @@ static void stm32f2xx_usart_receive(void *opaque, const uint8_t *buf, int size)
> > {
> > STM32F2XXUsartState *s = opaque;
> >
> > - s->usart_dr = *buf;
> > -
> > if (!(s->usart_cr1 & USART_CR1_UE && s->usart_cr1 & USART_CR1_RE)) {
> > /* USART not enabled - drop the chars */
> > DB_PRINT("Dropping the chars\n");
> > return;
> > }
> >
> > + s->usart_dr = *buf;
> > s->usart_sr |= USART_SR_RXNE;
> >
> > if (s->usart_cr1 & USART_CR1_RXNEIE) {
> >
>
next prev parent reply other threads:[~2019-01-04 19:48 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-04 18:20 [Qemu-devel] [PATCH] hw/char/stm32f2xx_usart: Do not update data register when device is disabled Philippe Mathieu-Daudé
2019-01-04 18:31 ` Philippe Mathieu-Daudé
2019-01-04 19:47 ` Alistair Francis [this message]
2019-01-08 11:53 ` Peter Maydell
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=CAKmqyKON+qf_+8sGYtaudLLcccdDz96SkiCNn_XztnJr8_m7bA@mail.gmail.com \
--to=alistair23@gmail.com \
--cc=alistair@alistair23.me \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=philmd@redhat.com \
--cc=qemu-devel@nongnu.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).