Home
last modified time | relevance | path

Searched refs:mdp (Results 1 – 25 of 105) sorted by relevance

12345

/linux/drivers/media/platform/mediatek/mdp3/
H A Dmtk-mdp3-core.c101 int mdp_vpu_get_locked(struct mdp_dev *mdp) in mdp_vpu_get_locked() argument
105 if (mdp->vpu_count++ == 0) { in mdp_vpu_get_locked()
106 ret = rproc_boot(mdp->rproc_handle); in mdp_vpu_get_locked()
108 dev_err(&mdp->pdev->dev, in mdp_vpu_get_locked()
112 ret = mdp_vpu_register(mdp); in mdp_vpu_get_locked()
114 dev_err(&mdp->pdev->dev, in mdp_vpu_get_locked()
118 ret = mdp_vpu_dev_init(&mdp->vpu, mdp->scp, &mdp->vpu_lock); in mdp_vpu_get_locked()
120 dev_err(&mdp->pdev->dev, in mdp_vpu_get_locked()
128 mdp_vpu_unregister(mdp); in mdp_vpu_get_locked()
131 mdp->vpu_count--; in mdp_vpu_get_locked()
[all …]
H A Dmtk-mdp3-cmdq.c105 static struct img_config *__get_config_offset(struct mdp_dev *mdp, in __get_config_offset() argument
109 const int p_id = mdp->mdp_data->mdp_plat_id; in __get_config_offset()
110 struct device *dev = &mdp->pdev->dev; in __get_config_offset()
112 long bound = mdp->vpu.config_size; in __get_config_offset()
114 if (pp_idx >= mdp->mdp_data->pp_used) in __get_config_offset()
131 if ((long)cfg_n - (long)mdp->vpu.config > bound) { in __get_config_offset()
261 static int mdp_path_ctx_init(struct mdp_dev *mdp, struct mdp_path *path) in mdp_path_ctx_init() argument
263 const int p_id = mdp->mdp_data->mdp_plat_id; in mdp_path_ctx_init()
290 ret = mdp_comp_ctx_config(mdp, &path->comps[index], in mdp_path_ctx_init()
391 static int mdp_path_config(struct mdp_dev *mdp, struct mdp_cmdq_cmd *cmd, in mdp_path_config() argument
[all …]
H A Dmtk-mdp3-m2m.c566 struct mdp_dev *mdp = video_get_drvdata(vdev); in mdp_m2m_open() local
568 struct device *dev = &mdp->pdev->dev; in mdp_m2m_open()
571 const struct mdp_limit *limit = mdp->mdp_data->def_limit; in mdp_m2m_open()
577 if (mutex_lock_interruptible(&mdp->m2m_lock)) { in mdp_m2m_open()
582 ret = ida_alloc(&mdp->mdp_ida, GFP_KERNEL); in mdp_m2m_open()
587 ctx->mdp_dev = mdp; in mdp_m2m_open()
600 ctx->m2m_ctx = v4l2_m2m_ctx_init(mdp->m2m_dev, ctx, mdp_m2m_queue_init); in mdp_m2m_open()
609 ret = mdp_frameparam_init(mdp, &ctx->curr_param); in mdp_m2m_open()
615 mutex_unlock(&mdp->m2m_lock); in mdp_m2m_open()
637 ida_free(&mdp->mdp_ida, ctx->id); in mdp_m2m_open()
[all …]
H A Dmtk-mdp3-vpu.c115 struct mdp_dev *mdp = vpu_to_mdp(vpu); in mdp_vpu_ipi_handle_frame_ack() local
117 dev_err(&mdp->pdev->dev, "VPU MDP failure:%d\n", param->state); in mdp_vpu_ipi_handle_frame_ack()
123 int mdp_vpu_register(struct mdp_dev *mdp) in mdp_vpu_register() argument
126 struct mtk_scp *scp = mdp->scp; in mdp_vpu_register()
127 struct device *dev = &mdp->pdev->dev; in mdp_vpu_register()
158 void mdp_vpu_unregister(struct mdp_dev *mdp) in mdp_vpu_unregister() argument
160 scp_ipi_unregister(mdp->scp, SCP_IPI_MDP_INIT); in mdp_vpu_unregister()
161 scp_ipi_unregister(mdp->scp, SCP_IPI_MDP_DEINIT); in mdp_vpu_unregister()
162 scp_ipi_unregister(mdp->scp, SCP_IPI_MDP_FRAME); in mdp_vpu_unregister()
168 struct mdp_dev *mdp = vpu_to_mdp(vpu); in mdp_vpu_sendmsg() local
[all …]
H A Dmtk-mdp3-core.h146 int mdp_vpu_get_locked(struct mdp_dev *mdp);
147 void mdp_vpu_put_locked(struct mdp_dev *mdp);
148 int mdp_vpu_register(struct mdp_dev *mdp);
149 void mdp_vpu_unregister(struct mdp_dev *mdp);
H A Dmtk-mdp3-regs.c116 int mdp_enum_fmt_mplane(struct mdp_dev *mdp, struct v4l2_fmtdesc *f) in mdp_enum_fmt_mplane() argument
120 fmt = mdp_find_fmt_by_index(mdp->mdp_data, f->index, f->type); in mdp_enum_fmt_mplane()
128 const struct mdp_format *mdp_try_fmt_mplane(struct mdp_dev *mdp, in mdp_try_fmt_mplane() argument
141 fmt = mdp_find_fmt(mdp->mdp_data, pix_mp->pixelformat, f->type); in mdp_try_fmt_mplane()
143 fmt = mdp_find_fmt_by_index(mdp->mdp_data, 0, f->type); in mdp_try_fmt_mplane()
307 bool mdp_check_pp_enable(struct mdp_dev *mdp, struct mdp_frame *frame) in mdp_check_pp_enable() argument
311 if (!mdp || !frame) in mdp_check_pp_enable()
314 if (!mdp->mdp_data->pp_criteria) in mdp_check_pp_enable()
317 s = mdp->mdp_data->pp_criteria->width * in mdp_check_pp_enable()
318 mdp->mdp_data->pp_criteria->height; in mdp_check_pp_enable()
[all …]
H A Dmtk-mdp3-comp.c1614 static int mdp_comp_get_id(struct mdp_dev *mdp, enum mdp_comp_type type, u32 alias_id) in mdp_comp_get_id() argument
1618 for (i = 0; i < mdp->mdp_data->comp_data_len; i++) in mdp_comp_get_id()
1619 if (mdp->mdp_data->comp_data[i].match.type == type && in mdp_comp_get_id()
1620 mdp->mdp_data->comp_data[i].match.alias_id == alias_id) in mdp_comp_get_id()
1733 static int mdp_get_subsys_id(struct mdp_dev *mdp, struct device *dev, in mdp_get_subsys_id() argument
1752 index = mdp->mdp_data->comp_data[comp->public_id].info.dts_reg_ofst; in mdp_get_subsys_id()
1767 static void __mdp_comp_init(struct mdp_dev *mdp, struct device_node *node, in __mdp_comp_init() argument
1774 index = mdp->mdp_data->comp_data[comp->public_id].info.dts_reg_ofst; in __mdp_comp_init()
1780 comp->mdp_dev = mdp; in __mdp_comp_init()
1785 static int mdp_comp_init(struct mdp_dev *mdp, struct device_node *node, in mdp_comp_init() argument
[all …]
H A Dmtk-mdp3-m2m.h43 int mdp_m2m_device_register(struct mdp_dev *mdp);
44 void mdp_m2m_device_unregister(struct mdp_dev *mdp);
H A Dmtk-mdp3-cmdq.h31 struct mdp_dev *mdp; member
42 int mdp_cmdq_send(struct mdp_dev *mdp, struct mdp_cmdq_param *param);
H A Dmtk-mdp3-regs.h359 int mdp_enum_fmt_mplane(struct mdp_dev *mdp, struct v4l2_fmtdesc *f);
360 const struct mdp_format *mdp_try_fmt_mplane(struct mdp_dev *mdp,
371 bool mdp_check_pp_enable(struct mdp_dev *mdp, struct mdp_frame *frame);
376 int mdp_frameparam_init(struct mdp_dev *mdp, struct mdp_frameparam *param);
H A Dmtk-mdp3-comp.h257 int mdp_comp_config(struct mdp_dev *mdp);
258 void mdp_comp_destroy(struct mdp_dev *mdp);
263 int mdp_comp_ctx_config(struct mdp_dev *mdp, struct mdp_comp_ctx *ctx,
/linux/drivers/pwm/
H A Dpwm-mtk-disp.c57 static void mtk_disp_pwm_update_bits(struct mtk_disp_pwm *mdp, u32 offset, in mtk_disp_pwm_update_bits() argument
60 void __iomem *address = mdp->base + offset; in mtk_disp_pwm_update_bits()
72 struct mtk_disp_pwm *mdp = to_mtk_disp_pwm(chip); in mtk_disp_pwm_apply() local
80 if (!state->enabled && mdp->enabled) { in mtk_disp_pwm_apply()
81 mtk_disp_pwm_update_bits(mdp, DISP_PWM_EN, in mtk_disp_pwm_apply()
82 mdp->data->enable_mask, 0x0); in mtk_disp_pwm_apply()
83 clk_disable_unprepare(mdp->clk_mm); in mtk_disp_pwm_apply()
84 clk_disable_unprepare(mdp->clk_main); in mtk_disp_pwm_apply()
86 mdp->enabled = false; in mtk_disp_pwm_apply()
90 if (!mdp->enabled) { in mtk_disp_pwm_apply()
[all …]
/linux/drivers/media/platform/mediatek/mdp/
H A Dmtk_mdp_core.c54 static void mtk_mdp_clock_on(struct mtk_mdp_dev *mdp) in mtk_mdp_clock_on() argument
56 struct device *dev = &mdp->pdev->dev; in mtk_mdp_clock_on()
59 list_for_each_entry(comp_node, &mdp->comp_list, node) in mtk_mdp_clock_on()
63 static void mtk_mdp_clock_off(struct mtk_mdp_dev *mdp) in mtk_mdp_clock_off() argument
65 struct device *dev = &mdp->pdev->dev; in mtk_mdp_clock_off()
68 list_for_each_entry(comp_node, &mdp->comp_list, node) in mtk_mdp_clock_off()
74 struct mtk_mdp_dev *mdp = in mtk_mdp_wdt_worker() local
80 list_for_each_entry(ctx, &mdp->ctx_list, list) { in mtk_mdp_wdt_worker()
88 struct mtk_mdp_dev *mdp = priv; in mtk_mdp_reset_handler() local
90 queue_work(mdp->wdt_wq, &mdp->wdt_work); in mtk_mdp_reset_handler()
[all …]
H A Dmtk_mdp_m2m.c176 struct mtk_mdp_dev *mdp = ctx->mdp_dev; in mtk_mdp_try_fmt_mplane() local
177 struct mtk_mdp_variant *variant = mdp->variant; in mtk_mdp_try_fmt_mplane()
279 struct mtk_mdp_dev *mdp = ctx->mdp_dev; in mtk_mdp_try_crop() local
280 struct mtk_mdp_variant *variant = mdp->variant; in mtk_mdp_try_crop()
473 struct mtk_mdp_dev *mdp = priv; in mtk_mdp_process_done() local
477 ctx = v4l2_m2m_get_curr_priv(mdp->m2m_dev); in mtk_mdp_process_done()
498 struct mtk_mdp_dev *mdp = ctx->mdp_dev; in mtk_mdp_m2m_worker() local
503 dev_err(&mdp->pdev->dev, "ctx is in error state"); in mtk_mdp_m2m_worker()
523 dev_err(&mdp->pdev->dev, "processing failed: %d", ret); in mtk_mdp_m2m_worker()
530 mtk_mdp_process_done(mdp, buf_state); in mtk_mdp_m2m_worker()
[all …]
H A DMakefile2 mtk-mdp-y += mtk_mdp_core.o
3 mtk-mdp-y += mtk_mdp_comp.o
4 mtk-mdp-y += mtk_mdp_m2m.o
5 mtk-mdp-y += mtk_mdp_regs.o
6 mtk-mdp-y += mtk_mdp_vpu.o
8 obj-$(CONFIG_VIDEO_MEDIATEK_MDP) += mtk-mdp.o
H A Dmtk_mdp_m2m.h11 int mtk_mdp_register_m2m_device(struct mtk_mdp_dev *mdp);
12 void mtk_mdp_unregister_m2m_device(struct mtk_mdp_dev *mdp);
H A Dmtk_mdp_vpu.c63 struct mtk_mdp_dev *mdp = platform_get_drvdata(pdev); in mtk_mdp_vpu_register() local
66 err = vpu_ipi_register(mdp->vpu_dev, IPI_MDP, in mtk_mdp_vpu_register()
69 dev_err(&mdp->pdev->dev, in mtk_mdp_vpu_register()
/linux/drivers/net/ethernet/renesas/
H A Dsh_eth.c349 struct sh_eth_private *mdp = netdev_priv(ndev); in sh_eth_write() local
350 u16 offset = mdp->reg_offset[enum_index]; in sh_eth_write()
355 iowrite32(data, mdp->addr + offset); in sh_eth_write()
360 struct sh_eth_private *mdp = netdev_priv(ndev); in sh_eth_read() local
361 u16 offset = mdp->reg_offset[enum_index]; in sh_eth_read()
366 return ioread32(mdp->addr + offset); in sh_eth_read()
376 static u16 sh_eth_tsu_get_offset(struct sh_eth_private *mdp, int enum_index) in sh_eth_tsu_get_offset() argument
378 return mdp->reg_offset[enum_index]; in sh_eth_tsu_get_offset()
381 static void sh_eth_tsu_write(struct sh_eth_private *mdp, u32 data, in sh_eth_tsu_write() argument
384 u16 offset = sh_eth_tsu_get_offset(mdp, enum_index); in sh_eth_tsu_write()
[all …]
/linux/drivers/gpu/drm/msm/disp/dpu1/
H A Ddpu_hw_top.c32 static void dpu_hw_setup_split_pipe(struct dpu_hw_mdp *mdp, in dpu_hw_setup_split_pipe() argument
39 if (!mdp || !cfg) in dpu_hw_setup_split_pipe()
42 c = &mdp->hw; in dpu_hw_setup_split_pipe()
70 static bool dpu_hw_setup_clk_force_ctrl(struct dpu_hw_mdp *mdp, in dpu_hw_setup_clk_force_ctrl() argument
73 if (!mdp) in dpu_hw_setup_clk_force_ctrl()
79 return dpu_hw_clk_force_ctrl(&mdp->hw, &mdp->caps->clk_ctrls[clk_ctrl], enable); in dpu_hw_setup_clk_force_ctrl()
83 static void dpu_hw_get_danger_status(struct dpu_hw_mdp *mdp, in dpu_hw_get_danger_status() argument
89 if (!mdp || !status) in dpu_hw_get_danger_status()
92 c = &mdp->hw; in dpu_hw_get_danger_status()
95 status->mdp = (value >> 0) & 0x3; in dpu_hw_get_danger_status()
[all …]
H A Ddpu_hw_top.h51 u8 mdp; member
90 void (*setup_split_pipe)(struct dpu_hw_mdp *mdp,
98 void (*setup_traffic_shaper)(struct dpu_hw_mdp *mdp,
108 bool (*setup_clk_force_ctrl)(struct dpu_hw_mdp *mdp,
116 void (*get_danger_status)(struct dpu_hw_mdp *mdp,
124 void (*setup_vsync_source)(struct dpu_hw_mdp *mdp,
132 void (*get_safe_status)(struct dpu_hw_mdp *mdp,
140 void (*dp_phy_intf_sel)(struct dpu_hw_mdp *mdp, enum dpu_dp_phy_sel phys[2]);
146 void (*intf_audio_select)(struct dpu_hw_mdp *mdp);
172 void dpu_hw_mdp_destroy(struct dpu_hw_mdp *mdp);
/linux/Documentation/devicetree/bindings/media/
H A Dmediatek-mdp.txt6 - compatible: "mediatek,mt8173-mdp"
12 "mediatek,mt8173-mdp-rdma" - read DMA
13 "mediatek,mt8173-mdp-rsz" - resizer
14 "mediatek,mt8173-mdp-wdma" - write DMA
15 "mediatek,mt8173-mdp-wrot" - write DMA with rotation
24 "mediatek,mt8173-mdp-rdma"
25 "mediatek,mt8173-mdp-wdma"
26 "mediatek,mt8173-mdp-wrot"
33 compatible = "mediatek,mt8173-mdp-rdma";
34 "mediatek,mt8173-mdp";
[all …]
/linux/drivers/gpu/drm/msm/disp/mdp5/
H A Dmdp5_cfg.c19 .mdp = {
108 .mdp = {
189 .mdp = {
276 .mdp = {
376 .mdp = {
448 .mdp = {
528 .mdp = {
628 .mdp = {
741 .mdp = {
838 .mdp = {
[all …]
/linux/scripts/selinux/
H A Dinstall_policy.sh38 cd mdp
39 ./mdp -m policy.conf file_contexts
/linux/Documentation/admin-guide/LSM/
H A DSELinux.rst12 testing, you can do using ``mdp`` provided under
19 2. Type ``make`` to compile ``mdp``.
/linux/arch/arm64/boot/dts/mediatek/
H A Dmt8173.dtsi39 mdp-rdma0 = &mdp_rdma0;
40 mdp-rdma1 = &mdp_rdma1;
41 mdp-rsz0 = &mdp_rsz0;
42 mdp-rsz1 = &mdp_rsz1;
43 mdp-rsz2 = &mdp_rsz2;
44 mdp-wdma0 = &mdp_wdma0;
45 mdp-wrot0 = &mdp_wrot0;
46 mdp-wrot1 = &mdp_wrot1;
1010 compatible = "mediatek,mt8173-mdp-rdma",
1011 "mediatek,mt8173-mdp";
[all …]

12345