Loading drivers/media/platform/msm/sde/rotator/sde_rotator_core.c +9 −1 Original line number Diff line number Diff line Loading @@ -1257,8 +1257,12 @@ static int sde_rotator_calc_perf(struct sde_rot_mgr *mgr, (mgr->overhead.denom - max_fps * mgr->overhead.numer)); /* use client provided clock if specified */ if (config->flags & SDE_ROTATION_EXT_PERF) perf->clk_rate = config->clk_rate; /* * check for Override clock calcualtion * check for Override clock calculation */ if (rot_dev->min_rot_clk > perf->clk_rate) perf->clk_rate = rot_dev->min_rot_clk; Loading @@ -1282,6 +1286,10 @@ static int sde_rotator_calc_perf(struct sde_rot_mgr *mgr, if (rot_dev->min_bw > perf->bw) perf->bw = rot_dev->min_bw; /* use client provided bandwidth if specified */ if (config->flags & SDE_ROTATION_EXT_PERF) perf->bw = config->data_bw; perf->rdot_limit = sde_mdp_get_ot_limit( config->input.width, config->input.height, config->input.format, config->frame_rate, true); Loading drivers/media/platform/msm/sde/rotator/sde_rotator_core.h +7 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,9 @@ /* use client mapped i/o virtual address */ #define SDE_ROTATION_EXT_IOVA 0x80000 /* use client provided clock/bandwidth parameters */ #define SDE_ROTATION_EXT_PERF 0x100000 /********************************************************************** * configuration structures **********************************************************************/ Loading @@ -91,6 +94,8 @@ struct sde_rotation_buf_info { * @input: input buffer information * @output: output buffer information * @frame_rate: session frame rate in fps * @clk_rate: requested rotator clock rate if SDE_ROTATION_EXT_PERF is set * @data_bw: requested data bus bandwidth if SDE_ROTATION_EXT_PERF is set * @flags: configuration flags, e.g. rotation angle, flip, etc... */ struct sde_rotation_config { Loading @@ -98,6 +103,8 @@ struct sde_rotation_config { struct sde_rotation_buf_info input; struct sde_rotation_buf_info output; uint32_t frame_rate; uint64_t clk_rate; uint64_t data_bw; uint32_t flags; }; Loading drivers/media/platform/msm/sde/rotator/sde_rotator_dev.c +18 −1 Original line number Diff line number Diff line Loading @@ -1380,7 +1380,7 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, } SDEROT_DBG( "s:%d.%u src:(%u,%u,%u,%u)/%ux%u/%c%c%c%c dst:(%u,%u,%u,%u)/%c%c%c%c r:%d f:%d/%d s:%d fps:%u wb:%d vid:%d cmd:%d\n", "s:%d.%u src:(%u,%u,%u,%u)/%ux%u/%c%c%c%c dst:(%u,%u,%u,%u)/%c%c%c%c r:%d f:%d/%d s:%d fps:%u clk:%llu bw:%llu wb:%d vid:%d cmd:%d\n", ctx->session_id, cmd->sequence_id, cmd->src_rect_x, cmd->src_rect_y, cmd->src_rect_w, cmd->src_rect_h, Loading @@ -1392,8 +1392,21 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, cmd->dst_pixfmt >> 0, cmd->dst_pixfmt >> 8, cmd->dst_pixfmt >> 16, cmd->dst_pixfmt >> 24, cmd->rot90, cmd->hflip, cmd->vflip, cmd->secure, cmd->fps, cmd->clkrate, cmd->data_bw, cmd->dst_writeback, cmd->video_mode, cmd_type); SDEROT_EVTLOG(ctx->session_id, cmd->sequence_id, cmd->src_rect_x, cmd->src_rect_y, cmd->src_rect_w, cmd->src_rect_h, cmd->src_width, cmd->src_height, cmd->src_pixfmt, cmd->dst_rect_x, cmd->dst_rect_y, cmd->dst_rect_w, cmd->dst_rect_h, cmd->dst_pixfmt, cmd->rot90, cmd->hflip, cmd->vflip, cmd->secure, cmd->fps, cmd->clkrate, cmd->data_bw, cmd->dst_writeback, cmd->video_mode, cmd_type); sde_rot_mgr_lock(rot_dev->mgr); if (cmd_type == SDE_ROTATOR_INLINE_CMD_VALIDATE || Loading @@ -1415,6 +1428,8 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, if (cmd->secure) flags |= SDE_ROTATION_SECURE; flags |= SDE_ROTATION_EXT_PERF; /* fill in item work structure */ memset(&item, 0, sizeof(struct sde_rotation_item)); item.flags = flags | SDE_ROTATION_EXT_IOVA; Loading Loading @@ -1478,6 +1493,8 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, memset(&rotcfg, 0, sizeof(struct sde_rotation_config)); rotcfg.flags = flags; rotcfg.frame_rate = cmd->fps; rotcfg.clk_rate = cmd->clkrate; rotcfg.data_bw = cmd->data_bw; rotcfg.session_id = ctx->session_id; rotcfg.input.width = cmd->src_rect_w; rotcfg.input.height = cmd->src_rect_h; Loading drivers/media/platform/msm/sde/rotator/sde_rotator_inline.h +4 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,8 @@ enum sde_rotator_inline_cmd_type { * @vflip: vertical flip prior to rotation * @secure: true if buffer is in secure domain * @prefill_bw: prefill bandwidth in Bps * @clkrate: clock rate in Hz * @data_bw: data bus bandwidth in Bps * @src_addr: source i/o buffer virtual address * @src_len: source i/o buffer length * @src_planes: source plane number Loading Loading @@ -73,6 +75,8 @@ struct sde_rotator_inline_cmd { bool vflip; bool secure; u64 prefill_bw; u64 clkrate; u64 data_bw; dma_addr_t src_addr[SDE_ROTATOR_INLINE_PLANE_MAX]; u32 src_len[SDE_ROTATOR_INLINE_PLANE_MAX]; u32 src_planes; Loading Loading
drivers/media/platform/msm/sde/rotator/sde_rotator_core.c +9 −1 Original line number Diff line number Diff line Loading @@ -1257,8 +1257,12 @@ static int sde_rotator_calc_perf(struct sde_rot_mgr *mgr, (mgr->overhead.denom - max_fps * mgr->overhead.numer)); /* use client provided clock if specified */ if (config->flags & SDE_ROTATION_EXT_PERF) perf->clk_rate = config->clk_rate; /* * check for Override clock calcualtion * check for Override clock calculation */ if (rot_dev->min_rot_clk > perf->clk_rate) perf->clk_rate = rot_dev->min_rot_clk; Loading @@ -1282,6 +1286,10 @@ static int sde_rotator_calc_perf(struct sde_rot_mgr *mgr, if (rot_dev->min_bw > perf->bw) perf->bw = rot_dev->min_bw; /* use client provided bandwidth if specified */ if (config->flags & SDE_ROTATION_EXT_PERF) perf->bw = config->data_bw; perf->rdot_limit = sde_mdp_get_ot_limit( config->input.width, config->input.height, config->input.format, config->frame_rate, true); Loading
drivers/media/platform/msm/sde/rotator/sde_rotator_core.h +7 −0 Original line number Diff line number Diff line Loading @@ -65,6 +65,9 @@ /* use client mapped i/o virtual address */ #define SDE_ROTATION_EXT_IOVA 0x80000 /* use client provided clock/bandwidth parameters */ #define SDE_ROTATION_EXT_PERF 0x100000 /********************************************************************** * configuration structures **********************************************************************/ Loading @@ -91,6 +94,8 @@ struct sde_rotation_buf_info { * @input: input buffer information * @output: output buffer information * @frame_rate: session frame rate in fps * @clk_rate: requested rotator clock rate if SDE_ROTATION_EXT_PERF is set * @data_bw: requested data bus bandwidth if SDE_ROTATION_EXT_PERF is set * @flags: configuration flags, e.g. rotation angle, flip, etc... */ struct sde_rotation_config { Loading @@ -98,6 +103,8 @@ struct sde_rotation_config { struct sde_rotation_buf_info input; struct sde_rotation_buf_info output; uint32_t frame_rate; uint64_t clk_rate; uint64_t data_bw; uint32_t flags; }; Loading
drivers/media/platform/msm/sde/rotator/sde_rotator_dev.c +18 −1 Original line number Diff line number Diff line Loading @@ -1380,7 +1380,7 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, } SDEROT_DBG( "s:%d.%u src:(%u,%u,%u,%u)/%ux%u/%c%c%c%c dst:(%u,%u,%u,%u)/%c%c%c%c r:%d f:%d/%d s:%d fps:%u wb:%d vid:%d cmd:%d\n", "s:%d.%u src:(%u,%u,%u,%u)/%ux%u/%c%c%c%c dst:(%u,%u,%u,%u)/%c%c%c%c r:%d f:%d/%d s:%d fps:%u clk:%llu bw:%llu wb:%d vid:%d cmd:%d\n", ctx->session_id, cmd->sequence_id, cmd->src_rect_x, cmd->src_rect_y, cmd->src_rect_w, cmd->src_rect_h, Loading @@ -1392,8 +1392,21 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, cmd->dst_pixfmt >> 0, cmd->dst_pixfmt >> 8, cmd->dst_pixfmt >> 16, cmd->dst_pixfmt >> 24, cmd->rot90, cmd->hflip, cmd->vflip, cmd->secure, cmd->fps, cmd->clkrate, cmd->data_bw, cmd->dst_writeback, cmd->video_mode, cmd_type); SDEROT_EVTLOG(ctx->session_id, cmd->sequence_id, cmd->src_rect_x, cmd->src_rect_y, cmd->src_rect_w, cmd->src_rect_h, cmd->src_width, cmd->src_height, cmd->src_pixfmt, cmd->dst_rect_x, cmd->dst_rect_y, cmd->dst_rect_w, cmd->dst_rect_h, cmd->dst_pixfmt, cmd->rot90, cmd->hflip, cmd->vflip, cmd->secure, cmd->fps, cmd->clkrate, cmd->data_bw, cmd->dst_writeback, cmd->video_mode, cmd_type); sde_rot_mgr_lock(rot_dev->mgr); if (cmd_type == SDE_ROTATOR_INLINE_CMD_VALIDATE || Loading @@ -1415,6 +1428,8 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, if (cmd->secure) flags |= SDE_ROTATION_SECURE; flags |= SDE_ROTATION_EXT_PERF; /* fill in item work structure */ memset(&item, 0, sizeof(struct sde_rotation_item)); item.flags = flags | SDE_ROTATION_EXT_IOVA; Loading Loading @@ -1478,6 +1493,8 @@ int sde_rotator_inline_commit(void *handle, struct sde_rotator_inline_cmd *cmd, memset(&rotcfg, 0, sizeof(struct sde_rotation_config)); rotcfg.flags = flags; rotcfg.frame_rate = cmd->fps; rotcfg.clk_rate = cmd->clkrate; rotcfg.data_bw = cmd->data_bw; rotcfg.session_id = ctx->session_id; rotcfg.input.width = cmd->src_rect_w; rotcfg.input.height = cmd->src_rect_h; Loading
drivers/media/platform/msm/sde/rotator/sde_rotator_inline.h +4 −0 Original line number Diff line number Diff line Loading @@ -43,6 +43,8 @@ enum sde_rotator_inline_cmd_type { * @vflip: vertical flip prior to rotation * @secure: true if buffer is in secure domain * @prefill_bw: prefill bandwidth in Bps * @clkrate: clock rate in Hz * @data_bw: data bus bandwidth in Bps * @src_addr: source i/o buffer virtual address * @src_len: source i/o buffer length * @src_planes: source plane number Loading Loading @@ -73,6 +75,8 @@ struct sde_rotator_inline_cmd { bool vflip; bool secure; u64 prefill_bw; u64 clkrate; u64 data_bw; dma_addr_t src_addr[SDE_ROTATOR_INLINE_PLANE_MAX]; u32 src_len[SDE_ROTATOR_INLINE_PLANE_MAX]; u32 src_planes; Loading