Replace the driver local defines, for the minimum and maximum TMDS char rates, with shared constants defined in <drm/display/drm_hdmi_helper.h>.
Suggested-by: Maxime Ripard <[email protected]> Signed-off-by: Javier Martinez Canillas <[email protected]> --- drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c index a86ff3706369..3d2c1de975da 100644 --- a/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c +++ b/drivers/gpu/drm/msm/hdmi/hdmi_phy_8998.c @@ -7,14 +7,13 @@ #include <linux/clk-provider.h> #include <linux/delay.h> +#include <drm/display/drm_hdmi_helper.h> + #include "hdmi.h" #define HDMI_VCO_MAX_FREQ 12000000000UL #define HDMI_VCO_MIN_FREQ 8000000000UL -#define HDMI_PCLK_MAX_FREQ 600000000 -#define HDMI_PCLK_MIN_FREQ 25000000 - #define HDMI_HIGH_FREQ_BIT_CLK_THRESHOLD 3400000000UL #define HDMI_DIG_FREQ_BIT_CLK_THRESHOLD 1500000000UL #define HDMI_MID_FREQ_BIT_CLK_THRESHOLD 750000000UL @@ -649,7 +648,9 @@ static int hdmi_8998_pll_prepare(struct clk_hw *hw) static int hdmi_8998_pll_determine_rate(struct clk_hw *hw, struct clk_rate_request *req) { - req->rate = clamp_t(unsigned long, req->rate, HDMI_PCLK_MIN_FREQ, HDMI_PCLK_MAX_FREQ); + req->rate = clamp_t(unsigned long, req->rate, + DRM_HDMI_TMDS_CHAR_RATE_MIN, + DRM_HDMI_TMDS_CHAR_RATE_MAX_2_0); return 0; } -- 2.54.0
