diff options
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/video/omap2/dss/core.c | 2 | ||||
| -rw-r--r-- | drivers/video/omap2/dss/dss_features.c | 49 | ||||
| -rw-r--r-- | drivers/video/omap2/dss/dss_features.h | 2 |
3 files changed, 34 insertions, 19 deletions
diff --git a/drivers/video/omap2/dss/core.c b/drivers/video/omap2/dss/core.c index b2af72dc20bd..d94ef9e31a35 100644 --- a/drivers/video/omap2/dss/core.c +++ b/drivers/video/omap2/dss/core.c | |||
| @@ -237,7 +237,7 @@ static int __init omap_dss_probe(struct platform_device *pdev) | |||
| 237 | 237 | ||
| 238 | core.pdev = pdev; | 238 | core.pdev = pdev; |
| 239 | 239 | ||
| 240 | dss_features_init(); | 240 | dss_features_init(pdata->version); |
| 241 | 241 | ||
| 242 | dss_apply_init(); | 242 | dss_apply_init(); |
| 243 | 243 | ||
diff --git a/drivers/video/omap2/dss/dss_features.c b/drivers/video/omap2/dss/dss_features.c index acbc1e1efba3..5936ba78c14a 100644 --- a/drivers/video/omap2/dss/dss_features.c +++ b/drivers/video/omap2/dss/dss_features.c | |||
| @@ -929,29 +929,44 @@ bool dss_feat_rotation_type_supported(enum omap_dss_rotation_type rot_type) | |||
| 929 | return omap_current_dss_features->supported_rotation_types & rot_type; | 929 | return omap_current_dss_features->supported_rotation_types & rot_type; |
| 930 | } | 930 | } |
| 931 | 931 | ||
| 932 | void dss_features_init(void) | 932 | void dss_features_init(enum omapdss_version version) |
| 933 | { | 933 | { |
| 934 | if (cpu_is_omap24xx()) | 934 | switch (version) { |
| 935 | case OMAPDSS_VER_OMAP24xx: | ||
| 935 | omap_current_dss_features = &omap2_dss_features; | 936 | omap_current_dss_features = &omap2_dss_features; |
| 936 | else if (cpu_is_omap3630()) | 937 | break; |
| 938 | |||
| 939 | case OMAPDSS_VER_OMAP34xx_ES1: | ||
| 940 | case OMAPDSS_VER_OMAP34xx_ES3: | ||
| 941 | omap_current_dss_features = &omap3430_dss_features; | ||
| 942 | break; | ||
| 943 | |||
| 944 | case OMAPDSS_VER_OMAP3630: | ||
| 937 | omap_current_dss_features = &omap3630_dss_features; | 945 | omap_current_dss_features = &omap3630_dss_features; |
| 938 | else if (cpu_is_omap34xx()) { | 946 | break; |
| 939 | if (soc_is_am35xx()) { | 947 | |
| 940 | omap_current_dss_features = &am35xx_dss_features; | 948 | case OMAPDSS_VER_OMAP4430_ES1: |
| 941 | } else { | ||
| 942 | omap_current_dss_features = &omap3430_dss_features; | ||
| 943 | } | ||
| 944 | } | ||
| 945 | else if (omap_rev() == OMAP4430_REV_ES1_0) | ||
| 946 | omap_current_dss_features = &omap4430_es1_0_dss_features; | 949 | omap_current_dss_features = &omap4430_es1_0_dss_features; |
| 947 | else if (omap_rev() == OMAP4430_REV_ES2_0 || | 950 | break; |
| 948 | omap_rev() == OMAP4430_REV_ES2_1 || | 951 | |
| 949 | omap_rev() == OMAP4430_REV_ES2_2) | 952 | case OMAPDSS_VER_OMAP4430_ES2: |
| 950 | omap_current_dss_features = &omap4430_es2_0_1_2_dss_features; | 953 | omap_current_dss_features = &omap4430_es2_0_1_2_dss_features; |
| 951 | else if (cpu_is_omap44xx()) | 954 | break; |
| 955 | |||
| 956 | case OMAPDSS_VER_OMAP4: | ||
| 952 | omap_current_dss_features = &omap4_dss_features; | 957 | omap_current_dss_features = &omap4_dss_features; |
| 953 | else if (soc_is_omap54xx()) | 958 | break; |
| 959 | |||
| 960 | case OMAPDSS_VER_OMAP5: | ||
| 954 | omap_current_dss_features = &omap5_dss_features; | 961 | omap_current_dss_features = &omap5_dss_features; |
| 955 | else | 962 | break; |
| 963 | |||
| 964 | case OMAPDSS_VER_AM35xx: | ||
| 965 | omap_current_dss_features = &am35xx_dss_features; | ||
| 966 | break; | ||
| 967 | |||
| 968 | default: | ||
| 956 | DSSWARN("Unsupported OMAP version"); | 969 | DSSWARN("Unsupported OMAP version"); |
| 970 | break; | ||
| 971 | } | ||
| 957 | } | 972 | } |
diff --git a/drivers/video/omap2/dss/dss_features.h b/drivers/video/omap2/dss/dss_features.h index 9218113b5e88..14a412ea8dc6 100644 --- a/drivers/video/omap2/dss/dss_features.h +++ b/drivers/video/omap2/dss/dss_features.h | |||
| @@ -123,7 +123,7 @@ bool dss_feat_rotation_type_supported(enum omap_dss_rotation_type rot_type); | |||
| 123 | 123 | ||
| 124 | bool dss_has_feature(enum dss_feat_id id); | 124 | bool dss_has_feature(enum dss_feat_id id); |
| 125 | void dss_feat_get_reg_field(enum dss_feat_reg_field id, u8 *start, u8 *end); | 125 | void dss_feat_get_reg_field(enum dss_feat_reg_field id, u8 *start, u8 *end); |
| 126 | void dss_features_init(void); | 126 | void dss_features_init(enum omapdss_version version); |
| 127 | #if defined(CONFIG_OMAP4_DSS_HDMI) | 127 | #if defined(CONFIG_OMAP4_DSS_HDMI) |
| 128 | void dss_init_hdmi_ip_ops(struct hdmi_ip_data *ip_data); | 128 | void dss_init_hdmi_ip_ops(struct hdmi_ip_data *ip_data); |
| 129 | #endif | 129 | #endif |
