mixer_ctx 774 drivers/gpu/drm/exynos/exynos_mixer.c static int mixer_resources_init(struct mixer_context *mixer_ctx) mixer_ctx 776 drivers/gpu/drm/exynos/exynos_mixer.c struct device *dev = &mixer_ctx->pdev->dev; mixer_ctx 780 drivers/gpu/drm/exynos/exynos_mixer.c spin_lock_init(&mixer_ctx->reg_slock); mixer_ctx 782 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->mixer = devm_clk_get(dev, "mixer"); mixer_ctx 783 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->mixer)) { mixer_ctx 788 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->hdmi = devm_clk_get(dev, "hdmi"); mixer_ctx 789 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->hdmi)) { mixer_ctx 791 drivers/gpu/drm/exynos/exynos_mixer.c return PTR_ERR(mixer_ctx->hdmi); mixer_ctx 794 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->sclk_hdmi = devm_clk_get(dev, "sclk_hdmi"); mixer_ctx 795 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->sclk_hdmi)) { mixer_ctx 799 drivers/gpu/drm/exynos/exynos_mixer.c res = platform_get_resource(mixer_ctx->pdev, IORESOURCE_MEM, 0); mixer_ctx 805 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->mixer_regs = devm_ioremap(dev, res->start, mixer_ctx 807 drivers/gpu/drm/exynos/exynos_mixer.c if (mixer_ctx->mixer_regs == NULL) { mixer_ctx 812 drivers/gpu/drm/exynos/exynos_mixer.c res = platform_get_resource(mixer_ctx->pdev, IORESOURCE_IRQ, 0); mixer_ctx 819 drivers/gpu/drm/exynos/exynos_mixer.c 0, "drm_mixer", mixer_ctx); mixer_ctx 824 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->irq = res->start; mixer_ctx 829 drivers/gpu/drm/exynos/exynos_mixer.c static int vp_resources_init(struct mixer_context *mixer_ctx) mixer_ctx 831 drivers/gpu/drm/exynos/exynos_mixer.c struct device *dev = &mixer_ctx->pdev->dev; mixer_ctx 834 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->vp = devm_clk_get(dev, "vp"); mixer_ctx 835 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->vp)) { mixer_ctx 840 drivers/gpu/drm/exynos/exynos_mixer.c if (test_bit(MXR_BIT_HAS_SCLK, &mixer_ctx->flags)) { mixer_ctx 841 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->sclk_mixer = devm_clk_get(dev, "sclk_mixer"); mixer_ctx 842 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->sclk_mixer)) { mixer_ctx 846 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->mout_mixer = devm_clk_get(dev, "mout_mixer"); mixer_ctx 847 drivers/gpu/drm/exynos/exynos_mixer.c if (IS_ERR(mixer_ctx->mout_mixer)) { mixer_ctx 852 drivers/gpu/drm/exynos/exynos_mixer.c if (mixer_ctx->sclk_hdmi && mixer_ctx->mout_mixer) mixer_ctx 853 drivers/gpu/drm/exynos/exynos_mixer.c clk_set_parent(mixer_ctx->mout_mixer, mixer_ctx 854 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->sclk_hdmi); mixer_ctx 857 drivers/gpu/drm/exynos/exynos_mixer.c res = platform_get_resource(mixer_ctx->pdev, IORESOURCE_MEM, 1); mixer_ctx 863 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->vp_regs = devm_ioremap(dev, res->start, mixer_ctx 865 drivers/gpu/drm/exynos/exynos_mixer.c if (mixer_ctx->vp_regs == NULL) { mixer_ctx 873 drivers/gpu/drm/exynos/exynos_mixer.c static int mixer_initialize(struct mixer_context *mixer_ctx, mixer_ctx 878 drivers/gpu/drm/exynos/exynos_mixer.c mixer_ctx->drm_dev = drm_dev; mixer_ctx 881 drivers/gpu/drm/exynos/exynos_mixer.c ret = mixer_resources_init(mixer_ctx); mixer_ctx 883 drivers/gpu/drm/exynos/exynos_mixer.c DRM_DEV_ERROR(mixer_ctx->dev, mixer_ctx 888 drivers/gpu/drm/exynos/exynos_mixer.c if (test_bit(MXR_BIT_VP_ENABLED, &mixer_ctx->flags)) { mixer_ctx 890 drivers/gpu/drm/exynos/exynos_mixer.c ret = vp_resources_init(mixer_ctx); mixer_ctx 892 drivers/gpu/drm/exynos/exynos_mixer.c DRM_DEV_ERROR(mixer_ctx->dev, mixer_ctx 898 drivers/gpu/drm/exynos/exynos_mixer.c return exynos_drm_register_dma(drm_dev, mixer_ctx->dev, mixer_ctx 899 drivers/gpu/drm/exynos/exynos_mixer.c &mixer_ctx->dma_priv); mixer_ctx 902 drivers/gpu/drm/exynos/exynos_mixer.c static void mixer_ctx_remove(struct mixer_context *mixer_ctx) mixer_ctx 904 drivers/gpu/drm/exynos/exynos_mixer.c exynos_drm_unregister_dma(mixer_ctx->drm_dev, mixer_ctx->dev, mixer_ctx 905 drivers/gpu/drm/exynos/exynos_mixer.c &mixer_ctx->dma_priv); mixer_ctx 910 drivers/gpu/drm/exynos/exynos_mixer.c struct mixer_context *mixer_ctx = crtc->ctx; mixer_ctx 912 drivers/gpu/drm/exynos/exynos_mixer.c __set_bit(MXR_BIT_VSYNC, &mixer_ctx->flags); mixer_ctx 913 drivers/gpu/drm/exynos/exynos_mixer.c if (!test_bit(MXR_BIT_POWERED, &mixer_ctx->flags)) mixer_ctx 917 drivers/gpu/drm/exynos/exynos_mixer.c mixer_reg_writemask(mixer_ctx, MXR_INT_STATUS, ~0, MXR_INT_CLEAR_VSYNC); mixer_ctx 918 drivers/gpu/drm/exynos/exynos_mixer.c mixer_reg_writemask(mixer_ctx, MXR_INT_EN, ~0, MXR_INT_EN_VSYNC); mixer_ctx 925 drivers/gpu/drm/exynos/exynos_mixer.c struct mixer_context *mixer_ctx = crtc->ctx; mixer_ctx 927 drivers/gpu/drm/exynos/exynos_mixer.c __clear_bit(MXR_BIT_VSYNC, &mixer_ctx->flags); mixer_ctx 929 drivers/gpu/drm/exynos/exynos_mixer.c if (!test_bit(MXR_BIT_POWERED, &mixer_ctx->flags)) mixer_ctx 933 drivers/gpu/drm/exynos/exynos_mixer.c mixer_reg_writemask(mixer_ctx, MXR_INT_STATUS, ~0, MXR_INT_CLEAR_VSYNC); mixer_ctx 934 drivers/gpu/drm/exynos/exynos_mixer.c mixer_reg_writemask(mixer_ctx, MXR_INT_EN, 0, MXR_INT_EN_VSYNC); mixer_ctx 952 drivers/gpu/drm/exynos/exynos_mixer.c struct mixer_context *mixer_ctx = crtc->ctx; mixer_ctx 954 drivers/gpu/drm/exynos/exynos_mixer.c DRM_DEV_DEBUG_KMS(mixer_ctx->dev, "win: %d\n", plane->index); mixer_ctx 956 drivers/gpu/drm/exynos/exynos_mixer.c if (!test_bit(MXR_BIT_POWERED, &mixer_ctx->flags)) mixer_ctx 960 drivers/gpu/drm/exynos/exynos_mixer.c vp_video_buffer(mixer_ctx, plane); mixer_ctx 962 drivers/gpu/drm/exynos/exynos_mixer.c mixer_graph_buffer(mixer_ctx, plane); mixer_ctx 968 drivers/gpu/drm/exynos/exynos_mixer.c struct mixer_context *mixer_ctx = crtc->ctx; mixer_ctx 971 drivers/gpu/drm/exynos/exynos_mixer.c DRM_DEV_DEBUG_KMS(mixer_ctx->dev, "win: %d\n", plane->index); mixer_ctx 973 drivers/gpu/drm/exynos/exynos_mixer.c if (!test_bit(MXR_BIT_POWERED, &mixer_ctx->flags)) mixer_ctx 976 drivers/gpu/drm/exynos/exynos_mixer.c spin_lock_irqsave(&mixer_ctx->reg_slock, flags); mixer_ctx 977 drivers/gpu/drm/exynos/exynos_mixer.c mixer_cfg_layer(mixer_ctx, plane->index, 0, false); mixer_ctx 978 drivers/gpu/drm/exynos/exynos_mixer.c spin_unlock_irqrestore(&mixer_ctx->reg_slock, flags); mixer_ctx 983 drivers/gpu/drm/exynos/exynos_mixer.c struct mixer_context *mixer_ctx = crtc->ctx; mixer_ctx 985 drivers/gpu/drm/exynos/exynos_mixer.c if (!test_bit(MXR_BIT_POWERED, &mixer_ctx->flags)) mixer_ctx 988 drivers/gpu/drm/exynos/exynos_mixer.c mixer_enable_sync(mixer_ctx);