Received: by 2002:a05:7412:b10a:b0:f3:1519:9f41 with SMTP id az10csp2970255rdb; Mon, 4 Dec 2023 12:36:58 -0800 (PST) X-Google-Smtp-Source: AGHT+IEbPD2/anjxCKX6GEMpIv3Pgwvh74qhm0sfbOIf8F4+Gcp301LCd7eLeyTuhAjadQMtCNT/ X-Received: by 2002:a17:902:c950:b0:1d0:8abf:3ea with SMTP id i16-20020a170902c95000b001d08abf03eamr2407957pla.85.1701722218186; Mon, 04 Dec 2023 12:36:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701722218; cv=none; d=google.com; s=arc-20160816; b=m52O2eVFAj62FTpc3nVU0nTnodf2drjLCqAG0uEhJ6oEZCWUoXwj8p8ypMdAxDwhI8 Kg0wnAvWXwkCfrXGRUfiwUbyhaMWyQ6Vg9hbql9dH8TF6E967K4lE7nP8VeVuM5JqoE9 8KjmkcpGyo3YtGh4V7SK7vqRkKWze6WKJ65J6YafmiLmhMyYiBMqj4XKxPypMZMySZgh A7QQ7Shv4WC2FzJlRy5AesAJLZfvENnHy0VYNFecRYDQ+ELL/GzAYYSt7iO1YvS2Vxcc NwsdPT6xdREyYu2nkGJawQAUEurLQaOu+c3OnnWwPHh8QiwdU4WaXeWvdBP1I9PKGUJt bcSg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=GYQdiLglumX47AmkW0CDMO7grjlb/fdqyvUvyFuwSEQ=; fh=CGOOTnmKnvJwPmpGOCvYU0+ukX3KDCyXl7P6/Xj1CPA=; b=d1BYRUyvSraAJrCNZrls/8Sq/srZtR07uprDBM48ivYvivJBKUj4O1x8e+AGWcx9c8 BPNJ5SCqtePXIHUvizKMSnV7z15pbqx5JxoDph3nTnHIAe8sRHB9yiS6WswbHJFv9he1 hkb2C6ielir1u0gteVdnLiraj1M4wCj0mEqkkeE3UVGoVAqR6vW8CwzY28y3rJslzdGO imUBuG8lRGH1yhR7G+4DDO1D5NsQqlR9A8zJlzmzoG0Sssa6qnxqH14ujJoJNLj1MRIc 8Pn5Aw2qk/H01CKpCEtCMpV7U5K8VR9xfGp/NvuouHUrpYWFXQsTuHCDkcdgST2pyBon JMuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=p6Y8HITa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id a14-20020a170902710e00b001c07bac13d0si2469480pll.383.2023.12.04.12.36.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Dec 2023 12:36:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=p6Y8HITa; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id C17A78095D95; Mon, 4 Dec 2023 12:36:55 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345961AbjLDUgg (ORCPT + 99 others); Mon, 4 Dec 2023 15:36:36 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36804 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1345729AbjLDUgM (ORCPT ); Mon, 4 Dec 2023 15:36:12 -0500 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F2DD4198B for ; Mon, 4 Dec 2023 12:34:51 -0800 (PST) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2F0CEC433CA; Mon, 4 Dec 2023 20:34:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1701722091; bh=d0x7v3HGnyDSRgQ6KgQ0tQ0Qs6El+7eD0tb299DREL8=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=p6Y8HITaExi+Mh96QCZHtesPIaQe4VywVqYD1cYrPxhSDiXwv79U5EY3vCsmDTnj0 /PIy9KyJvGLTwQoiicY3t5g61bJiRvhtMqYPs0GvIDLCAvxS3WFNdmS+q2KdLSfsnM v8MmKnRZih4tksjC52XogmmdEWDlEzXnCfAd7ZSKJsCxYZgM2ZTDAHkfmtnYi3+ESc 5/8XWNHykN3iLDDVjCJbEKCRo+OAvqalto0/96M+cohH4D0z6uvaqegCsNibBwT/qr 91TIvOb8j/OxTreY1HgSts2Ae591UsdeFoefm2VGSBkKkRRs8o5Fgb7z3Yh+0ywFb9 oAaWUm7XGA8JQ== From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Lijo Lazar , Hawking Zhang , Alex Deucher , Sasha Levin , christian.koenig@amd.com, Xinhui.Pan@amd.com, airlied@gmail.com, daniel@ffwll.ch, le.ma@amd.com, James.Zhu@amd.com, shane.xiao@amd.com, sonny.jiang@amd.com, Likun.Gao@amd.com, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org Subject: [PATCH AUTOSEL 6.6 28/32] drm/amdgpu: Use another offset for GC 9.4.3 remap Date: Mon, 4 Dec 2023 15:32:48 -0500 Message-ID: <20231204203317.2092321-28-sashal@kernel.org> X-Mailer: git-send-email 2.42.0 In-Reply-To: <20231204203317.2092321-1-sashal@kernel.org> References: <20231204203317.2092321-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore X-stable-base: Linux 6.6.4 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Mon, 04 Dec 2023 12:36:55 -0800 (PST) From: Lijo Lazar [ Upstream commit ed6e4f0a27ebafffbd12bf3878ab004787685d8a ] The legacy region at 0x7F000 maps to valid registers in GC 9.4.3 SOCs. Use 0x1A000 offset instead as MMIO register remap region. Signed-off-by: Lijo Lazar Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- drivers/gpu/drm/amd/amdgpu/soc15.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/soc15.c b/drivers/gpu/drm/amd/amdgpu/soc15.c index f5be40d7ba367..b85011106347c 100644 --- a/drivers/gpu/drm/amd/amdgpu/soc15.c +++ b/drivers/gpu/drm/amd/amdgpu/soc15.c @@ -1159,6 +1159,11 @@ static int soc15_common_early_init(void *handle) AMD_PG_SUPPORT_VCN_DPG | AMD_PG_SUPPORT_JPEG; adev->external_rev_id = adev->rev_id + 0x46; + /* GC 9.4.3 uses MMIO register region hole at a different offset */ + if (!amdgpu_sriov_vf(adev)) { + adev->rmmio_remap.reg_offset = 0x1A000; + adev->rmmio_remap.bus_addr = adev->rmmio_base + 0x1A000; + } break; default: /* FIXME: not supported yet */ -- 2.42.0