@@ -691,11 +691,6 @@ u32 dispc_mgr_get_sync_lost_irq(struct dispc_device *dispc,
691
691
return mgr_desc [channel ].sync_lost_irq ;
692
692
}
693
693
694
- u32 dispc_wb_get_framedone_irq (struct dispc_device * dispc )
695
- {
696
- return DISPC_IRQ_FRAMEDONEWB ;
697
- }
698
-
699
694
void dispc_mgr_enable (struct dispc_device * dispc ,
700
695
enum omap_channel channel , bool enable )
701
696
{
@@ -726,30 +721,6 @@ void dispc_mgr_go(struct dispc_device *dispc, enum omap_channel channel)
726
721
mgr_fld_write (dispc , channel , DISPC_MGR_FLD_GO , 1 );
727
722
}
728
723
729
- bool dispc_wb_go_busy (struct dispc_device * dispc )
730
- {
731
- return REG_GET (dispc , DISPC_CONTROL2 , 6 , 6 ) == 1 ;
732
- }
733
-
734
- void dispc_wb_go (struct dispc_device * dispc )
735
- {
736
- enum omap_plane_id plane = OMAP_DSS_WB ;
737
- bool enable , go ;
738
-
739
- enable = REG_GET (dispc , DISPC_OVL_ATTRIBUTES (plane ), 0 , 0 ) == 1 ;
740
-
741
- if (!enable )
742
- return ;
743
-
744
- go = REG_GET (dispc , DISPC_CONTROL2 , 6 , 6 ) == 1 ;
745
- if (go ) {
746
- DSSERR ("GO bit not down for WB\n" );
747
- return ;
748
- }
749
-
750
- REG_FLD_MOD (dispc , DISPC_CONTROL2 , 1 , 6 , 6 );
751
- }
752
-
753
724
static void dispc_ovl_write_firh_reg (struct dispc_device * dispc ,
754
725
enum omap_plane_id plane , int reg ,
755
726
u32 value )
@@ -1498,17 +1469,6 @@ void dispc_ovl_set_fifo_threshold(struct dispc_device *dispc,
1498
1469
min (high , 0xfffu ));
1499
1470
}
1500
1471
1501
- void dispc_enable_fifomerge (struct dispc_device * dispc , bool enable )
1502
- {
1503
- if (!dispc_has_feature (dispc , FEAT_FIFO_MERGE )) {
1504
- WARN_ON (enable );
1505
- return ;
1506
- }
1507
-
1508
- DSSDBG ("FIFO merge %s\n" , enable ? "enabled" : "disabled" );
1509
- REG_FLD_MOD (dispc , DISPC_CONFIG , enable ? 1 : 0 , 14 , 14 );
1510
- }
1511
-
1512
1472
void dispc_ovl_compute_fifo_thresholds (struct dispc_device * dispc ,
1513
1473
enum omap_plane_id plane ,
1514
1474
u32 * fifo_low , u32 * fifo_high ,
@@ -2814,95 +2774,6 @@ int dispc_ovl_setup(struct dispc_device *dispc,
2814
2774
return r ;
2815
2775
}
2816
2776
2817
- int dispc_wb_setup (struct dispc_device * dispc ,
2818
- const struct omap_dss_writeback_info * wi ,
2819
- bool mem_to_mem , const struct videomode * vm ,
2820
- enum dss_writeback_channel channel_in )
2821
- {
2822
- int r ;
2823
- u32 l ;
2824
- enum omap_plane_id plane = OMAP_DSS_WB ;
2825
- const int pos_x = 0 , pos_y = 0 ;
2826
- const u8 zorder = 0 , global_alpha = 0 ;
2827
- const bool replication = true;
2828
- bool truncation ;
2829
- int in_width = vm -> hactive ;
2830
- int in_height = vm -> vactive ;
2831
- enum omap_overlay_caps caps =
2832
- OMAP_DSS_OVL_CAP_SCALE | OMAP_DSS_OVL_CAP_PRE_MULT_ALPHA ;
2833
-
2834
- if (vm -> flags & DISPLAY_FLAGS_INTERLACED )
2835
- in_height /= 2 ;
2836
-
2837
- DSSDBG ("dispc_wb_setup, pa %x, pa_uv %x, %d,%d -> %dx%d, cmode %x, "
2838
- "rot %d\n" , wi -> paddr , wi -> p_uv_addr , in_width ,
2839
- in_height , wi -> width , wi -> height , wi -> fourcc , wi -> rotation );
2840
-
2841
- r = dispc_ovl_setup_common (dispc , plane , caps , wi -> paddr , wi -> p_uv_addr ,
2842
- wi -> buf_width , pos_x , pos_y , in_width , in_height , wi -> width ,
2843
- wi -> height , wi -> fourcc , wi -> rotation , zorder ,
2844
- wi -> pre_mult_alpha , global_alpha , wi -> rotation_type ,
2845
- replication , vm , mem_to_mem , DRM_COLOR_YCBCR_BT601 ,
2846
- DRM_COLOR_YCBCR_LIMITED_RANGE );
2847
- if (r )
2848
- return r ;
2849
-
2850
- switch (wi -> fourcc ) {
2851
- case DRM_FORMAT_RGB565 :
2852
- case DRM_FORMAT_RGB888 :
2853
- case DRM_FORMAT_ARGB4444 :
2854
- case DRM_FORMAT_RGBA4444 :
2855
- case DRM_FORMAT_RGBX4444 :
2856
- case DRM_FORMAT_ARGB1555 :
2857
- case DRM_FORMAT_XRGB1555 :
2858
- case DRM_FORMAT_XRGB4444 :
2859
- truncation = true;
2860
- break ;
2861
- default :
2862
- truncation = false;
2863
- break ;
2864
- }
2865
-
2866
- /* setup extra DISPC_WB_ATTRIBUTES */
2867
- l = dispc_read_reg (dispc , DISPC_OVL_ATTRIBUTES (plane ));
2868
- l = FLD_MOD (l , truncation , 10 , 10 ); /* TRUNCATIONENABLE */
2869
- l = FLD_MOD (l , channel_in , 18 , 16 ); /* CHANNELIN */
2870
- l = FLD_MOD (l , mem_to_mem , 19 , 19 ); /* WRITEBACKMODE */
2871
- if (mem_to_mem )
2872
- l = FLD_MOD (l , 1 , 26 , 24 ); /* CAPTUREMODE */
2873
- else
2874
- l = FLD_MOD (l , 0 , 26 , 24 ); /* CAPTUREMODE */
2875
- dispc_write_reg (dispc , DISPC_OVL_ATTRIBUTES (plane ), l );
2876
-
2877
- if (mem_to_mem ) {
2878
- /* WBDELAYCOUNT */
2879
- REG_FLD_MOD (dispc , DISPC_OVL_ATTRIBUTES2 (plane ), 0 , 7 , 0 );
2880
- } else {
2881
- u32 wbdelay ;
2882
-
2883
- if (channel_in == DSS_WB_TV_MGR )
2884
- wbdelay = vm -> vsync_len + vm -> vback_porch ;
2885
- else
2886
- wbdelay = vm -> vfront_porch + vm -> vsync_len +
2887
- vm -> vback_porch ;
2888
-
2889
- if (vm -> flags & DISPLAY_FLAGS_INTERLACED )
2890
- wbdelay /= 2 ;
2891
-
2892
- wbdelay = min (wbdelay , 255u );
2893
-
2894
- /* WBDELAYCOUNT */
2895
- REG_FLD_MOD (dispc , DISPC_OVL_ATTRIBUTES2 (plane ), wbdelay , 7 , 0 );
2896
- }
2897
-
2898
- return 0 ;
2899
- }
2900
-
2901
- bool dispc_has_writeback (struct dispc_device * dispc )
2902
- {
2903
- return dispc -> feat -> has_writeback ;
2904
- }
2905
-
2906
2777
int dispc_ovl_enable (struct dispc_device * dispc ,
2907
2778
enum omap_plane_id plane , bool enable )
2908
2779
{
@@ -3742,23 +3613,6 @@ void dispc_mgr_set_clock_div(struct dispc_device *dispc,
3742
3613
cinfo -> pck_div );
3743
3614
}
3744
3615
3745
- int dispc_mgr_get_clock_div (struct dispc_device * dispc ,
3746
- enum omap_channel channel ,
3747
- struct dispc_clock_info * cinfo )
3748
- {
3749
- unsigned long fck ;
3750
-
3751
- fck = dispc_fclk_rate (dispc );
3752
-
3753
- cinfo -> lck_div = REG_GET (dispc , DISPC_DIVISORo (channel ), 23 , 16 );
3754
- cinfo -> pck_div = REG_GET (dispc , DISPC_DIVISORo (channel ), 7 , 0 );
3755
-
3756
- cinfo -> lck = fck / cinfo -> lck_div ;
3757
- cinfo -> pck = cinfo -> lck / cinfo -> pck_div ;
3758
-
3759
- return 0 ;
3760
- }
3761
-
3762
3616
u32 dispc_read_irqstatus (struct dispc_device * dispc )
3763
3617
{
3764
3618
return dispc_read_reg (dispc , DISPC_IRQSTATUS );
0 commit comments