From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: "Luis Claudio R. Goncalves" <lgoncalv@redhat.com>
Cc: Linux RT Users <linux-rt-users@vger.kernel.org>,
Thomas Gleixner <tglx@linutronix.de>,
Steven Rostedt <rostedt@goodmis.org>
Subject: Re: [PATCH v6.4-rc5-rt4] rt: vmd: make cfg_lock a raw spinlock
Date: Tue, 20 Jun 2023 17:44:34 +0200 [thread overview]
Message-ID: <20230620154434.MosrzRUh@linutronix.de> (raw)
In-Reply-To: <ZIJwNBZa0UUTAx5i@uudg.org>
On 2023-06-08 21:20:04 [-0300], Luis Claudio R. Goncalves wrote:
> Sebastian, Steven,
>
> I don't know if this is the best solution for the problem, but surely the
> simplest one. If this patch makes sense, it could probably go upstream as
> the changes only affect RT.
Lockdep should complain, too because the locking order here is
raw_spinlock_t -> spinlock_t.
Instead of making the lock raw, I would argue to remove the lock an safe
a few cycles. The lock is only used by vmd_pci_read() and
vmd_pci_write(). Both functions are invoked by pci_bus_read_config_*()
or pci_bus_write_config_*() and both acquire pci_lock first. Therefore
the lock does not add any benefit because vmd_pci_read() vs
vmd_pci_write() is already serialized.
If you make the patch feel free to reuse the wording above.
From a quick look,
drivers/pci/controller/pci-tegra.c
drivers/pci/controller/pcie-rcar-host.c
could use some care ;)
Sebastian
prev parent reply other threads:[~2023-06-20 15:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-09 0:20 [PATCH v6.4-rc5-rt4] rt: vmd: make cfg_lock a raw spinlock Luis Claudio R. Goncalves
2023-06-09 1:02 ` Steven Rostedt
2023-06-20 15:44 ` Sebastian Andrzej Siewior [this message]
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=20230620154434.MosrzRUh@linutronix.de \
--to=bigeasy@linutronix.de \
--cc=lgoncalv@redhat.com \
--cc=linux-rt-users@vger.kernel.org \
--cc=rostedt@goodmis.org \
--cc=tglx@linutronix.de \
/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