Re: [PATCH] drm/msm: Fix NULL deref in adreno_load_gpu

2017-12-19 Thread Archit Taneja
On 12/15/2017 09:03 PM, Jordan Crouse wrote: On Thu, Dec 14, 2017 at 11:11:50AM +0530, Archit Taneja wrote: The msm/kms driver should work even if there is no GPU device specified in DT. Currently, we get a NULL dereference crash in adreno_load_gpu since the driver assumes that priv->gpu_pdev

Re: [PATCH v1] drm/tegra: gem: Correct iommu_map_sg() error checking

2017-12-19 Thread kbuild test robot
Hi Dmitry, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on tegra/for-next] [also build test WARNING on v4.15-rc4 next-20171220] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com/0day-

[Bug 104275] Stoney Ridge laptop display goes blank after HDMI gets plugged/unplugged in extended mode.

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=104275 --- Comment #7 from alex_zha...@dell.com --- Hi Michel, Before the buffer been pined to a location, can the buffer be moved to other place? My opinion, this is not about VRAM size, it is the mechanism of buffer move. Is this buffer content of r

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 08:38:10PM +, Hans de Goede wrote: > Hi, > > On 19-12-17 20:42, Rodrigo Vivi wrote: > > > > On Tue, Dec 19, 2017 at 07:21:13PM +, Hans de Goede wrote: > > > At least on the Chuwi Vi8 (non pro/plus) the LCD panel will show an image > > > shifted aprox. 20% to the le

Re: [PATCH] dt-bindings: display: panel: Fix compatible string for Toshiba LT089AC29000

2017-12-19 Thread Rob Herring
On Sun, Dec 17, 2017 at 03:34:33AM +0100, Jonathan Neuschäfer wrote: > The compatible string for this panel was specified as > toshiba,lt089ac29000.txt. I believe this is a mistake. > > Fixes: 06e733e41f87 ("drm/panel: simple: add Toshiba LT089AC19000") > Cc: Lucas Stach > Signed-off-by: Jonathan

Re: [RFC PATCH 01/60] hyper_dmabuf: initial working version of hyper_dmabuf drv

2017-12-19 Thread Dongwon Kim
I forgot to include this brief information about this patch series. This patch series contains the implementation of a new device driver, hyper_dmabuf, which provides a method for DMA-BUF sharing across different OSes running on the same virtual OS platform powered by a hypervisor. Detailed infor

Re: [Intel-gfx] [PATCH v2 7/8] drm/i915: Introduce a non-blocking power domain for vblank interrupts

2017-12-19 Thread Pandiyan, Dhinakaran
On Tue, 2017-12-19 at 13:41 -0800, Rodrigo Vivi wrote: > On Tue, Dec 19, 2017 at 05:26:58AM +, Dhinakaran Pandiyan wrote: > > When DC states are enabled and PSR is active, the hardware enters DC5/DC6 > > states resulting in frame counter resets. The frame counter resets mess > > up the vblan

[Bug 104306] Mesa 17.3 breaks Firefox and other Xwayland apps on AMD HD7750

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=104306 --- Comment #2 from eric vz --- Working on narrowing down the source of the issue, I've found so far that 17.2.7 builds work fine (though I had to change --enable-omx-bellagio back to --enable-omx), and 17.3.0-rc3 does not. I'll try an -rc1 bui

Re: [PATCH 1/2] drm/nouveau/bar/gf100: fix hang when calling ->fini() before ->init()

2017-12-19 Thread Jon Hunter
On 06/12/17 17:18, Jon Hunter wrote: > > On 06/12/17 09:22, Guillaume Tucker wrote: >> On 05/12/17 18:32, Ben Skeggs wrote: >>> On Wed, Dec 6, 2017 at 12:30 AM, Jon Hunter wrote: >>> On 04/12/17 18:37, Guillaume Tucker wrote: > If the firmware fails to load then ->fini() will be ca

Re: [PATCH v2 7/8] drm/i915: Introduce a non-blocking power domain for vblank interrupts

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 05:26:58AM +, Dhinakaran Pandiyan wrote: > When DC states are enabled and PSR is active, the hardware enters DC5/DC6 > states resulting in frame counter resets. The frame counter resets mess > up the vblank counting logic. In order to disable DC states when > vblank inte

Re: [PATCH v2 3/8] drm/i915/psr: Avoid initializing PSR if there is no sink support.

2017-12-19 Thread Pandiyan, Dhinakaran
On Tue, 2017-12-19 at 13:29 -0800, Rodrigo Vivi wrote: > On Tue, Dec 19, 2017 at 05:26:54AM +, Dhinakaran Pandiyan wrote: > > DPCD read for the eDP is complete by the time intel_psr_init() is > > called, which means we can avoid initializing PSR structures and state > > if there is no sink s

Re: [PATCH v2 3/8] drm/i915/psr: Avoid initializing PSR if there is no sink support.

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 05:26:54AM +, Dhinakaran Pandiyan wrote: > DPCD read for the eDP is complete by the time intel_psr_init() is > called, which means we can avoid initializing PSR structures and state > if there is no sink support. > > Cc: Rodrigo Vivi > Cc: Ville Syrjälä > Signed-off-b

[Bug 104331] [r600g] Ogre demo "TutorialUAV01" crash at r600_decompress_color_images

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=104331 --- Comment #4 from MWATTT --- Created attachment 136303 --> https://bugs.freedesktop.org/attachment.cgi?id=136303&action=edit Right texture -- You are receiving this mail because: You are the assignee for the bug.___

Re: [PATCH v2 2/8] drm/i915/psr: CAN_PSR() macro to check for PSR source and sink support.

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 05:26:53AM +, Dhinakaran Pandiyan wrote: > The global variable dev_priv->psr.sink_support is set if an eDP sink > supports PSR. Use this instead of redoing the check with is_edp_psr(). > Combine source and sink support checks into a macro that can be used to > return ear

Re: [PATCH v2 1/8] drm/i915/psr: Kill psr.source_ok flag.

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 05:26:52AM +, Dhinakaran Pandiyan wrote: > This flag has become redundant since > commit 4d90f2d507ab ("drm/i915: Start tracking PSR state in crtc state") > It is set at the same place as psr.enabled, which is also exposed via > debugfs. > > Cc: Rodrigo Vivi > Cc: Vill

[Bug 104331] [r600g] Ogre demo "TutorialUAV01" crash at r600_decompress_color_images

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=104331 MWATTT changed: What|Removed |Added Attachment #136265|0 |1 is obsolete|

[Bug 196197] [drm:r600_ring_test [radeon]] *ERROR* radeon: ring 0 test failed (scratch(0x8504)=0xCAFEDEAD)

2017-12-19 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=196197 --- Comment #15 from Andreas Brogle (an...@ok.de) --- Hmm, seems like a lucky punch to mee. No chance if the two commits would have been vice versa ;-) # skip: [d939cdfde34f50b95254b375f498447c82190b3e] md/linear: shutup lockdep warnning git bise

[Bug 104331] [r600g] Ogre demo "TutorialUAV01" crash at r600_decompress_color_images

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=104331 --- Comment #2 from MWATTT --- I can confirm that the segfault is gone. However, the demo does not render properly(I don't know if I should make another report for that). I'll upload an other trace, as the first one was generated on PITCAIRN a

Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing

2017-12-19 Thread Ray Strode
Hi, On Tue, Dec 19, 2017 at 10:41 AM, Max Staudt wrote: > I'm hooking into the in-kernel terminal emulator, because the bootsplash is a > functional extension of that. It just happens that fbcon sits on top of FB, > so I > work with what I get. > > And the console in turn happens to work on all

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Hans de Goede
Hi, On 19-12-17 20:48, Ville Syrjälä wrote: On Tue, Dec 19, 2017 at 08:31:07PM +0100, Hans de Goede wrote: Hi, I forgot to add a coverletter, anyways what I wanted to put in the coverletter and not in the commit message is a link to a picture of the problem this fixes: https://fedorapeople.or

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Hans de Goede
Hi, On 19-12-17 20:42, Rodrigo Vivi wrote: On Tue, Dec 19, 2017 at 07:21:13PM +, Hans de Goede wrote: At least on the Chuwi Vi8 (non pro/plus) the LCD panel will show an image shifted aprox. 20% to the left (with wraparound) and sometimes also wrong colors, showing that the panel controlle

Re: [RFC PATCH v2 00/13] Kernel based bootsplash

2017-12-19 Thread Ray Strode
Hi, > For example, having a userspace splash that starts as early as it can > (thus on vesafb/efifb on a PC) will cause the KMS driver to fail > reserving the entirety of video RAM, and thus fail loading. This cannot be > fixed. well the fix there is to use drm devices... like this: https://cgit

[Bug 196197] [drm:r600_ring_test [radeon]] *ERROR* radeon: ring 0 test failed (scratch(0x8504)=0xCAFEDEAD)

2017-12-19 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=196197 --- Comment #14 from Andreas Brogle (an...@ok.de) --- Concerning myself with git I randomly discovered that. That is the last GOOD commit : # good: [190c3ee06a0f0660839785b7ad8a830e832d9481] Merge git://git.kernel.org/pub/scm/linux/kernel/git/dav

Re: [PATCH v.2] 4.15 vmgfx boot warning

2017-12-19 Thread Sinclair Yeh
This looks okay to me. On Mon, Dec 18, 2017 at 07:26:03PM -0500, Woody Suwalski wrote: > The 4.15 drm_atomic_helper driver shows a warning during boot (both 32 and > 64 bit x86) > It is caused by a mismatch between the result of vmw_enable_vblank() and > what the drm_atomic_helper expects: >    /.

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Ville Syrjälä
On Tue, Dec 19, 2017 at 08:31:07PM +0100, Hans de Goede wrote: > Hi, > > I forgot to add a coverletter, anyways what I wanted to put in the > coverletter and not in the commit message is a link to a picture of the > problem this fixes: > > https://fedorapeople.org/~jwrdegoede/IMG_20171217_195637.

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Rodrigo Vivi
On Tue, Dec 19, 2017 at 07:21:13PM +, Hans de Goede wrote: > At least on the Chuwi Vi8 (non pro/plus) the LCD panel will show an image > shifted aprox. 20% to the left (with wraparound) and sometimes also wrong > colors, showing that the panel controller is starting with sampling the > datastr

[RFC PATCH 59/60] hyper_dmabuf: freeing hy_drv_priv when drv init fails (v2)

2017-12-19 Thread Dongwon Kim
From: Kai Chen Make sure hy_drv_priv is freed before exiting in several places in hyper_dmabuf_drv_init. v2: unlocking mutex before freeing hy_drv_priv when bknd_ops->init fails Signed-off-by: Kai Chen Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c | 7 ++- 1

[RFC PATCH 46/60] hyper_dmabuf: delay auto initialization of comm_env

2017-12-19 Thread Dongwon Kim
Comm env intialization is now scheduled to be done when xenstore is initialized. This scheduling is done in driver's init routine. Also, adding a recursively scheduled routine that monitors any new tx ch setup from other domains and automaticlaly configure rx channel accordingly (every 10 sec). O

[RFC PATCH 58/60] hyper_dmabuf: move device node out of /dev/xen/

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola hyper_dmabuf driver is generic driver that is designed to work with any hypervisor with various backend implementations. So moving out its device node out of /dev/xen. Signed-off-by: Mateusz Polrola Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv

[RFC PATCH 47/60] hyper_dmabuf: fix issues with event-polling

2017-12-19 Thread Dongwon Kim
This patch fixes several defects on event handling including: 1. Imported sgt info and exported sgt info now have buffer for private data (priv) with variable size 2. Now user input to export_remote_ioctl contain sz_priv, which specifies size of private data (e.g. meta data) 3. Increased m

[RFC PATCH 53/60] hyper_dmabuf: define fastpath_export for exporting existing buffer

2017-12-19 Thread Dongwon Kim
To make hyper_dmabuf_export_remote_ioctl more compact and readable, a new function call, 'fastpath_export' is created to replace a routine in hyper_dmabuf_export_remote_ioctl for the case requested buffer for exporting is already in the LIST (exported previously). Signed-off-by: Dongwon Kim ---

[RFC PATCH 51/60] hyper_dmabuf: missing mutex_unlock and move spinlock

2017-12-19 Thread Dongwon Kim
Added missing mutex_unlock to make sure mutex is unlocked before returning. Also, moved spinlock lock/unlock into hyper_dmabuf_send_event and remove checking on spinlock (with assumption caller does the spinlock in advance) to make it more straight forward. This patch includes a couple of minor m

[RFC PATCH 57/60] hyper_dmabuf: change type of ref to shared pages to unsigned long

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Changed data type of reference for the group of pages to be shared unsigned long in case it is direct representation of the memory address. Signed-off-by: Mateusz Polrola Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.h | 2 +- drivers/x

[RFC PATCH 45/60] hyper_dmabuf: adding poll/read for event generation

2017-12-19 Thread Dongwon Kim
hyper_dmabuf driver on importing domain now generates event every time new hyper_dmabuf is available (visible) to the importer. Each event comes with 128 byte private data, which can contain any meta data or user data specific to the originator of DMA BUF. Signed-off-by: Dongwon Kim --- drivers

[RFC PATCH 55/60] hyper_dmabuf: fixed wrong send_req call

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Wrong vmid is used in case of sending HYPER_DMABUF_EXPORT_FD_FAILED message. Instead of vmid, hypder dmabuf id is being used. Signed-off-by: Mateusz Polrola Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 2 +- 1 file changed, 1 insertion(+

[RFC PATCH 54/60] hyper_dmabuf: 'backend_ops' reduced to 'bknd_ops' and 'ops' to 'bknd_ops'

2017-12-19 Thread Dongwon Kim
To make type's name compact, *_backend_ops is changed to '*_bknd_ops'. Also 'ops' is now changed to 'bknd_ops' to clarify it is a data structure with entry points of 'backend' operations. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 14 +-- drivers/

[RFC PATCH 56/60] hyper_dmabuf: add initialization and cleanup to bknd_ops

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Introduced additional init and cleanup routines in the backend API structure that might be useful for hypervisors other than Xen. Signed-off-by: Mateusz Polrola Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c | 14 ++ driver

[RFC PATCH 48/60] hyper_dmabuf: add query items for buffer private info.

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola This change adds two query items, 'HYPER_DMABUF_QUERY_PRIV_INFO_SIZE' and 'HYPER_DMABUF_QUERY_PRIV_INFO', for retrieving buffer's private info and its size. 'info' is an address of user-space buffer (user application provides this) ,where private data will be copied in case

[RFC PATCH 52/60] hyper_dmabuf: remove prefix 'hyper_dmabuf' from static func and backend APIs

2017-12-19 Thread Dongwon Kim
Removed prefix "hyper_dmabuf" from backend functions and static func (except for driver APIs) and add 'be' after 'xen' in backend function calls to show those are backend APIs. Also, modified some of function names for clarification and addressed some missing errors and warnings in hyper_dmabuf_l

[RFC PATCH 41/60] hyper_dmabuf: re-organize driver source

2017-12-19 Thread Dongwon Kim
Re-orginized source code for more intuitive structure For this, 1. driver's file operations other than ioctls have been moved to hyper_dmabuf_drv.c. 2. Separated out dma-buf operations from hyper_dmabuf_ops.c and put those in a new file, 'hyper_dmabuf_ops.c'. Remaining part (SGT core management)

[RFC PATCH 42/60] hyper_dmabuf: always generate a new random keys

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Need to update random keys when reusing hyper_dmabuf_id in the list to increase security Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_id.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/xen/hyper_dmabuf/hyper_dmabu

[RFC PATCH 50/60] hyper_dmabuf: fix styling err and warns caught by checkpatch.pl

2017-12-19 Thread Dongwon Kim
Fixing all styling problems caught by checkpatch.pl Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 53 ++-- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.h| 6 +- drivers/xen/hyper_dmabuf/hyper_dmabuf_event.c | 12 +- drivers/xen/hyper_dmabuf/hyp

[RFC PATCH 38/60] hyper_dmabuf: preventing self exporting of dma_buf

2017-12-19 Thread Dongwon Kim
Adding ID check to make sure a dma-buf is exported externally since hyper_dmabuf only allows to export a dmabuf to a different VM. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/xen/hyper_dmabuf/hyper

[RFC PATCH 44/60] hyper_dmabuf: proper handling of sgt_info->priv

2017-12-19 Thread Dongwon Kim
sgt_info->priv will be used to store user private info passed in ioctl. Data in sgt_info->priv is transfered via comm channel to the importer VM whenever DMA_BUF is exported to keep the private data synchroized across VMs. This patch also adds hyper_dmabuf_send_export_msg that replaces some of exp

[RFC PATCH 43/60] hyper_dmabuf: fixes on memory leaks in various places

2017-12-19 Thread Dongwon Kim
Make sure to free buffers before returning to prevent memory leaks Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 19 +++- drivers/xen/hyper_dmabuf/hyper_dmabuf_msg.c| 9 +++- drivers/xen/hyper_dmabuf/hyper_dmabuf_ops.c| 6 ++- drivers/x

[RFC PATCH 23/60] hyper_dmabuf: use CONFIG_HYPER_DMABUF_XEN instead of CONFIG_XEN

2017-12-19 Thread Dongwon Kim
Now, use CONFIG_HYPER_DMABUF_XEN as a configuration option for building hyper_dmabuf for Xen hypervisor. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c

[RFC PATCH 28/60] hyper_dmabuf: address several synchronization issues

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola This patch addresses several synchronization issues while sharing DMA_BUF with another VM. 1. Set WAIT_AFTER_SYNC_REQ to false by default to prevent possible performance degradation when waing for the response for every syncrhonization request to exporter VM. 2. Remo

[RFC PATCH 32/60] hyper_dmabuf: make all shared pages read-only

2017-12-19 Thread Dongwon Kim
All shared pages need to be read-only from importer's point of view to prevent the buffer from being corrupted. This patch may need to be reverted if we find a better way to protect the original content in this sharing model. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/xen/hyper_dma

[RFC PATCH 34/60] hyper_dmabuf: extend DMA bitmask to 64-bits.

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Extending DMA bitmask of hyper_dmabuf device to cover whole address space driver may access. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/xen/hyper_dmabuf/hyper_dma

[RFC PATCH 30/60] hyper_dmabuf: free already mapped pages when error happens

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola It is needed to freeing already-mapped pages if it gets error before finishing mapping all pages. Signed-off-by: Dongwon Kim --- .../xen/hyper_dmabuf/xen/hyper_dmabuf_xen_shm.c| 43 +++--- 1 file changed, 38 insertions(+), 5 deletions(-) diff --git a/

[RFC PATCH 36/60] hyper_dmabuf: error handling when share_pages fails

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola When error occurs while sharing pages, all pages already shared needs to be un-shared and proper error code has to be returned. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 6 ++- .../xen/hyper_dmabuf/xen/hyper_dmabuf_xen_shm.c|

[RFC PATCH 37/60] hyper_dmabuf: implementation of query ioctl

2017-12-19 Thread Dongwon Kim
List of queries is re-defined. Now it supports following items: enum hyper_dmabuf_query { DMABUF_QUERY_TYPE = 0x10, DMABUF_QUERY_EXPORTER, DMABUF_QUERY_IMPORTER, DMABUF_QUERY_SIZE, DMABUF_QUERY_BUSY,

[RFC PATCH 40/60] hyper_dmabuf: do not use 'private' as field name

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Using a word, 'private' is not recommended because of conflict with language keyword when compiling with C++. So changing those to 'priv'. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 8 include/uapi/xen/hyper_dmabuf.h

[RFC PATCH 31/60] hyper_dmabuf: built-in compilation option

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Enabled built-in compilation option of hyper_dmabuf driver. Also, moved backend initialization into open() to remove its dependencies on Kernel booting sequence. hyper_dmabuf.h is now installed as one of standard header files of Kernel. This patch also addresses possible m

[RFC PATCH 25/60] hyper_dmabuf: introduced delayed unexport

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola To prevent overhead when a DMA BUF needs to be exported right after it is unexported, a marginal delay is introduced in unexporting process. This adds a probation period to the unexporting process. If the same DMA_BUF is requested to be exported agagin, unexporting process i

[RFC PATCH 39/60] hyper_dmabuf: correcting DMA-BUF clean-up order

2017-12-19 Thread Dongwon Kim
Reordering clean-up procedure Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 37 +-- 1 file changed, 24 insertions(+), 13 deletions(-) diff --git a/drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c b/drivers/xen/hyper_dmabuf/hyper_dmabuf_ioct

[RFC PATCH 29/60] hyper_dmabuf: make sure to release allocated buffers when exiting

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola It is required to release all allocated buffers when the application crashes. With the change, hyper_dmabuf_sgt_info includes file pointers for the driver. If it's released unexpectedly, the driver is now unexporting all already-exported buffers to prevent memory leak. In c

[RFC PATCH 35/60] hyper_dmabuf: 128bit hyper_dmabuf_id with random keys

2017-12-19 Thread Dongwon Kim
The length of hyper_dmabuf_id is increased to 128bit by adding random key (96bit) to the id. This is to prevent possible leak of the id by guessing on importer VM (by unauthorized application). hyper_dmabuf_id_t is now defined as, typedef struct { int id; int rng_k

[RFC PATCH 33/60] hyper_dmabuf: error checking on the result of dma_buf_map_attachment

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Added error checking on the result of function call, dma_buf_map_attachment Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c b/drivers/xen/h

[RFC PATCH 24/60] hyper_dmabuf: waits for resp only if WAIT_AFTER_SYNC_REQ == 1

2017-12-19 Thread Dongwon Kim
hyper_dmabuf's sync_request (previously hyper_dmabuf_sync_request_ and_wait) now does not wait for the response from exporter if WAIT_AFTER_SYNC_REQ==0. This is to prevent peformance degradation due to the communication latency while doing indirect hyper DMABUF synchronization. This patch also inc

[RFC PATCH 27/60] hyper_dmabuf: use proper error codes

2017-12-19 Thread Dongwon Kim
Cleaned up and corrected error codes and condition in various error check routines. Also added proper err messages when func returns error. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 14 +++-- drivers/xen/hyper_dmabuf/hyper_dmabuf_id.c | 2 +- dr

[RFC PATCH 19/60] hyper_dmabuf: fix the case with sharing a buffer with 2 pages

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Checking whether buffer has more than two pages should be done by evaluating nents > 1 instead of i > 1 to properly cover the case when nents == 2. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletio

[RFC PATCH 26/60] hyper_dmabuf: add mutexes to prevent several race conditions

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Added mutex to export_fd ioctl to prevent double pages mapping of the same buffer to prevent race condition when two consumers are trying to map the same buffer on importer VM. Also locked mutex before sending request via xen communication channel to prevent req_pending ove

[RFC PATCH 22/60] hyper_dmabuf: configure license

2017-12-19 Thread Dongwon Kim
Set the license of the driver to "GPL and MIT-X dual" and owner to "Intel". Also attached license term to all source and header files Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_conf.h | 26 ++ drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 32

[RFC PATCH 20/60] hyper_dmabuf: optimized loop with less condition check

2017-12-19 Thread Dongwon Kim
Redefined nents_last, which means # of gref in the last page of lvl2 table in any situation even if it is same as REFS_PER_PAGE. With this, loop can be simplified with less condition check. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/xen/hyper_dmabuf_xen_shm.c | 8 +--- 1 file ch

[RFC PATCH 16/60] hyper_dmabuf: define hypervisor specific backend API

2017-12-19 Thread Dongwon Kim
For adoption of hyper_dmabuf driver to various hypervisors other than Xen, a "backend" layer is defined and separated out from existing one-body structure. "Backend" is basically a list of entry points of function calls that provides method to do Kernel's page-level sharing and inter VMs communica

[RFC PATCH 21/60] hyper_dmabuf: exposing drv information using sysfs

2017-12-19 Thread Dongwon Kim
From: Michał Janiszewski This adds two entries in SYSFS with information about imported and exported entries. The information exposed contains details about number of pages, whether a buffer is valid or not, and importer/exporter count. Sysfs for hyper_dmabuf can be enabled by setting a new conf

[RFC PATCH 18/60] hyper_dmabuf: reset comm channel when one end has disconnected.

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola When exporter or importer is disconnected, ring buffer should be reinitialzed, otherwise on next reconnection exporter/importer will receive old requests/responses remaining in the ring buffer, which are not valid anymore. This patch also blocks back ring irq until communic

[RFC PATCH 10/60] hyper_dmabuf: make sure to free memory to prevent leak

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola In hyper_dmabuf_export_remote, page_info->pages needs to be freed before freeing page_info. Also, info_entry in hyper_dmabuf_remove_exported/imported and hyper_dmabuf_remove_exporter/importer_ring needs to be freed after removal of an entry. Signed-off-by: Dongwon Kim ---

[RFC PATCH 15/60] hyper_dmabuf: reusing previously released hyper_dmabuf_id

2017-12-19 Thread Dongwon Kim
Now, released hyper_dmabuf_ids are stored in a stack - (hyper_dmabuf_private.id_queue) for reuse. This is to prevent overflow of ids for buffers. We also limit maximum number for the id to 1000 for the stability and optimal performance. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/Mak

[RFC PATCH 13/60] hyper_dmabuf: postponing cleanup of hyper_DMABUF

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Immediate clean up of buffer is not possible if the buffer is actively used by importer. In this case, we need to postpone freeing hyper_DMABUF until the last consumer unmaps and releases the buffer on impoter VM. New reference count is added for tracking usage by importers.

[RFC PATCH 17/60] hyper_dmabuf: use dynamic debug macros for logging

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola Replaces printk to debug macros Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 4 +- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.h| 4 ++ drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c| 46 +- drivers/xen/hyper

[RFC PATCH 14/60] hyper_dmabuf: clean-up process based on file->f_count

2017-12-19 Thread Dongwon Kim
Now relaese funcs checks f_count for the file instead of our own refcount because it can't track dma_buf_get. Also, importer now sends out HYPER_DMABUF_FIRST_EXPORT to let the exporter know corresponding dma-buf has ever exported on importer's side. This is to cover the case where exporter exports

[RFC PATCH 12/60] hyper_dmabuf: two different unexporting mechanisms

2017-12-19 Thread Dongwon Kim
unexporting on exporter's side now have two options, one is , that just remove and free everything to literally "disconnect" from importer, the other is just to return fail if any apps running on importer is still attached or DMAing. Currently whether forcing or unforcing it is determined by how "F

[RFC PATCH 06/60] hyper_dmabuf: map shared pages only once when importing.

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola If shared pages of buffer were already mapped on importer side, do not map them again on next request to export fd. Signed-off-by: Mateusz Polrola Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.c | 20 +++- 1 file changed, 11 i

[RFC PATCH 08/60] hyper_dmabuf: automatic comm channel initialization using xenstore

2017-12-19 Thread Dongwon Kim
From: Mateusz Polrola This introduces use of xenstore for creating and managing communication channels between two VMs in the system. When hyper_dmabuf driver is loaded in the service VM (host OS), a new xenstore directory, "/local/domain//data/hyper_dmabuf" is created in xenstore filesystem. Wh

[RFC PATCH 09/60] hyper_dmabuf: indirect DMA_BUF synchronization via shadowing

2017-12-19 Thread Dongwon Kim
Importer now sends a synchronization request to the exporter when any of DMA_BUF operations on imported Hyper_DMABUF is executed (e.g dma_buf_map and dma_buf_unmap). This results in a creation of shadow DMA_BUF and exactly same DMA_BUF operation to be executed on it. The main purpose of this is to

[RFC PATCH 05/60] hyper_dmabuf: skip creating a comm ch if exist for the VM

2017-12-19 Thread Dongwon Kim
hyper_dmabuf_importer_ring_setup creates new channel only if there is no existing downstream communication channel previously created for the exporter VM. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c | 13 +++-- drivers/xen/hyper_dmabuf/hyper_dmabuf_ioctl.

[RFC PATCH 07/60] hyper_dmabuf: message parsing done via workqueue

2017-12-19 Thread Dongwon Kim
Use workqueue mechanism to delay message parsing done after exiting from ISR to reduce ISR execution time. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.c| 13 ++ drivers/xen/hyper_dmabuf/hyper_dmabuf_drv.h| 5 + drivers/xen/hyper_dmabuf/hyper_dmabuf

[RFC PATCH 11/60] hyper_dmabuf: check stack before unmapping/detaching shadow DMA_BUF

2017-12-19 Thread Dongwon Kim
Make sure list of mapping/attaching activities on impoter VM is not empty before doing unmapping/detaching shadow DMA BUF for indirect synchronization. Signed-off-by: Dongwon Kim --- .../xen/hyper_dmabuf/hyper_dmabuf_remote_sync.c| 68 +- 1 file changed, 53 insertions(+),

[RFC PATCH 04/60] hyper_dmabuf: new index, k for pointing a right n-th page

2017-12-19 Thread Dongwon Kim
Need a new index, k in hyper_dmabuf_extract_pgs function for picking up a correct n-th page in contigous memory space. Signed-off-by: Dongwon Kim --- drivers/xen/hyper_dmabuf/hyper_dmabuf_imp.c | 11 ++- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/drivers/xen/hyper_dmab

[RFC PATCH 03/60] hyper_dmabuf: re-use dma_buf previously exported if exist

2017-12-19 Thread Dongwon Kim
Now we re-use dma_buf instead of exporting it via normal process (including new mappings). For this, hyper_dmabuf list entries can be searched with "struct dma_buf*". Also, ioctl (export_remote) is modified to just return hyper_dmabuf_id if the specific dmabuf has already been exported to the targe

[RFC PATCH 02/60] hyper_dmabuf: added a doc for hyper_dmabuf sharing

2017-12-19 Thread Dongwon Kim
High-level description of hyper_dmabuf driver has been added to "Documentation" directory. Signed-off-by: Dongwon Kim --- Documentation/hyper-dmabuf-sharing.txt | 734 + 1 file changed, 734 insertions(+) create mode 100644 Documentation/hyper-dmabuf-sharing.txt

[RFC PATCH 01/60] hyper_dmabuf: initial working version of hyper_dmabuf drv

2017-12-19 Thread Dongwon Kim
Upload of intial version of hyper_DMABUF driver enabling DMA_BUF exchange between two different VMs in virtualized platform based on hypervisor such as KVM or XEN. Hyper_DMABUF drv's primary role is to import a DMA_BUF from originator then re-export it to another Linux VM so that it can be mapped

Re: [PATCH] drm/i915/vlv: Add cdclk workaround for DSI

2017-12-19 Thread Hans de Goede
Hi, I forgot to add a coverletter, anyways what I wanted to put in the coverletter and not in the commit message is a link to a picture of the problem this fixes: https://fedorapeople.org/~jwrdegoede/IMG_20171217_195637.jpg Note the screen is actually a portrait screen, so the picture is the ri

Re: [-next PATCH 0/4] sysfs and DEVICE_ATTR_

2017-12-19 Thread Jani Nikula
On Tue, 19 Dec 2017, Joe Perches wrote: > drivers/gpu/drm/i915/i915_sysfs.c | 12 ++-- For i915, Acked-by: Jani Nikula -- Jani Nikula, Intel Open Source Technology Center ___ dri-devel mailing list dri-devel@lists.freedesktop.org h

Re: [-next PATCH 2/4] treewide: Use DEVICE_ATTR_RW

2017-12-19 Thread Andy Shevchenko
On Tue, Dec 19, 2017 at 8:15 PM, Joe Perches wrote: > Convert DEVICE_ATTR uses to DEVICE_ATTR_RW where possible. > > Done with perl script: > > $ git grep -w --name-only DEVICE_ATTR | \ > xargs perl -i -e 'local $/; while (<>) { > s/\bDEVICE_ATTR\s*\(\s*(\w+)\s*,\s*\(?(\s*S_IRUGO\s*\|\s*S_IWUSR

Re: [RFC PATCH v2 00/13] Kernel based bootsplash

2017-12-19 Thread Max Staudt
On 12/19/2017 06:26 PM, Daniel Vetter wrote: > On Tue, Dec 19, 2017 at 6:04 PM, Max Staudt wrote: >> Well, those could enable fbcon if they want the bootsplash. Shouldn't make a >> difference anyway if they're powerful enough to run Linux. As long as the >> bootsplash is shown, no fbcon drawing

[-next PATCH 0/4] sysfs and DEVICE_ATTR_

2017-12-19 Thread Joe Perches
Joe Perches (4): sysfs.h: Use octal permissions treewide: Use DEVICE_ATTR_RW treewide: Use DEVICE_ATTR_RO treewide: Use DEVICE_ATTR_WO arch/arm/mach-pxa/sharpsl_pm.c | 4 +- arch/s390/kernel/smp.c | 2 +- arch/s390/kernel/topology.c

[-next PATCH 3/4] treewide: Use DEVICE_ATTR_RO

2017-12-19 Thread Joe Perches
Convert DEVICE_ATTR uses to DEVICE_ATTR_RO where possible. Done with perl script: $ git grep -w --name-only DEVICE_ATTR | \ xargs perl -i -e 'local $/; while (<>) { s/\bDEVICE_ATTR\s*\(\s*(\w+)\s*,\s*\(?(?:\s*S_IRUGO\s*|\s*0444\s*)\)?\s*,\s*\1_show\s*,\s*NULL\s*\)/DEVICE_ATTR_RO(\1)/g; print;

[-next PATCH 2/4] treewide: Use DEVICE_ATTR_RW

2017-12-19 Thread Joe Perches
Convert DEVICE_ATTR uses to DEVICE_ATTR_RW where possible. Done with perl script: $ git grep -w --name-only DEVICE_ATTR | \ xargs perl -i -e 'local $/; while (<>) { s/\bDEVICE_ATTR\s*\(\s*(\w+)\s*,\s*\(?(\s*S_IRUGO\s*\|\s*S_IWUSR|\s*S_IWUSR\s*\|\s*S_IRUGO\s*|\s*0644\s*)\)?\s*,\s*\1_show\s*,\s*

Re: [RFC PATCH v2 00/13] Kernel based bootsplash

2017-12-19 Thread Daniel Vetter
On Tue, Dec 19, 2017 at 6:04 PM, Max Staudt wrote: > On 12/19/2017 05:16 PM, Daniel Vetter wrote: >> On Wed, Dec 13, 2017 at 08:47:42PM +0100, Max Staudt wrote: >>> Dear fbdev and fbcon developers, >>> >>> Thank you very much for your input for the first patch series. >>> >>> I've included your fe

Re: [RFC PATCH v2 00/13] Kernel based bootsplash

2017-12-19 Thread Max Staudt
On 12/19/2017 05:16 PM, Daniel Vetter wrote: > On Wed, Dec 13, 2017 at 08:47:42PM +0100, Max Staudt wrote: >> Dear fbdev and fbcon developers, >> >> Thank you very much for your input for the first patch series. >> >> I've included your feedback into this second roll, and kindly ask for >> your opi

[Bug 196197] [drm:r600_ring_test [radeon]] *ERROR* radeon: ring 0 test failed (scratch(0x8504)=0xCAFEDEAD)

2017-12-19 Thread bugzilla-daemon
https://bugzilla.kernel.org/show_bug.cgi?id=196197 --- Comment #13 from Andreas Brogle (an...@ok.de) --- Hello, here is the complete bisection process. Testing needs about a week. All versions 4.10.0-rc1 lead to a kernel panic. So there are 60 commits that have to be SKIPped. git bisect start #

Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing

2017-12-19 Thread Max Staudt
On 12/19/2017 05:09 PM, Daniel Vetter wrote: > btw the reason drmcon didn't move is that David Herrmann moved on from > hacking on graphics stuff, and no one needs it. There's nothing > fundamentally wrong with his patches for a basic emergency console on > plain drm, or the simpledrm driver to get

Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing

2017-12-19 Thread Max Staudt
On 12/19/2017 05:02 PM, Daniel Vetter wrote: > On Tue, Dec 19, 2017 at 4:41 PM, Max Staudt wrote: >> On 12/19/2017 02:57 PM, Daniel Vetter wrote: >>> The problem is that defio is totally not how a real driver works. >> >> But they do exist and I can't ignore them. >> >> I'm afraid I don't understa

Re: [RFC PATCH v2 00/13] Kernel based bootsplash

2017-12-19 Thread Daniel Vetter
On Wed, Dec 13, 2017 at 08:47:42PM +0100, Max Staudt wrote: > Dear fbdev and fbcon developers, > > Thank you very much for your input for the first patch series. > > I've included your feedback into this second roll, and kindly ask for > your opinion on the new patch series. Ok I've realized tha

[Bug 101900] No HDMI HBR audio on Polaris (no TrueHD, no Atmos, no Neo:X, no HD Master audio) and static noise in sound when LPCM

2017-12-19 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=101900 Sandro changed: What|Removed |Added CC||sandro.well...@arcor.de --- Comment #16 from S

Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing

2017-12-19 Thread Daniel Vetter
btw the reason drmcon didn't move is that David Herrmann moved on from hacking on graphics stuff, and no one needs it. There's nothing fundamentally wrong with his patches for a basic emergency console on plain drm, or the simpledrm driver to get a basic drm framebuffer up on vesafb/efifb and frien

Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing

2017-12-19 Thread Daniel Vetter
On Tue, Dec 19, 2017 at 4:41 PM, Max Staudt wrote: > On 12/19/2017 02:57 PM, Daniel Vetter wrote: >> Where do drivers deal with struct file deep down? > > As an example, I remembered this to be the case in nouveau's code for > allocating a framebuffer. So I checked, and it's much better now. > >

  1   2   >