From: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
To: Maciej Falkowski <maciej.falkowski@linux.intel.com>,
dri-devel@lists.freedesktop.org
Cc: oded.gabbay@gmail.com, quic_jhugo@quicinc.com,
Karol Wachowski <karol.wachowski@intel.com>
Subject: Re: [PATCH 08/14] accel/ivpu: Fix missing MMU events from reserved SSID
Date: Thu, 9 Jan 2025 09:27:31 +0100 [thread overview]
Message-ID: <9da84826-7ac4-4623-ad19-96648c5c8fea@linux.intel.com> (raw)
In-Reply-To: <20250107173238.381120-9-maciej.falkowski@linux.intel.com>
Reviewed-by: Jacek Lawrynowicz <jacek.lawrynowicz@linux.intel.com>
On 1/7/2025 6:32 PM, Maciej Falkowski wrote:
> From: Karol Wachowski <karol.wachowski@intel.com>
>
> Generate recovery when fault from reserved context is detected.
> Add Abort (A) bit to reserved (1) SSID to ensure NPU also receives a fault.
>
> There is no way to create a file_priv with reserved SSID
> but it is still possible to receive MMU faults from that SSID
> as it is a default NPU HW setting. Such situation will occur if
> FW freed context related resources but still performed access to DRAM.
>
> Signed-off-by: Karol Wachowski <karol.wachowski@intel.com>
> Signed-off-by: Maciej Falkowski <maciej.falkowski@linux.intel.com>
> ---
> drivers/accel/ivpu/ivpu_mmu.c | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/accel/ivpu/ivpu_mmu.c b/drivers/accel/ivpu/ivpu_mmu.c
> index ae1dcd04051c..b80bdded9fd7 100644
> --- a/drivers/accel/ivpu/ivpu_mmu.c
> +++ b/drivers/accel/ivpu/ivpu_mmu.c
> @@ -725,8 +725,8 @@ static int ivpu_mmu_cdtab_entry_set(struct ivpu_device *vdev, u32 ssid, u64 cd_d
> cd[2] = 0;
> cd[3] = 0x0000000000007444;
>
> - /* For global context generate memory fault on VPU */
> - if (ssid == IVPU_GLOBAL_CONTEXT_MMU_SSID)
> + /* For global and reserved contexts generate memory fault on VPU */
> + if (ssid == IVPU_GLOBAL_CONTEXT_MMU_SSID || ssid == IVPU_RESERVED_CONTEXT_MMU_SSID)
> cd[0] |= IVPU_MMU_CD_0_A;
>
> if (valid)
> @@ -945,7 +945,8 @@ void ivpu_mmu_irq_evtq_handler(struct ivpu_device *vdev)
>
> while ((event = ivpu_mmu_get_event(vdev))) {
> ssid = FIELD_GET(IVPU_MMU_EVT_SSID_MASK, *event);
> - if (ssid == IVPU_GLOBAL_CONTEXT_MMU_SSID) {
> + if (ssid == IVPU_GLOBAL_CONTEXT_MMU_SSID ||
> + ssid == IVPU_RESERVED_CONTEXT_MMU_SSID) {
> ivpu_mmu_dump_event(vdev, event);
> ivpu_pm_trigger_recovery(vdev, "MMU event");
> return;
next prev parent reply other threads:[~2025-01-09 8:27 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-07 17:32 [PATCH 00/14] accel/ivpu: Changes for 6.14 Maciej Falkowski
2025-01-07 17:32 ` [PATCH 01/14] accel/ivpu: Separate DB ID and CMDQ ID allocations from CMDQ allocation Maciej Falkowski
2025-01-09 8:22 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 02/14] accel/ivpu: Add API for command queue create/destroy/submit Maciej Falkowski
2025-01-09 8:22 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 03/14] accel/ivpu: Abort all jobs after command queue unregister Maciej Falkowski
2025-01-09 8:23 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 04/14] accel/ivpu: Expose NPU memory utilization info in sysfs Maciej Falkowski
2025-01-08 19:53 ` Lizhi Hou
2025-01-09 8:19 ` Jacek Lawrynowicz
2025-01-09 8:24 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 05/14] accel/ivpu: Use workqueue for IRQ handling Maciej Falkowski
2025-01-09 8:26 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 06/14] accel/ivpu: Dump only first MMU fault from single context Maciej Falkowski
2025-01-09 8:26 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 07/14] accel/ivpu: Move parts of MMU event IRQ handling to thread handler Maciej Falkowski
2025-01-09 8:27 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 08/14] accel/ivpu: Fix missing MMU events from reserved SSID Maciej Falkowski
2025-01-09 8:27 ` Jacek Lawrynowicz [this message]
2025-01-07 17:32 ` [PATCH 09/14] accel/ivpu: Set command queue management capability based on HWS Maciej Falkowski
2025-01-09 8:28 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 10/14] accel/ivpu: Fix locking order in ivpu_cmdq_destroy_ioctl Maciej Falkowski
2025-01-09 8:28 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 11/14] accel/ivpu: Fix locking order in ivpu_job_submit Maciej Falkowski
2025-01-09 8:28 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 12/14] accel/ivpu: Add handling of VPU_JSM_STATUS_MVNCI_CONTEXT_VIOLATION_HW Maciej Falkowski
2025-01-09 8:29 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 13/14] accel/ivpu: Add platform detection for presilicon Maciej Falkowski
2025-01-09 8:29 ` Jacek Lawrynowicz
2025-01-07 17:32 ` [PATCH 14/14] accel/ivpu: Enable HWS by default on all platforms Maciej Falkowski
2025-01-08 18:19 ` [PATCH 00/14] accel/ivpu: Changes for 6.14 Simona Vetter
2025-01-09 8:14 ` Jacek Lawrynowicz
2025-01-09 8:43 ` Jacek Lawrynowicz
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=9da84826-7ac4-4623-ad19-96648c5c8fea@linux.intel.com \
--to=jacek.lawrynowicz@linux.intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=karol.wachowski@intel.com \
--cc=maciej.falkowski@linux.intel.com \
--cc=oded.gabbay@gmail.com \
--cc=quic_jhugo@quicinc.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.