From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D9A2012DDB5; Tue, 23 Jan 2024 01:01:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705971718; cv=none; b=oP6H23HIkqFfJCu8XYUieypq4RWKPACb3aKXMdHwi4ET/+CqjdYNcTX5CetaL0QZTdOYYUlgJa/dww447H73sADY8sQn+3GdA3McCK3Yarbl5JWjV6raLnAPwtFnp10whSp/amyM4khP+PgTaPujL1wIteDt1UAl0v9Zsq3X0KI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1705971718; c=relaxed/simple; bh=5D28+W9GOH06mkQSe57NRZuVKsZUt7pIKucYx0eMBmc=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=T+lVmij4HQnFdFuk4hZva/8QIo8CTK5KRCZRkAIbtVTN0YtBbWGo+6ayf2szxP7Y/0tZJT9r9xSukLurhVF0Cph2GJIEYcirnW1Yw4DPwzdvjhgBgbozb5CaBSeyoNsGi7UTZAjhmFg3AjJPFP904gkWOPjgAgIUvXWEQHPZMK8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=F/HkLQOi; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="F/HkLQOi" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 99CF4C43390; Tue, 23 Jan 2024 01:01:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1705971718; bh=5D28+W9GOH06mkQSe57NRZuVKsZUt7pIKucYx0eMBmc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=F/HkLQOiQ4eu9mPrV9E9TRn6ejp4AfLvbeVtx9q+ouWo+NaLp8MBDFedpb5vShSFi 36L/vtIfVO2B3BwRCESacgKEenjdL2nrrsaD1Sf3P2Ah+wf1eBSJIzgNsQ5oWUouQj rji0k4gK3AZ5dJcUxV9Ed1cySphAqgxLKNBo/W/A= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Rob Clark , Johan Hovold , Robin Murphy , Will Deacon Subject: [PATCH 6.1 305/417] iommu/arm-smmu-qcom: Add missing GMU entry to match table Date: Mon, 22 Jan 2024 15:57:53 -0800 Message-ID: <20240122235802.395795060@linuxfoundation.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240122235751.480367507@linuxfoundation.org> References: <20240122235751.480367507@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.1-stable review patch. If anyone has any objections, please let me know. ------------------ From: Rob Clark commit afc95681c3068956fed1241a1ff1612c066c75ac upstream. In some cases the firmware expects cbndx 1 to be assigned to the GMU, so we also want the default domain for the GMU to be an identy domain. This way it does not get a context bank assigned. Without this, both of_dma_configure() and drm/msm's iommu_domain_attach() will trigger allocating and configuring a context bank. So GMU ends up attached to both cbndx 1 and later cbndx 2. This arrangement seemingly confounds and surprises the firmware if the GPU later triggers a translation fault, resulting (on sc8280xp / lenovo x13s, at least) in the SMMU getting wedged and the GPU stuck without memory access. Cc: stable@vger.kernel.org Signed-off-by: Rob Clark Tested-by: Johan Hovold Reviewed-by: Robin Murphy Link: https://lore.kernel.org/r/20231210180655.75542-1-robdclark@gmail.com Signed-off-by: Will Deacon Signed-off-by: Greg Kroah-Hartman --- drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c +++ b/drivers/iommu/arm/arm-smmu/arm-smmu-qcom.c @@ -243,6 +243,7 @@ static int qcom_adreno_smmu_init_context static const struct of_device_id qcom_smmu_client_of_match[] __maybe_unused = { { .compatible = "qcom,adreno" }, + { .compatible = "qcom,adreno-gmu" }, { .compatible = "qcom,mdp4" }, { .compatible = "qcom,mdss" }, { .compatible = "qcom,sc7180-mdss" },