mirror of
https://github.com/FEX-Emu/linux.git
synced 2024-12-29 04:45:05 +00:00
Merge branch 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos
This pull request fixes module build and g2d clock control issues, and includes related cleanup. * 'exynos-drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/daeinki/drm-exynos: drm/exynos: Remove module.h header inclusion drm/exynos: consider common clock framework to g2d driver. drm/exynos: fix module build error drm/exynos: exynos_drm_ipp: fix return value check
This commit is contained in:
commit
ca089b7266
@ -15,7 +15,6 @@
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/i2c.h>
|
||||
#include <linux/module.h>
|
||||
|
||||
|
||||
#include "exynos_drm_drv.h"
|
||||
|
@ -12,7 +12,6 @@
|
||||
*
|
||||
*/
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/mfd/syscon.h>
|
||||
#include <linux/regmap.h>
|
||||
|
@ -14,7 +14,6 @@
|
||||
#include <drm/drmP.h>
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/clk.h>
|
||||
#include <linux/of_device.h>
|
||||
@ -130,7 +129,6 @@ static const struct of_device_id fimd_driver_dt_match[] = {
|
||||
.data = &exynos5_fimd_driver_data },
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, fimd_driver_dt_match);
|
||||
#endif
|
||||
|
||||
static inline struct fimd_driver_data *drm_fimd_get_driver_data(
|
||||
@ -1082,7 +1080,6 @@ static struct platform_device_id fimd_driver_ids[] = {
|
||||
},
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(platform, fimd_driver_ids);
|
||||
|
||||
static const struct dev_pm_ops fimd_pm_ops = {
|
||||
SET_SYSTEM_SLEEP_PM_OPS(fimd_suspend, fimd_resume)
|
||||
|
@ -8,7 +8,6 @@
|
||||
*/
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/clk.h>
|
||||
#include <linux/err.h>
|
||||
#include <linux/interrupt.h>
|
||||
@ -806,9 +805,20 @@ static void g2d_dma_start(struct g2d_data *g2d,
|
||||
struct g2d_cmdlist_node *node =
|
||||
list_first_entry(&runqueue_node->run_cmdlist,
|
||||
struct g2d_cmdlist_node, list);
|
||||
int ret;
|
||||
|
||||
pm_runtime_get_sync(g2d->dev);
|
||||
clk_enable(g2d->gate_clk);
|
||||
ret = pm_runtime_get_sync(g2d->dev);
|
||||
if (ret < 0) {
|
||||
dev_warn(g2d->dev, "failed pm power on.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
ret = clk_prepare_enable(g2d->gate_clk);
|
||||
if (ret < 0) {
|
||||
dev_warn(g2d->dev, "failed to enable clock.\n");
|
||||
pm_runtime_put_sync(g2d->dev);
|
||||
return;
|
||||
}
|
||||
|
||||
writel_relaxed(node->dma_addr, g2d->regs + G2D_DMA_SFR_BASE_ADDR);
|
||||
writel_relaxed(G2D_DMA_START, g2d->regs + G2D_DMA_COMMAND);
|
||||
@ -861,7 +871,7 @@ static void g2d_runqueue_worker(struct work_struct *work)
|
||||
runqueue_work);
|
||||
|
||||
mutex_lock(&g2d->runqueue_mutex);
|
||||
clk_disable(g2d->gate_clk);
|
||||
clk_disable_unprepare(g2d->gate_clk);
|
||||
pm_runtime_put_sync(g2d->dev);
|
||||
|
||||
complete(&g2d->runqueue_node->complete);
|
||||
@ -1521,7 +1531,6 @@ static const struct of_device_id exynos_g2d_match[] = {
|
||||
{ .compatible = "samsung,exynos5250-g2d" },
|
||||
{},
|
||||
};
|
||||
MODULE_DEVICE_TABLE(of, exynos_g2d_match);
|
||||
#endif
|
||||
|
||||
struct platform_driver g2d_driver = {
|
||||
|
@ -12,7 +12,6 @@
|
||||
*
|
||||
*/
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/clk.h>
|
||||
#include <linux/pm_runtime.h>
|
||||
|
@ -15,7 +15,6 @@
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/wait.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/pm_runtime.h>
|
||||
|
||||
|
@ -12,7 +12,6 @@
|
||||
*
|
||||
*/
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/types.h>
|
||||
#include <linux/clk.h>
|
||||
@ -342,10 +341,10 @@ int exynos_drm_ipp_get_property(struct drm_device *drm_dev, void *data,
|
||||
*/
|
||||
ippdrv = ipp_find_obj(&ctx->ipp_idr, &ctx->ipp_lock,
|
||||
prop_list->ipp_id);
|
||||
if (!ippdrv) {
|
||||
if (IS_ERR(ippdrv)) {
|
||||
DRM_ERROR("not found ipp%d driver.\n",
|
||||
prop_list->ipp_id);
|
||||
return -EINVAL;
|
||||
return PTR_ERR(ippdrv);
|
||||
}
|
||||
|
||||
prop_list = ippdrv->prop_list;
|
||||
@ -970,9 +969,9 @@ int exynos_drm_ipp_queue_buf(struct drm_device *drm_dev, void *data,
|
||||
/* find command node */
|
||||
c_node = ipp_find_obj(&ctx->prop_idr, &ctx->prop_lock,
|
||||
qbuf->prop_id);
|
||||
if (!c_node) {
|
||||
if (IS_ERR(c_node)) {
|
||||
DRM_ERROR("failed to get command node.\n");
|
||||
return -EFAULT;
|
||||
return PTR_ERR(c_node);
|
||||
}
|
||||
|
||||
/* buffer control */
|
||||
@ -1106,9 +1105,9 @@ int exynos_drm_ipp_cmd_ctrl(struct drm_device *drm_dev, void *data,
|
||||
|
||||
c_node = ipp_find_obj(&ctx->prop_idr, &ctx->prop_lock,
|
||||
cmd_ctrl->prop_id);
|
||||
if (!c_node) {
|
||||
if (IS_ERR(c_node)) {
|
||||
DRM_ERROR("invalid command node list.\n");
|
||||
return -EINVAL;
|
||||
return PTR_ERR(c_node);
|
||||
}
|
||||
|
||||
if (!exynos_drm_ipp_check_valid(ippdrv->dev, cmd_ctrl->ctrl,
|
||||
|
@ -10,7 +10,6 @@
|
||||
*/
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/err.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/io.h>
|
||||
|
@ -13,7 +13,6 @@
|
||||
#include <drm/drmP.h>
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
#include <drm/exynos_drm.h>
|
||||
|
@ -24,7 +24,6 @@
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/wait.h>
|
||||
#include <linux/i2c.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/irq.h>
|
||||
|
@ -15,7 +15,6 @@
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/i2c.h>
|
||||
#include <linux/module.h>
|
||||
|
||||
#include "exynos_drm_drv.h"
|
||||
#include "exynos_hdmi.h"
|
||||
|
@ -23,7 +23,6 @@
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/wait.h>
|
||||
#include <linux/i2c.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/platform_device.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/irq.h>
|
||||
|
Loading…
Reference in New Issue
Block a user