drm/i915/cdclk: put the cdclk vtables in const data
authorJani Nikula <jani.nikula@intel.com>
Thu, 21 Oct 2021 13:34:08 +0000 (16:34 +0300)
committerJani Nikula <jani.nikula@intel.com>
Fri, 22 Oct 2021 08:20:02 +0000 (11:20 +0300)
Add the const that was accidentally left out from the vtables.

Fixes: 6b4cd9cba620 ("drm/i915: constify the cdclk vtable")
Cc: Dave Airlie <airlied@redhat.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20211021133408.32166-1-jani.nikula@intel.com
drivers/gpu/drm/i915/display/intel_cdclk.c

index 9e466d829019a352ce9b132ae5d3c92a8ad0c36a..868dd43a7542f8ca9ab1a66c9271373759995c45 100644 (file)
@@ -2885,7 +2885,7 @@ u32 intel_read_rawclk(struct drm_i915_private *dev_priv)
        return freq;
 }
 
-static struct intel_cdclk_funcs tgl_cdclk_funcs = {
+static const struct intel_cdclk_funcs tgl_cdclk_funcs = {
        .get_cdclk = bxt_get_cdclk,
        .set_cdclk = bxt_set_cdclk,
        .bw_calc_min_cdclk = skl_bw_calc_min_cdclk,
@@ -2893,7 +2893,7 @@ static struct intel_cdclk_funcs tgl_cdclk_funcs = {
        .calc_voltage_level = tgl_calc_voltage_level,
 };
 
-static struct intel_cdclk_funcs ehl_cdclk_funcs = {
+static const struct intel_cdclk_funcs ehl_cdclk_funcs = {
        .get_cdclk = bxt_get_cdclk,
        .set_cdclk = bxt_set_cdclk,
        .bw_calc_min_cdclk = skl_bw_calc_min_cdclk,
@@ -2901,7 +2901,7 @@ static struct intel_cdclk_funcs ehl_cdclk_funcs = {
        .calc_voltage_level = ehl_calc_voltage_level,
 };
 
-static struct intel_cdclk_funcs icl_cdclk_funcs = {
+static const struct intel_cdclk_funcs icl_cdclk_funcs = {
        .get_cdclk = bxt_get_cdclk,
        .set_cdclk = bxt_set_cdclk,
        .bw_calc_min_cdclk = skl_bw_calc_min_cdclk,
@@ -2909,7 +2909,7 @@ static struct intel_cdclk_funcs icl_cdclk_funcs = {
        .calc_voltage_level = icl_calc_voltage_level,
 };
 
-static struct intel_cdclk_funcs bxt_cdclk_funcs = {
+static const struct intel_cdclk_funcs bxt_cdclk_funcs = {
        .get_cdclk = bxt_get_cdclk,
        .set_cdclk = bxt_set_cdclk,
        .bw_calc_min_cdclk = skl_bw_calc_min_cdclk,
@@ -2917,54 +2917,54 @@ static struct intel_cdclk_funcs bxt_cdclk_funcs = {
        .calc_voltage_level = bxt_calc_voltage_level,
 };
 
-static struct intel_cdclk_funcs skl_cdclk_funcs = {
+static const struct intel_cdclk_funcs skl_cdclk_funcs = {
        .get_cdclk = skl_get_cdclk,
        .set_cdclk = skl_set_cdclk,
        .bw_calc_min_cdclk = skl_bw_calc_min_cdclk,
        .modeset_calc_cdclk = skl_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs bdw_cdclk_funcs = {
+static const struct intel_cdclk_funcs bdw_cdclk_funcs = {
        .get_cdclk = bdw_get_cdclk,
        .set_cdclk = bdw_set_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = bdw_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs chv_cdclk_funcs = {
+static const struct intel_cdclk_funcs chv_cdclk_funcs = {
        .get_cdclk = vlv_get_cdclk,
        .set_cdclk = chv_set_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = vlv_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs vlv_cdclk_funcs = {
+static const struct intel_cdclk_funcs vlv_cdclk_funcs = {
        .get_cdclk = vlv_get_cdclk,
        .set_cdclk = vlv_set_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = vlv_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs hsw_cdclk_funcs = {
+static const struct intel_cdclk_funcs hsw_cdclk_funcs = {
        .get_cdclk = hsw_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
 /* SNB, IVB, 965G, 945G */
-static struct intel_cdclk_funcs fixed_400mhz_cdclk_funcs = {
+static const struct intel_cdclk_funcs fixed_400mhz_cdclk_funcs = {
        .get_cdclk = fixed_400mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs ilk_cdclk_funcs = {
+static const struct intel_cdclk_funcs ilk_cdclk_funcs = {
        .get_cdclk = fixed_450mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs gm45_cdclk_funcs = {
+static const struct intel_cdclk_funcs gm45_cdclk_funcs = {
        .get_cdclk = gm45_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
@@ -2972,7 +2972,7 @@ static struct intel_cdclk_funcs gm45_cdclk_funcs = {
 
 /* G45 uses G33 */
 
-static struct intel_cdclk_funcs i965gm_cdclk_funcs = {
+static const struct intel_cdclk_funcs i965gm_cdclk_funcs = {
        .get_cdclk = i965gm_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
@@ -2980,19 +2980,19 @@ static struct intel_cdclk_funcs i965gm_cdclk_funcs = {
 
 /* i965G uses fixed 400 */
 
-static struct intel_cdclk_funcs pnv_cdclk_funcs = {
+static const struct intel_cdclk_funcs pnv_cdclk_funcs = {
        .get_cdclk = pnv_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs g33_cdclk_funcs = {
+static const struct intel_cdclk_funcs g33_cdclk_funcs = {
        .get_cdclk = g33_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i945gm_cdclk_funcs = {
+static const struct intel_cdclk_funcs i945gm_cdclk_funcs = {
        .get_cdclk = i945gm_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
@@ -3000,37 +3000,37 @@ static struct intel_cdclk_funcs i945gm_cdclk_funcs = {
 
 /* i945G uses fixed 400 */
 
-static struct intel_cdclk_funcs i915gm_cdclk_funcs = {
+static const struct intel_cdclk_funcs i915gm_cdclk_funcs = {
        .get_cdclk = i915gm_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i915g_cdclk_funcs = {
+static const struct intel_cdclk_funcs i915g_cdclk_funcs = {
        .get_cdclk = fixed_333mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i865g_cdclk_funcs = {
+static const struct intel_cdclk_funcs i865g_cdclk_funcs = {
        .get_cdclk = fixed_266mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i85x_cdclk_funcs = {
+static const struct intel_cdclk_funcs i85x_cdclk_funcs = {
        .get_cdclk = i85x_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i845g_cdclk_funcs = {
+static const struct intel_cdclk_funcs i845g_cdclk_funcs = {
        .get_cdclk = fixed_200mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,
 };
 
-static struct intel_cdclk_funcs i830_cdclk_funcs = {
+static const struct intel_cdclk_funcs i830_cdclk_funcs = {
        .get_cdclk = fixed_133mhz_get_cdclk,
        .bw_calc_min_cdclk = intel_bw_calc_min_cdclk,
        .modeset_calc_cdclk = fixed_modeset_calc_cdclk,