From: Jani Nikula <jani.nikula@linux.intel.com>
To: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
"Souza, Jose" <jose.souza@intel.com>,
"intel-gfx@lists.freedesktop.org"
<intel-gfx@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH 16/16] drm/i915: Drop display.has_fpga_db from device info
Date: Tue, 10 May 2022 10:41:44 +0300 [thread overview]
Message-ID: <87czglkf5z.fsf@intel.com> (raw)
In-Reply-To: <165216392440.6877.2731939801619952697@jlahtine-mobl.ger.corp.intel.com>
On Tue, 10 May 2022, Joonas Lahtinen <joonas.lahtinen@linux.intel.com> wrote:
> Quoting Souza, Jose (2022-05-09 17:19:28)
>> On Mon, 2022-05-09 at 15:38 +0300, Joonas Lahtinen wrote:
>> > Quoting José Roberto de Souza (2022-05-07 16:28:50)
>> > > No need to have this parameter in intel_device_info struct
>> > > as this feature is supported by Broadwell, Haswell all platforms with
>> > > display version 9 or newer.
>> >
>> > This is opposite of the direction we want to move to.
>> >
>> > We want to embrace the has_xyz flags, instead of the macro trickery.
>>
>> This ever growing flag definition is causing problems when defining new platforms.
>
> The ever growing macros that change between kernel versions are much
> more painful than easily printable list per SKU.
>
> Just to make it clear, a strict NACK from me for merging any patches
> into this direction.
I was hoping to start a discussion to reach consensus on this with my
mail [1], adding all maintainers in Cc, but merging started before the
discussion really even started.
Obviously no further patches on this are to be merged, and the question
now is really what to do with the ones that were. Revert?
BR,
Jani.
[1] https://lore.kernel.org/r/87sfpol0kz.fsf@intel.com
>
> Regards, Joonas
>
>>
>> There is too many features to check if a new platform supports each one of it, what is leading to platform definition errors.
>>
>> Also usually when a feature is dropped a HSD will be filed, so the person taking care of that can just adjust the macro upper platform or IP bound and
>> disable it for good.
>>
>> >
>> > > As a side effect of the of removal this flag, it will not be printed
>> > > in dmesg during driver load anymore and developers will have to rely
>> > > on to check the macro and compare with platform being used and IP
>> > > versions of it.
>> >
>> > This is not a very good rationale. If the platform has something, but it
>> > becomes disabled in runtime, then we should add an another print after
>> > the runtime sanitization has been done.
>>
>> In my opinion this flags should only change in runtime if the feature is fused off like is done for has_dsc and has_dmc.
>>
>> >
>> > Regards, Joonas
>> >
>> > >
>> > > Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
>> > > ---
>> > > drivers/gpu/drm/i915/i915_drv.h | 4 +++-
>> > > drivers/gpu/drm/i915/i915_pci.c | 3 ---
>> > > drivers/gpu/drm/i915/intel_device_info.h | 1 -
>> > > 3 files changed, 3 insertions(+), 5 deletions(-)
>> > >
>> > > diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
>> > > index 4b1025dbaab2a..4a1edf48d37b9 100644
>> > > --- a/drivers/gpu/drm/i915/i915_drv.h
>> > > +++ b/drivers/gpu/drm/i915/i915_drv.h
>> > > @@ -1306,7 +1306,9 @@ IS_SUBPLATFORM(const struct drm_i915_private *i915,
>> > > IS_BROADWELL(dev_priv) || \
>> > > IS_HASWELL(dev_priv))
>> > > #define HAS_DP_MST(dev_priv) (HAS_DDI(dev_priv))
>> > > -#define HAS_FPGA_DBG_UNCLAIMED(dev_priv) (INTEL_INFO(dev_priv)->display.has_fpga_dbg)
>> > > +#define HAS_FPGA_DBG_UNCLAIMED(dev_priv) (DISPLAY_VER(dev_priv) >= 9 || \
>> > > + IS_BROADWELL(dev_priv) || \
>> > > + IS_HASWELL(dev_priv))
>> > > #define HAS_PSR(dev_priv) (DISPLAY_VER(dev_priv) >= 9)
>> > > #define HAS_PSR2_SEL_FETCH(dev_priv) (DISPLAY_VER(dev_priv) >= 12)
>> > > #define HAS_TRANSCODER(dev_priv, trans) ((INTEL_INFO(dev_priv)->display.cpu_transcoder_mask & BIT(trans)) != 0)
>> > > diff --git a/drivers/gpu/drm/i915/i915_pci.c b/drivers/gpu/drm/i915/i915_pci.c
>> > > index 5a42acb162a15..6a5b70b3ea2d7 100644
>> > > --- a/drivers/gpu/drm/i915/i915_pci.c
>> > > +++ b/drivers/gpu/drm/i915/i915_pci.c
>> > > @@ -523,7 +523,6 @@ static const struct intel_device_info vlv_info = {
>> > > .platform_engine_mask = BIT(RCS0) | BIT(VCS0) | BIT(BCS0) | BIT(VECS0), \
>> > > .display.cpu_transcoder_mask = BIT(TRANSCODER_A) | BIT(TRANSCODER_B) | \
>> > > BIT(TRANSCODER_C) | BIT(TRANSCODER_EDP), \
>> > > - .display.has_fpga_dbg = 1, \
>> > > HSW_PIPE_OFFSETS
>> > >
>> > > #define HSW_PLATFORM \
>> > > @@ -657,7 +656,6 @@ static const struct intel_device_info skl_gt4_info = {
>> > > .display.cpu_transcoder_mask = BIT(TRANSCODER_A) | BIT(TRANSCODER_B) | \
>> > > BIT(TRANSCODER_C) | BIT(TRANSCODER_EDP) | \
>> > > BIT(TRANSCODER_DSI_A) | BIT(TRANSCODER_DSI_C), \
>> > > - .display.has_fpga_dbg = 1, \
>> > > .display.fbc_mask = BIT(INTEL_FBC_A), \
>> > > .display.has_hdcp = 1, \
>> > > .display.has_dmc = 1, \
>> > > @@ -894,7 +892,6 @@ static const struct intel_device_info adl_s_info = {
>> > > .display.has_dmc = 1, \
>> > > .display.has_dsc = 1, \
>> > > .display.fbc_mask = BIT(INTEL_FBC_A), \
>> > > - .display.has_fpga_dbg = 1, \
>> > > .display.has_hdcp = 1, \
>> > > .display.has_hotplug = 1, \
>> > > .display.ver = 13, \
>> > > diff --git a/drivers/gpu/drm/i915/intel_device_info.h b/drivers/gpu/drm/i915/intel_device_info.h
>> > > index 7581ef4a68f94..e61a334b611ac 100644
>> > > --- a/drivers/gpu/drm/i915/intel_device_info.h
>> > > +++ b/drivers/gpu/drm/i915/intel_device_info.h
>> > > @@ -157,7 +157,6 @@ enum intel_ppgtt_type {
>> > > func(has_cdclk_crawl); \
>> > > func(has_dmc); \
>> > > func(has_dsc); \
>> > > - func(has_fpga_dbg); \
>> > > func(has_gmch); \
>> > > func(has_hdcp); \
>> > > func(has_hotplug); \
>> > > --
>> > > 2.36.0
>> > >
>>
--
Jani Nikula, Intel Open Source Graphics Center
next prev parent reply other threads:[~2022-05-10 7:41 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-07 13:28 [Intel-gfx] [PATCH 01/16] drm/i915: Drop has_llc from device info José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 02/16] drm/i915: Drop has_ipc " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 03/16] drm/i915/display: Disable DSB for DG2 and Alderlake-P José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 04/16] drm/i915: Drop has_rc6p from device info José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 05/16] drm/i915: Drop has_psr_hw_tracking " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 06/16] drm/i915: Drop supports_tv " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 07/16] drm/i915: Drop has_4tile " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 08/16] drm/i915: Drop has_64bit_reloc " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 09/16] drm/i915: Drop has_global_mocs " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 10/16] drm/i915: Drop has_guc_deprivilege " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 11/16] drm/i915: Drop has_pxp " José Roberto de Souza
2022-05-07 18:05 ` kernel test robot
2022-05-07 19:47 ` kernel test robot
2022-05-07 13:28 ` [Intel-gfx] [PATCH 12/16] drm/i915: Drop has_heci_gscfi " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 13/16] " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 14/16] drm/i915: Drop has_runtime_pm " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 15/16] drm/i915: Drop has_logical_ring_contexts " José Roberto de Souza
2022-05-07 13:28 ` [Intel-gfx] [PATCH 16/16] drm/i915: Drop display.has_fpga_db " José Roberto de Souza
2022-05-09 12:38 ` Joonas Lahtinen
2022-05-09 14:19 ` Souza, Jose
2022-05-10 6:25 ` Joonas Lahtinen
2022-05-10 7:41 ` Jani Nikula [this message]
2022-05-11 7:39 ` Tvrtko Ursulin
2022-05-11 13:56 ` Souza, Jose
2022-05-07 13:43 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/16] drm/i915: Drop has_llc " Patchwork
2022-05-07 13:43 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2022-05-07 13:52 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2022-05-07 15:01 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2022-05-09 11:09 ` [Intel-gfx] [PATCH 01/16] " Matthew Auld
2022-05-09 14:05 ` Souza, Jose
2022-05-09 14:52 ` Matthew Auld
2022-05-09 14:55 ` Souza, Jose
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=87czglkf5z.fsf@intel.com \
--to=jani.nikula@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=joonas.lahtinen@linux.intel.com \
--cc=jose.souza@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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox