From: Lucas De Marchi <lucas.demarchi@intel.com> To: Matt Roper <matthew.d.roper@intel.com> Cc: intel-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/i915/tgl: MOCS table fixes Date: Mon, 11 Nov 2019 12:37:30 -0800 [thread overview] Message-ID: <20191111203730.czdgdkrfh2mxd7jt@ldmartin-desk1> (raw) In-Reply-To: <20191111190721.32606-1-matthew.d.roper@intel.com> On Mon, Nov 11, 2019 at 11:07:21AM -0800, Matt Roper wrote: >The bspec was just updated with a couple corrections to the TGL MOCS >table. Entries 16 and 17 are marked as reserved (overriding the value >we inherit from GEN11_MOCS_ENTRIES) and entry 61 shouldn't have the >LE_SCF bit applied. > >Note that since we're intentionally/explicitly overriding table entries >from GEN11_MOCS_ENTRIES we should suppress the 'override-init' compiler >warnings for this file. > >Bspec: 45101 >Fixes: 2ddf992179c4 ("drm/i915/tgl: Define MOCS entries for Tigerlake") >Cc: Tomasz Lis <tomasz.lis@intel.com> >Cc: Lucas De Marchi <lucas.demarchi@intel.com> >Signed-off-by: Matt Roper <matthew.d.roper@intel.com> >--- > drivers/gpu/drm/i915/Makefile | 1 + > drivers/gpu/drm/i915/gt/intel_mocs.c | 6 +++++- > 2 files changed, 6 insertions(+), 1 deletion(-) > >diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile >index e0fd10c0cfb8..8c6b5fa43473 100644 >--- a/drivers/gpu/drm/i915/Makefile >+++ b/drivers/gpu/drm/i915/Makefile >@@ -27,6 +27,7 @@ subdir-ccflags-$(CONFIG_DRM_I915_WERROR) += -Werror > # Fine grained warnings disable > CFLAGS_i915_pci.o = $(call cc-disable-warning, override-init) > CFLAGS_display/intel_fbdev.o = $(call cc-disable-warning, override-init) >+CFLAGS_gt/intel_mocs.o = $(call cc-disable-warning, override-init) I'm pretty sure at some point I had a pragma push/pop to ignore this warning just around the tables and nothing else. Probably it was dropped in a patch revision, because git log doesn't show it. It looks like we even define special macros __diag_push(), __diag_pop(), __diag_ignore() for that, but it doesn't see much use in the kernel, not sure why. > > subdir-ccflags-y += \ > $(call as-instr,movntdqa (%eax)$(comma)%xmm0,-DCONFIG_AS_MOVNTDQA) >diff --git a/drivers/gpu/drm/i915/gt/intel_mocs.c b/drivers/gpu/drm/i915/gt/intel_mocs.c >index 6e881c735b20..cd72235553aa 100644 >--- a/drivers/gpu/drm/i915/gt/intel_mocs.c >+++ b/drivers/gpu/drm/i915/gt/intel_mocs.c >@@ -249,6 +249,10 @@ static const struct drm_i915_mocs_entry tigerlake_mocs_table[] = { > > GEN11_MOCS_ENTRIES, > >+ /* Reserved (overrides values from GEN11_MOCS_ENTRIES) */ >+ MOCS_ENTRY(16, 0x0, 0x0), >+ MOCS_ENTRY(17, 0x0, 0x0), MOCS_ENTRY implicitly define the entry to used. What I think we need is a way to override the used field, so it's more inline with what the bspec is telling us to do... probably something like #define MOCS_ENTRY_SET_UNUSED(__idx) \ [__idx] = { \ .used = 0, \ } Difference is that in tests that read back the value and check if they make sense, they won't test values that are marked as not used. IMO what we should be doing for these fields. Lucas De Marchi >+ > /* Implicitly enable L1 - HDC:L1 + L3 + LLC */ > MOCS_ENTRY(48, > LE_3_WB | LE_TC_1_LLC | LE_LRUM(3), >@@ -271,7 +275,7 @@ static const struct drm_i915_mocs_entry tigerlake_mocs_table[] = { > L3_1_UC), > /* HW Special Case (Displayable) */ > MOCS_ENTRY(61, >- LE_1_UC | LE_TC_1_LLC | LE_SCF(1), >+ LE_1_UC | LE_TC_1_LLC, > L3_3_WB), > }; > >-- >2.21.0 > _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx
WARNING: multiple messages have this Message-ID (diff)
From: Lucas De Marchi <lucas.demarchi@intel.com> To: Matt Roper <matthew.d.roper@intel.com> Cc: intel-gfx@lists.freedesktop.org Subject: Re: [Intel-gfx] [PATCH] drm/i915/tgl: MOCS table fixes Date: Mon, 11 Nov 2019 12:37:30 -0800 [thread overview] Message-ID: <20191111203730.czdgdkrfh2mxd7jt@ldmartin-desk1> (raw) Message-ID: <20191111203730.a841o8jar2XRTi1yTmy3HqlY8sPVWw85z1_CsBseB2c@z> (raw) In-Reply-To: <20191111190721.32606-1-matthew.d.roper@intel.com> On Mon, Nov 11, 2019 at 11:07:21AM -0800, Matt Roper wrote: >The bspec was just updated with a couple corrections to the TGL MOCS >table. Entries 16 and 17 are marked as reserved (overriding the value >we inherit from GEN11_MOCS_ENTRIES) and entry 61 shouldn't have the >LE_SCF bit applied. > >Note that since we're intentionally/explicitly overriding table entries >from GEN11_MOCS_ENTRIES we should suppress the 'override-init' compiler >warnings for this file. > >Bspec: 45101 >Fixes: 2ddf992179c4 ("drm/i915/tgl: Define MOCS entries for Tigerlake") >Cc: Tomasz Lis <tomasz.lis@intel.com> >Cc: Lucas De Marchi <lucas.demarchi@intel.com> >Signed-off-by: Matt Roper <matthew.d.roper@intel.com> >--- > drivers/gpu/drm/i915/Makefile | 1 + > drivers/gpu/drm/i915/gt/intel_mocs.c | 6 +++++- > 2 files changed, 6 insertions(+), 1 deletion(-) > >diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile >index e0fd10c0cfb8..8c6b5fa43473 100644 >--- a/drivers/gpu/drm/i915/Makefile >+++ b/drivers/gpu/drm/i915/Makefile >@@ -27,6 +27,7 @@ subdir-ccflags-$(CONFIG_DRM_I915_WERROR) += -Werror > # Fine grained warnings disable > CFLAGS_i915_pci.o = $(call cc-disable-warning, override-init) > CFLAGS_display/intel_fbdev.o = $(call cc-disable-warning, override-init) >+CFLAGS_gt/intel_mocs.o = $(call cc-disable-warning, override-init) I'm pretty sure at some point I had a pragma push/pop to ignore this warning just around the tables and nothing else. Probably it was dropped in a patch revision, because git log doesn't show it. It looks like we even define special macros __diag_push(), __diag_pop(), __diag_ignore() for that, but it doesn't see much use in the kernel, not sure why. > > subdir-ccflags-y += \ > $(call as-instr,movntdqa (%eax)$(comma)%xmm0,-DCONFIG_AS_MOVNTDQA) >diff --git a/drivers/gpu/drm/i915/gt/intel_mocs.c b/drivers/gpu/drm/i915/gt/intel_mocs.c >index 6e881c735b20..cd72235553aa 100644 >--- a/drivers/gpu/drm/i915/gt/intel_mocs.c >+++ b/drivers/gpu/drm/i915/gt/intel_mocs.c >@@ -249,6 +249,10 @@ static const struct drm_i915_mocs_entry tigerlake_mocs_table[] = { > > GEN11_MOCS_ENTRIES, > >+ /* Reserved (overrides values from GEN11_MOCS_ENTRIES) */ >+ MOCS_ENTRY(16, 0x0, 0x0), >+ MOCS_ENTRY(17, 0x0, 0x0), MOCS_ENTRY implicitly define the entry to used. What I think we need is a way to override the used field, so it's more inline with what the bspec is telling us to do... probably something like #define MOCS_ENTRY_SET_UNUSED(__idx) \ [__idx] = { \ .used = 0, \ } Difference is that in tests that read back the value and check if they make sense, they won't test values that are marked as not used. IMO what we should be doing for these fields. Lucas De Marchi >+ > /* Implicitly enable L1 - HDC:L1 + L3 + LLC */ > MOCS_ENTRY(48, > LE_3_WB | LE_TC_1_LLC | LE_LRUM(3), >@@ -271,7 +275,7 @@ static const struct drm_i915_mocs_entry tigerlake_mocs_table[] = { > L3_1_UC), > /* HW Special Case (Displayable) */ > MOCS_ENTRY(61, >- LE_1_UC | LE_TC_1_LLC | LE_SCF(1), >+ LE_1_UC | LE_TC_1_LLC, > L3_3_WB), > }; > >-- >2.21.0 > _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2019-11-11 20:37 UTC|newest] Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-11-11 19:07 [PATCH] drm/i915/tgl: MOCS table fixes Matt Roper 2019-11-11 19:07 ` [Intel-gfx] " Matt Roper 2019-11-11 20:37 ` Lucas De Marchi [this message] 2019-11-11 20:37 ` Lucas De Marchi 2019-11-11 20:57 ` Matt Roper 2019-11-11 20:57 ` [Intel-gfx] " Matt Roper 2019-11-11 21:59 ` [PATCH v2] " Matt Roper 2019-11-11 21:59 ` [Intel-gfx] " Matt Roper 2019-11-11 23:02 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915/tgl: MOCS table fixes (rev2) Patchwork 2019-11-11 23:02 ` [Intel-gfx] " Patchwork 2019-11-11 23:03 ` ✗ Fi.CI.SPARSE: " Patchwork 2019-11-11 23:03 ` [Intel-gfx] " Patchwork 2019-11-11 23:55 ` ✗ Fi.CI.BAT: failure " Patchwork 2019-11-11 23:55 ` [Intel-gfx] " Patchwork 2019-11-11 20:44 ` ✓ Fi.CI.BAT: success for drm/i915/tgl: MOCS table fixes Patchwork 2019-11-11 20:44 ` [Intel-gfx] " Patchwork
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=20191111203730.czdgdkrfh2mxd7jt@ldmartin-desk1 \ --to=lucas.demarchi@intel.com \ --cc=intel-gfx@lists.freedesktop.org \ --cc=matthew.d.roper@intel.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: linkBe 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.