osd: use the old fence close way [3/3]
authorJiyu Yang <Jiyu.Yang@amlogic.com>
Mon, 11 Sep 2017 11:18:26 +0000 (19:18 +0800)
committerJianxin Pan <jianxin.pan@amlogic.com>
Thu, 14 Sep 2017 04:15:29 +0000 (21:15 -0700)
PD#149525: osd use the old fence close way

Change-Id: I9473e4820d2cbf42c623ee6c563163b654c7fe85
Signed-off-by: Jiyu Yang <Jiyu.Yang@amlogic.com>
drivers/amlogic/media/osd/osd_hw.c

index 7daa60d..fee822c 100644 (file)
@@ -428,6 +428,7 @@ int osd_sync_request(u32 index, u32 yres, u32 xoffset, u32 yoffset,
        list_add_tail(&fence_map->list, &post_fence_list);
        mutex_unlock(&post_fence_list_lock);
        kthread_queue_work(&buffer_toggle_worker, &buffer_toggle_work);
+       __close_fd(current->files, in_fence_fd);
        return  out_fence_fd;
 }
 
@@ -481,6 +482,7 @@ int osd_sync_request_render(u32 index, u32 yres,
        mutex_unlock(&post_fence_list_lock);
        kthread_queue_work(&buffer_toggle_worker, &buffer_toggle_work);
        request->out_fen_fd = out_fence_fd;
+       __close_fd(current->files, in_fence_fd);
        return  out_fence_fd;
 }