Linux kernel -stable discussions
 help / color / mirror / Atom feed
From: Lee Jones <lee@kernel.org>
To: Rahul Pathak <rahul.pathak@oss.qualcomm.com>
Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org,
	Albert Ou <aou@eecs.berkeley.edu>,
	Alexandre Ghiti <alex@ghiti.fr>,
	Anup Patel <apatel@ventanamicro.com>,
	Jassi Brar <jassisinghbrar@gmail.com>,
	linux-riscv@lists.infradead.org,
	Palmer Dabbelt <palmer@dabbelt.com>,
	Paul Walmsley <pjw@kernel.org>,
	Rahul Pathak <rahul@summations.net>
Subject: Re: [PATCH 03/10] mailbox: riscv-sbi-mpxy: Protect per-CPU shmem access with irqsave
Date: Thu, 3 Dec 2026 15:05:06 +0000	[thread overview]
Message-ID: <20261203150506.GK98551@kernel.org> (raw)
In-Reply-To: <CAFR3w37A48LJkACSMnbmmMwdJR1d_GWwhe4bt+0VBZaEnXFwEA@mail.gmail.com>

On Thu, 03 Dec 2026, Rahul Pathak wrote:

> On Thu, Dec 3, 2026 at 1:59 PM Lee Jones <lee@kernel.org> wrote:
> >
> > The SBI MPXY helpers evaluate this_cpu_ptr(&mpxy_local) before calling
> > get_cpu(), allowing CPU migration between computing the per-CPU pointer
> > and disabling preemption.  They also leave local interrupts enabled
> > while using the per-CPU shared memory buffer, allowing a hardirq caller
> > (such as mbox_send_message() or mpxy_mbox_msi_write()) to clobber the
> > shared memory buffer mid-operation.
> >
> > Use guard(irqsave)() across all per-CPU shared memory helpers and fetch
> > this_cpu_ptr(&mpxy_local) inside the IRQ-disabled section.
> >
> > Fixes: bf3022a4eb11 ("mailbox: Add RISC-V SBI message proxy (MPXY) based mailbox driver")
> > Closes: https://sashiko.dev/#/bug/linux-d2c1eefe-4777-4ad6-94c5-504e347f3add
> > Cc: stable@vger.kernel.org
> > Signed-off-by: Lee Jones <lee@kernel.org>
> > ---
> >
> 
> This patch is not needed as its being
> already taken care by earlier patch sent
> but not yet merged -
> https://lists.infradead.org/pipermail/linux-riscv/2026-November/104034.html

Noted.  Thanks for letting me know.

-- 
Lee Jones

  reply	other threads:[~2026-12-03 15:05 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1796286447.git.lee@kernel.org>
2026-12-03  8:28 ` [PATCH 01/10] mailbox: qcom-ipcc: Skip of_node_put() on phandle parse failure Lee Jones
2026-12-03 10:38   ` Konrad Dybcio
2026-12-03  8:28 ` [PATCH 02/10] mailbox: ti-msgmgr: Use unsigned IDs in ti_msgmgr_of_xlate() Lee Jones
2026-12-03  8:28 ` [PATCH 03/10] mailbox: riscv-sbi-mpxy: Protect per-CPU shmem access with irqsave Lee Jones
2026-12-03 14:32   ` Rahul Pathak
2026-12-03 15:05     ` Lee Jones [this message]
2026-12-03  8:28 ` [PATCH 04/10] mailbox: riscv-sbi-mpxy: Validate shmem bounds in message send helpers Lee Jones
2026-12-03  8:28 ` [PATCH 05/10] mailbox: bcm-pdc: Unregister mailbox controller before destroying DMA pools Lee Jones
2026-12-03  8:28 ` [PATCH 06/10] mailbox: qcom-ipcc: Remove IRQ domain via devm to avoid ISR use-after-free Lee Jones
2026-12-03 10:39   ` Konrad Dybcio
2026-12-03  8:28 ` [PATCH 07/10] mailbox: sun6i-msgbox: Free IRQ before disabling clock on teardown Lee Jones
2026-12-03 13:43   ` Chen-Yu Tsai
2026-12-03  8:28 ` [PATCH 08/10] mailbox: sun6i-msgbox: Synchronise IRQ during channel shutdown Lee Jones
2026-12-03 13:49   ` Chen-Yu Tsai
2026-12-03  8:28 ` [PATCH 09/10] mailbox: arm_mhu_db: Initialise channel registers before controller registration Lee Jones
2026-12-03  9:40   ` Sudeep Holla
2026-12-03  8:28 ` [PATCH 10/10] mailbox: ti-msgmgr: Return -EIO on queue error in ti_msgmgr_send_data() Lee Jones

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=20261203150506.GK98551@kernel.org \
    --to=lee@kernel.org \
    --cc=alex@ghiti.fr \
    --cc=aou@eecs.berkeley.edu \
    --cc=apatel@ventanamicro.com \
    --cc=jassisinghbrar@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=palmer@dabbelt.com \
    --cc=pjw@kernel.org \
    --cc=rahul.pathak@oss.qualcomm.com \
    --cc=rahul@summations.net \
    --cc=stable@vger.kernel.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