Re: [PATCH] drm/exynos: g2d: fix overflow of cmdlist size

2017-01-23 Thread Joonyoung Shim
Hi Tobias, On 01/21/2017 01:05 AM, Tobias Jakobi wrote: > Hello Joonyoung, > > > Joonyoung Shim wrote: >> Hi Tobias, >> >> On 01/19/2017 10:16 PM, Tobias Jakobi wrote: >>> Hello Joonyoung, >>> >>> Joonyoung Shim wrote: >>>

Re: [PATCH] drm/exynos: g2d: fix overflow of cmdlist size

2017-01-19 Thread Joonyoung Shim
Hi Tobias, On 01/19/2017 10:16 PM, Tobias Jakobi wrote: > Hello Joonyoung, > > Joonyoung Shim wrote: >> Hi Tobias, >> >> On 01/17/2017 11:24 PM, Tobias Jakobi wrote: >>> Joonyoung Shim wrote: >>>> The size of cmdlist is integer type, so it can be

Re: [PATCH] drm/exynos: g2d: fix overflow of cmdlist size

2017-01-17 Thread Joonyoung Shim
Hi Tobias, On 01/17/2017 11:24 PM, Tobias Jakobi wrote: > Joonyoung Shim wrote: >> The size of cmdlist is integer type, so it can be overflowed by cmd and >> cmd_buf that has too big size. This patch will fix overflow issue as >> checking maximum size of cmd and cmd_buf. >

[PATCH] drm/exynos: g2d: fix overflow of cmdlist size

2017-01-16 Thread Joonyoung Shim
The size of cmdlist is integer type, so it can be overflowed by cmd and cmd_buf that has too big size. This patch will fix overflow issue as checking maximum size of cmd and cmd_buf. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_g2d.c | 9 - 1 file changed, 8

Re: [PATCH v2] drm/exynos/decon5433: set STANDALONE_UPDATE_F also if planes are disabled

2017-01-13 Thread Joonyoung Shim
> + } > > if (ctx->out_type & IFTYPE_I80) > set_bit(BIT_WIN_UPDATED, &ctx->flags); > I tested on TM2E board, Tested-by: Joonyoung Shim Thanks. ___ dri-devel mailing list dri-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/dri-devel

Re: [PATCH] drm/exynos/decon5433: set STANDALONE_UPDATE_F also if planes are disabled

2017-01-13 Thread Joonyoung Shim
Hi Andrzej, On 01/13/2017 05:10 PM, Andrzej Hajda wrote: > STANDALONE_UPDATE_F should be set if something changed in plane > configurations, > including plane disable. > The patch fixes page-faults bugs, caused by decon still using framebuffers > of disabled planes. > > Signed-off-by: Andrzej Ha

[PATCH] drm/exynos: use directly DMA mapping APIs on g2d

2016-04-22 Thread Joonyoung Shim
There is no reason to be wapper functions to use DMA mapping APIs. Use directly DMA mapping APIs and remove the wapper functions. Signed-off-by: Joonyoung Shim --- This is based on linux-next for 20160422. drivers/gpu/drm/exynos/exynos_drm_g2d.c | 10 +- drivers/gpu/drm/exynos

[PATCH 2/2] drm/exynos: fix imported dma-buf to be mapped

2016-04-22 Thread Joonyoung Shim
The imported dma-buf should be mapped by sub-system exporting it. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index

[PATCH 1/2] drm/exynos: support gem_prime_mmap

2016-04-22 Thread Joonyoung Shim
This allows exported dma-bufs to be mapped using gem_prime_mmap. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_drv.c | 1 + drivers/gpu/drm/exynos/exynos_drm_gem.c | 45 +++-- drivers/gpu/drm/exynos/exynos_drm_gem.h | 2 ++ 3 files changed, 35

[PATCH v3 5/7] drm/exynos: mixer: refactor layer setup

2015-12-18 Thread Joonyoung Shim
+Cc Boram Park, On 12/18/2015 12:54 AM, Marek Szyprowski wrote: > Hi Joonyoung, > > On 2015-12-17 05:19, Joonyoung Shim wrote: >> Hi Marek, >> >> On 12/16/2015 09:21 PM, Marek Szyprowski wrote: >>> Properly configure blending properties of given hardware l

[PATCH v3 2/7] drm/exynos: make zpos property configurable

2015-12-18 Thread Joonyoung Shim
On 12/17/2015 10:05 PM, Marek Szyprowski wrote: > Hello, > > On 2015-12-17 03:55, Joonyoung Shim wrote: >> +Cc: Boram Park, >> >> Hi Marek, >> >> On 12/16/2015 09:21 PM, Marek Szyprowski wrote: >>> This patch adds all infrastructure to make zpo

[PATCH v3 5/7] drm/exynos: mixer: refactor layer setup

2015-12-17 Thread Joonyoung Shim
Hi Marek, On 12/16/2015 09:21 PM, Marek Szyprowski wrote: > Properly configure blending properties of given hardware layer based on > the selected pixel format. Currently only per-pixel-based alpha is possible > when respective pixel format has been selected. Configuration of global, > per-plane a

[PATCH v3 2/7] drm/exynos: make zpos property configurable

2015-12-17 Thread Joonyoung Shim
+Cc: Boram Park, Hi Marek, On 12/16/2015 09:21 PM, Marek Szyprowski wrote: > This patch adds all infrastructure to make zpos plane property > configurable from userspace. > > Signed-off-by: Marek Szyprowski > --- > drivers/gpu/drm/exynos/exynos_drm_drv.h | 4 ++- > drivers/gpu/drm/exynos/ex

drm/exynos: when to call dma_map_sg() on a GEM object?

2015-11-02 Thread Joonyoung Shim
On 10/31/2015 05:44 AM, Tobias Jakobi wrote: > Hey there, > > this question arose during some discussion with someone concerning the > Exynos mixer and G2D. > > The question is the following. Consider the Exynos mixer when run under > the IOMMU (that's sysmmu_tv IIRC). What exactly does setup the

[PATCH 6/9] drm/exynos: switch to new buffer allocation

2015-10-20 Thread Joonyoung Shim
On 10/19/2015 09:20 PM, Inki Dae wrote: > Hi, > > How about combining patch 5 and 6? > > Patch 5 just introduces new internal API but these API aren't used anywhere > in patch 5. > I split it to be easy to understand changes of codes on patch file. It's no matter to me to combine them. Anyway

[PATCH 0/9] drm/exynos: update codes related with gem

2015-10-14 Thread Joonyoung Shim
On 10/13/2015 09:29 PM, Daniel Vetter wrote: > On Tue, Oct 13, 2015 at 06:32:53PM +0900, Joonyoung Shim wrote: >> On 10/13/2015 05:37 PM, Joonyoung Shim wrote: >>> On 10/13/2015 05:27 PM, Daniel Vetter wrote: >>>> On Tue, Oct 13, 2015 at 04:00:45PM +0900,

[PATCH] drm/exynos/gem: remove DMA-mapping hacks used for constructing page array

2015-10-13 Thread Joonyoung Shim
Hi Marek, On 10/13/2015 07:22 PM, Marek Szyprowski wrote: > Exynos GEM objects contains an array of pointers to the pages, which the > allocated buffer consists of. Till now the code used some hacks (like > relying on DMA-mapping internal structures or using ARM-specific > dma_to_pfn helper) to bu

[PATCH 0/9] drm/exynos: update codes related with gem

2015-10-13 Thread Joonyoung Shim
On 10/13/2015 05:37 PM, Joonyoung Shim wrote: > On 10/13/2015 05:27 PM, Daniel Vetter wrote: >> On Tue, Oct 13, 2015 at 04:00:45PM +0900, Joonyoung Shim wrote: >>> Hi, >>> >>> This patchset is about gem codes update of exynos-drm. >>> >>> The

[PATCH 0/9] drm/exynos: update codes related with gem

2015-10-13 Thread Joonyoung Shim
On 10/13/2015 05:27 PM, Daniel Vetter wrote: > On Tue, Oct 13, 2015 at 04:00:45PM +0900, Joonyoung Shim wrote: >> Hi, >> >> This patchset is about gem codes update of exynos-drm. >> >> The first and second patches are cleanup to remove useless codes. >&

[PATCH 9/9] drm/exynos: add ioctls for cpu access of gem object from user

2015-10-13 Thread Joonyoung Shim
. - DRM_IOCTL_EXYNOS_GEM_CPU_FINI Should be used explicitly after it is finished cpu access of gem object from user. Signed-off-by: Joonyoung Shim --- This is based on patch of Daniel dropping DRM_UNLOCKED flag on each drivers[1] and patch that is droped DRM_UNLOCKED flag from my posted patch[2]. [1] http

[PATCH 8/9] drm/exynos: use DMA_ERROR_CODE

2015-10-13 Thread Joonyoung Shim
The dma_addr of gem will be DMA_ERROR_CODE if gem is created and will keep DMA_ERROR_CODE if gem has EXYNOS_BO_NONCONTIG flag on non-iommu. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 24 +--- 1 file changed, 9 insertions(+), 15 deletions

[PATCH 7/9] drm/exynos: always use EXYNOS_BO_CONTIG flag on iommu

2015-10-13 Thread Joonyoung Shim
It doesn't care whether memory is continuous physically if iommu is supported but we will always use EXYNOS_BO_CONTIG flag on iommu, so it can mean that the memory is continuous memory for device. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c

[PATCH 6/9] drm/exynos: switch to new buffer allocation

2015-10-13 Thread Joonyoung Shim
ned-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 90 +++-- 1 file changed, 29 insertions(+), 61 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index d982d46b04da..163d113df1ab 10

[PATCH 5/9] drm/exynos: introduce buffer allocation using drm_gem_get/put_pages()

2015-10-13 Thread Joonyoung Shim
This introduces new functions to allocate/free buffer using drm_gem_get/put_pages() instead of DMA mapping API. They also use sg list to manage pages. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 48 + drivers/gpu/drm/exynos

[PATCH 4/9] drm/exynos: split buffer allocation using DMA mapping API on non-iommu

2015-10-13 Thread Joonyoung Shim
: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 90 +++-- 1 file changed, 64 insertions(+), 26 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index d5951f75c774..88196edd4ade 100644 --- a/drivers/gpu

[PATCH 3/9] drm/exynos: remove using non-consistent DMA attribute

2015-10-13 Thread Joonyoung Shim
DMA_ATTR_NON_CONSISTENT isn't supported in DMA mapping API of ARM, so it doesn't give any effects to use non-consistent DMA attribute. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 7 +-- 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/d

[PATCH 2/9] drm/exynos: use directly DMA mapping APIs on g2d

2015-10-13 Thread Joonyoung Shim
There is no reason to be wapper functions to use DMA mapping APIs. We can use directly DMA mapping APIs without locking and remove the wapper functions. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_g2d.c | 10 +- drivers/gpu/drm/exynos/exynos_drm_gem.c | 26

[PATCH 1/9] drm/exynos: eliminate useless codes of exynos_drm_gem.h

2015-10-13 Thread Joonyoung Shim
m_userptr_ioctl(), there is no body for them. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.h | 28 1 file changed, 28 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.h b/drivers/gpu/drm/exynos/exynos_drm_gem.h index 0d0ab27b48f

[PATCH 0/9] drm/exynos: update codes related with gem

2015-10-13 Thread Joonyoung Shim
ly in order for the cpu and device if buffer of gem object is cachable. Thanks. Joonyoung Shim (9): drm/exynos: eliminate useless codes of exynos_drm_gem.h drm/exynos: use directly DMA mapping APIs on g2d drm/exynos: remove using non-consistent DMA attribute drm/exynos: split buffer alloc

[PATCH] drm/exynos: add DRM_EXYNOS_GEM_MAP ioctl

2015-10-13 Thread Joonyoung Shim
On 10/13/2015 02:23 PM, Joonyoung Shim wrote: > On 10/13/2015 02:11 PM, Inki Dae wrote: >> >> Merged. >> > > Thanks for merge but this will be conflicted with the patch of Daniel, > http://patchwork.freedesktop.org/patch/60565/ > Oops, wrong link, http://lis

[PATCH] drm/exynos: add DRM_EXYNOS_GEM_MAP ioctl

2015-10-13 Thread Joonyoung Shim
, > Inki Dae > > 2015년 10월 05일 12:04에 Joonyoung Shim 이(가) 쓴 글: >> The commit d931589c01a2 ("drm/exynos: remove DRM_EXYNOS_GEM_MAP_OFFSET >> ioctl") removed it same with the ioctl that this patch adds. The reason >> that removed DRM_EXYNOS_GEM_MAP_OFFSET

[PATCH] drm/exynos: add DRM_EXYNOS_GEM_MAP ioctl

2015-10-05 Thread Joonyoung Shim
vive it as DRM_EXYNOS_GEM_MAP because of render node. DRM_IOCTL_MODE_MAP_DUMB isn't permitted in render node. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_drv.c | 2 ++ drivers/gpu/drm/exynos/exynos_drm_gem.c | 9 + drivers/gpu/drm/exynos/exynos_drm_gem.h | 4 i

[PATCH] drm/exynos: cleanup name of gem object for exynos_drm

2015-10-02 Thread Joonyoung Shim
isunderstanding with variable name "obj" of struct drm_gem_object. This will clean about name of gem object for exynos_drm as follows. s/struct exynos_drm_gem_obj/struct exynos_drm_gem s/exynos_gem_obj or gem_obj or obj/exynos_gem Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos

[PATCH] drm/exynos: fix to detach device of iommu

2015-10-02 Thread Joonyoung Shim
to release mapping of iommu created by arm_iommu_create_mapping(). It is called by exynos_drm_unload() so shouldn't be called by drm_iommu_detach_device(). Signed-off-by: Joonyoung Shim Cc: # v3.8+ --- drivers/gpu/drm/exynos/exynos_drm_iommu.c | 3 +-- 1 file changed, 1 insertion(

[PATCH 09/14] drm/exynos: remove call to drm_gem_free_mmap_offset()

2015-09-30 Thread Joonyoung Shim
On 09/25/2015 06:15 PM, Inki Dae wrote: > On 2015년 09월 24일 10:01, Joonyoung Shim wrote: >> Hi Inki, >> >> On 08/17/2015 06:03 PM, Inki Dae wrote: >>> On 2015년 08월 17일 17:17, Joonyoung Shim wrote: >>>> On 08/17/2015 04:52 PM, Inki Dae wrote: >

[PATCH 09/14] drm/exynos: remove call to drm_gem_free_mmap_offset()

2015-09-24 Thread Joonyoung Shim
Hi Inki, On 08/17/2015 06:03 PM, Inki Dae wrote: > On 2015년 08월 17일 17:17, Joonyoung Shim wrote: >> On 08/17/2015 04:52 PM, Inki Dae wrote: >>> On 2015년 08월 17일 14:29, Joonyoung Shim wrote: >>>> On 08/16/2015 02:07 PM, Inki Dae wrote: >>>>>

[PATCH] drm/exynos: get event time from ktime

2015-09-16 Thread Joonyoung Shim
On 09/16/2015 02:31 PM, Joonyoung Shim wrote: > G2D and IPP drivers get event time from do_gettimeofday(), but drm > vblank event gets it from ktime. Use ktime for consistency. Oops, this causes build errors, please ignore, i will retry. Thanks. > > Signed-off-by: Jo

[PATCH] drm/exynos: get event time from ktime

2015-09-16 Thread Joonyoung Shim
G2D and IPP drivers get event time from do_gettimeofday(), but drm vblank event gets it from ktime. Use ktime for consistency. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_g2d.c | 4 +++- drivers/gpu/drm/exynos/exynos_drm_ipp.c | 4 +++- 2 files changed, 6 insertions

[PATCH 4/4] drm/exynos: cleanup line feed in exynos_drm_gem_get_ioctl

2015-09-16 Thread Joonyoung Shim
The beginning of statement in function is next line of a brace. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c

[PATCH 3/4] drm/exynos: cleanup function calling written twice

2015-09-16 Thread Joonyoung Shim
By if statment, some function callings are written twice. It needs several line feed by indentation in if statment. Make to one function calling from outside if statment. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 56 ++--- 1 file

[PATCH 2/4] drm/exynos: staticize exynos_drm_gem_init()

2015-09-16 Thread Joonyoung Shim
The exynos_drm_gem_init() is used only in exynos_drm_gem.c file. Make it static and don't export it. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 +-- drivers/gpu/drm/exynos/exynos_drm_gem.h | 4 2 files changed, 1 insertion(+), 6 deletions(-) diff --

[PATCH 1/4] drm/exynos: remove unnecessary NULL assignment

2015-09-16 Thread Joonyoung Shim
They will be freed right or was freed already, so NULL assignment is unnecessary. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c

[PATCH 0/4] drm/exynos: small cleanup for exynos_drm_gem

2015-09-16 Thread Joonyoung Shim
Hi, This patchset is small cleanup about exynos_drm_gem codes of exynos-drm driver. This removes unnecessary and redundant codes, and staticize a local function. Thanks. Joonyoung Shim (4): drm/exynos: remove unnecessary NULL assignment drm/exynos: staticize exynos_drm_gem_init

[PATCH] drm/exynos: fix layering violation of address

2015-09-16 Thread Joonyoung Shim
There is no guarantee that DMA addresses are the same as physical addresses, but dma_to_pfn() knows how to convert a dma_addr_t to a PFN which can then be converted to a struct page. Suggested-by: Russell King Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 ++- 1

[PATCH] drm/exynos: fix missed calling of drm_prime_gem_destroy()

2015-09-16 Thread Joonyoung Shim
rt() to import dma-bufs, so exynos-drm driver using drm_gem_prime_import() needs calling drm_prime_gem_destroy(). Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 9 + drivers/gpu/drm/exynos/exynos_drm_gem.h | 2 ++ 2 files changed, 7 insertions(+), 4 deletion

[PATCH 9/9] drm/exynos: remove buf_cnt from struct exynos_drm_fb

2015-09-01 Thread Joonyoung Shim
-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c | 9 - 1 file changed, 9 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_fb.c b/drivers/gpu/drm/exynos/exynos_drm_fb.c index d2e746e..6d1b70e 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_fb.c +++ b/drivers

[PATCH 8/9] drm/exynos: remove exynos_drm_fb_get_buf_cnt()

2015-09-01 Thread Joonyoung Shim
We can get buffer count of framebuffer using drm_format_num_planes(), so keeping exynos_drm_fb_get_buf_cnt() is unnecessary. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c| 9 - drivers/gpu/drm/exynos/exynos_drm_fb.h| 3 --- drivers/gpu/drm/exynos

[PATCH 7/9] drm/exynos: cleanup exynos_user_fb_create()

2015-09-01 Thread Joonyoung Shim
Using exynos_drm_framebuffer_init(), redundant codes can be removed. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c | 47 ++ 1 file changed, 13 insertions(+), 34 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_fb.c b

[PATCH 6/9] drm/exynos: update exynos_drm_framebuffer_init() for multiple buffers

2015-09-01 Thread Joonyoung Shim
This modifies exynos_drm_framebuffer_init() to be possible to support multiple buffers. Then it can be used by exynos_user_fb_create(). Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c| 36 +-- drivers/gpu/drm/exynos/exynos_drm_fb.h

[PATCH 5/9] drm/exynos: cleanup to get gem object for fb

2015-09-01 Thread Joonyoung Shim
Current codes get first gem object and then again get remain gem objects. They can be unified to one routine. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fb.c | 23 --- 1 file changed, 8 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm

[PATCH 4/9] drm/exynos: update fb_info via only one function

2015-09-01 Thread Joonyoung Shim
This patch moves codes to update fb_info into exynos_drm_fbdev_update(), so fb_info is updated via only one function. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 29 + 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a

[PATCH 3/9] drm/exynos: cleanup exynos_drm_fbdev_update()

2015-09-01 Thread Joonyoung Shim
It can get exynos_gem object via function argument, so no need to call exynos_drm_fb_gem_obj() in exynos_drm_fbdev_update. It also can get struct drm_framebuffer *fb via helper->fb, so can remove a function argument for it. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exy

[PATCH 2/9] drm/exynos: s/exynos_gem_obj/obj in exynos_drm_fbdev.c

2015-09-01 Thread Joonyoung Shim
The variable name "exynos_gem_obj" is too long, so some lines exceed 80 characters. It's simple to use "obj" instead of "exynos_gem_obj". Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fbdev.c | 30 ++ 1

[PATCH 1/9] drm/exynos: remove exynos_drm_fb_set_buf_cnt()

2015-09-01 Thread Joonyoung Shim
The exynos_drm_fb_set_buf_cnt() is used to set buffer count only in exynos_drm_fbdev_update(). This patch sets directly buffer count in exynos_drm_framebuffer_init() without using exynos_drm_fb_set_buf_cnt(), so there is no any reason to keep exynos_drm_fb_set_buf_cnt(). Signed-off-by: Joonyoung

[PATCH 0/9] drm/exynos: cleanup patchset for exynos_drm_fb/fbdev

2015-09-01 Thread Joonyoung Shim
Hi, This patchset is for cleanup about fb and fbdev codes of exynos-drm driver. This removes unnecesary and redundant codes mostly, and make a variable having too long name to be short. Thanks. Joonyoung Shim (9): drm/exynos: remove exynos_drm_fb_set_buf_cnt() drm/exynos: s

[PATCH] drm/exynos: fix exynos_drm_gem_prime_import_sg_table() error handling

2015-09-01 Thread Joonyoung Shim
On 08/31/2015 01:10 AM, Inki Dae wrote: > 2015-08-27 17:31 GMT+09:00 Joonyoung Shim : >> If exynos_drm_gem_init() is failed, the result is ERR_PTR, so we should >> just return the result. If not, wrong porinter will be referenced from >> err label. >> >> Reported

[PATCH] drm/exynos: fix exynos_drm_gem_prime_import_sg_table() error handling

2015-08-27 Thread Joonyoung Shim
If exynos_drm_gem_init() is failed, the result is ERR_PTR, so we should just return the result. If not, wrong porinter will be referenced from err label. Reported-by: Dan Carpenter Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 6 ++ 1 file changed, 2

[PATCH 09/14] drm/exynos: remove call to drm_gem_free_mmap_offset()

2015-08-17 Thread Joonyoung Shim
On 08/17/2015 04:52 PM, Inki Dae wrote: > On 2015년 08월 17일 14:29, Joonyoung Shim wrote: >> On 08/16/2015 02:07 PM, Inki Dae wrote: >>> On 2015년 07월 28일 17:53, Joonyoung Shim wrote: >>>> The drm_gem_object_release() function already performs this cleanup,

[PATCH 09/14] drm/exynos: remove call to drm_gem_free_mmap_offset()

2015-08-17 Thread Joonyoung Shim
On 08/16/2015 02:07 PM, Inki Dae wrote: > On 2015년 07월 28일 17:53, Joonyoung Shim wrote: >> The drm_gem_object_release() function already performs this cleanup, >> so there is no reason to do it explicitly. >> >> Signed-off-by: Joonyoung Shim >&g

[PATCH 08/14] drm/exynos: create a fake mmap offset with gem creation

2015-08-17 Thread Joonyoung Shim
On 08/16/2015 01:50 PM, Inki Dae wrote: > On 2015년 07월 28일 17:53, Joonyoung Shim wrote: >> Don't create a fake mmap offset in exynos_drm_gem_dumb_map_offset. If >> not, it will call drm_gem_create_mmap_offset whenever user requests >> DRM_IOCTL_MODE_MAP_DUMB io

[PATCH 10/14] drm/exynos: remove function check_gem_flags

2015-08-11 Thread Joonyoung Shim
On 08/06/2015 07:00 PM, Daniel Stone wrote: > Hi Joonyoung, > > On 28 July 2015 at 09:53, Joonyoung Shim wrote: >> static void update_vm_cache_attr(struct exynos_drm_gem_obj *obj, >> struct vm_area_struct *vma) >> { >

[PATCH 14/14] drm/exynos: merge exynos_drm_buf.c to exynos_drm_gem.c

2015-07-28 Thread Joonyoung Shim
The struct exynos_drm_gem_obj can have fields of the struct exynos_drm_gem_buf then don't need to use exynos_drm_buf.c file. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/Makefile | 3 +- drivers/gpu/drm/exynos/exynos_drm_buf.c | 170 dr

[PATCH 13/14] drm/exynos: use prime helpers

2015-07-28 Thread Joonyoung Shim
The dma-buf codes of exynos drm is almost same with prime helpers. A difference is that consider DMA_NONE when import dma-buf, but it's wrong and we don't consider it any more, so we can use prime interface. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/Makefile

[PATCH 12/14] drm/exynos: remove function roundup_gem_size

2015-07-28 Thread Joonyoung Shim
The function roundup_gem_size can be merged in exynos_drm_gem_create. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 9 + 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos

[PATCH 11/14] drm/exynos: remove function update_vm_cache_attr

2015-07-28 Thread Joonyoung Shim
The function update_vm_cache_attr can be merged in exynos_drm_gem_mmap. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 28 +++- 1 file changed, 11 insertions(+), 17 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers

[PATCH 10/14] drm/exynos: remove function check_gem_flags

2015-07-28 Thread Joonyoung Shim
The function check_gem_flags is too simple, so it's better to move codes in each consumer functions. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 24 1 file changed, 8 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/e

[PATCH 09/14] drm/exynos: remove call to drm_gem_free_mmap_offset()

2015-07-28 Thread Joonyoung Shim
The drm_gem_object_release() function already performs this cleanup, so there is no reason to do it explicitly. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu

[PATCH 08/14] drm/exynos: create a fake mmap offset with gem creation

2015-07-28 Thread Joonyoung Shim
Don't create a fake mmap offset in exynos_drm_gem_dumb_map_offset. If not, it will call drm_gem_create_mmap_offset whenever user requests DRM_IOCTL_MODE_MAP_DUMB ioctl. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 12 +++- 1 file changed, 7 inser

[PATCH 07/14] drm/exynos: use ERR_PTR instead of NULL in exynos_drm_gem_init

2015-07-28 Thread Joonyoung Shim
For more correct error information. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index 8fffc4d..550d267

[PATCH 06/14] drm/exynos: remove unused fields of struct exynos_drm_gem_buf

2015-07-28 Thread Joonyoung Shim
The userptr, write and pfnmap of struct exynos_drm_gem_buf are not used anywhere. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.h | 7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.h b/drivers/gpu/drm/exynos

[PATCH 05/14] drm/exynos: stop copying sg table

2015-07-28 Thread Joonyoung Shim
Already struct exynos_drm_gem_buf has pages of the buffer, so we don't need to copy from sg table of the buffer to sg table of dma-buf attachment, just can make sg table from pages of the buffer. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_dmabuf.c

[PATCH 04/14] drm/exynos: remove function exynos_drm_gem_map_buf

2015-07-28 Thread Joonyoung Shim
The exynos_drm_gem_map_buf can be merged in exynos_drm_gem_fault. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 36 +++-- 1 file changed, 12 insertions(+), 24 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers

[PATCH 03/14] drm/exynos: remove mutex locking in pagefault handler

2015-07-28 Thread Joonyoung Shim
There is no reason to use mutex locking in pagefault handler. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index 752cb7c

[PATCH 02/14] drm/exynos: remove function convert_to_vm_err_msg

2015-07-28 Thread Joonyoung Shim
The convert_to_vm_err_msg is called just once by exynos_drm_gem_fault, so it's simple not to use the function. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_gem.c | 33 + 1 file changed, 9 insertions(+), 24 deletions(-) diff --git a/dr

[PATCH 01/14] drm/exynos: stop using sgtable in page fault handler

2015-07-28 Thread Joonyoung Shim
Already struct exynos_drm_gem_buf has pages of the buffer when buffer is created, so just can use pages in page fault handler, we don't have to make sgtable of the buffer. But this needs to construct pages of the buffer that is imported from dma-buf prime. Signed-off-by: Joonyoung

[PATCH 00/14] drm/exynos: cleanup and update gem/dma-buf

2015-07-28 Thread Joonyoung Shim
This patchset improves gem and dma-buf codes of exynos drm. Major changes: - remove needless using sg table. - use prime helpers instead of exynos specific dma-buf functions. - merge struct exynos_drm_gem_buf in struct exynos_drm_gem. - remove simple functions. - cleanup. Thanks. Joonyoung

[PATCH v2] drm/exynos: clear channels only when iommu is enabled

2015-07-28 Thread Joonyoung Shim
1/404 Reported-by: Krzysztof Kozlowski Signed-off-by: Joonyoung Shim --- v2: add Reported-by. drivers/gpu/drm/exynos/exynos_drm_fimd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c

[PATCH] drm/exynos: clear channels only when iommu is enabled

2015-07-28 Thread Joonyoung Shim
On 07/28/2015 05:30 PM, Krzysztof Kozlowski wrote: > On 28.07.2015 17:28, Joonyoung Shim wrote: >> This is simplest solution about reported problem[1]. It's no problem to >> clear channel only when iommu is enabled, if we consider that we cannot >> recognize iommu errors

[PATCH] drm/exynos: clear channels only when iommu is enabled

2015-07-28 Thread Joonyoung Shim
1/404 Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_fimd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_fimd.c b/drivers/gpu/drm/exynos/exynos_drm_fimd.c index 8d362b9..337af02 100644 --- a/drivers/gpu/drm/e

Linux-next, Exynos Octa boot fail, bisected to: "drm/exynos: remove drm_iommu_attach_device_if_possible"

2015-07-22 Thread Joonyoung Shim
On 07/22/2015 05:22 PM, Inki Dae wrote: > On 2015년 07월 22일 17:12, Joonyoung Shim wrote: >> On 07/22/2015 01:55 PM, Inki Dae wrote: >>> On 2015년 07월 22일 11:02, Joonyoung Shim wrote: >>>> On 07/21/2015 10:19 PM, Krzysztof Kozlowski wrote: >>>>

Linux-next, Exynos Octa boot fail, bisected to: "drm/exynos: remove drm_iommu_attach_device_if_possible"

2015-07-22 Thread Joonyoung Shim
On 07/22/2015 01:55 PM, Inki Dae wrote: > On 2015년 07월 22일 11:02, Joonyoung Shim wrote: >> On 07/21/2015 10:19 PM, Krzysztof Kozlowski wrote: >>> Hi, >>> >>> Today's linux-next (next-20150721) encounters boot failures on Exynos >>> Octa (Exyn

Linux-next, Exynos Octa boot fail, bisected to: "drm/exynos: remove drm_iommu_attach_device_if_possible"

2015-07-22 Thread Joonyoung Shim
rst bad commit > commit d80167b85024982c5f18d0481a5c248100360118 > Author: Joonyoung Shim > Date: Thu Jul 2 21:49:39 2015 +0900 > > drm/exynos: remove drm_iommu_attach_device_if_possible > > Already drm_iommu_attach_device checks whether support iommu internally. > It should

[PATCH libdrm] remove if HAVE_LIBUDEV for vbltest

2015-07-20 Thread Joonyoung Shim
The vbltest doesn't have any dependency of LIBUDEV. Signed-off-by: Joonyoung Shim --- tests/Makefile.am | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/tests/Makefile.am b/tests/Makefile.am index 069285f..c5edec8 100644 --- a/tests/Makefile.am +++ b/tests/Makefi

[PATCH] drm/exynos: move order to register vidi kms driver

2015-07-15 Thread Joonyoung Shim
The vidi is virtual kms driver and now it is registered earlier than actual hw kms drivers, so it will occupy crtc index 0. Some users assume the condition yet that actual hw kms driver has crtc index 0. It may or may not be matter but let's arrange register order. Signed-off-by: Joonyoung

[PATCH v2 00/23] drm/exynos: atomic improvements + exynos_encoder removal

2015-07-14 Thread Joonyoung Shim
ror 1 If you post the stuff that only be related, it will be reviewed and merged easier. 01-04 and 06-11 patches look good to me, about them, Reviewed-by: Joonyoung Shim > > > v2: Fix comments by Joonyoung

[PATCH 0/7] drm/exynos/hdmi: refactoring/cleanup patches

2015-07-14 Thread Joonyoung Shim
hdmi_v14_conf struct > > drivers/gpu/drm/exynos/exynos_hdmi.c | 860 > ++- > 1 file changed, 245 insertions(+), 615 deletions(-) > Looks good to me about this patchset, Reviewed-by: Joonyoung Shim

[PATCH v2 12/23] drm/exynos: don't track enabled state at exynos_crtc

2015-07-10 Thread Joonyoung Shim
On 07/10/2015 07:56 AM, Gustavo Padovan wrote: > 2015-07-09 Joonyoung Shim : > >> +Cc Andrzej, >> >> On 07/07/2015 02:41 AM, Daniel Vetter wrote: >>> On Mon, Jul 06, 2015 at 11:20:13AM -0300, Gustavo Padovan wrote: >>>> From: Gustavo Padovan >>

[PATCH RESEND v2 2/6] drm/exynos/mixer: fix interrupt clearing

2015-07-09 Thread Joonyoung Shim
* clear interrupts */ > - if (~val & MXR_INT_EN_VSYNC) { > - /* vsync interrupt use different bit for read and clear */ > - val &= ~MXR_INT_EN_VSYNC; > - val |= MXR_INT_CLEAR_VSYNC; > - } > mixer_reg_write(res, MXR_INT_STATUS, val); > > spin_unlock(&res->reg_slock); > Reviewed-by: Joonyoung Shim Thanks.

[PATCH v2 12/23] drm/exynos: don't track enabled state at exynos_crtc

2015-07-09 Thread Joonyoung Shim
+Cc Andrzej, On 07/07/2015 02:41 AM, Daniel Vetter wrote: > On Mon, Jul 06, 2015 at 11:20:13AM -0300, Gustavo Padovan wrote: >> From: Gustavo Padovan >> >> struct drm_crtc already stores the enabled state of the crtc >> thus we don't need to replicate enabled in exynos_drm_crtc. >> I think exyno

[PATCH RESEND 0/6] drm/exynos: HDMI related fixes

2015-07-09 Thread Joonyoung Shim
ertions(+), 51 deletions(-) > Looks good to me except one comment of "drm/exynos/mixer: fix interrupt clearing" patch. Also below my patch can be dropped by this patchset. http://www.spinics.net/lists/dri-devel/msg85322.html Reviewed-by: Joonyoung Shim

[PATCH RESEND 2/6] drm/exynos/mixer: fix interrupt clearing

2015-07-09 Thread Joonyoung Shim
On 07/09/2015 03:25 PM, Andrzej Hajda wrote: > The driver used incorrect flags to clear interrupt status. > The patch fixes it. > > Signed-off-by: Andrzej Hajda > --- > drivers/gpu/drm/exynos/exynos_mixer.c | 8 +++- > 1 file changed, 3 insertions(+), 5 deletions(-) > > diff --git a/drivers

[PATCH 19/23] drm/exynos: remove extra call to exynos_dp_commit()

2015-07-03 Thread Joonyoung Shim
Hi Hyungwon, On 07/02/2015 09:39 PM, Joonyoung Shim wrote: > +Cc Hyungwon, > > On 06/24/2015 06:35 AM, Gustavo Padovan wrote: >> From: Gustavo Padovan >> >> exynos_dp_commit() was getting called twice by exynos encoder core, once >> inside the .enable() call and

[PATCH 3/3] drm/exynos: remove drm_iommu_attach_device_if_possible

2015-07-02 Thread Joonyoung Shim
can remove drm_iommu_attach_device_if_possible and clear_channels function pointer. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 5 +++-- drivers/gpu/drm/exynos/exynos7_drm_decon.c| 5 +++-- drivers/gpu/drm/exynos/exynos_drm_drv.h | 1 - drivers/gpu/

[PATCH 2/3] drm/exynos: remove unnecessary checking to support iommu

2015-07-02 Thread Joonyoung Shim
Already drm_iommu_attach_device and drm_iommu_detach_device check whether support iommu internally, so we don't have to call is_drm_iommu_supported before call them. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos5433_drm_decon.c | 3 +-- drivers/gpu/drm/e

[PATCH 1/3] drm/exynos: remove to use ifdef CONFIG_ARM_DMA_USE_IOMMU

2015-07-02 Thread Joonyoung Shim
If CONFIG_ARM_DMA_USE_IOMMU is disable, CONFIG_DRM_EXYNOS_IOMMU also is disable. When CONFIG_DRM_EXYNOS_IOMMU is disable, is_drm_iommu_supported() returns always false, so we can remove to use ifdef CONFIG_ARM_DMA_USE_IOMMU in is_drm_iommu_supported(). Signed-off-by: Joonyoung Shim --- drivers

[PATCH] drm/exynos: fix vsync interrupt clear routine of mixer

2015-07-02 Thread Joonyoung Shim
manual. Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_mixer.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_mixer.c b/drivers/gpu/drm/exynos/exynos_mixer.c index cae98db..60538bf 100644 --- a/drivers/gpu/drm/exynos

[PATCH] drm/exynos: fix compile error and warning of g2d

2015-07-02 Thread Joonyoung Shim
Wmaybe-uninitialized] int ret; ^ Signed-off-by: Joonyoung Shim --- drivers/gpu/drm/exynos/exynos_drm_g2d.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_g2d.c b/drivers/gpu/drm/exynos/exynos_drm_g2d.c index 810e1ee..7584834 100644 --- a/d

[PATCH] drm/exynos: iommu: fix potential NULL pointer dereference

2015-07-02 Thread Joonyoung Shim
On 06/29/2015 03:35 PM, Hyungwon Hwang wrote: > Dear Marek, > > On Thu, 25 Jun 2015 15:10:12 +0200 > Marek Szyprowski wrote: > >> Some drivers (like Exynos mixer) calls >> drm_iommu_attach_device_if_possible before registering crtc, so >> additional check for NULL crtc pointer is required. > >

[PATCH 00/23] drm/exynos: atomic improvements + exynos_encoder removal

2015-07-02 Thread Joonyoung Shim
Hi Gustavo, On 06/24/2015 06:35 AM, Gustavo Padovan wrote: > From: Gustavo Padovan > > Hi, > > This set improves exynos in a number of ways. The first five patches are > general clean up/fixes. > > Patches 06 to 12 are improvements on top of the newly added atomic modesetting > support. I'm n

[PATCH 19/23] drm/exynos: remove extra call to exynos_dp_commit()

2015-07-02 Thread Joonyoung Shim
+Cc Hyungwon, On 06/24/2015 06:35 AM, Gustavo Padovan wrote: > From: Gustavo Padovan > > exynos_dp_commit() was getting called twice by exynos encoder core, once > inside the .enable() call and another time by .commit() itself. > > The remove of the second call caused the wake of a bug, the ope

  1   2   3   4   5   6   >