diff mbox

[v2,1/2] drm/i915/dsi: rename the current DSI files based on generation

Message ID 20180703135329.4920-1-jani.nikula@intel.com (mailing list archive)
State New, archived
Headers show

Commit Message

Jani Nikula July 3, 2018, 1:53 p.m. UTC
Starting from ICL or gen 11 we have a new DSI block which requires
completely different programming from the current implementation. Having
them in the same file would be confusing. Rename the current DSI and DSI
PLL implementation files as gen7_dsi.c and gen7_dsi_pll.c.

No functional changes.

References: https://patchwork.freedesktop.org/series/44823/
Cc: Madhav Chauhan <madhav.chauhan@intel.com>
Cc: Daniel Vetter <daniel@ffwll.ch>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/Makefile                            | 4 ++--
 drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c}         | 0
 drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} | 0
 drivers/gpu/drm/i915/intel_drv.h                         | 2 +-
 drivers/gpu/drm/i915/intel_dsi.h                         | 4 ++--
 5 files changed, 5 insertions(+), 5 deletions(-)
 rename drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c} (100%)
 rename drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} (100%)

Comments

Chauhan, Madhav July 3, 2018, 2:12 p.m. UTC | #1
> -----Original Message-----
> From: Nikula, Jani
> Sent: Tuesday, July 3, 2018 7:23 PM
> To: intel-gfx@lists.freedesktop.org
> Cc: Nikula, Jani <jani.nikula@intel.com>; Chauhan, Madhav
> <madhav.chauhan@intel.com>; Daniel Vetter <daniel@ffwll.ch>; Chris
> Wilson <chris@chris-wilson.co.uk>
> Subject: [PATCH v2 1/2] drm/i915/dsi: rename the current DSI files based on
> generation
> 
> Starting from ICL or gen 11 we have a new DSI block which requires
> completely different programming from the current implementation. Having
> them in the same file would be confusing. Rename the current DSI and DSI
> PLL implementation files as gen7_dsi.c and gen7_dsi_pll.c.
> 
> No functional changes.

This looks fine to me,
Reviewed-by: Madhav Chauhan <madhav.chauhan@intel.com>

Regards,
Madhav

> 
> References: https://patchwork.freedesktop.org/series/44823/
> Cc: Madhav Chauhan <madhav.chauhan@intel.com>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  drivers/gpu/drm/i915/Makefile                            | 4 ++--
>  drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c}         | 0
>  drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} | 0
>  drivers/gpu/drm/i915/intel_drv.h                         | 2 +-
>  drivers/gpu/drm/i915/intel_dsi.h                         | 4 ++--
>  5 files changed, 5 insertions(+), 5 deletions(-)  rename
> drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c} (100%)  rename
> drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} (100%)
> 
> diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile
> index 4c6adae23e18..a1cfb3a3926b 100644
> --- a/drivers/gpu/drm/i915/Makefile
> +++ b/drivers/gpu/drm/i915/Makefile
> @@ -135,15 +135,15 @@ i915-y += dvo_ch7017.o \
>  	  dvo_ns2501.o \
>  	  dvo_sil164.o \
>  	  dvo_tfp410.o \
> +	  gen7_dsi.o \
> +	  gen7_dsi_pll.o \
>  	  intel_crt.o \
>  	  intel_ddi.o \
>  	  intel_dp_aux_backlight.o \
>  	  intel_dp_link_training.o \
>  	  intel_dp_mst.o \
>  	  intel_dp.o \
> -	  intel_dsi.o \
>  	  intel_dsi_dcs_backlight.o \
> -	  intel_dsi_pll.o \
>  	  intel_dsi_vbt.o \
>  	  intel_dvo.o \
>  	  intel_hdmi.o \
> diff --git a/drivers/gpu/drm/i915/intel_dsi.c
> b/drivers/gpu/drm/i915/gen7_dsi.c similarity index 100% rename from
> drivers/gpu/drm/i915/intel_dsi.c rename to
> drivers/gpu/drm/i915/gen7_dsi.c diff --git
> a/drivers/gpu/drm/i915/intel_dsi_pll.c
> b/drivers/gpu/drm/i915/gen7_dsi_pll.c
> similarity index 100%
> rename from drivers/gpu/drm/i915/intel_dsi_pll.c
> rename to drivers/gpu/drm/i915/gen7_dsi_pll.c
> diff --git a/drivers/gpu/drm/i915/intel_drv.h
> b/drivers/gpu/drm/i915/intel_drv.h
> index b9b70321c054..888a85dc3856 100644
> --- a/drivers/gpu/drm/i915/intel_drv.h
> +++ b/drivers/gpu/drm/i915/intel_drv.h
> @@ -1730,7 +1730,7 @@ int intel_dp_aux_init_backlight_funcs(struct
> intel_connector *intel_connector);
>  /* intel_dp_mst.c */
>  int intel_dp_mst_encoder_init(struct intel_digital_port *intel_dig_port, int
> conn_id);  void intel_dp_mst_encoder_cleanup(struct intel_digital_port
> *intel_dig_port);
> -/* intel_dsi.c */
> +/* gen7_dsi.c */
>  void intel_dsi_init(struct drm_i915_private *dev_priv);
> 
>  /* intel_dsi_dcs_backlight.c */
> diff --git a/drivers/gpu/drm/i915/intel_dsi.h
> b/drivers/gpu/drm/i915/intel_dsi.h
> index 7afeb9580f41..1b5c2c167472 100644
> --- a/drivers/gpu/drm/i915/intel_dsi.h
> +++ b/drivers/gpu/drm/i915/intel_dsi.h
> @@ -129,11 +129,11 @@ static inline struct intel_dsi
> *enc_to_intel_dsi(struct drm_encoder *encoder)
>  	return container_of(encoder, struct intel_dsi, base.base);  }
> 
> -/* intel_dsi.c */
> +/* gen7_dsi.c */
>  void wait_for_dsi_fifo_empty(struct intel_dsi *intel_dsi, enum port port);
> enum mipi_dsi_pixel_format pixel_format_from_register_bits(u32 fmt);
> 
> -/* intel_dsi_pll.c */
> +/* gen7_dsi_pll.c */
>  bool intel_dsi_pll_is_enabled(struct drm_i915_private *dev_priv);  int
> intel_compute_dsi_pll(struct intel_encoder *encoder,
>  			  struct intel_crtc_state *config);
> --
> 2.11.0
Ville Syrjälä July 3, 2018, 2:20 p.m. UTC | #2
On Tue, Jul 03, 2018 at 04:53:28PM +0300, Jani Nikula wrote:
> Starting from ICL or gen 11 we have a new DSI block which requires
> completely different programming from the current implementation. Having
> them in the same file would be confusing. Rename the current DSI and DSI
> PLL implementation files as gen7_dsi.c and gen7_dsi_pll.c.

gen7 is a rather odd name for this. vlv would seem more
appropriate, though not particularly good either.

> 
> No functional changes.
> 
> References: https://patchwork.freedesktop.org/series/44823/
> Cc: Madhav Chauhan <madhav.chauhan@intel.com>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
> ---
>  drivers/gpu/drm/i915/Makefile                            | 4 ++--
>  drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c}         | 0
>  drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} | 0
>  drivers/gpu/drm/i915/intel_drv.h                         | 2 +-
>  drivers/gpu/drm/i915/intel_dsi.h                         | 4 ++--
>  5 files changed, 5 insertions(+), 5 deletions(-)
>  rename drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c} (100%)
>  rename drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} (100%)
> 
> diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile
> index 4c6adae23e18..a1cfb3a3926b 100644
> --- a/drivers/gpu/drm/i915/Makefile
> +++ b/drivers/gpu/drm/i915/Makefile
> @@ -135,15 +135,15 @@ i915-y += dvo_ch7017.o \
>  	  dvo_ns2501.o \
>  	  dvo_sil164.o \
>  	  dvo_tfp410.o \
> +	  gen7_dsi.o \
> +	  gen7_dsi_pll.o \
>  	  intel_crt.o \
>  	  intel_ddi.o \
>  	  intel_dp_aux_backlight.o \
>  	  intel_dp_link_training.o \
>  	  intel_dp_mst.o \
>  	  intel_dp.o \
> -	  intel_dsi.o \
>  	  intel_dsi_dcs_backlight.o \
> -	  intel_dsi_pll.o \
>  	  intel_dsi_vbt.o \
>  	  intel_dvo.o \
>  	  intel_hdmi.o \
> diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/gen7_dsi.c
> similarity index 100%
> rename from drivers/gpu/drm/i915/intel_dsi.c
> rename to drivers/gpu/drm/i915/gen7_dsi.c
> diff --git a/drivers/gpu/drm/i915/intel_dsi_pll.c b/drivers/gpu/drm/i915/gen7_dsi_pll.c
> similarity index 100%
> rename from drivers/gpu/drm/i915/intel_dsi_pll.c
> rename to drivers/gpu/drm/i915/gen7_dsi_pll.c
> diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
> index b9b70321c054..888a85dc3856 100644
> --- a/drivers/gpu/drm/i915/intel_drv.h
> +++ b/drivers/gpu/drm/i915/intel_drv.h
> @@ -1730,7 +1730,7 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector);
>  /* intel_dp_mst.c */
>  int intel_dp_mst_encoder_init(struct intel_digital_port *intel_dig_port, int conn_id);
>  void intel_dp_mst_encoder_cleanup(struct intel_digital_port *intel_dig_port);
> -/* intel_dsi.c */
> +/* gen7_dsi.c */
>  void intel_dsi_init(struct drm_i915_private *dev_priv);
>  
>  /* intel_dsi_dcs_backlight.c */
> diff --git a/drivers/gpu/drm/i915/intel_dsi.h b/drivers/gpu/drm/i915/intel_dsi.h
> index 7afeb9580f41..1b5c2c167472 100644
> --- a/drivers/gpu/drm/i915/intel_dsi.h
> +++ b/drivers/gpu/drm/i915/intel_dsi.h
> @@ -129,11 +129,11 @@ static inline struct intel_dsi *enc_to_intel_dsi(struct drm_encoder *encoder)
>  	return container_of(encoder, struct intel_dsi, base.base);
>  }
>  
> -/* intel_dsi.c */
> +/* gen7_dsi.c */
>  void wait_for_dsi_fifo_empty(struct intel_dsi *intel_dsi, enum port port);
>  enum mipi_dsi_pixel_format pixel_format_from_register_bits(u32 fmt);
>  
> -/* intel_dsi_pll.c */
> +/* gen7_dsi_pll.c */
>  bool intel_dsi_pll_is_enabled(struct drm_i915_private *dev_priv);
>  int intel_compute_dsi_pll(struct intel_encoder *encoder,
>  			  struct intel_crtc_state *config);
> -- 
> 2.11.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Jani Nikula July 4, 2018, 8:10 a.m. UTC | #3
On Tue, 03 Jul 2018, Ville Syrjälä <ville.syrjala@linux.intel.com> wrote:
> On Tue, Jul 03, 2018 at 04:53:28PM +0300, Jani Nikula wrote:
>> Starting from ICL or gen 11 we have a new DSI block which requires
>> completely different programming from the current implementation. Having
>> them in the same file would be confusing. Rename the current DSI and DSI
>> PLL implementation files as gen7_dsi.c and gen7_dsi_pll.c.
>
> gen7 is a rather odd name for this. vlv would seem more
> appropriate, though not particularly good either.

Daniel and Chris suggested a gen based name, and specifically to name
both the old and new with a prefix. I guess I would've gone with
"legacy" or "byt". Madhav has gone for gen11 prefixed function naming in
the new series.

I find myself caring less and less, as long as we reach some consensus
on the name.

BR,
Jani.



>
>> 
>> No functional changes.
>> 
>> References: https://patchwork.freedesktop.org/series/44823/
>> Cc: Madhav Chauhan <madhav.chauhan@intel.com>
>> Cc: Daniel Vetter <daniel@ffwll.ch>
>> Cc: Chris Wilson <chris@chris-wilson.co.uk>
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>> ---
>>  drivers/gpu/drm/i915/Makefile                            | 4 ++--
>>  drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c}         | 0
>>  drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} | 0
>>  drivers/gpu/drm/i915/intel_drv.h                         | 2 +-
>>  drivers/gpu/drm/i915/intel_dsi.h                         | 4 ++--
>>  5 files changed, 5 insertions(+), 5 deletions(-)
>>  rename drivers/gpu/drm/i915/{intel_dsi.c => gen7_dsi.c} (100%)
>>  rename drivers/gpu/drm/i915/{intel_dsi_pll.c => gen7_dsi_pll.c} (100%)
>> 
>> diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile
>> index 4c6adae23e18..a1cfb3a3926b 100644
>> --- a/drivers/gpu/drm/i915/Makefile
>> +++ b/drivers/gpu/drm/i915/Makefile
>> @@ -135,15 +135,15 @@ i915-y += dvo_ch7017.o \
>>  	  dvo_ns2501.o \
>>  	  dvo_sil164.o \
>>  	  dvo_tfp410.o \
>> +	  gen7_dsi.o \
>> +	  gen7_dsi_pll.o \
>>  	  intel_crt.o \
>>  	  intel_ddi.o \
>>  	  intel_dp_aux_backlight.o \
>>  	  intel_dp_link_training.o \
>>  	  intel_dp_mst.o \
>>  	  intel_dp.o \
>> -	  intel_dsi.o \
>>  	  intel_dsi_dcs_backlight.o \
>> -	  intel_dsi_pll.o \
>>  	  intel_dsi_vbt.o \
>>  	  intel_dvo.o \
>>  	  intel_hdmi.o \
>> diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/gen7_dsi.c
>> similarity index 100%
>> rename from drivers/gpu/drm/i915/intel_dsi.c
>> rename to drivers/gpu/drm/i915/gen7_dsi.c
>> diff --git a/drivers/gpu/drm/i915/intel_dsi_pll.c b/drivers/gpu/drm/i915/gen7_dsi_pll.c
>> similarity index 100%
>> rename from drivers/gpu/drm/i915/intel_dsi_pll.c
>> rename to drivers/gpu/drm/i915/gen7_dsi_pll.c
>> diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
>> index b9b70321c054..888a85dc3856 100644
>> --- a/drivers/gpu/drm/i915/intel_drv.h
>> +++ b/drivers/gpu/drm/i915/intel_drv.h
>> @@ -1730,7 +1730,7 @@ int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector);
>>  /* intel_dp_mst.c */
>>  int intel_dp_mst_encoder_init(struct intel_digital_port *intel_dig_port, int conn_id);
>>  void intel_dp_mst_encoder_cleanup(struct intel_digital_port *intel_dig_port);
>> -/* intel_dsi.c */
>> +/* gen7_dsi.c */
>>  void intel_dsi_init(struct drm_i915_private *dev_priv);
>>  
>>  /* intel_dsi_dcs_backlight.c */
>> diff --git a/drivers/gpu/drm/i915/intel_dsi.h b/drivers/gpu/drm/i915/intel_dsi.h
>> index 7afeb9580f41..1b5c2c167472 100644
>> --- a/drivers/gpu/drm/i915/intel_dsi.h
>> +++ b/drivers/gpu/drm/i915/intel_dsi.h
>> @@ -129,11 +129,11 @@ static inline struct intel_dsi *enc_to_intel_dsi(struct drm_encoder *encoder)
>>  	return container_of(encoder, struct intel_dsi, base.base);
>>  }
>>  
>> -/* intel_dsi.c */
>> +/* gen7_dsi.c */
>>  void wait_for_dsi_fifo_empty(struct intel_dsi *intel_dsi, enum port port);
>>  enum mipi_dsi_pixel_format pixel_format_from_register_bits(u32 fmt);
>>  
>> -/* intel_dsi_pll.c */
>> +/* gen7_dsi_pll.c */
>>  bool intel_dsi_pll_is_enabled(struct drm_i915_private *dev_priv);
>>  int intel_compute_dsi_pll(struct intel_encoder *encoder,
>>  			  struct intel_crtc_state *config);
>> -- 
>> 2.11.0
>> 
>> _______________________________________________
>> Intel-gfx mailing list
>> Intel-gfx@lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Ville Syrjälä July 4, 2018, 11:09 a.m. UTC | #4
On Wed, Jul 04, 2018 at 11:10:06AM +0300, Jani Nikula wrote:
> On Tue, 03 Jul 2018, Ville Syrjälä <ville.syrjala@linux.intel.com> wrote:
> > On Tue, Jul 03, 2018 at 04:53:28PM +0300, Jani Nikula wrote:
> >> Starting from ICL or gen 11 we have a new DSI block which requires
> >> completely different programming from the current implementation. Having
> >> them in the same file would be confusing. Rename the current DSI and DSI
> >> PLL implementation files as gen7_dsi.c and gen7_dsi_pll.c.
> >
> > gen7 is a rather odd name for this. vlv would seem more
> > appropriate, though not particularly good either.
> 
> Daniel and Chris suggested a gen based name, and specifically to name
> both the old and new with a prefix.

gen based names rarely make sense when it comes to the display. If
there's a display thing with a gen7 name I immediately think "oh
that's ivb, maybe also hsw", but never in a million years would
I think of vlv.

Also the gen naming for display has getting even more confusing
since glk display pipes were pulled in from cnl. So if you read the
spec and see a "gen10 display" note it generally applies to glk as
well, even though for us glk is gen9.

So I think the generally best bet is to never use a genX label on
any display code.

> I guess I would've gone with
> "legacy" or "byt". Madhav has gone for gen11 prefixed function naming in
> the new series.

"byt" I would not use because everything else is named "vlv". So
I guess "vlv" is what I would suggest here. Or that earlier
"legacy" idea.
diff mbox

Patch

diff --git a/drivers/gpu/drm/i915/Makefile b/drivers/gpu/drm/i915/Makefile
index 4c6adae23e18..a1cfb3a3926b 100644
--- a/drivers/gpu/drm/i915/Makefile
+++ b/drivers/gpu/drm/i915/Makefile
@@ -135,15 +135,15 @@  i915-y += dvo_ch7017.o \
 	  dvo_ns2501.o \
 	  dvo_sil164.o \
 	  dvo_tfp410.o \
+	  gen7_dsi.o \
+	  gen7_dsi_pll.o \
 	  intel_crt.o \
 	  intel_ddi.o \
 	  intel_dp_aux_backlight.o \
 	  intel_dp_link_training.o \
 	  intel_dp_mst.o \
 	  intel_dp.o \
-	  intel_dsi.o \
 	  intel_dsi_dcs_backlight.o \
-	  intel_dsi_pll.o \
 	  intel_dsi_vbt.o \
 	  intel_dvo.o \
 	  intel_hdmi.o \
diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/gen7_dsi.c
similarity index 100%
rename from drivers/gpu/drm/i915/intel_dsi.c
rename to drivers/gpu/drm/i915/gen7_dsi.c
diff --git a/drivers/gpu/drm/i915/intel_dsi_pll.c b/drivers/gpu/drm/i915/gen7_dsi_pll.c
similarity index 100%
rename from drivers/gpu/drm/i915/intel_dsi_pll.c
rename to drivers/gpu/drm/i915/gen7_dsi_pll.c
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
index b9b70321c054..888a85dc3856 100644
--- a/drivers/gpu/drm/i915/intel_drv.h
+++ b/drivers/gpu/drm/i915/intel_drv.h
@@ -1730,7 +1730,7 @@  int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector);
 /* intel_dp_mst.c */
 int intel_dp_mst_encoder_init(struct intel_digital_port *intel_dig_port, int conn_id);
 void intel_dp_mst_encoder_cleanup(struct intel_digital_port *intel_dig_port);
-/* intel_dsi.c */
+/* gen7_dsi.c */
 void intel_dsi_init(struct drm_i915_private *dev_priv);
 
 /* intel_dsi_dcs_backlight.c */
diff --git a/drivers/gpu/drm/i915/intel_dsi.h b/drivers/gpu/drm/i915/intel_dsi.h
index 7afeb9580f41..1b5c2c167472 100644
--- a/drivers/gpu/drm/i915/intel_dsi.h
+++ b/drivers/gpu/drm/i915/intel_dsi.h
@@ -129,11 +129,11 @@  static inline struct intel_dsi *enc_to_intel_dsi(struct drm_encoder *encoder)
 	return container_of(encoder, struct intel_dsi, base.base);
 }
 
-/* intel_dsi.c */
+/* gen7_dsi.c */
 void wait_for_dsi_fifo_empty(struct intel_dsi *intel_dsi, enum port port);
 enum mipi_dsi_pixel_format pixel_format_from_register_bits(u32 fmt);
 
-/* intel_dsi_pll.c */
+/* gen7_dsi_pll.c */
 bool intel_dsi_pll_is_enabled(struct drm_i915_private *dev_priv);
 int intel_compute_dsi_pll(struct intel_encoder *encoder,
 			  struct intel_crtc_state *config);