Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=103.168.172.155 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1795946687; b=Fc0xvaDdupQZceE5pyhuCjqfHjY9eFmHi6BDYkpYLwGW47tZoZKaOgdBB8JItSUS64b7 2JQv5VayrUkywmXP9cf4PPBTWDaar3ByUG/z/YqEgkvP+gWlm4aA4/gB/kesKkHO1mS5B 7b2NhktUaXnj1ZODSAiMHHoPNB1GS3f07q059wKIlWGjGoWd6kKLZLZyc4OZ6Cbc53uHN 80WhfTdp/v9b8uLrotYmuAsTn8JRe8bdZYgSvm2czyRZ5Xv3B1rpC14BBxFybPZTSokGF poemkseJk/nbkkVLRRoPbGpFLGklkpMimrTUYargOaAiau7nnHlKGQo8qf/3nBtIM8w== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1795946687; h=DMARC-Filter:Received:Received:DKIM-Signature:DKIM-Signature: X-DKIM2-Info:DKIM2-Signature:X-DKIM2-Info:Message-Instance: X-ME-Sender:X-ME-Received:X-ME-Proxy-Cause:X-ME-Proxy:Feedback-ID: Received:From:To:Cc:Subject:Date:Message-ID:X-Mailer:In-Reply-To: References:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=1JHCpF0wmCvmD5xBxyBQBJRhN6JTKE0/iqBI+kMc/eY=; b=h9YePbl2H2rqkeBDkKnj0UQADuKHLRzUiSGzcq3sLsyi1D6a7TTEqAfLnlrcKm+FyHmH 4aUex54bsRg0dCIwV2CAeWsCtffk1UkzEXiubzynilyMfKvmPg2Q/7nQC1XEa3OMWdiM/ w0AKe0FSa8nBtsz6QXIoiYkPk8iCdaxGPm2cReTKFK4OyxX4bRYfBmRrpyxlrLE9Vnb4b pWnDq4Ul8ZZ6VHmpqYhLOhCNb8X7RYV1HGrR0HUmsZgP4asIzQfqtfr+h4QfCyTmbNWD+ +0Vpztw2XR+VinuxTZxge0xOPA0LQ1v1lbz2gu2UKZzyxqZnb+BAMGLWW+VXY5yN7lw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=gahingwoo.com; spf=pass smtp.mailfrom=gahingwoo.com; dkim=pass header.d=gahingwoo.com header.i=@gahingwoo.com header.a=rsa-sha256 header.s=fm2 header.b=mN+f+5sO; dkim=pass header.d=messagingengine.com header.i=@messagingengine.com header.a=rsa-sha256 header.s=fm3 header.b=tZGQrODT; arc=none smtp.remote-ip=103.168.172.155 Received: from fhigh-a4-smtp.messagingengine.com (fhigh-a4-smtp.messagingengine.com [103.168.172.155]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 26FA0606A323 for ; Sun, 29 Nov 2026 10:04:46 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 26FA0606A323 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gahingwoo.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gahingwoo.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key, unprotected) header.d=gahingwoo.com header.i=@gahingwoo.com header.a=rsa-sha256 header.s=fm2 header.b=mN+f+5sO; dkim=pass (2048-bit key, unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.a=rsa-sha256 header.s=fm3 header.b=tZGQrODT Received: from phl-compute-02.internal (phl-compute-02.internal [10.202.2.42]) by mailfhigh.phl.internal (Postfix) with ESMTP id F1FDD14002E9 for ; Sun, 29 Nov 2026 05:04:45 -0500 (EST) Received: from phl-frontend-03 ([10.202.2.162]) by phl-compute-02.internal (MEProxy); Sun, 29 Nov 2026 05:04:45 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gahingwoo.com; h=cc:cc:content-transfer-encoding:content-type:content-type :date:date:from:from:in-reply-to:in-reply-to:message-id :mime-version:references:reply-to:subject:subject:to:to; s=fm2; t=1795946685; x=1796033085; bh=1JHCpF0wmCvmD5xBxyBQBJRhN6JTKE0/ iqBI+kMc/eY=; b=mN+f+5sOzpaMDoUvBscVAW5HrRnFuJ0OEQcFNSvjPSIiqolQ gMenTrvlfKH+fYQ1v6SGbbHliTNLtv/Ea7vGs6CkMP2IVp0eCaTC07PMAo8U2ucA 2dw/wnvNcACrHoAIweR0THPqqfSCWxbUIQMbrL2GFlfU+F4vYroGRaebOyey5xeU +Bw/YqNgRwnxWyqN2TGJ1gCJp7YEF4qm54oSsN0MeXd/x+ngiS+t+751o7mOKrrx Lp+aLw7M7H7kHgT7xE9i07jPNqr6lFNnRDL6Ws54cBHtPV2fW1YZA2nwh+26ixeB 09ShyhHmUA8O6zbGvlLRuysDXxsnNOC9ltGYeQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1795946685; x= 1796033085; bh=1JHCpF0wmCvmD5xBxyBQBJRhN6JTKE0/iqBI+kMc/eY=; b=t ZGQrODT5hePrW72xkbuPwGuYihLe/eJn/18RBgRRV1KTW3BNsrzMfaw6KmFT8ouM KeuMUoCyy3UTf6j2M73Y4YsGrkl7T69yN9wo/E1mG6V0Ksa/RVHSHDGMZfnxyMPf x4tB/pub3/SSO7l7w+t0gALMu8Fn2YDz5QLLFeXwFvcybLU5bmmKK/vAIqiWnfDJ aMDnNlxB1LL9LHKyrO/2GUplDIB7aaMW9RrEukCgvxAkWxnWqDeeqt7CPpBf+VsK ZazNbwFfQw61txRQ6dAGIT64KO028fvg5NtnpsiG764tGG8Kti0PkFMwB+hgqEvk T6Bz7r5S4EbnV6VRKS/Zw== X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-09; repo=github.com/dkim2wg/interop; date=2026-11-03; sw=lmtpprox; action=sign d=gahingwoo.com a=rsa-sha256; DKIM2-Signature: i=1; m=1; t=1795946685; d=gahingwoo.com; mf=PGdhaGluZ0BnYWhpbmd3b28uY29tPg==; rt=PGlvbW11QGxpc3RzLmxpbnV4LmRldj4=; s=fm2:rsa-sha256:FCmmd91hRS11POBVhU5RT/M2N0O+liCBotz823fIWjrmRq6 4i30U9iXdDGBJGDP39eE5UXAWGqxEBq7Ct80l3jmv7M16+E3LaDuQQh/tgceyDl2 4VeMR+Uwd5EH4vPLSidsD4GwvuWpmCEUvIy13VoutIcTMV0lyTSt7KhwBO9e9U9o bqQixqXbgwtEwPoh5jk0qglkriuPfOokKrAiR3Q3glGyGzbaAUuNde+wIaeh0OLp h0lWfMM3xFFR9HXtXtkQsfJLInME4gF6fYLOxNN/KQQuuEdBnTWhSM0vNuGPu7p0 EHOc91gPl1TJ8/mglWDYXEgNB9CKUc7lOi10HWw==; X-DKIM2-Info: draft=ietf-dkim-dkim2-spec-09; repo=github.com/dkim2wg/interop; date=2026-11-03; sw=lmtpprox; action=mi-m=1; hc=12; hn=cc,content-transfer-encoding,content-type,date,feedback-id, from,in-reply-to,message-id,mime-version,references,subject,to; Message-Instance: m=1; h=sha256:uN2LKgRcjdGn9KjD+mUXa/V0U99Dfr2Zt3By89vwTSo=:1JHCpF0wmCvmD5xBxyBQBJRhN6JTKE0/iqBI+kMc/eY=; X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: dmFkZTEHM+rnMrhx1aPg1rsUFeAqSdTUz68VfzCEtfm6GvON9516IkStZTf4ndOL+XiyUR 3Tnvpt3qWmEY9u7GbHT/oMqs915101BFoSFYNrn4gBX69GGy7YzmFUgkuH0UvVh3CCRHtf LAWcZ6sVPqjCZUDohSwY/ATuW8yK9UzNMqA6QeBIGfJ+wEqgoiKoyog4Vo1v32bHlacn7M OJ49O3HhtWvTMqpp4x1DahS5bCeG1Q9TQqW57e4JZNXUNCGSwiTlvQhTo907R1EIoSeuGI VKKCfpFb+GO3RH1Bxp7PiPRfFB2898AzW6A+nznntsJQxyNb4C/tTErAXnYzPtHz1cqKgW JMR4+5Pbfu7aOhmZI2gFJhQgAJ1b6A/Ym+yHkSCSvnGq7s+jjxM6qCO8EYV2jONWpLK892 5FAaPoVPy+wBdcdL6Rqb0JLYpuHxl6DyOvxejeGzLs2XBP/4zY9FLGlJ3LwJ9nV8v7cyPl 5CSRpW9fLtRv1XNX2uyj1ymz4MGNi+pOOFf6P58aLDzS6fTakJgTXbcupTUAEQ9sKHGTfC Yyz0L6dEMYEg8LFmpwdzmP7P+iYdY3sWvkh6cp39v2ZS8bCt0TfhIvpXMROgzOKAJ/nG2g 86PXWhjnEhSrVeM86vqjFCQAcbMhC6L5+Dq3jEyqyWSTg4MhUEbA+mhCRDFw X-ME-Proxy: Feedback-ID: i7a5e4b5f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 29 Nov 2026 05:04:38 -0500 (EST) From: Jiaxing Hu To: Francesco Saverio Pavone Cc: Joerg Roedel , Will Deacon , Robin Murphy , Heiko Stuebner , Sandy Huang , Andy Yan , Chaoyi Chen , Damon Ding , Jagan Teki , Lucas Tanure , Sebastian Reichel , Cristian Ciocaltea , iommu@lists.linux.dev, dri-devel@lists.freedesktop.org, linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org Subject: Re: rk3588: VOP IOMMU faults at boot while the firmware window is on Date: Sun, 29 Nov 2026 23:04:36 +1300 Message-ID: <20261129100436.290926-1-gahing@gahingwoo.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <16FDB47B-9986-417E-B081-89A381BE9411@gmail.com> References: <16FDB47B-9986-417E-B081-89A381BE9411@gmail.com> X-Mailing-List: iommu@lists.linux.dev List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Hi Francesco, I am seeing the same behavior on RK3576 with my EDK2 port (edk2-rk3576, https://github.com/gahingwoo/edk2-rk3576). When booting Armbian 7.3.4-edge (with rockchipdrm built in) on a TaishanPi 3M, the firmware hands over control while Esmart0 on VP0 is still scanning out the HDMI framebuffer at 0xff190000. Shortly after the VOP binds, when it is first enabled, the kernel logs: rk_iommu 27d07e00.iommu: Enable stall request timed out, status: 0x00040b rk_iommu 27d07e00.iommu: Enable stall request timed out, status: 0x00001d rockchip-drm display-subsystem: [drm] *ERROR* POST_BUF_EMPTY irq err at vp0 This happened in 2 out of 3 HDMI boots where the VOP managed to bind. The 0x40b status matches your 0x30b (just with bus ID 0x10), meaning paging is enabled with an active page fault. On a DSI boot before my fix, the same pair of timeouts came on every DRM enable, and later a BUS_ERROR. To work around this on the DSI path, I added a quirk at ExitBootServices when booting Linux: it turns off the window, puts the VP into standby, and waits for DSP_HOLD_VALID. Essentially, it is your experiment implemented in the firmware. Across 32 DSI Linux boots since that change, I haven't seen a single rk_iommu error. Take that with a grain of salt, though, as most of those runs only captured partial serial logs. The HDMI path still hands over a live window for now, and I plan to quiesce it the same way. Regarding my IOMMU patch from Nov 23 [1]: that originated from an RK3576 NPU issue, where one bank kept paging after a core reset while the other didn't, causing the all-banks guards to skip the stall and breaking the force reset. You're right that it doesn't help here when both banks are paging. One data point from the OS side: my Windows display driver takes over the live window without tearing it down first. It avoids faulting by identity-mapping the firmware framebuffer in the VOP IOMMU right before enabling paging. Getting that seamless handover on Linux would need something like get_resv_regions in rockchip-iommu, so that iommu-addresses on the framebuffer node is honored. Quiescing in firmware works today without kernel changes, at the cost of blanking the screen until KMS sets a mode. A CM5-IO running Fedora (where rockchipdrm is built as a module) showed none of these faults across 16 boots in September (7.3.0-rc3-next). I suspect clk_disable_unused gates the VOP clocks before the module gets a chance to load, though I haven't verified that yet. Thanks, Jiaxing [1] https://lore.kernel.org/all/20261123235154.315460-1-gahing@gahingwoo.com/