OMAP: DSS2: Generalize DSS clock source names
Subsystems (3)
cover OMAP: DSS2: Generalize DSS clock source names
The OMAP Display Subsystem has multiple clock sources available for its modules. One of these sources has to be selected through a global control register called DSS_CTRL.
For example, on OMAP4, the Display Controller Module's (DISPC) functional clock can be derived from:
a) output of DPLL_PER's M5 divisor
b) output of DSI1 PLL's M4 divisor
c) output of DSI2 PLL's M4 divisor
d) output of HDMI PLL
There is, hence, an enum called 'dss_clk_source' which is used throughout DSS2, to select clock sources for various DSS sub modules. These clock source names are currently specific to OMAP2/3 TRM clock names.
All enum members, variables, functions which are based on these clock source names have been made generic such that they can be used for future OMAPs as well.
Archit Taneja (3):
OMAP2PLUS: DSS2: Make members of dss_clk_source generic
OMAP2PLUS: DSS2: Use dss features to get clock source names of
current OMAP
OMAP2PLUS: DSS2: DSI: Generalize DSI PLL Clock Naming
arch/arm/plat-omap/include/plat/display.h | 4 +- drivers/video/omap2/dss/dispc.c | 11 +- drivers/video/omap2/dss/dpi.c | 8 +- drivers/video/omap2/dss/dsi.c | 178 ++++++++++++++++------------- drivers/video/omap2/dss/dss.c | 43 +++++--- drivers/video/omap2/dss/dss.h | 33 ++++-- drivers/video/omap2/dss/dss_features.c | 23 ++++ drivers/video/omap2/dss/dss_features.h | 1 + 8 files changed, 185 insertions(+), 116 deletions(-)
PATCH 1/3 OMAP2PLUS: DSS2: Make members of dss_clk_source generic
The enum members of 'dss_clk_source' have clock source names specific to OMAP2/3. Change the names to more generic terms such that they now describe where the clocks come from and what they are used for.
Also, change the enum member names to have "DSS_CLK_SRC" instead of "DSS_SRC" for more clarity.
--- drivers/video/omap2/dss/dispc.c | 4 ++-- drivers/video/omap2/dss/dpi.c | 4 ++-- drivers/video/omap2/dss/dsi.c | 20 ++++++++++---------- drivers/video/omap2/dss/dss.c | 20 ++++++++++---------- drivers/video/omap2/dss/dss.h | 6 +++--- 5 files changed, 27 insertions(+), 27 deletions(-)
drivers/video/omap2/dss/dispc.c +2 -2
@@ -2341,7 +2341,7 @@ unsigned long dispc_fclk_rate(void) {unsigned long r =0 ; -if (dss_get_dispc_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ) +if (dss_get_dispc_clk_source () ==DSS_CLK_SRC_FCK ) r =dss_clk_get_rate (DSS_CLK_FCK ); else#ifdef CONFIG_OMAP2_DSS_DSI
@@ -2393,7 +2393,7 @@ void dispc_dump_clocks(struct seq_file *s)seq_printf (s,"- DISPC -\n" );seq_printf (s,"dispc fclk source = %s\n" , -dss_get_dispc_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ? +dss_get_dispc_clk_source () ==DSS_CLK_SRC_FCK ?"dss1_alwon_fclk" :"dsi1_pll_fclk" );seq_printf (s,"fck\t\t%-16lu\n" ,dispc_fclk_rate ());
drivers/video/omap2/dss/dpi.c +2 -2
@@ -57,7 +57,7 @@ static int dpi_set_dsi_clk(struct omap_dss_device *dssdev, bool is_tft,if (r)return r; -dss_select_dispc_clk_source (DSS_SRC_DSI1_PLL_FCLK ); +dss_select_dispc_clk_source (DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ); r =dispc_set_clock_div (dssdev->manager->id, &dispc_cinfo);if (r)
@@ -217,7 +217,7 @@ void omapdss_dpi_display_disable(struct omap_dss_device *dssdev) dssdev->manager->disable (dssdev->manager);#ifdef CONFIG_OMAP2_DSS_USE_DSI_PLL -dss_select_dispc_clk_source (DSS_SRC_DSS1_ALWON_FCLK ); +dss_select_dispc_clk_source (DSS_CLK_SRC_FCK );dsi_pll_uninit ();dss_clk_disable (DSS_CLK_SYSCK );#endif
drivers/video/omap2/dss/dsi.c +10 -10
@@ -731,7 +731,7 @@ static unsigned long dsi_fclk_rate(void) {unsigned long r; -if (dss_get_dsi_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ) { +if (dss_get_dsi_clk_source () ==DSS_CLK_SRC_FCK ) {/* DSI FCLK source is DSS1_ALWON_FCK, which is dss1_fck */ r =dss_clk_get_rate (DSS_CLK_FCK ); }else {
@@ -1188,19 +1188,19 @@ void dsi_dump_clocks(struct seq_file *s)seq_printf (s,"dsi1_pll_fck\t%-16luregm3 %u\t(%s)\n" , cinfo->dsi1_pll_fclk, cinfo->regm3, -dss_get_dispc_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ? +dss_get_dispc_clk_source () ==DSS_CLK_SRC_FCK ?"off" :"on" );seq_printf (s,"dsi2_pll_fck\t%-16luregm4 %u\t(%s)\n" , cinfo->dsi2_pll_fclk, cinfo->regm4, -dss_get_dsi_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ? +dss_get_dsi_clk_source () ==DSS_CLK_SRC_FCK ?"off" :"on" );seq_printf (s,"- DSI -\n" );seq_printf (s,"dsi fclk source = %s\n" , -dss_get_dsi_clk_source () ==DSS_SRC_DSS1_ALWON_FCLK ? +dss_get_dsi_clk_source () ==DSS_CLK_SRC_FCK ?"dss1_alwon_fclk" :"dsi2_pll_fclk" );seq_printf (s,"DSI_FCLK\t%lu\n" ,dsi_fclk_rate ());
@@ -3052,8 +3052,8 @@ static int dsi_display_init_dsi(struct omap_dss_device *dssdev)if (r) goto err1; -dss_select_dispc_clk_source (DSS_SRC_DSI1_PLL_FCLK ); -dss_select_dsi_clk_source (DSS_SRC_DSI2_PLL_FCLK ); +dss_select_dispc_clk_source (DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ); +dss_select_dsi_clk_source (DSS_CLK_SRC_DSI_PLL_HSDIV_DSI );DSSDBG ("PLL OK\n" );
@@ -3089,8 +3089,8 @@ static int dsi_display_init_dsi(struct omap_dss_device *dssdev) err3:dsi_complexio_uninit (); err2: -dss_select_dispc_clk_source (DSS_SRC_DSS1_ALWON_FCLK ); -dss_select_dsi_clk_source (DSS_SRC_DSS1_ALWON_FCLK ); +dss_select_dispc_clk_source (DSS_CLK_SRC_FCK ); +dss_select_dsi_clk_source (DSS_CLK_SRC_FCK ); err1:dsi_pll_uninit (); err0:
@@ -3106,8 +3106,8 @@ static void dsi_display_uninit_dsi(struct omap_dss_device *dssdev)dsi_vc_enable (2 ,0 );dsi_vc_enable (3 ,0 ); -dss_select_dispc_clk_source (DSS_SRC_DSS1_ALWON_FCLK ); -dss_select_dsi_clk_source (DSS_SRC_DSS1_ALWON_FCLK ); +dss_select_dispc_clk_source (DSS_CLK_SRC_FCK ); +dss_select_dsi_clk_source (DSS_CLK_SRC_FCK );dsi_complexio_uninit ();dsi_pll_uninit (); }
drivers/video/omap2/dss/dss.c +10 -10
@@ -272,12 +272,12 @@ void dss_select_dispc_clk_source(enum dss_clk_source clk_src) {int b; -BUG_ON (clk_src !=DSS_SRC_DSI1_PLL_FCLK && - clk_src !=DSS_SRC_DSS1_ALWON_FCLK ); +BUG_ON (clk_src !=DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC && + clk_src !=DSS_CLK_SRC_FCK ); - b = clk_src ==DSS_SRC_DSS1_ALWON_FCLK ?0 :1 ; + b = clk_src ==DSS_CLK_SRC_FCK ?0 :1 ; -if (clk_src ==DSS_SRC_DSI1_PLL_FCLK ) +if (clk_src ==DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC )dsi_wait_dsi1_pll_active ();REG_FLD_MOD (DSS_CONTROL , b,0 ,0 );/* DISPC_CLK_SWITCH */
@@ -289,12 +289,12 @@ void dss_select_dsi_clk_source(enum dss_clk_source clk_src) {int b; -BUG_ON (clk_src !=DSS_SRC_DSI2_PLL_FCLK && - clk_src !=DSS_SRC_DSS1_ALWON_FCLK ); +BUG_ON (clk_src !=DSS_CLK_SRC_DSI_PLL_HSDIV_DSI && + clk_src !=DSS_CLK_SRC_FCK ); - b = clk_src ==DSS_SRC_DSS1_ALWON_FCLK ?0 :1 ; + b = clk_src ==DSS_CLK_SRC_FCK ?0 :1 ; -if (clk_src ==DSS_SRC_DSI2_PLL_FCLK ) +if (clk_src ==DSS_CLK_SRC_DSI_PLL_HSDIV_DSI )dsi_wait_dsi2_pll_active ();REG_FLD_MOD (DSS_CONTROL , b,1 ,1 );/* DSI_CLK_SWITCH */
@@ -595,8 +595,8 @@ static int dss_init(bool skip_init) } } - dss.dsi_clk_source =DSS_SRC_DSS1_ALWON_FCLK ; - dss.dispc_clk_source =DSS_SRC_DSS1_ALWON_FCLK ; + dss.dsi_clk_source =DSS_CLK_SRC_FCK ; + dss.dispc_clk_source =DSS_CLK_SRC_FCK ;dss_save_context ();
drivers/video/omap2/dss/dss.h +3 -3
@@ -118,9 +118,9 @@ enum dss_clock { };enum dss_clk_source { -DSS_SRC_DSI1_PLL_FCLK , -DSS_SRC_DSI2_PLL_FCLK , -DSS_SRC_DSS1_ALWON_FCLK , +DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ,/* DSI1_PLL_FCLK */ +DSS_CLK_SRC_DSI_PLL_HSDIV_DSI ,/* DSI2_PLL_FCLK */ +DSS_CLK_SRC_FCK ,/* DSS1_ALWON_FCLK */ };struct dss_clock_info {
Signature · 1 line
1.7.1
PATCH 2/3 OMAP2PLUS: DSS2: Use dss features to get clock source names of current OMAP
In reply to Archit TanejaClock source names vary across OMAP2/3 and OMAP4, the clock source enum names have been made generic in the driver, but for purposes of debugging and dumping clock sources, it is better to preserve the actual TRM name of the clock.
Introduce a dss feature function 'dss_feat_get_clk_source_name()' which returns a string with the TRM clock name for the current OMAP in use. The OMAP specific name is printed along the generic name within brackets.
--- drivers/video/omap2/dss/dispc.c | 7 +++-- drivers/video/omap2/dss/dsi.c | 42 ++++++++++++++++++++++---------- drivers/video/omap2/dss/dss.c | 19 +++++++++++++- drivers/video/omap2/dss/dss.h | 7 +++++ drivers/video/omap2/dss/dss_features.c | 23 +++++++++++++++++ drivers/video/omap2/dss/dss_features.h | 1 + 6 files changed, 81 insertions(+), 18 deletions(-)
drivers/video/omap2/dss/dispc.c +4 -3
@@ -2387,14 +2387,15 @@ void dispc_dump_clocks(struct seq_file *s) {int lcd, pcd;u32 l; +enum dss_clk_source dispc_clk_src =dss_get_dispc_clk_source ();enable_clocks (1 );seq_printf (s,"- DISPC -\n" ); -seq_printf (s,"dispc fclk source = %s\n" , -dss_get_dispc_clk_source () ==DSS_CLK_SRC_FCK ? -"dss1_alwon_fclk" :"dsi1_pll_fclk" ); +seq_printf (s,"dispc fclk source = %s (%s)\n" , +dss_get_generic_clk_source_name (dispc_clk_src), +dss_feat_get_clk_source_name (dispc_clk_src));seq_printf (s,"fck\t\t%-16lu\n" ,dispc_fclk_rate ());
drivers/video/omap2/dss/dsi.c +29 -13
81 lines not on this page · raw message
drivers/video/omap2/dss/dss.c +17 -2
@@ -81,6 +81,12 @@ static struct {u32 ctx[DSS_SZ_REGS /sizeof (u32)]; } dss; +static const struct dss_clk_source_name dss_generic_clk_source_names[] = { + {DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ,"DSI_PLL_HSDIV_DISPC" }, + {DSS_CLK_SRC_DSI_PLL_HSDIV_DSI ,"DSI_PLL_HSDIV_DSI" }, + {DSS_CLK_SRC_FCK ,"DSS_FCK" }, +}; +static void dss_clk_enable_all_no_ctx (void );static void dss_clk_disable_all_no_ctx (void );static void dss_clk_enable_no_ctx (enum dss_clock clks);
@@ -221,6 +227,11 @@ void dss_sdi_disable(void)REG_FLD_MOD (DSS_PLL_CONTROL ,0 ,18 ,18 );/* SDI_PLL_SYSRESET */ } +const char *dss_get_generic_clk_source_name (enum dss_clk_source clk_src) +{ +return dss_generic_clk_source_names[clk_src].clksrc_name; +} +void dss_dump_clocks (struct seq_file *s) {unsigned long dpll4_ck_rate;
@@ -236,12 +247,16 @@ void dss_dump_clocks(struct seq_file *s)seq_printf (s,"dpll4_ck %lu\n" , dpll4_ck_rate);if (cpu_is_omap3630 ()) -seq_printf (s,"dss1_alwon_fclk = %lu / %lu = %lu\n" , +seq_printf (s,"%s (%s) = %lu / %lu = %lu\n" , +dss_get_generic_clk_source_name (DSS_CLK_SRC_FCK ), +dss_feat_get_clk_source_name (DSS_CLK_SRC_FCK ), dpll4_ck_rate, dpll4_ck_rate / dpll4_m4_ck_rate,dss_clk_get_rate (DSS_CLK_FCK ));else -seq_printf (s,"dss1_alwon_fclk = %lu / %lu * 2 = %lu\n" , +seq_printf (s,"%s (%s) = %lu / %lu * 2 = %lu\n" , +dss_get_generic_clk_source_name (DSS_CLK_SRC_FCK ), +dss_feat_get_clk_source_name (DSS_CLK_SRC_FCK ), dpll4_ck_rate, dpll4_ck_rate / dpll4_m4_ck_rate,dss_clk_get_rate (DSS_CLK_FCK ));
drivers/video/omap2/dss/dss.h +7 -0
@@ -123,6 +123,12 @@ enum dss_clk_source { DSS_CLK_SRC_FCK, /* DSS1_ALWON_FCLK */ }; +/* Correlates clock source name and dss_clk_source member */ +struct dss_clk_source_name { +enum dss_clk_source clksrc; +const char *clksrc_name; +}; +struct dss_clock_info {/* rates that we get with dividers below */ unsigned long fck;
@@ -215,6 +221,7 @@ void dss_clk_enable(enum dss_clock clks);void dss_clk_disable (enum dss_clock clks);unsigned long dss_clk_get_rate (enum dss_clock clk);int dss_need_ctx_restore (void ); +const char *dss_get_generic_clk_source_name (enum dss_clk_source clk_src);void dss_dump_clocks (struct seq_file *s);void dss_dump_regs (struct seq_file *s);
drivers/video/omap2/dss/dss_features.c +23 -0
@@ -25,6 +25,7 @@#include <plat/display.h> #include <plat/cpu.h> +#include "dss.h" #include "dss_features.h" /* Defines a generic omap register field */
@@ -44,6 +45,7 @@ struct omap_dss_features {const unsigned long max_dss_fck;const enum omap_display_type *supported_displays;const enum omap_color_mode *supported_color_modes; +const struct dss_clk_source_name *clksrc_names; };/* This struct is assigned to one of the below during initialization */
@@ -149,6 +151,18 @@ static const enum omap_color_mode omap3_dss_supported_color_modes[] = { OMAP_DSS_COLOR_RGBA32 | OMAP_DSS_COLOR_RGBX32, }; +static const struct dss_clk_source_name omap2_dss_clk_source_names[] = { + {DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ,"N/A" }, + {DSS_CLK_SRC_DSI_PLL_HSDIV_DSI ,"N/A" }, + {DSS_CLK_SRC_FCK ,"DSS_FCLK1" }, +}; + +static const struct dss_clk_source_name omap3_dss_clk_source_names[] = { + {DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ,"DSI1_PLL_FCLK" }, + {DSS_CLK_SRC_DSI_PLL_HSDIV_DSI ,"DSI2_PLL_FCLK" }, + {DSS_CLK_SRC_FCK ,"DSS1_ALWON_FCLK" }, +}; +/* OMAP2 DSS Features */ static struct omap_dss_features omap2_dss_features = { .reg_fields = omap2_dss_reg_fields,
@@ -164,6 +178,7 @@ static struct omap_dss_features omap2_dss_features = { .max_dss_fck = 173000000, .supported_displays = omap2_dss_supported_displays, .supported_color_modes = omap2_dss_supported_color_modes, + .clksrc_names = omap2_dss_clk_source_names, };/* OMAP3 DSS Features */
@@ -182,6 +197,7 @@ static struct omap_dss_features omap3430_dss_features = { .max_dss_fck = 173000000, .supported_displays = omap3_dss_supported_displays, .supported_color_modes = omap3_dss_supported_color_modes, + .clksrc_names = omap3_dss_clk_source_names, };static struct omap_dss_features omap3630_dss_features = {
@@ -200,6 +216,7 @@ static struct omap_dss_features omap3630_dss_features = { .max_dss_fck = 173000000, .supported_displays = omap3_dss_supported_displays, .supported_color_modes = omap3_dss_supported_color_modes, + .clksrc_names = omap3_dss_clk_source_names, };/* OMAP4 DSS Features */
@@ -217,6 +234,7 @@ static struct omap_dss_features omap4_dss_features = { .max_dss_fck = 186000000, .supported_displays = omap4_dss_supported_displays, .supported_color_modes = omap3_dss_supported_color_modes, + .clksrc_names = omap3_dss_clk_source_names, };/* Functions returning values related to a DSS feature */
@@ -253,6 +271,11 @@ bool dss_feat_color_mode_supported(enum omap_plane plane, color_mode; } +const char *dss_feat_get_clk_source_name (enum dss_clk_source id) +{ +return omap_current_dss_features->clksrc_names[id].clksrc_name; +} +/* DSS has_feature check */ bool dss_has_feature (enum dss_feat_id id) {
drivers/video/omap2/dss/dss_features.h +1 -0
@@ -59,6 +59,7 @@ enum omap_display_type dss_feat_get_supported_displays(enum omap_channel channelenum omap_color_mode dss_feat_get_supported_color_modes (enum omap_plane plane);bool dss_feat_color_mode_supported (enum omap_plane plane,enum omap_color_mode color_mode); +const char *dss_feat_get_clk_source_name (enum dss_clk_source id);bool dss_has_feature (enum dss_feat_id id);void dss_feat_get_reg_field (enum dss_feat_reg_field id,u8 *start,u8 *end);
Signature · 1 line
1.7.1
PATCH 3/3 OMAP2PLUS: DSS2: DSI: Generalize DSI PLL Clock Naming
In reply to Archit TanejaDSI PLL output clock names have been made more generic. The clock name describes what the source of the clock and what clock is used for. Some of DSI PLL parameters like dividers and DSI PLL source have also been made more generic.
dsi1_pll_fclk and dsi2_pll_fclk have been changed as dsi_pll_hsdiv_dispc_clk and dsi_pll_hsdiv_dsi_clk respectively. Also, the hsdividers are now named regm_dispc and regm_dsi instead of regm3 and regm4.
Functions and macros named on the basis of these clock names have also been made generic.
--- arch/arm/plat-omap/include/plat/display.h | 4 +- drivers/video/omap2/dss/dispc.c | 2 +- drivers/video/omap2/dss/dpi.c | 4 +- drivers/video/omap2/dss/dsi.c | 134 +++++++++++++++-------------- drivers/video/omap2/dss/dss.c | 4 +- drivers/video/omap2/dss/dss.h | 20 ++-- 6 files changed, 87 insertions(+), 81 deletions(-)
arch/arm/plat-omap/include/plat/display.h +2 -2
@@ -401,8 +401,8 @@ struct omap_dss_device {struct {u16 regn;u16 regm; -u16 regm3; -u16 regm4; +u16 regm_dispc; +u16 regm_dsi;u16 lp_clk_div;
drivers/video/omap2/dss/dispc.c +1 -1
@@ -2345,7 +2345,7 @@ unsigned long dispc_fclk_rate(void) r =dss_clk_get_rate (DSS_CLK_FCK ); else#ifdef CONFIG_OMAP2_DSS_DSI - r =dsi_get_dsi1_pll_rate (); + r =dsi_get_pll_hsdiv_dispc_rate ();#else BUG ();#endif
drivers/video/omap2/dss/dpi.c +2 -2
@@ -63,7 +63,7 @@ static int dpi_set_dsi_clk(struct omap_dss_device *dssdev, bool is_tft,if (r)return r; - *fck = dsi_cinfo.dsi1_pll_fclk; + *fck = dsi_cinfo.dsi_pll_hsdiv_dispc_clk; *lck_div = dispc_cinfo.lck_div; *pck_div = dispc_cinfo.pck_div;
@@ -271,7 +271,7 @@ int dpi_check_timings(struct omap_dss_device *dssdev,if (r)return r; - fck = dsi_cinfo.dsi1_pll_fclk; + fck = dsi_cinfo.dsi_pll_hsdiv_dispc_clk; lck_div = dispc_cinfo.lck_div; pck_div = dispc_cinfo.pck_div; }
drivers/video/omap2/dss/dsi.c +70 -64
313 lines not on this page · raw message
drivers/video/omap2/dss/dss.c +2 -2
@@ -293,7 +293,7 @@ void dss_select_dispc_clk_source(enum dss_clk_source clk_src) b = clk_src ==DSS_CLK_SRC_FCK ?0 :1 ;if (clk_src ==DSS_CLK_SRC_DSI_PLL_HSDIV_DISPC ) -dsi_wait_dsi1_pll_active (); +dsi_wait_pll_hsdiv_dispc_active ();REG_FLD_MOD (DSS_CONTROL , b,0 ,0 );/* DISPC_CLK_SWITCH */
@@ -310,7 +310,7 @@ void dss_select_dsi_clk_source(enum dss_clk_source clk_src) b = clk_src ==DSS_CLK_SRC_FCK ?0 :1 ;if (clk_src ==DSS_CLK_SRC_DSI_PLL_HSDIV_DSI ) -dsi_wait_dsi2_pll_active (); +dsi_wait_pll_hsdiv_dsi_active ();REG_FLD_MOD (DSS_CONTROL , b,1 ,1 );/* DSI_CLK_SWITCH */
drivers/video/omap2/dss/dss.h +10 -10
@@ -152,21 +152,21 @@ struct dsi_clock_info {unsigned long fint;unsigned long clkin4ddr;unsigned long clkin; -unsigned long dsi1_pll_fclk; -unsigned long dsi2_pll_fclk; +unsigned long dsi_pll_hsdiv_dispc_clk;/* DSI1_PLL_CLK */ +unsigned long dsi_pll_hsdiv_dsi_clk;/* DSI2_PLL_CLK */ unsigned long lp_clk;/* dividers */ u16 regn;u16 regm; -u16 regm3; -u16 regm4; +u16 regm_dispc;/* REGM3 */ +u16 regm_dsi;/* REGM4 */ u16 lp_clk_div;u8 highfreq; -bool use_dss2_fck; +bool use_sys_clk; };struct seq_file ;
@@ -278,7 +278,7 @@ void dsi_restore_context(void);int dsi_init_display (struct omap_dss_device *display);void dsi_irq_handler (void ); -unsigned long dsi_get_dsi1_pll_rate (void ); +unsigned long dsi_get_pll_hsdiv_dispc_rate (void );int dsi_pll_set_clock_div (struct dsi_clock_info *cinfo); int dsi_pll_calc_clock_div_pck(bool is_tft, unsigned long req_pck, struct dsi_clock_info *cinfo,
@@ -289,8 +289,8 @@ void dsi_pll_uninit(void);void dsi_get_overlay_fifo_thresholds (enum omap_plane plane,u32 fifo_size,enum omap_burst_size *burst_size,u32 *fifo_low,u32 *fifo_high); -void dsi_wait_dsi1_pll_active (void ); -void dsi_wait_dsi2_pll_active (void ); +void dsi_wait_pll_hsdiv_dispc_active (void ); +void dsi_wait_pll_hsdiv_dsi_active (void );#else static inline int dsi_init_platform_driver (void ) {
@@ -299,10 +299,10 @@ static inline int dsi_init_platform_driver(void)static inline void dsi_uninit_platform_driver (void ) { } -static inline void dsi_wait_dsi1_pll_active (void ) +static inline void dsi_wait_pll_hsdiv_dispc_active (void ) { } -static inline void dsi_wait_dsi2_pll_active (void ) +static inline void dsi_wait_pll_hsdiv_dsi_active (void ) { }#endif
Signature · 1 line
1.7.1
Hi,
Quoted 19 lines · Archit
The OMAP Display Subsystem has multiple clock sources available for its modules. One of these sources has to be selected through a global control register called
DSS_CTRL.For example, on OMAP4, the Display Controller Module's (DISPC) functional clock can be derived from:
a) output of DPLL_PER's M5 divisor
b) output of DSI1 PLL's M4 divisor
c) output of DSI2 PLL's M4 divisor
d) output of HDMI PLLThere is, hence, an enum called '
dss_clk_source' which is used throughout DSS2, to select clock sources for various DSS sub modules. These clock source names are currently specific to OMAP2/3 TRM clock names.All enum members, variables, functions which are based on these clock source names have been made generic such that they can be used for future OMAPs as well.
Quoted 5 lines
Archit Taneja (3):
OMAP2PLUS: DSS2: Make members ofdss_clk_sourcegeneric
OMAP2PLUS: DSS2: Use dss features to get clock source names of
current OMAP
OMAP2PLUS: DSS2: DSI: Generalize DSI PLL Clock Naming
This patch set, and also the two individual patches for using dss_features, look ok. However, they don't apply to DSS tree. Can you rebase these on top of DSS master branch, please?
Tomi