video: rockchip: iep: compatible for did not config CONFIG_FB_ROCKCHIP
authorbuluess.li <buluess.li@rock-chips.com>
Tue, 27 Jun 2017 03:29:40 +0000 (11:29 +0800)
committerJianqun Xu <jay.xu@rock-chips.com>
Tue, 27 Jun 2017 06:47:48 +0000 (14:47 +0800)
if there not config CONFIG_FB_ROCKCHIP that will build error

Change-Id: Icaa837f3c0a539e98133b7cb9550700e8a46817f
Signed-off-by: buluess.li <buluess.li@rock-chips.com>
drivers/video/rockchip/iep/iep_drv.c
drivers/video/rockchip/iep/iep_iommu_ops.h

index 2d9900b8baa9d786dc831285efbd1f95b99e9e1d..77ace774a48baefd9d9ba9dc0cf4cba03d4fc175 100644 (file)
@@ -288,6 +288,7 @@ static void iep_power_off_work(struct work_struct *work)
        }
 }
 
+#ifdef CONFIG_FB_ROCKCHIP
 extern void rk_direct_fb_show(struct fb_info *fbi);
 extern struct fb_info* rk_get_fb(int fb_id);
 extern bool rk_fb_poll_wait_frame_complete(void);
@@ -404,7 +405,6 @@ static int iep_switch_dpi(struct iep_reg *reg)
                        bool status;
                        rk_fb_dpi_open(false);
                        status = rk_fb_poll_wait_frame_complete();
-
                        iep_drvdata1->dpi_mode = false;
                        IEP_INFO("%s %d, iep dpi inactivated\n",
                                 __func__, __LINE__);
@@ -413,6 +413,7 @@ static int iep_switch_dpi(struct iep_reg *reg)
 
        return 0;
 }
+#endif
 
 static void iep_reg_copy_to_hw(struct iep_reg *reg)
 {
@@ -444,8 +445,9 @@ static void iep_switch_fields_order(void)
 {
        void *pbase = (void *)iep_drvdata1->iep_base;
        int mode = iep_get_deinterlace_mode(pbase);
+#ifdef CONFIG_FB_ROCKCHIP
        struct fb_info *fb;
-
+#endif
        switch (mode) {
        case dein_mode_I4O1B:
                iep_set_deinterlace_mode(dein_mode_I4O1T, pbase);
@@ -462,10 +464,10 @@ static void iep_switch_fields_order(void)
        default:
                ;
        }
-
+#ifdef CONFIG_FB_ROCKCHIP
        fb = rk_get_fb(1);
        rk_direct_fb_show(fb);
-
+#endif
        /*iep_switch_input_address(pbase);*/
 }
 
@@ -507,9 +509,9 @@ static void iep_try_start_frm(void)
        if (list_empty(&iep_service.running)) {
                if (!list_empty(&iep_service.ready)) {
                        reg = list_entry(iep_service.ready.next, struct iep_reg, status_link);
-
+#ifdef CONFIG_FB_ROCKCHIP
                        iep_switch_dpi(reg);
-
+#endif
                        iep_reg_from_ready_to_running(reg);
                        iep_config_frame_end_int_en(iep_drvdata1->iep_base);
                        iep_config_done(iep_drvdata1->iep_base);
index b1c5ff88fcce961331e61b212b8658e752250d63..09f33fd5139c44da911a6d0ed85c72a982e440aa 100644 (file)
@@ -17,6 +17,7 @@
 #define __IEP_IOMMU_OPS_H__
 
 #include <linux/platform_device.h>
+#include <linux/rockchip-iovmm.h>
 #include "iep_drv.h"
 
 #define BUFFER_LIST_MAX_NUMS   30