Lines Matching full:dsc
28 #include "dsc.h"
34 dsc->ctx->logger
38 /* default DSC policy target bitrate limit is 16bpp */
41 /* default DSC policy enables DSC only when needed */
66 if (!timing->flags.DSC) { in apply_128b_132b_stream_overhead()
97 if (timing->flags.DSC) in dc_bandwidth_in_kbps_from_timing()
169 const struct display_stream_compressor *dsc,
205 dm_error("%s: DPCD DSC buffer size not recognized.\n", __func__); in dsc_buff_block_size_from_dpcd()
221 dm_error("%s: DPCD DSC buffer depth not recognized.\n", __func__); in dsc_line_buff_depth_from_dpcd()
281 dm_error("%s: DPCD DSC throughput mode not recognized.\n", __func__); in dsc_throughput_from_dpcd()
312 dm_error("%s: DPCD DSC bits-per-pixel increment not recognized.\n", __func__); in dsc_bpp_increment_div_from_dpcd()
408 …if (dpcd_dsc_branch_decoder_caps == NULL) { // branch decoder DPCD DSC data can be null for non br… in dc_dsc_parse_dsc_dpcd()
446 /* If DSC is possbile, get DSC bandwidth range based on [min_bpp, max_bpp] target bitrate range and
448 * If DSC is not possible, leave '*range' untouched.
451 const struct display_stream_compressor *dsc, in dc_dsc_compute_bandwidth_range() argument
470 get_dsc_enc_caps(dsc, &dsc_enc_caps, timing->pix_clk_100hz); in dc_dsc_compute_bandwidth_range()
486 void dc_dsc_dump_encoder_caps(const struct display_stream_compressor *dsc, in dc_dsc_dump_encoder_caps() argument
491 get_dsc_enc_caps(dsc, &dsc_enc_caps, timing->pix_clk_100hz); in dc_dsc_dump_encoder_caps()
493 DC_LOG_DSC("dsc encoder caps:"); in dc_dsc_dump_encoder_caps()
505 void dc_dsc_dump_decoder_caps(const struct display_stream_compressor *dsc, in dc_dsc_dump_decoder_caps() argument
508 DC_LOG_DSC("dsc decoder caps:"); in dc_dsc_dump_decoder_caps()
529 const struct display_stream_compressor *dsc, in get_dsc_enc_caps() argument
533 // This is a static HW query, so we can use any DSC in get_dsc_enc_caps()
536 if (dsc) { in get_dsc_enc_caps()
537 if (!dsc->ctx->dc->debug.disable_dsc) in get_dsc_enc_caps()
538 dsc->funcs->dsc_get_enc_caps(dsc_enc_caps, pixel_clock_100Hz); in get_dsc_enc_caps()
539 if (dsc->ctx->dc->debug.native422_support) in get_dsc_enc_caps()
615 …// TODO DSC: Remove this workaround for N422 and 420 once it's fixed, or move it to get_dsc_encode… in intersect_dsc_caps()
653 /* Decide DSC bandwidth range based on signal, timing, specs specific and input min and max
656 * and native timing bandwidth requirement when DSC is not used.
671 /* apply signal, timing, specs and explicitly specified DSC range requirements */ in decide_dsc_bandwidth_range()
696 /* max dsc target bpp */ in decide_dsc_bandwidth_range()
700 /* min dsc target bpp */ in decide_dsc_bandwidth_range()
708 /* Decides if DSC should be used and calculates target bpp if it should, applying DSC policy.
712 * - 'false' if target bpp cannot be decided (e.g. cannot fit even with min DSC bpp),
732 /* enable max bpp even dsc is not needed */ in decide_dsc_target_bpp_x16()
884 /* Attempts to set DSC configuration for the stream, applying DSC policy.
889 * dsc_sink_caps - DSC sink decoder capabilities (from DPCD)
891 * dsc_enc_caps - DSC encoder capabilities
899 * dsc_cfg - DSC configuration to use if it was possible to come up with
901 * The target bitrate after DSC can be calculated by multiplying
941 // Intersect decoder with encoder DSC caps and validate DSC settings in setup_dsc_config()
948 // Validate available DSC settings against the mode timing in setup_dsc_config()
1038 min_slices_h = 0; // DSC TODO: Maybe try increasing the number of slices first? in setup_dsc_config()
1067 // When we force ODM, num dsc h slices must be divisible by num odm h slices in setup_dsc_config()
1141 /* Fill out the rest of DSC settings */ in setup_dsc_config()
1155 const struct display_stream_compressor *dsc, in dc_dsc_compute_config() argument
1166 get_dsc_enc_caps(dsc, &dsc_enc_caps, timing->pix_clk_100hz); in dc_dsc_compute_config()
1226 /* DSC Policy: Use minimum number of slices that fits the pixel clock */ in dc_dsc_get_policy_for_timing()
1229 /* DSC Policy: Use max available slices in dc_dsc_get_policy_for_timing()
1234 /* DSC Policy: Use slice height recommended in dc_dsc_get_policy_for_timing()
1235 * by VESA DSC Spreadsheet user guide in dc_dsc_get_policy_for_timing()
1239 /* DSC Policy: follow DP specs with an internal upper limit to 16 bpp in dc_dsc_get_policy_for_timing()
1282 /* enable DSC when not needed, default false */ in dc_dsc_get_policy_for_timing()