Re: [PATCH v3] drm/amd: Fix memory leak according to error branch

2020-06-22 Thread Markus Elfring
> The function kobject_init_and_add alloc memory like: > kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs > ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller > ->kmalloc_slab, in err branch this memory not free. If use > kmemleak, this path maybe catched. > These change

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 06:19:41PM +0200, Daniel Vetter wrote: > The madness is only that device B's mmu notifier might need to wait > for fence_B so that the dma operation finishes. Which in turn has to > wait for device A to finish first. So, it sound, fundamentally you've got this graph of ope

[PATCH v2] dmabuf: use spinlock to access dmabuf->name

2020-06-22 Thread Charan Teja Kalla
There exists a sleep-while-atomic bug while accessing the dmabuf->name under mutex in the dmabuffs_dname(). This is caused from the SELinux permissions checks on a process where it tries to validate the inherited files from fork() by traversing them through iterate_fd() (which traverse files under

Re: [PATCH] mm: Track mmu notifiers in fs_reclaim_acquire/release

2020-06-22 Thread Qian Cai
On Wed, Jun 10, 2020 at 09:41:01PM +0200, Daniel Vetter wrote: > fs_reclaim_acquire/release nicely catch recursion issues when > allocating GFP_KERNEL memory against shrinkers (which gpu drivers tend > to use to keep the excessive caches in check). For mmu notifier > recursions we do have lockdep a

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 02:09:35PM -0400, Jerome Glisse wrote: > On Fri, Jun 19, 2020 at 02:23:08PM -0300, Jason Gunthorpe wrote: > > On Fri, Jun 19, 2020 at 06:19:41PM +0200, Daniel Vetter wrote: > > > > > The madness is only that device B's mmu notifier might need to wait > > > for fence_B so th

[PATCH v1 07/11] soc: mediatek: cmdq: add write_s_mask value function

2020-06-22 Thread Dennis YC Hsieh
add write_s_mask_value function in cmdq helper functions which writes a constant value to address with mask and large dma access support. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 21 + include/linux/soc/mediatek/mtk-cmdq.h | 15

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 03:30:32PM -0400, Felix Kuehling wrote: > We have a potential problem with CPU updating page tables while the GPU > is retrying on page table entries because 64 bit CPU transactions don't > arrive in device memory atomically. Except for 32 bit platforms atomicity is guarent

Re: [PATCH v4 3/5] drm: panel: Add Xingbangda XBD599 panel (ST7703 controller)

2020-06-22 Thread Ondřej Jirman
On Sat, Jun 20, 2020 at 11:25:29PM +0200, Sam Ravnborg wrote: > Hi Ondrej et al. > > On Wed, Jun 17, 2020 at 02:32:07AM +0200, Ondrej Jirman wrote: > > From: Icenowy Zheng > > > > Xingbangda XBD599 is a 5.99" 720x1440 MIPI-DSI IPS LCD panel made by > > Xingbangda, which is used on PinePhone fina

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 05:06:04PM +0200, Daniel Vetter wrote: > On Fri, Jun 19, 2020 at 1:39 PM Jason Gunthorpe wrote: > > > > On Fri, Jun 19, 2020 at 09:22:09AM +0200, Daniel Vetter wrote: > > > > As I've understood GPU that means you need to show that the commands > > > > associated with the bu

Re: [PATCH v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Markus Elfring
> The function kobject_init_and_add alloc memory like: > kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs > ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller > ->kmalloc_slab, in err branch this memory not free. If use > kmemleak, this path maybe catched. > These change

Re: [PATCH 0/6] remove deprecated i2c_new_device API

2020-06-22 Thread Wolfram Sang
On Mon, Jun 15, 2020 at 09:58:09AM +0200, Wolfram Sang wrote: > I want to remove the above API this cycle, and just a few patches have > not made it into 5.8-rc1. They have been reviewed and most had been > promised to get into linux-next, but well, things happen. So, I hope it > is okay for everyo

[PATCH v1 05/11] soc: mediatek: cmdq: add read_s function

2020-06-22 Thread Dennis YC Hsieh
Add read_s function in cmdq helper functions which support read value from register or dma physical address into gce internal register. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 15 +++ include/linux/mailbox/mtk-cmdq-mailbox.h |1 + include/l

Re: [PATCH v8 7/7] drm/panel-simple: Add missing connector type for some panels

2020-06-22 Thread Dmitry Osipenko
20.06.2020 17:31, Sam Ravnborg пишет: > Hi Dmitry > >> >> Oops! Good catch! > Yep, thanks Laurent. Should have taken a better look before applying. > >> Indeed, I blindly set the LVDS type to all these >> panels. Please revert this patch, I'll double check each panel and >> prepare an updated ver

[PATCH] drm: fix double free for gbo in drm_gem_vram_init and drm_gem_vram_create

2020-06-22 Thread Jia Yang
I got a use-after-free report when doing some fuzz test: If ttm_bo_init() fails, the "gbo" and "gbo->bo.base" will be freed by ttm_buffer_object_destroy() in ttm_bo_init(). But then drm_gem_vram_create() and drm_gem_vram_init() will free "gbo" and "gbo->bo.base" again. BUG: KMSAN: use-after-free

[PATCH v1 03/11] soc: mediatek: cmdq: add write_s function

2020-06-22 Thread Dennis YC Hsieh
add write_s function in cmdq helper functions which writes value contains in internal register to address with large dma access support. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 19 +++ include/linux/mailbox/mtk-cmdq-mailbox.h |1 + incl

[PATCH] drm/mediatek: check plane visibility in atomic_update

2020-06-22 Thread Hsin-Yi Wang
Disable the plane if it's not visible. Otherwise mtk_ovl_layer_config() would proceed with invalid plane and we may see vblank timeout. Signed-off-by: Hsin-Yi Wang --- drivers/gpu/drm/mediatek/mtk_drm_plane.c | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-) diff -

Re: [PATCH v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Markus Elfring
>> I suggest to improve this change description. >> >> * Can an other wording variant be nicer? > > Markus's suggestion is as usual extremely imprecise. I pointed a general possibility out. I did not propose an exact wording alternative as it happened for other patches. > However, I also find th

Re: [PATCH v7 31/36] staging: tegra-vde: fix common struct sg_table related issues

2020-06-22 Thread Dmitry Osipenko
В Fri, 19 Jun 2020 12:36:31 +0200 Marek Szyprowski пишет: > The Documentation/DMA-API-HOWTO.txt states that the dma_map_sg() > function returns the number of the created entries in the DMA address > space. However the subsequent calls to the > dma_sync_sg_for_{device,cpu}() and dma_unmap_sg must

Re: [PATCH v3] drm/amd: Fix memory leak according to error branch

2020-06-22 Thread Julia Lawall
On Sat, 20 Jun 2020, Markus Elfring wrote: > > The function kobject_init_and_add alloc memory like: > > kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs > > ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller > > ->kmalloc_slab, in err branch this memory not free. If u

[PATCH v1 10/11] soc: mediatek: cmdq: add clear option in cmdq_pkt_wfe api

2020-06-22 Thread Dennis YC Hsieh
Add clear parameter to let client decide if event should be clear to 0 after GCE receive it. Signed-off-by: Dennis YC Hsieh Reviewed-by: CK Hu --- drivers/gpu/drm/mediatek/mtk_drm_crtc.c |2 +- drivers/soc/mediatek/mtk-cmdq-helper.c |5 +++-- include/linux/mailbox/mtk-cmdq-mailbox.h

[PATCH v1 2/2] drm/panel-simple: Add missing BUS descriptions for some panels

2020-06-22 Thread Dmitry Osipenko
This patch adds missing BUS fields to the display panel descriptions of the panels which are found on NVIDIA Tegra devices: 1. AUO B101AW03 2. Chunghwa CLAA070WP03XG 3. Chunghwa CLAA101WA01A 4. Chunghwa CLAA101WB01 5. Innolux N156BGE L21 6. Samsung LTN101NT05 Suggested-by: Laurent Pin

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 03:48:49PM -0400, Felix Kuehling wrote: > Am 2020-06-19 um 2:18 p.m. schrieb Jason Gunthorpe: > > On Fri, Jun 19, 2020 at 02:09:35PM -0400, Jerome Glisse wrote: > >> On Fri, Jun 19, 2020 at 02:23:08PM -0300, Jason Gunthorpe wrote: > >>> On Fri, Jun 19, 2020 at 06:19:41PM +02

[PATCH v1 1/2] drm/panel-simple: Correct EDT ET057090DHU connector type

2020-06-22 Thread Dmitry Osipenko
The EDT ET057090DHU panel has a DPI connector and not LVDS. This patch corrects the panel's description. Reported-by: Laurent Pinchart Fixes: 94f07917ebe8 ("drm/panel-simple: Add missing connector type for some panels") Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/panel/panel-simple.c |

[PATCH] drm/lima: Expose job_hang_limit module parameter

2020-06-22 Thread Andrey Lebedev
From: Andrey Lebedev Some pp or gp jobs can be successfully repeated even after they time outs. Introduce lima module parameter to specify number of times a job can hang before being dropped. Signed-off-by: Andrey Lebedev --- Now all types are correct (uint). drivers/gpu/drm/lima/lima_drv.c

[PATCH] video: fbdev: savage: fix memory leak on error handling path in probe

2020-06-22 Thread Evgeny Novikov
savagefb_probe() calls savage_init_fb_info() that can successfully allocate memory for info->pixmap.addr but then fail when fb_alloc_cmap() fails. savagefb_probe() goes to label failed_init and does not free allocated memory. It is not valid to go to label failed_mmio since savage_init_fb_info() ca

[PATCH v1 02/11] soc: mediatek: cmdq: add assign function

2020-06-22 Thread Dennis YC Hsieh
Add assign function in cmdq helper which assign constant value into internal register by index. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 24 +++- include/linux/mailbox/mtk-cmdq-mailbox.h |1 + include/linux/soc/mediatek/mtk-cmdq.h

Re: [PATCH 01/18] mm: Track mmu notifiers in fs_reclaim_acquire/release

2020-06-22 Thread Qian Cai
On Thu, Jun 04, 2020 at 10:12:07AM +0200, Daniel Vetter wrote: > fs_reclaim_acquire/release nicely catch recursion issues when > allocating GFP_KERNEL memory against shrinkers (which gpu drivers tend > to use to keep the excessive caches in check). For mmu notifier > recursions we do have lockdep a

[PATCH v1 0/2] Improve descriptions of a few simple-panels

2020-06-22 Thread Dmitry Osipenko
Hello, This is a follow up to [1], which was already applied to drm-misc and then Laurent Pinchart spotted some problems. This series addresses those problems. [1] https://patchwork.ozlabs.org/project/linux-tegra/patch/20200617222703.17080-8-dig...@gmail.com/ Dmitry Osipenko (2): drm/panel-si

Re: [PATCH] mm: Track mmu notifiers in fs_reclaim_acquire/release

2020-06-22 Thread Qian Cai
On Sun, Jun 21, 2020 at 10:01:03PM +0200, Daniel Vetter wrote: > On Sun, Jun 21, 2020 at 08:07:08PM +0200, Daniel Vetter wrote: > > On Sun, Jun 21, 2020 at 7:42 PM Qian Cai wrote: > > > > > > On Wed, Jun 10, 2020 at 09:41:01PM +0200, Daniel Vetter wrote: > > > > fs_reclaim_acquire/release nicely c

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 09:22:09AM +0200, Daniel Vetter wrote: > > As I've understood GPU that means you need to show that the commands > > associated with the buffer have completed. This is all local stuff > > within the driver, right? Why use fence (other than it already exists) > > Because that

[PATCH v1 09/11] soc: mediatek: cmdq: add jump function

2020-06-22 Thread Dennis YC Hsieh
Add jump function so that client can jump to any address which contains instruction. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 13 + include/linux/soc/mediatek/mtk-cmdq.h | 11 +++ 2 files changed, 24 insertions(+) diff --git a/drivers/

[PATCH v3] drm/amd: fix potential memleak in err branch

2020-06-22 Thread Bernard Zhao
The function kobject_init_and_add alloc memory like: kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller ->kmalloc_slab, in err branch this memory not free. If use kmemleak, this path maybe catched. These changes are to add

Re: [PATCH] drm/rockchip: vop: fix vop full rgb24 r/b color error

2020-06-22 Thread Huang Jiachai
Hi heiko, 在 2020/6/19 15:02, Heiko Stuebner 写道: Hi Sandy, Am Freitag, 19. Juni 2020, 04:12:51 CEST schrieb Sandy Huang: RGB888 format msb is red component and the lsb is blue component, at vop full platform this is swapped, and this is different from vop lite and vop next, so add this patch to

[PATCH] drm/amd: fix potential memleak in err branch

2020-06-22 Thread Bernard Zhao
The function kobject_init_and_add alloc memory like: kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller ->kmalloc_slab, in err branch this memory not free. If use kmemleak, this path maybe catched. These changes are to add

[PATCH v2] drm/rockchip: vop: fix vop full rgb24 r/b color error

2020-06-22 Thread Sandy Huang
RGB888 format msb is red component and the lsb is blue component, at vop full platform this is swapped, and this is different from vop lite and vop next, so add this patch to fix it. v2: move to has_rb_swapped() function. Signed-off-by: Sandy Huang --- drivers/gpu/drm/rockchip/rockchip_drm_

Re:Re: [PATCH v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Bernard
From: Julia Lawall Date: 2020-06-20 17:37:19 To: Markus Elfring Cc: Bernard Zhao ,opensource.ker...@vivo.com,amd-...@lists.freedesktop.org,dri-devel@lists.freedesktop.org,kernel-janit...@vger.kernel.org,linux-ker...@vger.kernel.org,Alex Deucher ,"Christian König" ,"Felix Kühling" ,Daniel

[PATCH v1 01/11] soc: mediatek: cmdq: add address shift in jump

2020-06-22 Thread Dennis YC Hsieh
Add address shift when compose jump instruction to compatible with 35bit format. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/soc/mediatek/mtk-cmdq-helper.c b/drivers/soc/mediatek/mtk-c

[PATCH v1 04/11] soc: mediatek: cmdq: add write_s_mask function

2020-06-22 Thread Dennis YC Hsieh
add write_s_mask function in cmdq helper functions which writes value contains in internal register to address with mask and large dma access support. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 23 +++ include/linux/mailbox/mtk-cmdq-mailbo

[PATCH v2] drm/amd: fix potential memleak in err branch

2020-06-22 Thread Bernard Zhao
The function kobject_init_and_add alloc memory like: kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller ->kmalloc_slab, in err branch this memory not free. If use kmemleak, this path maybe catched. These changes are to add

Re:Re: [PATCH v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Julia Lawall
On Sat, 20 Jun 2020, Bernard wrote: > > > From: Julia Lawall > Date: 2020-06-20 17:37:19 > To: Markus Elfring > Cc: Bernard Zhao > ,opensource.ker...@vivo.com,amd-...@lists.freedesktop.org,dri-devel@lists.freedesktop.org,kernel-janit...@vger.kernel.org,linux-ker...@vger.kernel.org,Alex > D

Re: [PATCH v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Julia Lawall
On Sat, 20 Jun 2020, Markus Elfring wrote: > > The function kobject_init_and_add alloc memory like: > > kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs > > ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller > > ->kmalloc_slab, in err branch this memory not free. If u

Re: [PATCH] drm/msm/dpu: Fix usage of ERR_PTR()

2020-06-22 Thread Zenghui Yu
ping for this obvious fix... On 2020/5/28 21:08, Zenghui Yu wrote: ERR_PTR() is used in the kernel to encode an usual *negative* errno code into a pointer. Passing a positive value (ENOMEM) to it will break the following IS_ERR() check. Though memory allocation is unlikely to fail, it's still

[PATCH v1 06/11] soc: mediatek: cmdq: add write_s value function

2020-06-22 Thread Dennis YC Hsieh
add write_s function in cmdq helper functions which writes a constant value to address with large dma access support. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 14 ++ include/linux/soc/mediatek/mtk-cmdq.h | 13 + 2 files changed, 27

Re: [PATCH] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Markus Elfring
> The function kobject_init_and_add alloc memory like: > kobject_init_and_add->kobject_add_varg->kobject_set_name_vargs > ->kvasprintf_const->kstrdup_const->kstrdup->kmalloc_track_caller > ->kmalloc_slab, in err branch this memory not free. If use > kmemleak, this path maybe catched. > These change

[PATCH v1 0/11] support cmdq helper function on mt6779 platform

2020-06-22 Thread Dennis YC Hsieh
This patch support cmdq helper function on mt6779 platform, based on "support gce on mt6779 platform" patchset. Dennis YC Hsieh (11): soc: mediatek: cmdq: add address shift in jump soc: mediatek: cmdq: add assign function soc: mediatek: cmdq: add write_s function soc: mediatek: cmdq: add

Re: [PATCH v8 7/7] drm/panel-simple: Add missing connector type for some panels

2020-06-22 Thread Dmitry Osipenko
20.06.2020 14:49, Laurent Pinchart пишет: > Hi Sam and Dmitry, > > On Sat, Jun 20, 2020 at 01:21:32PM +0200, Sam Ravnborg wrote: >> On Thu, Jun 18, 2020 at 01:27:03AM +0300, Dmitry Osipenko wrote: >>> The DRM panel bridge core requires connector type to be set up properly, >>> otherwise it rejects

[PATCH v1 08/11] soc: mediatek: cmdq: export finalize function

2020-06-22 Thread Dennis YC Hsieh
Export finalize function to client which helps append eoc and jump command to pkt. Let client decide call finalize or not. Signed-off-by: Dennis YC Hsieh Reviewed-by: CK Hu Acked-by: Chun-Kuang Hu --- drivers/gpu/drm/mediatek/mtk_drm_crtc.c |1 + drivers/soc/mediatek/mtk-cmdq-helper.c |

Re: [PATCH 01/18] mm: Track mmu notifiers in fs_reclaim_acquire/release

2020-06-22 Thread Qian Cai
On Sun, Jun 21, 2020 at 07:28:40PM +0200, Daniel Vetter wrote: > On Sun, Jun 21, 2020 at 7:01 PM Qian Cai wrote: > > > > On Thu, Jun 04, 2020 at 10:12:07AM +0200, Daniel Vetter wrote: > > > fs_reclaim_acquire/release nicely catch recursion issues when > > > allocating GFP_KERNEL memory against shr

Re: drivers/gpu/drm/panel/panel-samsung-ld9040.c:240:12: warning: stack frame size of 8312 bytes in function 'ld9040_prepare'

2020-06-22 Thread Vladimir Oltean
On Sat, 20 Jun 2020 at 21:22, kernel test robot wrote: > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git > master > head: 4333a9b0b67bb4e8bcd91bdd80da80b0ec151162 > commit: 79591b7db21d255db158afaa48c557dcab631a1c spi: Add a PTP system > timestamp to the transfer s

Re: [v2] drm/amdkfd: Fix memory leaks according to error branches

2020-06-22 Thread Markus Elfring
> memleak is also not an English word. Memory leak is only a few more > characters, and doesn't require the reader to make the small extra effort > to figure out what you mean. Would you like to achieve similar adjustments at any more places? How do you think about effects from a corresponding j

Re: [PATCH v8 7/7] drm/panel-simple: Add missing connector type for some panels

2020-06-22 Thread Dmitry Osipenko
20.06.2020 18:30, Sam Ravnborg пишет: > Hi Dmitry > On Sat, Jun 20, 2020 at 06:05:37PM +0300, Dmitry Osipenko wrote: >> 20.06.2020 17:31, Sam Ravnborg пишет: >>> Hi Dmitry >>> Oops! Good catch! >>> Yep, thanks Laurent. Should have taken a better look before applying. >>> Indeed, I bl

[PATCH RESEND v1] drm/meson: viu: fix setting the OSD burst length in VIU_OSD1_FIFO_CTRL_STAT

2020-06-22 Thread Martin Blumenstingl
The burst length is configured in VIU_OSD1_FIFO_CTRL_STAT[31] and VIU_OSD1_FIFO_CTRL_STAT[11:10]. The public S905D3 datasheet describes this as: - 0x0 = up to 24 per burst - 0x1 = up to 32 per burst - 0x2 = up to 48 per burst - 0x3 = up to 64 per burst - 0x4 = up to 96 per burst - 0x5 = up to 128 p

[PATCH v4] display/drm/bridge: TC358775 DSI/LVDS driver

2020-06-22 Thread Vinay Simha BN
Signed-off-by: Vinay Simha BN --- v1: Initial version v2: * Andrzej Hajda review comments incorporated SPDX identifier development debug removed alphabetic order headers u32 instead of unit32_t magic numbers to macros for CLRSI and mux registers ignored return value * Laurent Pinch

Re: [PATCH v3 3/3] drm/bridge: Introduce LT9611 DSI to HDMI bridge

2020-06-22 Thread Vinod Koul
Hello Sam, On 20-06-20, 20:05, Sam Ravnborg wrote: > Hi Vinod. > > Looks good but some some of small nits. Great :) > And a few larger things in the following. > The larger things is releated to prepare the bridge driver to live in a > world with chained bridges. Sure, so that entails adding t

[PATCH v1 11/11] soc: mediatek: cmdq: add set event function

2020-06-22 Thread Dennis YC Hsieh
Add set event function in cmdq helper functions to set specific event. Signed-off-by: Dennis YC Hsieh --- drivers/soc/mediatek/mtk-cmdq-helper.c | 15 +++ include/linux/mailbox/mtk-cmdq-mailbox.h |1 + include/linux/soc/mediatek/mtk-cmdq.h|9 + 3 files changed

Re: [PATCH v11 1/4] drm/panel: Add helper for reading DT rotation

2020-06-22 Thread Dmitry Osipenko
18.06.2020 02:18, Dmitry Osipenko пишет: > From: Derek Basehore > > This adds a helper function for reading the rotation (panel > orientation) from the device tree. > > Signed-off-by: Derek Basehore > Reviewed-by: Sam Ravnborg > --- My t-b accidentally got lost after rebase, here it is: Test

Re: [PATCH v3 03/15] pwm: lpss: Fix off by one error in base_unit math in pwm_lpss_prepare()

2020-06-22 Thread Uwe Kleine-König
On Sat, Jun 20, 2020 at 02:17:46PM +0200, Hans de Goede wrote: > According to the data-sheet the way the PWM controller works is that > each input clock-cycle the base_unit gets added to a N bit counter and > that counter overflowing determines the PWM output frequency. > > So assuming e.g. a 16 b

Re: [PATCH v3 04/15] pwm: lpss: Add range limit check for the base_unit register value

2020-06-22 Thread Uwe Kleine-König
On Sat, Jun 20, 2020 at 02:17:47PM +0200, Hans de Goede wrote: > When the user requests a high enough period ns value, then the > calculations in pwm_lpss_prepare() might result in a base_unit value of 0. > > But according to the data-sheet the way the PWM controller works is that > each input clo

Re: [PATCH v3 09/15] pwm: crc: Enable/disable PWM output on enable/disable

2020-06-22 Thread Uwe Kleine-König
Hello, [adding Shobhit Kumar to Cc who is the author of this driver according to the comment on the top of the driver] On Sat, Jun 20, 2020 at 02:17:52PM +0200, Hans de Goede wrote: > The pwm-crc code is using 2 different enable bits: > 1. bit 7 of the PWM0_CLK_DIV (PWM_OUTPUT_ENABLE) > 2. bit 0

Re: [PATCH v3 11/15] pwm: crc: Implement get_state() method

2020-06-22 Thread Uwe Kleine-König
On Sat, Jun 20, 2020 at 02:17:54PM +0200, Hans de Goede wrote: > Implement the pwm_ops.get_state() method to complete the support for the > new atomic PWM API. > > Reviewed-by: Andy Shevchenko > Signed-off-by: Hans de Goede > --- > Changes in v3: > - Add Andy's Reviewed-by tag > - Remove extra w

Re: [PATCH 2/3] drm: uapi: Use SPDX in DRM drivers uAPI headers

2020-06-22 Thread Christian König
Am 21.06.20 um 04:07 schrieb Laurent Pinchart: Most of the DRM drivers uAPI headers are licensed under the MIT license, and carry copies of the license with slight variations. Replace them with SPDX headers. My personal opinion is that this is a really good idea, but my professional is that we

Re: [PATCH RESEND v1] drm/meson: viu: fix setting the OSD burst length in VIU_OSD1_FIFO_CTRL_STAT

2020-06-22 Thread Neil Armstrong
Hi Martin, On 20/06/2020 17:57, Martin Blumenstingl wrote: > The burst length is configured in VIU_OSD1_FIFO_CTRL_STAT[31] and > VIU_OSD1_FIFO_CTRL_STAT[11:10]. The public S905D3 datasheet describes > this as: > - 0x0 = up to 24 per burst > - 0x1 = up to 32 per burst > - 0x2 = up to 48 per burst >

Re: [PATCH v4 3/5] drm: panel: Add Xingbangda XBD599 panel (ST7703 controller)

2020-06-22 Thread Sam Ravnborg
On Sun, Jun 21, 2020 at 12:30:10AM +0200, Ondřej Jirman wrote: > On Sat, Jun 20, 2020 at 11:25:29PM +0200, Sam Ravnborg wrote: > > Hi Ondrej et al. > > > > On Wed, Jun 17, 2020 at 02:32:07AM +0200, Ondrej Jirman wrote: > > > From: Icenowy Zheng > > > > > > Xingbangda XBD599 is a 5.99" 720x1440 M

Re: [Intel-gfx] [PATCH 03/18] dma-fence: basic lockdep annotations

2020-06-22 Thread Daniel Vetter
On Fri, Jun 19, 2020 at 3:12 PM Chris Wilson wrote: > > Quoting Daniel Vetter (2020-06-19 10:43:09) > > On Fri, Jun 19, 2020 at 10:13:35AM +0100, Chris Wilson wrote: > > > Quoting Daniel Vetter (2020-06-19 09:51:59) > > > > On Fri, Jun 19, 2020 at 10:25 AM Chris Wilson > > > > wrote: > > > > > F

Re: [PATCH 1/3] drm: uapi: Use SPDX in DRM core uAPI headers

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 05:07:01AM +0300, Laurent Pinchart wrote: > The DRM core uAPI headers are licensed under the MIT license, and carry > copies of the license with slight variations. Replace them with SPDX > headers. > > Following a discussion with Daniel Vetter on this topic, add a > clarifi

Re: [PATCH 3/3] drm: uapi: Remove copies of GPL license text from headers

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 05:07:03AM +0300, Laurent Pinchart wrote: > Several DRM drivers uAPI headers that are licensed under the GPL carry > both an SPDX header and a copy of the license text. Drop the latter. > > Signed-off-by: Laurent Pinchart I do kinda wonder how much lolz these gpl-only hea

Re: [kbuild-all] Re: [PATCH 4/4] drm: pl111: Update documentation

2020-06-22 Thread Rong Chen
On 6/12/20 8:40 PM, Philip Li wrote: On Fri, Jun 12, 2020 at 01:04:02PM +0200, Linus Walleij wrote: On Wed, Jun 10, 2020 at 9:38 AM kernel test robot wrote: I love your patch! Perhaps something to improve: [auto build test WARNING on drm-exynos/exynos-drm-next] [also build test WARNING on

Re: [PATCH 2/3] drm: uapi: Use SPDX in DRM drivers uAPI headers

2020-06-22 Thread Daniel Vetter
On Mon, Jun 22, 2020 at 09:58:44AM +0200, Christian König wrote: > Am 21.06.20 um 04:07 schrieb Laurent Pinchart: > > Most of the DRM drivers uAPI headers are licensed under the MIT license, > > and carry copies of the license with slight variations. Replace them > > with SPDX headers. > > My pers

Re: [PATCH v2 1/8] drm: Add dummy page per device or GEM object

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:01AM -0400, Andrey Grodzovsky wrote: > Will be used to reroute CPU mapped BO's page faults once > device is removed. > > Signed-off-by: Andrey Grodzovsky > --- > drivers/gpu/drm/drm_file.c | 8 > drivers/gpu/drm/drm_prime.c | 10 ++ > include/drm/

Re: [PATCH v2 2/8] drm/ttm: Remap all page faults to per process dummy page.

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:02AM -0400, Andrey Grodzovsky wrote: > On device removal reroute all CPU mappings to dummy page per drm_file > instance or imported GEM object. > > Signed-off-by: Andrey Grodzovsky > --- > drivers/gpu/drm/ttm/ttm_bo_vm.c | 65 > -

Re: [PATCH v2 3/8] drm/ttm: Add unampping of the entire device address space

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:03AM -0400, Andrey Grodzovsky wrote: > Helper function to be used to invalidate all BOs CPU mappings > once device is removed. > > Signed-off-by: Andrey Grodzovsky This seems to be missing the code to invalidate all the dma-buf mmaps? Probably needs more testcases

Re: [PATCH v2 0/8] RFC Support hot device unplug in amdgpu

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:00AM -0400, Andrey Grodzovsky wrote: > This RFC is more of a proof of concept then a fully working solution as there > are a few unresolved issues we are hoping to get advise on from people on the > mailing list. > Until now extracting a card either by physical extra

Re: [PATCH v2 4/8] drm/amdgpu: Split amdgpu_device_fini into early and late

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:04AM -0400, Andrey Grodzovsky wrote: > Some of the stuff in amdgpu_device_fini such as HW interrupts > disable and pending fences finilization must be done right away on > pci_remove while most of the stuff which relates to finilizing and releasing > driver data struct

Re: [PATCH v2 5/8] drm/amdgpu: Refactor sysfs removal

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:05AM -0400, Andrey Grodzovsky wrote: > Track sysfs files in a list so they all can be removed during pci remove > since otherwise their removal after that causes crash because parent > folder was already removed during pci remove. > > Signed-off-by: Andrey Grodzovsky

Re: [PATCH v2 8/8] drm/amdgpu: Prevent any job recoveries after device is unplugged.

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:08AM -0400, Andrey Grodzovsky wrote: > No point to try recovery if device is gone, just messes up things. > > Signed-off-by: Andrey Grodzovsky > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 16 > drivers/gpu/drm/amd/amdgpu/amdgpu_job.c | 8 +

Re: [PATCH v2 7/8] drm/amdgpu: Fix sdma code crash post device unplug

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:07AM -0400, Andrey Grodzovsky wrote: > entity->rq becomes null aftre device unplugged so just return early > in that case. > > Signed-off-by: Andrey Grodzovsky That looks very deep in amdgpu internals ... how do you even get in here after the device is fully unplugg

Re: [PATCH v2 6/8] drm/amdgpu: Unmap entire device address space on device remove.

2020-06-22 Thread Daniel Vetter
On Sun, Jun 21, 2020 at 02:03:06AM -0400, Andrey Grodzovsky wrote: > Use the new TTM interface to invalidate all exsisting BO CPU mappings > form all user proccesses. > > Signed-off-by: Andrey Grodzovsky > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 1 + > 1 file changed, 1 insertion(+) > >

Re: [PATCH v4] drm/fourcc: document modifier uniqueness requirements

2020-06-22 Thread Brian Starkey
On Fri, Jun 19, 2020 at 06:36:17PM +0200, Daniel Vetter wrote: > On Fri, Jun 19, 2020 at 01:39:34PM +0100, Brian Starkey wrote: > > Hi Simon, > > > > On Fri, Jun 19, 2020 at 11:12:25AM +, Simon Ser wrote: > > > There have suggestions to bake pitch alignment, address alignement, > > > contiguou

Re: [PATCH] dt-bindings: backlight: Convert common backlight bindings to DT schema

2020-06-22 Thread Daniel Thompson
On Fri, Jun 19, 2020 at 11:53:41PM +0200, Sam Ravnborg wrote: > Good to have these converted. A few comments in the following. One > comment is for the backlight people as you copied the original text. ... and I've sliced out everything except that in this reply. > On Thu, Jun 18, 2020 at 04:44:1

Re: [PATCH v1 02/11] soc: mediatek: cmdq: add assign function

2020-06-22 Thread Matthias Brugger
On 21/06/2020 16:18, Dennis YC Hsieh wrote: > Add assign function in cmdq helper which assign constant value into > internal register by index. > > Signed-off-by: Dennis YC Hsieh Applied to v5.8-next/soc Thanks > --- > drivers/soc/mediatek/mtk-cmdq-helper.c | 24 +++

Re: [PATCH v1 03/11] soc: mediatek: cmdq: add write_s function

2020-06-22 Thread Matthias Brugger
On 21/06/2020 16:18, Dennis YC Hsieh wrote: > add write_s function in cmdq helper functions which > writes value contains in internal register to address > with large dma access support. > > Signed-off-by: Dennis YC Hsieh > --- > drivers/soc/mediatek/mtk-cmdq-helper.c | 19 +++

[RFC PATCH 2/2] MAINTAINERS: Add maintainer for hyperv video device

2020-06-22 Thread Deepak Rawat
Maintainer for hyperv synthetic video device. Signed-off-by: Deepak Rawat --- MAINTAINERS | 8 1 file changed, 8 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index f437f42b73ad..102f734b99bd 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -5316,6 +5316,14 @@ T: git git://an

[RFC PATCH 0/2] DRM driver for hyper-v synthetic video device

2020-06-22 Thread Deepak Rawat
Hi All, First draft of DRM driver for hyper-v synthetic video device. This synthetic device is already supported by hyper-v and a corresponding framebuffer driver exist at drivers/video/fbdev/hyperv_fb.c. With this patch, just reworked the framebuffer driver into DRM, in doing so got mode-setting

[RFC PATCH 1/2] drm/hyperv: Add DRM driver for hyperv synthetic video device

2020-06-22 Thread Deepak Rawat
DRM driver for hyperv synthetic video device, based on hyperv_fb framebuffer driver. Also added config option "DRM_HYPERV" to enabled this driver. Signed-off-by: Deepak Rawat --- drivers/gpu/drm/tiny/Kconfig |9 + drivers/gpu/drm/tiny/Makefile |1 + drivers/gpu/drm/tiny/hyperv_d

Re: [PATCH v1 08/11] soc: mediatek: cmdq: export finalize function

2020-06-22 Thread Matthias Brugger
On 21/06/2020 16:18, Dennis YC Hsieh wrote: > Export finalize function to client which helps append eoc and jump > command to pkt. Let client decide call finalize or not. > > Signed-off-by: Dennis YC Hsieh > Reviewed-by: CK Hu > Acked-by: Chun-Kuang Hu > --- > drivers/gpu/drm/mediatek/mtk_d

Re: [PATCH v1 10/11] soc: mediatek: cmdq: add clear option in cmdq_pkt_wfe api

2020-06-22 Thread Matthias Brugger
On 21/06/2020 16:18, Dennis YC Hsieh wrote: > Add clear parameter to let client decide if > event should be clear to 0 after GCE receive it. > > Signed-off-by: Dennis YC Hsieh > Reviewed-by: CK Hu > --- > drivers/gpu/drm/mediatek/mtk_drm_crtc.c |2 +- > drivers/soc/mediatek/mtk-cmdq-hel

Re: [PATCH v2 5/8] drm/amdgpu: Refactor sysfs removal

2020-06-22 Thread Greg KH
On Mon, Jun 22, 2020 at 11:51:24AM +0200, Daniel Vetter wrote: > On Sun, Jun 21, 2020 at 02:03:05AM -0400, Andrey Grodzovsky wrote: > > Track sysfs files in a list so they all can be removed during pci remove > > since otherwise their removal after that causes crash because parent > > folder was al

Re: [PATCH v1 11/11] soc: mediatek: cmdq: add set event function

2020-06-22 Thread Matthias Brugger
On 21/06/2020 16:18, Dennis YC Hsieh wrote: > Add set event function in cmdq helper functions to set specific event. > > Signed-off-by: Dennis YC Hsieh > --- > drivers/soc/mediatek/mtk-cmdq-helper.c | 15 +++ > include/linux/mailbox/mtk-cmdq-mailbox.h |1 + > include/linux

RE: [PATCH v2] dmabuf: use spinlock to access dmabuf->name

2020-06-22 Thread Ruhl, Michael J
>-Original Message- >From: charante=codeaurora@mg.codeaurora.org > On Behalf Of Charan Teja >Kalla >Sent: Monday, June 22, 2020 5:26 AM >To: Ruhl, Michael J ; Sumit Semwal >; david.lai...@aculab.com; open list:DMA >BUFFER SHARING FRAMEWORK ; DRI mailing >list >Cc: Linaro MM SIG ; LKML

Re: [RFC PATCH 1/2] drm/hyperv: Add DRM driver for hyperv synthetic video device

2020-06-22 Thread Gerd Hoffmann
Hi, > +/* Should be done only once during init and resume */ > +static int synthvid_update_vram_location(struct hv_device *hdev, > + phys_addr_t vram_pp) > +{ > + struct hyperv_device *hv = hv_get_drvdata(hdev); > + struct synthvid_msg *msg = (struct

Re: [PATCH v2 1/8] drm: Add dummy page per device or GEM object

2020-06-22 Thread Christian König
Am 21.06.20 um 08:03 schrieb Andrey Grodzovsky: Will be used to reroute CPU mapped BO's page faults once device is removed. Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/drm_file.c | 8 drivers/gpu/drm/drm_prime.c | 10 ++ include/drm/drm_file.h | 2 ++ incl

Re: [PATCH v2 5/8] drm/amdgpu: Refactor sysfs removal

2020-06-22 Thread Christian König
Am 21.06.20 um 08:03 schrieb Andrey Grodzovsky: Track sysfs files in a list so they all can be removed during pci remove since otherwise their removal after that causes crash because parent folder was already removed during pci remove. That looks extremely fishy to me. It sounds like we just d

Re: [PATCH v7 04/36] drm: amdgpu: fix common struct sg_table related issues

2020-06-22 Thread Christian König
Am 19.06.20 um 12:36 schrieb Marek Szyprowski: The Documentation/DMA-API-HOWTO.txt states that the dma_map_sg() function returns the number of the created entries in the DMA address space. However the subsequent calls to the dma_sync_sg_for_{device,cpu}() and dma_unmap_sg must be called with the

[PATCH v4] drm/doc: device hot-unplug for userspace

2020-06-22 Thread Pekka Paalanen
From: Pekka Paalanen Set up the expectations on how hot-unplugging a DRM device should look like to userspace. Written by Daniel Vetter's request and largely based on his comments in IRC and from https://lists.freedesktop.org/archives/dri-devel/2020-May/265484.html . A related Wayland protocol

[Bug 207673] amdgpu/radeon: crash due to over temperature

2020-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=207673 phileimer (p...@jpmr.org) changed: What|Removed |Added Summary|radeon: crash due to over |amdgpu/radeon: crash due to

[Bug 207673] amdgpu/radeon: crash due to over temperature

2020-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=207673 phileimer (p...@jpmr.org) changed: What|Removed |Added Kernel Version|5.6.x and previous |5.6.x, 5.7.x -- You are rece

[Bug 207673] amdgpu/radeon: crash due to over temperature

2020-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=207673 --- Comment #3 from phileimer (p...@jpmr.org) --- Created attachment 289807 --> https://bugzilla.kernel.org/attachment.cgi?id=289807&action=edit amdgpu: lower the temperature limit to avoid kernel crash -- You are receiving this mail because:

[Bug 207673] amdgpu/radeon: crash due to over temperature

2020-06-22 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=207673 --- Comment #4 from phileimer (p...@jpmr.org) --- I modified my kernel configuration to use the new amdgpu driver for this SI chip, instead of the legacy radeon. The same problem occurs: to avoid frequent kernel crashes, I must apply a patch to lo

Re: [PATCH] drm/mediatek: check plane visibility in atomic_update

2020-06-22 Thread Chun-Kuang Hu
Hi, Hsin-Yi: Hsin-Yi Wang 於 2020年6月22日 週一 下午1:32寫道: > > Disable the plane if it's not visible. Otherwise mtk_ovl_layer_config() > would proceed with invalid plane and we may see vblank timeout. Except the Fixes tag, Reviewed-by: Chun-Kuang Hu > > Signed-off-by: Hsin-Yi Wang > --- > drivers/

RE: [RFC PATCH 2/2] drm: xlnx: driver for Xilinx DSI TX Subsystem

2020-06-22 Thread Venkateshwar Rao Gannavarapu
Hi Laurent, Thanks for the comment. >-Original Message- >From: Laurent Pinchart >Sent: Wednesday, June 17, 2020 3:18 AM >To: Venkateshwar Rao Gannavarapu >Cc: Hyun Kwon ; dri-devel@lists.freedesktop.org; >airl...@linux.ie; dan...@ffwll.ch; linux-ker...@vger.kernel.org; Sandip Kothari >;

  1   2   >