drm/i915: make plane func structs const

Submitted by Jani Nikula on June 13, 2018, 10:24 a.m.

Details

Message ID 20180613102422.13773-1-jani.nikula@intel.com
State New
Headers show
Series "drm/i915: make plane func structs const" ( rev: 1 ) in Intel GFX

Not browsing as part of any series.

Commit Message

Jani Nikula June 13, 2018, 10:24 a.m.
No reason not to be const.

Signed-off-by: Jani Nikula <jani.nikula@intel.com>
---
 drivers/gpu/drm/i915/intel_display.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Patch hide | download patch | download mbox

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 2c16c3a3cdea..4bb8c12c333f 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -13346,7 +13346,7 @@  static bool intel_cursor_format_mod_supported(struct drm_plane *_plane,
 		format == DRM_FORMAT_ARGB8888;
 }
 
-static struct drm_plane_funcs skl_plane_funcs = {
+static const struct drm_plane_funcs skl_plane_funcs = {
 	.update_plane = drm_atomic_helper_update_plane,
 	.disable_plane = drm_atomic_helper_disable_plane,
 	.destroy = intel_plane_destroy,
@@ -13357,7 +13357,7 @@  static struct drm_plane_funcs skl_plane_funcs = {
 	.format_mod_supported = skl_plane_format_mod_supported,
 };
 
-static struct drm_plane_funcs i965_plane_funcs = {
+static const struct drm_plane_funcs i965_plane_funcs = {
 	.update_plane = drm_atomic_helper_update_plane,
 	.disable_plane = drm_atomic_helper_disable_plane,
 	.destroy = intel_plane_destroy,
@@ -13368,7 +13368,7 @@  static struct drm_plane_funcs i965_plane_funcs = {
 	.format_mod_supported = i965_plane_format_mod_supported,
 };
 
-static struct drm_plane_funcs i8xx_plane_funcs = {
+static const struct drm_plane_funcs i8xx_plane_funcs = {
 	.update_plane = drm_atomic_helper_update_plane,
 	.disable_plane = drm_atomic_helper_disable_plane,
 	.destroy = intel_plane_destroy,

Comments

On Wed, Jun 13, 2018 at 01:24:22PM +0300, Jani Nikula wrote:
> No reason not to be const.
> 
> Signed-off-by: Jani Nikula <jani.nikula@intel.com>

https://patchwork.freedesktop.org/patch/226875/

> ---
>  drivers/gpu/drm/i915/intel_display.c | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 2c16c3a3cdea..4bb8c12c333f 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -13346,7 +13346,7 @@ static bool intel_cursor_format_mod_supported(struct drm_plane *_plane,
>  		format == DRM_FORMAT_ARGB8888;
>  }
>  
> -static struct drm_plane_funcs skl_plane_funcs = {
> +static const struct drm_plane_funcs skl_plane_funcs = {
>  	.update_plane = drm_atomic_helper_update_plane,
>  	.disable_plane = drm_atomic_helper_disable_plane,
>  	.destroy = intel_plane_destroy,
> @@ -13357,7 +13357,7 @@ static struct drm_plane_funcs skl_plane_funcs = {
>  	.format_mod_supported = skl_plane_format_mod_supported,
>  };
>  
> -static struct drm_plane_funcs i965_plane_funcs = {
> +static const struct drm_plane_funcs i965_plane_funcs = {
>  	.update_plane = drm_atomic_helper_update_plane,
>  	.disable_plane = drm_atomic_helper_disable_plane,
>  	.destroy = intel_plane_destroy,
> @@ -13368,7 +13368,7 @@ static struct drm_plane_funcs i965_plane_funcs = {
>  	.format_mod_supported = i965_plane_format_mod_supported,
>  };
>  
> -static struct drm_plane_funcs i8xx_plane_funcs = {
> +static const struct drm_plane_funcs i8xx_plane_funcs = {
>  	.update_plane = drm_atomic_helper_update_plane,
>  	.disable_plane = drm_atomic_helper_disable_plane,
>  	.destroy = intel_plane_destroy,
> -- 
> 2.11.0
> 
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
On Wed, 13 Jun 2018, Ville Syrjälä <ville.syrjala@linux.intel.com> wrote:
> On Wed, Jun 13, 2018 at 01:24:22PM +0300, Jani Nikula wrote:
>> No reason not to be const.
>> 
>> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
>
> https://patchwork.freedesktop.org/patch/226875/

Okay, rb on that.

BR,
Jani.


>
>> ---
>>  drivers/gpu/drm/i915/intel_display.c | 6 +++---
>>  1 file changed, 3 insertions(+), 3 deletions(-)
>> 
>> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
>> index 2c16c3a3cdea..4bb8c12c333f 100644
>> --- a/drivers/gpu/drm/i915/intel_display.c
>> +++ b/drivers/gpu/drm/i915/intel_display.c
>> @@ -13346,7 +13346,7 @@ static bool intel_cursor_format_mod_supported(struct drm_plane *_plane,
>>  		format == DRM_FORMAT_ARGB8888;
>>  }
>>  
>> -static struct drm_plane_funcs skl_plane_funcs = {
>> +static const struct drm_plane_funcs skl_plane_funcs = {
>>  	.update_plane = drm_atomic_helper_update_plane,
>>  	.disable_plane = drm_atomic_helper_disable_plane,
>>  	.destroy = intel_plane_destroy,
>> @@ -13357,7 +13357,7 @@ static struct drm_plane_funcs skl_plane_funcs = {
>>  	.format_mod_supported = skl_plane_format_mod_supported,
>>  };
>>  
>> -static struct drm_plane_funcs i965_plane_funcs = {
>> +static const struct drm_plane_funcs i965_plane_funcs = {
>>  	.update_plane = drm_atomic_helper_update_plane,
>>  	.disable_plane = drm_atomic_helper_disable_plane,
>>  	.destroy = intel_plane_destroy,
>> @@ -13368,7 +13368,7 @@ static struct drm_plane_funcs i965_plane_funcs = {
>>  	.format_mod_supported = i965_plane_format_mod_supported,
>>  };
>>  
>> -static struct drm_plane_funcs i8xx_plane_funcs = {
>> +static const struct drm_plane_funcs i8xx_plane_funcs = {
>>  	.update_plane = drm_atomic_helper_update_plane,
>>  	.disable_plane = drm_atomic_helper_disable_plane,
>>  	.destroy = intel_plane_destroy,
>> -- 
>> 2.11.0
>> 
>> _______________________________________________
>> Intel-gfx mailing list
>> Intel-gfx@lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/intel-gfx