Lines Matching +full:re +full:- +full:routed
1 // SPDX-License-Identifier: GPL-2.0+
3 * R-Car Display Unit Color Management Module
27 * @lut: 1D-LUT state
28 * @lut.enabled: 1D-LUT enabled flag
37 return ioread32(rcmm->base + reg); in rcar_cmm_read()
42 iowrite32(data, rcmm->base + reg); in rcar_cmm_write()
46 * rcar_cmm_lut_write() - Scale the DRM LUT table entries to hardware precision
66 * rcar_cmm_setup() - Configure the CMM unit
71 * disabling and programming of the 1-D LUT unit is supported.
87 if (!config->lut.table) { in rcar_cmm_setup()
88 if (rcmm->lut.enabled) { in rcar_cmm_setup()
90 rcmm->lut.enabled = false; in rcar_cmm_setup()
97 if (!rcmm->lut.enabled) { in rcar_cmm_setup()
99 rcmm->lut.enabled = true; in rcar_cmm_setup()
102 rcar_cmm_lut_write(rcmm, config->lut.table); in rcar_cmm_setup()
109 * rcar_cmm_enable() - Enable the CMM unit
112 * When the output of the corresponding DU channel is routed to the CMM unit,
117 * Calls to rcar_cmm_enable() and rcar_cmm_disable() are not reference-counted.
125 ret = pm_runtime_resume_and_get(&pdev->dev); in rcar_cmm_enable()
134 * rcar_cmm_disable() - Disable the CMM unit
140 * state shall thus be restored with rcar_cmm_setup() when re-enabling the CMM
148 rcmm->lut.enabled = false; in rcar_cmm_disable()
150 pm_runtime_put(&pdev->dev); in rcar_cmm_disable()
155 * rcar_cmm_init() - Initialize the CMM unit
158 * Return: 0 on success, -EPROBE_DEFER if the CMM is not available yet,
159 * -ENODEV if the DRM_RCAR_CMM config option is disabled
166 return -EPROBE_DEFER; in rcar_cmm_init()
176 rcmm = devm_kzalloc(&pdev->dev, sizeof(*rcmm), GFP_KERNEL); in rcar_cmm_probe()
178 return -ENOMEM; in rcar_cmm_probe()
181 rcmm->base = devm_platform_ioremap_resource(pdev, 0); in rcar_cmm_probe()
182 if (IS_ERR(rcmm->base)) in rcar_cmm_probe()
183 return PTR_ERR(rcmm->base); in rcar_cmm_probe()
185 pm_runtime_enable(&pdev->dev); in rcar_cmm_probe()
192 pm_runtime_disable(&pdev->dev); in rcar_cmm_remove()
196 { .compatible = "renesas,rcar-gen3-cmm", },
197 { .compatible = "renesas,rcar-gen2-cmm", },
206 .name = "rcar-cmm",
214 MODULE_DESCRIPTION("Renesas R-Car CMM Driver");