| /kernel/linux/linux-6.6/drivers/gpu/drm/msm/disp/dpu1/ |
| D | dpu_hw_dsc.c | 36 static void dpu_hw_dsc_disable(struct dpu_hw_dsc *dsc) in dpu_hw_dsc_disable() argument 38 struct dpu_hw_blk_reg_map *c = &dsc->hw; in dpu_hw_dsc_disable() 44 struct drm_dsc_config *dsc, in dpu_hw_dsc_config() argument 59 slice_last_group_size = (dsc->slice_width + 2) % 3; in dpu_hw_dsc_config() 64 data |= (dsc->bits_per_pixel << 8); in dpu_hw_dsc_config() 65 data |= (dsc->block_pred_enable << 7); in dpu_hw_dsc_config() 66 data |= (dsc->line_buf_depth << 3); in dpu_hw_dsc_config() 67 data |= (dsc->simple_422 << 2); in dpu_hw_dsc_config() 68 data |= (dsc->convert_rgb << 1); in dpu_hw_dsc_config() 69 data |= dsc->bits_per_component; in dpu_hw_dsc_config() [all …]
|
| D | dpu_hw_dsc_1_2.c | 86 struct drm_dsc_config *dsc, in dpu_hw_dsc_config_1_2() argument 97 if (!hw_dsc || !dsc) in dpu_hw_dsc_config_1_2() 110 num_active_slice_per_enc = dsc->slice_count; in dpu_hw_dsc_config_1_2() 112 num_active_slice_per_enc = dsc->slice_count / 2; in dpu_hw_dsc_config_1_2() 127 data = (dsc->dsc_version_minor & 0xf) << 28; in dpu_hw_dsc_config_1_2() 128 if (dsc->dsc_version_minor == 0x2) { in dpu_hw_dsc_config_1_2() 129 if (dsc->native_422) in dpu_hw_dsc_config_1_2() 131 if (dsc->native_420) in dpu_hw_dsc_config_1_2() 135 bpp = dsc->bits_per_pixel; in dpu_hw_dsc_config_1_2() 139 if (dsc->native_422 || dsc->native_420) in dpu_hw_dsc_config_1_2() [all …]
|
| D | dpu_hw_dsc.h | 19 * struct dpu_hw_dsc_ops - interface to the dsc hardware driver functions 24 * dsc_disable - disable dsc 25 * @hw_dsc: Pointer to dsc context 30 * dsc_config - configures dsc encoder 31 * @hw_dsc: Pointer to dsc context 32 * @dsc: panel dsc parameters 33 * @mode: dsc topology mode to be set 37 struct drm_dsc_config *dsc, 43 * @hw_dsc: Pointer to dsc context 44 * @dsc: panel dsc parameters [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/dc/core/ |
| D | dc_link_hwss.c | 15 #include "dsc.h" 393 dsc->ctx->logger 394 static void dsc_optc_config_log(struct display_stream_compressor *dsc, in dsc_optc_config_log() argument 402 /* 7 fractional digits decimal precision for bytes per pixel is enough because DSC in dsc_optc_config_log() 428 /* The stream with these settings can be sent (unblanked) only after DSC was enabled on RX first, 433 struct display_stream_compressor *dsc = pipe_ctx->stream_res.dsc; in dp_set_dsc_on_stream() local 447 /* Enable DSC hw block */ in dp_set_dsc_on_stream() 457 dsc->funcs->dsc_set_config(dsc, &dsc_cfg, &dsc_optc_cfg); in dp_set_dsc_on_stream() 458 dsc->funcs->dsc_enable(dsc, pipe_ctx->stream_res.opp->inst); in dp_set_dsc_on_stream() 460 struct display_stream_compressor *odm_dsc = odm_pipe->stream_res.dsc; in dp_set_dsc_on_stream() [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/dc/dcn20/ |
| D | dcn20_dsc.c | 28 #include "dsc/dscc_types.h" 30 static void dsc_log_pps(struct display_stream_compressor *dsc, struct drm_dsc_config *pps); 35 static void dsc_write_to_registers(struct display_stream_compressor *dsc, const struct dsc_reg_valu… 41 static void dsc2_read_state(struct display_stream_compressor *dsc, struct dcn_dsc_state *s); 42 static bool dsc2_validate_stream(struct display_stream_compressor *dsc, const struct dsc_config *ds… 43 static void dsc2_set_config(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 45 static bool dsc2_get_packed_pps(struct display_stream_compressor *dsc, const struct dsc_config *dsc… 46 static void dsc2_enable(struct display_stream_compressor *dsc, int opp_pipe); 47 static void dsc2_disable(struct display_stream_compressor *dsc); 70 dsc->ctx->logger [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/dc/dsc/ |
| D | dc_dsc.c | 27 #include "dsc.h" 34 /* default DSC policy target bitrate limit is 16bpp */ 37 /* default DSC policy enables DSC only when needed */ 46 if (timing->flags.DSC) { in dc_dsc_bandwidth_in_kbps_from_timing() 110 dm_error("%s: DPCD DSC buffer size not recognized.\n", __func__); in dsc_buff_block_size_from_dpcd() 126 dm_error("%s: DPCD DSC buffer depth not recognized.\n", __func__); in dsc_line_buff_depth_from_dpcd() 186 dm_error("%s: DPCD DSC throughput mode not recognized.\n", __func__); in dsc_throughput_from_dpcd() 217 dm_error("%s: DPCD DSC bits-per-pixel increment not recognized.\n", __func__); in dsc_bpp_increment_div_from_dpcd() 226 const struct display_stream_compressor *dsc, in get_dsc_enc_caps() argument 230 // This is a static HW query, so we can use any DSC in get_dsc_enc_caps() [all …]
|
| D | Makefile | 3 # Makefile for the 'dsc' sub-component of DAL. 34 CFLAGS_$(AMDDALPATH)/dc/dsc/rc_calc.o := $(dsc_ccflags) 35 CFLAGS_REMOVE_$(AMDDALPATH)/dc/dsc/rc_calc.o := $(dsc_rcflags) 37 DSC = dc_dsc.o rc_calc.o rc_calc_dpi.o macro 39 AMD_DAL_DSC = $(addprefix $(AMDDALPATH)/dc/dsc/,$(DSC))
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/dcn20/ |
| D | dcn20_dsc.c | 30 #include "dsc/dscc_types.h" 31 #include "dsc/rc_calc.h" 33 static void dsc_write_to_registers(struct display_stream_compressor *dsc, const struct dsc_reg_valu… 36 static void dsc2_read_state(struct display_stream_compressor *dsc, struct dcn_dsc_state *s); 37 static bool dsc2_validate_stream(struct display_stream_compressor *dsc, const struct dsc_config *ds… 38 static void dsc2_set_config(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 40 static void dsc2_enable(struct display_stream_compressor *dsc, int opp_pipe); 41 static void dsc2_disable(struct display_stream_compressor *dsc); 42 static void dsc2_disconnect(struct display_stream_compressor *dsc); 66 dsc->ctx->logger [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/inc/hw/ |
| D | dsc.h | 36 /* Input parameters for configuring DSC from the outside of DSC */ 47 /* Output parameters for configuring DSC-related part of OPTC */ 69 /* DSC encoder capabilities 70 * They differ from the DPCD DSC caps because they are based on AMD DSC encoder caps. 76 uint8_t NUM_SLICES_3 : 1; /* This one is not per DSC spec, but our encoder supports it */ 99 void (*dsc_read_state)(struct display_stream_compressor *dsc, struct dcn_dsc_state *s); 100 …bool (*dsc_validate_stream)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cf… 101 void (*dsc_set_config)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 103 bool (*dsc_get_packed_pps)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 105 void (*dsc_enable)(struct display_stream_compressor *dsc, int opp_pipe); [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/dc/inc/hw/ |
| D | dsc.h | 36 /* Input parameters for configuring DSC from the outside of DSC */ 47 /* Output parameters for configuring DSC-related part of OPTC */ 67 /* DSC encoder capabilities 68 * They differ from the DPCD DSC caps because they are based on AMD DSC encoder caps. 74 uint8_t NUM_SLICES_3 : 1; /* This one is not per DSC spec, but our encoder supports it */ 95 void (*dsc_read_state)(struct display_stream_compressor *dsc, struct dcn_dsc_state *s); 96 …bool (*dsc_validate_stream)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cf… 97 void (*dsc_set_config)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 99 bool (*dsc_get_packed_pps)(struct display_stream_compressor *dsc, const struct dsc_config *dsc_cfg, 101 void (*dsc_enable)(struct display_stream_compressor *dsc, int opp_pipe); [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/i915/display/ |
| D | intel_vdsc.c | 49 /* There's no pipe A DSC engine on ICL */ in is_pipe_dsc() 69 * We are using the method provided in DSC 1.2a C-Model in codec_main.c 70 * Above method use a common formula to derive values for any combination of DSC 92 * According to DSC 1.2 spec in Section 4.1 if native_420 is set: in calculate_rc_params() 244 struct drm_dsc_config *vdsc_cfg = &pipe_config->dsc.config; in intel_dsc_compute_params() 245 u16 compressed_bpp = pipe_config->dsc.compressed_bpp; in intel_dsc_compute_params() 251 pipe_config->dsc.slice_count); in intel_dsc_compute_params() 261 * According to DSC 1.2 specs if colorspace is YCbCr then convert_rgb is 0 in intel_dsc_compute_params() 280 * According to DSC 1.2 specs in Section 4.1 if native_420 is set in intel_dsc_compute_params() 355 int num_vdsc_instances = (crtc_state->dsc.dsc_split) ? 2 : 1; in intel_dsc_get_num_vdsc_instances() [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/dsc/ |
| D | dc_dsc.c | 28 #include "dsc.h" 35 /* default DSC policy target bitrate limit is 16bpp */ 38 /* default DSC policy enables DSC only when needed */ 63 if (!timing->flags.DSC) { in apply_128b_132b_stream_overhead() 94 if (timing->flags.DSC) in dc_bandwidth_in_kbps_from_timing() 162 const struct display_stream_compressor *dsc, 198 dm_error("%s: DPCD DSC buffer size not recognized.\n", __func__); in dsc_buff_block_size_from_dpcd() 214 dm_error("%s: DPCD DSC buffer depth not recognized.\n", __func__); in dsc_line_buff_depth_from_dpcd() 274 dm_error("%s: DPCD DSC throughput mode not recognized.\n", __func__); in dsc_throughput_from_dpcd() 305 dm_error("%s: DPCD DSC bits-per-pixel increment not recognized.\n", __func__); in dsc_bpp_increment_div_from_dpcd() [all …]
|
| D | Makefile | 3 # Makefile for the 'dsc' sub-component of DAL. 4 DSC = dc_dsc.o rc_calc.o rc_calc_dpi.o macro 6 AMD_DAL_DSC = $(addprefix $(AMDDALPATH)/dc/dsc/,$(DSC))
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/amd/display/amdgpu_dm/ |
| D | amdgpu_dm_debugfs.c | 37 #include "dsc.h" 991 /* function: Read link's DSC & FEC capabilities 1034 * enable DSC on the sink device or on MST branch in dp_dsc_fec_support_show() 1160 /* function: read DSC status on the connector 1163 * returns current status of DSC clock on the connector. 1172 * 1 - means that DSC is currently enabled 1173 * 0 - means that DSC is disabled 1181 struct display_stream_compressor *dsc; in dp_dsc_clock_en_read() local 1207 dsc = pipe_ctx->stream_res.dsc; in dp_dsc_clock_en_read() 1208 if (dsc) in dp_dsc_clock_en_read() [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/dcn314/ |
| D | dcn314_hwseq.c | 54 #include "dsc.h" 97 struct display_stream_compressor *dsc = pipe_ctx->stream_res.dsc; in update_dsc_on_stream() local 102 ASSERT(dsc); in update_dsc_on_stream() 111 /* Enable DSC hw block */ in update_dsc_on_stream() 121 dsc->funcs->dsc_set_config(dsc, &dsc_cfg, &dsc_optc_cfg); in update_dsc_on_stream() 122 dsc->funcs->dsc_enable(dsc, pipe_ctx->stream_res.opp->inst); in update_dsc_on_stream() 124 struct display_stream_compressor *odm_dsc = odm_pipe->stream_res.dsc; in update_dsc_on_stream() 135 /* Enable DSC in OPTC */ in update_dsc_on_stream() 136 DC_LOG_DSC("Setting optc DSC config for tg instance %d:", pipe_ctx->stream_res.tg->inst); in update_dsc_on_stream() 142 /* disable DSC in OPTC */ in update_dsc_on_stream() [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/ |
| D | drm_dsc.c | 19 * DOC: dsc helpers 22 * Compression (DSC) used to compress the pixel bits before sending it on 23 * DP/eDP/MIPI DSI interface. DSC is required to be enabled so that the existing 28 * Display Stream Compression standard required for DSC on Display Port/eDP or 35 * @pps_header: Secondary data packet header for DSC Picture 53 * drm_dsc_pps_payload_pack() - Populates the DSC PPS 56 * Bitwise struct for DSC Picture Parameter Set. This is defined 59 * DSC Configuration data filled by driver as defined by 62 * DSC source device sends a picture parameter set (PPS) containing the 64 * populates the DSC PPS struct using the DSC configuration parameters in [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/msm/ |
| D | msm_dsc_helper.h | 5 * Helper methods for MSM-specific DSC calculations that are common between timing engine, 17 * @dsc: Pointer to drm dsc config struct 22 static inline u32 msm_dsc_get_bytes_per_line(const struct drm_dsc_config *dsc) in msm_dsc_get_bytes_per_line() argument 24 return dsc->slice_count * dsc->slice_chunk_size; in msm_dsc_get_bytes_per_line()
|
| /kernel/linux/linux-6.6/Documentation/devicetree/bindings/display/mediatek/ |
| D | mediatek,dsc.yaml | 4 $id: http://devicetree.org/schemas/display/mediatek/mediatek,dsc.yaml# 7 title: mediatek display DSC controller 14 The DSC standard is a specification of the algorithms used for 17 video bit stream. DSC is designed for real-time systems with 24 - mediatek,mt8195-disp-dsc 34 - description: DSC Wrapper Clock 73 compatible = "mediatek,mt8195-disp-dsc";
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/panel/ |
| D | panel-visionox-r66451.c | 196 if (!dsi->dsc) { in visionox_r66451_enable() 197 dev_err(&dsi->dev, "DSC not attached to DSI\n"); in visionox_r66451_enable() 201 drm_dsc_pps_payload_pack(&pps, dsi->dsc); in visionox_r66451_enable() 298 struct drm_dsc_config *dsc; in visionox_r66451_probe() local 305 dsc = devm_kzalloc(dev, sizeof(*dsc), GFP_KERNEL); in visionox_r66451_probe() 306 if (!dsc) in visionox_r66451_probe() 309 /* Set DSC params */ in visionox_r66451_probe() 310 dsc->dsc_version_major = 0x1; in visionox_r66451_probe() 311 dsc->dsc_version_minor = 0x2; in visionox_r66451_probe() 313 dsc->slice_height = 20; in visionox_r66451_probe() [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/amdgpu_dm/ |
| D | amdgpu_dm_debugfs.c | 36 #include "dsc.h" 1113 * Disable dsc passthrough, i.e.,: have dsc decoding at converver, not external RX 1115 * Enable dsc passthrough, i.e.,: have dsc passthrough to external RX 1244 /* function: Read link's DSC & FEC capabilities 1287 * enable DSC on the sink device or on MST branch in dp_dsc_fec_support_show() 1430 /* function: read DSC status on the connector 1433 * returns current status of DSC clock on the connector. 1442 * 1 - means that DSC is currently enabled 1443 * 0 - means that DSC is disabled 1451 struct display_stream_compressor *dsc; in dp_dsc_clock_en_read() local [all …]
|
| /kernel/linux/linux-5.10/include/drm/ |
| D | drm_dsc.h | 13 /* VESA Display Stream Compression DSC 1.2 constants */ 21 /* DSC Rate Control Constants */ 27 /* DSC PPS constants and macros */ 48 * struct drm_dsc_rc_range_parameters - DSC Rate Control range parameters 50 * This defines different rate control parameters used by the DSC engine 70 * struct drm_dsc_config - Parameters required to configure DSC 92 * @slice_count: Number fo slices per line used by the DSC encoder 242 * @dsc_version_minor: DSC minor version 246 * @dsc_version_major: DSC major version 278 * The VESA DSC standard defines picture parameter set (PPS) which display [all …]
|
| /kernel/linux/linux-6.6/include/drm/display/ |
| D | drm_dsc.h | 13 /* VESA Display Stream Compression DSC 1.2 constants */ 21 /* DSC Rate Control Constants */ 27 /* DSC PPS constants and macros */ 48 * struct drm_dsc_rc_range_parameters - DSC Rate Control range parameters 50 * This defines different rate control parameters used by the DSC engine 70 * struct drm_dsc_config - Parameters required to configure DSC 92 * @slice_count: Number fo slices per line used by the DSC encoder 242 * @dsc_version_minor: DSC minor version 246 * @dsc_version_major: DSC major version 279 * The VESA DSC standard defines picture parameter set (PPS) which display [all …]
|
| /kernel/linux/linux-5.10/drivers/gpu/drm/i915/display/ |
| D | intel_vdsc.c | 346 /* On TGL, DSC is supported on all Pipes */ in intel_dsc_source_support() 374 /* There's no pipe A DSC engine on ICL */ in is_pipe_dsc() 383 struct drm_dsc_config *vdsc_cfg = &pipe_config->dsc.config; in intel_dsc_compute_params() 384 u16 compressed_bpp = pipe_config->dsc.compressed_bpp; in intel_dsc_compute_params() 391 pipe_config->dsc.slice_count); in intel_dsc_compute_params() 498 const struct drm_dsc_config *vdsc_cfg = &crtc_state->dsc.config; in intel_dsc_pps_configure() 503 u8 num_vdsc_instances = (crtc_state->dsc.dsc_split) ? 2 : 1; in intel_dsc_pps_configure() 527 if (crtc_state->dsc.dsc_split) in intel_dsc_pps_configure() 534 if (crtc_state->dsc.dsc_split) in intel_dsc_pps_configure() 551 if (crtc_state->dsc.dsc_split) in intel_dsc_pps_configure() [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/msm/dsi/ |
| D | dsi_host.c | 38 static int dsi_populate_dsc_params(struct msm_dsi_host *msm_host, struct drm_dsc_config *dsc); 163 struct drm_dsc_config *dsc; member 533 const struct drm_dsc_config *dsc) in dsi_adjust_pclk_for_compression() argument 535 int new_hdisplay = DIV_ROUND_UP(mode->hdisplay * drm_dsc_get_bpp_int(dsc), in dsi_adjust_pclk_for_compression() 536 dsc->bits_per_component * 3); in dsi_adjust_pclk_for_compression() 544 const struct drm_dsc_config *dsc, bool is_bonded_dsi) in dsi_get_pclk_rate() argument 550 if (dsc) in dsi_get_pclk_rate() 551 pclk_rate = dsi_adjust_pclk_for_compression(mode, dsc); in dsi_get_pclk_rate() 571 unsigned long pclk_rate = dsi_get_pclk_rate(mode, msm_host->dsc, is_bonded_dsi); in dsi_byte_clk_get_rate() 590 msm_host->pixel_clk_rate = dsi_get_pclk_rate(msm_host->mode, msm_host->dsc, is_bonded_dsi); in dsi_calc_pclk() [all …]
|
| /kernel/linux/linux-6.6/drivers/gpu/drm/amd/display/dc/link/ |
| D | link_dpms.c | 55 #include "dsc.h" 746 static void dsc_optc_config_log(struct display_stream_compressor *dsc, in dsc_optc_config_log() argument 753 DC_LOGGER_INIT(dsc->ctx->logger); in dsc_optc_config_log() 755 /* 7 fractional digits decimal precision for bytes per pixel is enough because DSC in dsc_optc_config_log() 781 /* The stream with these settings can be sent (unblanked) only after DSC was enabled on RX first, 786 struct display_stream_compressor *dsc = pipe_ctx->stream_res.dsc; in link_set_dsc_on_stream() local 790 DC_LOGGER_INIT(dsc->ctx->logger); in link_set_dsc_on_stream() 800 /* Enable DSC hw block */ in link_set_dsc_on_stream() 810 dsc->funcs->dsc_set_config(dsc, &dsc_cfg, &dsc_optc_cfg); in link_set_dsc_on_stream() 811 dsc->funcs->dsc_enable(dsc, pipe_ctx->stream_res.opp->inst); in link_set_dsc_on_stream() [all …]
|