Linux Serial subsystem development
 help / color / mirror / Atom feed
From: Jiri Slaby <jirislaby@kernel.org>
To: Dan Carpenter <dan.carpenter@linaro.org>
Cc: Elen Song <elen.song@atmel.com>,
	Richard Genoud <richard.genoud@gmail.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Nicolas Ferre <nicolas.ferre@microchip.com>,
	Alexandre Belloni <alexandre.belloni@bootlin.com>,
	Claudiu Beznea <claudiu.beznea@microchip.com>,
	Ludovic Desroches <ludovic.desroches@atmel.com>,
	linux-serial@vger.kernel.org, kernel-janitors@vger.kernel.org
Subject: Re: [PATCH] serial: atmel: don't enable IRQs prematurely
Date: Tue, 20 Jun 2023 06:50:02 +0200	[thread overview]
Message-ID: <0876fda2-80ca-20f9-397d-6990e3f40e98@kernel.org> (raw)
In-Reply-To: <0be8c2ad-499a-4cf1-af98-920af542c5b9@kadam.mountain>

On 19. 06. 23, 13:47, Dan Carpenter wrote:
> On Mon, Jun 19, 2023 at 02:44:11PM +0300, Dan Carpenter wrote:
>> On Mon, Jun 19, 2023 at 01:01:49PM +0200, Jiri Slaby wrote:
>>> On 19. 06. 23, 11:45, Dan Carpenter wrote:
>>>> The atmel_complete_tx_dma() function disables IRQs at the start
>>>> of the function by calling spin_lock_irqsave(&port->lock, flags);
>>>> There is no need to disable them a second time using the
>>>> spin_lock_irq() function and, in fact, doing so is a bug because
>>>> it will enable IRQs prematurely when we call spin_unlock_irq().
>>>>
>>>> Just use spin_lock/unlock() instead without disabling or enabling
>>>> IRQs.
> 
> Maybe I should add a "a second time".
> 
> "Just use spin_lock/unlock() instead without disabling or enabling
> IRQs a second time."

No, I'm just stupid and I apparently fail to understand written text at 
times.

Reviewed-by: Jiri Slaby <jirislaby@kernel.org>

thanks,
-- 
js
suse labs


  reply	other threads:[~2023-06-20  4:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-19  9:45 [PATCH] serial: atmel: don't enable IRQs prematurely Dan Carpenter
2023-06-19 11:01 ` Jiri Slaby
2023-06-19 11:44   ` Dan Carpenter
2023-06-19 11:47     ` Dan Carpenter
2023-06-20  4:50       ` Jiri Slaby [this message]
2023-06-21  8:19         ` Richard Genoud

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=0876fda2-80ca-20f9-397d-6990e3f40e98@kernel.org \
    --to=jirislaby@kernel.org \
    --cc=alexandre.belloni@bootlin.com \
    --cc=claudiu.beznea@microchip.com \
    --cc=dan.carpenter@linaro.org \
    --cc=elen.song@atmel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-serial@vger.kernel.org \
    --cc=ludovic.desroches@atmel.com \
    --cc=nicolas.ferre@microchip.com \
    --cc=richard.genoud@gmail.com \
    /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