[Mesa-dev] [PATCH v5 3/3] gallium/hud: Prevent buffer overflow in hud_thread_busy_install

2017-07-04 Thread Robert Foss
Switch to using util_strlcpy to avoid potential overflow of name array in struct hud_graph. Coverity-id: 1413760 Signed-off-by: Robert Foss --- Changes since v3: Matt Turner - Switch from util_strncpy to util_strlcpy Brian Paul - Fix comment to mention the correct string copy

[Mesa-dev] [PATCH v5 2/3] gallium/hud: Prevent buffer overflow in hud_thread_counter_install

2017-07-04 Thread Robert Foss
Switch to using util_strlcpy to avoid potential overflow of name array in struct hud_graph. Also extract the name element length into a define so that it can be used for strncpy et al. Coverity-id: 1413761 Signed-off-by: Robert Foss --- Changes since v3: Matt Turner - Switch from

[Mesa-dev] [PATCH v6 2/3] gallium/hud: Prevent buffer overflow in hud_thread_counter_install

2017-07-04 Thread Robert Foss
Switch to using util_strlcpy to avoid potential overflow of name array in struct hud_graph. Also extract the name element length into a define so that it can be used for strncpy et al. Coverity-id: 1413761 Signed-off-by: Robert Foss --- Changes since v3: Matt Turner - Switch from

[Mesa-dev] [PATCH v6 3/3] gallium/hud: Prevent buffer overflow in hud_thread_busy_install

2017-07-04 Thread Robert Foss
Switch to using util_strlcpy to avoid potential overflow of name array in struct hud_graph. Coverity-id: 1413760 Signed-off-by: Robert Foss --- Changes since v3: Matt Turner - Switch from util_strncpy to util_strlcpy Brian Paul - Fix comment to mention the correct string copy

[Mesa-dev] [PATCH v6 1/3] util: Add util_strlcpy

2017-07-04 Thread Robert Foss
Add local strlcpy implementation. Signed-off-by: Robert Foss --- Changes since v5: Actually include changes from v5 in patch Changes since v4: Gustaw Smolarczyk - Make util_strlcpy have the same behaviour as strlcpy Changes since v3: Matt Turner - Change name of util_strncpy to

Re: [Mesa-dev] [PATCH v6 1/3] util: Add util_strlcpy

2017-07-06 Thread Robert Foss
On Wed, 2017-07-05 at 08:46 -0600, Brian Paul wrote: > On 07/05/2017 12:57 AM, Robert Foss wrote: > > Add local strlcpy implementation. > > > > Signed-off-by: Robert Foss > > --- > > Changes since v5: > >    Actually include changes from v5 in patch &

[Mesa-dev] [RFC libdrm 4/5] android: Remove member name from alloc_handle_t

2017-12-13 Thread Robert Foss
The name member of alloc_handle_t is no longer needed and has been removed. The version field has also been bumped. Signed-off-by: Robert Foss --- android/alloc_handle.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/android/alloc_handle.h b/android/alloc_handle.h index

[Mesa-dev] [RFC libdrm 2/5] android: Add version variable to alloc_handle_t

2017-12-13 Thread Robert Foss
The version variable will be used for versioning of this struct and the corresponding accessor functions. Signed-off-by: Robert Foss --- android/alloc_handle.h | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/android/alloc_handle.h b/android/alloc_handle.h index

[Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2017-12-13 Thread Robert Foss
seful. [1] https://lists.freedesktop.org/archives/mesa-dev/2017-November/178199.html Robert Foss (5): android: Move gralloc handle struct to libdrm android: Add version variable to alloc_handle_t android: Mark alloc_handle_t magic variable as const android: Remove member name from all

[Mesa-dev] [RFC libdrm 1/5] android: Move gralloc handle struct to libdrm

2017-12-13 Thread Robert Foss
: Robert Foss --- Android.mk | 8 +++-- Makefile.sources | 3 ++ android/alloc_handle.h | 84 android/gralloc_drm_handle.h | 1 + 4 files changed, 94 insertions(+), 2 deletions(-) create mode 100644 android

[Mesa-dev] [RFC libdrm 3/5] android: Mark alloc_handle_t magic variable as const

2017-12-13 Thread Robert Foss
Mark magic member of alloc_handle_t as const. Also bump the version of alloc_handle_t. Sign-off-by: Robert Foss --- android/alloc_handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/alloc_handle.h b/android/alloc_handle.h index b722615638e7..fe93ad7e6567

[Mesa-dev] [RFC libdrm 5/5] android: Change alloc_handle_t format from Android format to fourcc

2017-12-13 Thread Robert Foss
version. Sign-off-by: Robert Foss --- android/alloc_handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/alloc_handle.h b/android/alloc_handle.h index ed9a720a8990..70a311a8cfa9 100644 --- a/android/alloc_handle.h +++ b/android/alloc_handle.h @@ -38,7 +38,7

Re: [Mesa-dev] [PATCH v2] egl/android: Partially handle HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED

2017-12-13 Thread Robert Foss
Hey Rob&Emil, I've chatted to both of you about this patch, and it seemed acceptable to both of you. Can I have a s-o-b for either of you? Rob. On Mon, 2017-12-04 at 19:22 +0100, Robert Foss wrote: > From: Tomasz Figa > > There is no API available to

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2017-12-15 Thread Robert Foss
Rob Herring (gbm_gralloc) and Kalyan Kondapally (intel-minigbm) too. The previous related discussion can be found here: https://patchwork.freedesktop.org/patch/190406/ Rob. > > On Wed, Dec 13, 2017 at 9:30 AM, Robert Foss om> wrote: > > This series moves {gbm,drm,cros}_gralloc_ha

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2018-01-04 Thread Robert Foss
shortcomings of the gralloc API for DRM/KMS use > > > > cases. > > > > > > I think there might be also d). Define a standard struct in libdrm > headers and add a custom call to gralloc that would fill in such > struct for given buffer. This would keep

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2018-01-11 Thread Robert Foss
regards, Tomasz On Wed, Dec 13, 2017 at 9:30 AM, Robert Foss wrote: This series moves {gbm,drm,cros}_gralloc_handle_t struct to libdrm, since at least 4 implementations exist, and share a lot of contents. The idea is to keep the common stuff defined in one place, and libdrm is the common

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2018-01-12 Thread Robert Foss
On 1/12/18 9:29 AM, Tomasz Figa wrote: Hi Rob, On Fri, Jan 12, 2018 at 5:26 AM, Robert Foss wrote: Heya, On 12/22/17 1:09 PM, Tomasz Figa wrote: On Fri, Dec 22, 2017 at 10:09 AM, Gurchetan Singh wrote: So the plan is for alloc_handle_t to not be sub-classed by the implementations

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2018-01-15 Thread Robert Foss
44 AM, Rob Herring <mailto:r...@kernel.org>> wrote: On Fri, Jan 12, 2018 at 2:29 AM, Tomasz Figa mailto:tf...@chromium.org>> wrote: > Hi Rob, > > On Fri, Jan 12, 2018 at 5:26 AM, Robert Foss mailto:robert.f...@collabora.com>> wrote: >> Heya,

Re: [Mesa-dev] [RFC libdrm 0/5] Move alloc_handle_t from gralloc impls.

2018-01-15 Thread Robert Foss
Hey Tomasz, On 01/15/2018 04:03 PM, Tomasz Figa wrote: On Tue, Jan 16, 2018 at 12:00 AM, Rob Herring wrote: On Mon, Jan 15, 2018 at 7:09 AM, Robert Foss wrote: Hey, On 01/13/2018 12:49 AM, Gurchetan Singh wrote: We can define accessor functions too (not ptrs), then the struct is

[Mesa-dev] [PATCH v1 6/7] android: Change gralloc_handle_t members to be fixed width

2018-01-16 Thread Robert Foss
In order to lessen future alignment issues, lets switch to fixed width integers where possible. This excludes the data_owner since it is a pid_t which in theory could be larger than 32 bits. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 22 -- 1 file changed, 12

[Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-01-16 Thread Robert Foss
defined in libdrm will make it easier for mesa and gralloc implementations to communicate. Robert Foss (7): android: Move gralloc handle struct to libdrm android: Add version variable to gralloc_handle_t android: Mark gralloc_handle_t magic variable as const android: Remove member name from

[Mesa-dev] [PATCH v1 2/7] android: Add version variable to gralloc_handle_t

2018-01-16 Thread Robert Foss
The version variable will be used for versioning of this struct and the corresponding accessor functions. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h

[Mesa-dev] [PATCH v1 1/7] android: Move gralloc handle struct to libdrm

2018-01-16 Thread Robert Foss
: Robert Foss Signed-off-by: Robert Foss --- Android.mk | 8 +++-- Makefile.sources | 3 ++ android/gralloc_handle.h | 84 3 files changed, 93 insertions(+), 2 deletions(-) create mode 100644 android/gralloc_handle.h diff --git

[Mesa-dev] [PATCH v1 3/7] android: Mark gralloc_handle_t magic variable as const

2018-01-16 Thread Robert Foss
Mark magic member of gralloc_handle_t as const. Sign-off-by: Robert Foss Signed-off-by: Robert Foss --- android/gralloc_handle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 647351eedaf7..e4ef8179f584 100644 --- a

[Mesa-dev] [PATCH v1 4/7] android: Remove member name from gralloc_handle_t

2018-01-16 Thread Robert Foss
The name member of gralloc_handle_t is no longer needed and has been removed. The version field has also been bumped. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h

[Mesa-dev] [PATCH v1 5/7] android: Change gralloc_handle_t format from Android format to fourcc

2018-01-16 Thread Robert Foss
version. Sign-off-by: Robert Foss --- android/gralloc_handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 827c001fdcbb..098ec22a6f5f 100644 --- a/android/gralloc_handle.h +++ b/android/gralloc_handle.h @@ -39,7

[Mesa-dev] [PATCH v1 7/7] android: Add accessor functions for gralloc_handle_t variables

2018-01-16 Thread Robert Foss
Supply accessor functions for most of the common gralloc_handle_t variables. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 57 1 file changed, 57 insertions(+) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index

Re: [Mesa-dev] [PATCH 3/3] egl/android: Add DRM node probing and filtering

2018-06-09 Thread Robert Foss
Hey Tomasz, On 2018-05-25 09:27, Tomasz Figa wrote: > Hi Rob, > > Finally got to review this. Please see my comments inline. > > On Fri, May 11, 2018 at 10:48 PM Robert Foss > wrote: > [snip] >> +EGLBoolean >> +droid_load_driver(_EGLDisplay *disp) >

Re: [Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-06-09 Thread Robert Foss
Hey, On 2018-05-25 17:38, Rob Herring wrote: On Fri, May 25, 2018 at 9:25 AM, Tomasz Figa wrote: On Fri, May 25, 2018 at 10:59 PM Rob Herring wrote: On Fri, May 25, 2018 at 4:15 AM, Robert Foss wrote: On 2018-05-25 10:38, Tomasz Figa wrote: On Fri, May 25, 2018 at 5:33 PM Robert

[Mesa-dev] [PATCH v3 2/3] egl/android: #ifdef out flink name support

2018-06-09 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss --- Changes

[Mesa-dev] [PATCH v3 3/3] egl/android: Add DRM node probing and filtering

2018-06-09 Thread Robert Foss
y. Signed-off-by: Robert Foss --- Changes since v2: - Switch from drmGetDevices2 to manual renderD node iteration - Add probe_res enum to communicate probing results better - Avoid using _eglError() in internal static functions - Avoid actually loading the driver while probing, just verify

[Mesa-dev] [PATCH v3 0/3] egl/android: Remove dependencies on specific grallocs

2018-06-09 Thread Robert Foss
: - Rebased work on the libdrm patch [2]. - Included patch from Rob Herring disabling drm_gralloc/flink support by default. - Added device handler driver probing. Rob Herring (1): egl/android: #ifdef out flink name support Robert Foss (2): gallium/util: Fix build error due to cast to

[Mesa-dev] [PATCH v3 1/3] gallium/util: Fix build error due to cast to different size

2018-06-09 Thread Robert Foss
Signed-off-by: Robert Foss --- src/gallium/auxiliary/util/u_debug_stack_android.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/util/u_debug_stack_android.cpp b/src/gallium/auxiliary/util/u_debug_stack_android.cpp index b3d56aebe6..395a1fe911

Re: [Mesa-dev] [PATCH v3 3/3] egl/android: Add DRM node probing and filtering

2018-06-18 Thread Robert Foss
On 2018-06-14 04:54, Tomasz Figa wrote: On Thu, Jun 14, 2018 at 4:14 AM Rob Herring wrote: On Wed, Jun 13, 2018 at 12:19 PM, Amit Pundir wrote: On 13 June 2018 at 20:45, Rob Herring wrote: +Amit and John On Sat, Jun 9, 2018 at 11:27 AM, Robert Foss wrote: This patch both adds

Re: [Mesa-dev] [PATCH v3 3/3] egl/android: Add DRM node probing and filtering

2018-06-20 Thread Robert Foss
Hey Tomasz, Thanks for the quick feedback. On 2018-06-14 08:30, Tomasz Figa wrote: Hi Rob, Thanks for sending v3. Please see few more comments inline. On Sun, Jun 10, 2018 at 2:28 AM Robert Foss wrote: This patch both adds support for probing & filtering DRM nodes and switches away

[Mesa-dev] [PATCH v4 1/3] gallium/util: Fix build error due to cast to different size

2018-06-20 Thread Robert Foss
Signed-off-by: Robert Foss Reviewed-by: Tomasz Figa --- Changes since v3: - Added r-b from Tomasz src/gallium/auxiliary/util/u_debug_stack_android.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/util/u_debug_stack_android.cpp b/src/gallium

[Mesa-dev] [PATCH v4 2/3] egl/android: #ifdef out flink name support

2018-06-20 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss Reviewed-by

[Mesa-dev] [PATCH v4 3/3] egl/android: Add DRM node probing and filtering

2018-06-20 Thread Robert Foss
y. Signed-off-by: Robert Foss --- Changes since v3: - Reduced number of probing return codes - Simplified driver vendor check in droid_probe_device() - Fixed type with ';' prepended to a if-statement - Removed a strlen call - Switched a sprintf to snprintf - Replaced fd == -1 chec

[Mesa-dev] [PATCH v4 0/3] egl/android: Add DRM node probing and filtering

2018-06-20 Thread Robert Foss
ng (1): egl/android: #ifdef out flink name support Robert Foss (2): gallium/util: Fix build error due to cast to different size egl/android: Add DRM node probing and filtering src/egl/Android.mk| 6 +- src/egl/drivers/dri2/egl_dri2.h | 2 - sr

[Mesa-dev] [PATCH v5 1/3] gallium/util: Fix build error due to cast to different size

2018-06-22 Thread Robert Foss
Signed-off-by: Robert Foss Reviewed-by: Tomasz Figa Reviewed-by: Marek Olšák --- Changes since v4: - Added r-b from Marek Changes since v3: - Added r-b from Tomasz src/gallium/auxiliary/util/u_debug_stack_android.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[Mesa-dev] [PATCH v5 3/3] egl/android: Add DRM node probing and filtering

2018-06-22 Thread Robert Foss
y. Signed-off-by: Robert Foss Reviewed-by: Tomasz Figa --- Changes since v4: - Removed dead continue statement - Switched function argument to const char* from char* - Added r-b from Tomasz Changes since v3: - Reduced number of probing return codes - Simplified driver vendor check in droi

[Mesa-dev] [PATCH v5 2/3] egl/android: #ifdef out flink name support

2018-06-22 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss Reviewed-by

[Mesa-dev] [PATCH v5 0/3] egl/android: Add DRM node probing and filtering

2018-06-22 Thread Robert Foss
m Rob Herring disabling drm_gralloc/flink support by default. - Added device handler driver probing. Rob Herring (1): egl/android: #ifdef out flink name support Robert Foss (2): gallium/util: Fix build error due to cast to different size egl/android: Add DRM node probing and filtering src/e

[Mesa-dev] [RESEND PATCH v5 1/3] gallium/util: Fix build error due to cast to different size

2018-06-25 Thread Robert Foss
Signed-off-by: Robert Foss Reviewed-by: Tomasz Figa Reviewed-by: Marek Olšák --- Changes since v4: - Added r-b from Marek Changes since v3: - Added r-b from Tomasz src/gallium/auxiliary/util/u_debug_stack_android.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a

[Mesa-dev] [RESEND PATCH v5 0/3] egl/android: Add DRM node probing and filtering

2018-06-25 Thread Robert Foss
m devices are found Changes since RFC: - Rebased work on the libdrm patch [2]. - Included patch from Rob Herring disabling drm_gralloc/flink support by default. - Added device handler driver probing. Rob Herring (1): egl/android: #ifdef out flink name support Robert Foss (2): gallium/ut

[Mesa-dev] [RESEND PATCH v5 2/3] egl/android: #ifdef out flink name support

2018-06-25 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss Reviewed-by

[Mesa-dev] [RESEND PATCH v5 3/3] egl/android: Add DRM node probing and filtering

2018-06-25 Thread Robert Foss
y. Signed-off-by: Robert Foss Reviewed-by: Tomasz Figa --- Changes since v4: - Removed dead continue statement - Switched function argument to const char* from char* - Added r-b from Tomasz Changes since v3: - Reduced number of probing return codes - Simplified driver vendor check in droi

Re: [Mesa-dev] [RESEND PATCH v5 0/3] egl/android: Add DRM node probing and filtering

2018-06-25 Thread Robert Foss
Pushed. On 2018-06-25 13:39, Robert Foss wrote: [RESEND] due to the previous version sent to the ML mistakenly being v4 again. Please excuse the spam. This series replaces the dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD with DRM node probing and disables the support for drm_gralloc. The

[Mesa-dev] [RFC] egl/android: Add DRM node probing and filtering

2018-04-18 Thread Robert Foss
property. The filtering itself is done using the newly introduced libdrm drmHandleMatch() call. Signed-off-by: Robert Foss --- This patch is based on[1], which contains a new libdrm function, called drmHandleMatch(), which allows for matching an opened drm node handle against some desired properties.

Re: [Mesa-dev] [RFC] egl/android: Add DRM node probing and filtering

2018-04-20 Thread Robert Foss
On 04/20/2018 06:41 AM, Tomasz Figa wrote: Hi Rob, On Thu, Apr 19, 2018 at 1:03 AM Robert Foss wrote: This patch both adds support for probing & filtering DRM nodes and switches away from using the GRALLOC_MODULE_PERFORM_GET_DRM_FD gralloc call. Currently the filtering is based jus

Re: [Mesa-dev] [RFC] egl/android: Add DRM node probing and filtering

2018-04-20 Thread Robert Foss
On 04/20/2018 09:38 AM, Tomasz Figa wrote: On Fri, Apr 20, 2018 at 4:17 PM Robert Foss wrote: On 04/20/2018 06:41 AM, Tomasz Figa wrote: Hi Rob, On Thu, Apr 19, 2018 at 1:03 AM Robert Foss wrote: This patch both adds support for probing & filtering DRM nodes and switches away

Re: [Mesa-dev] [PATCH] egl/android: remove flink name support

2018-04-20 Thread Robert Foss
Hey Rob, This looks good to me. Do you mind if I carry this patch my series to get it all pushed upstream at once? Rob. On 04/19/2018 11:09 PM, Rob Herring wrote: Maintaining both flink names and prime fd support which are provided by 2 different gralloc implementations is problematic becaus

Re: [Mesa-dev] [PATCH] egl/android: remove flink name support

2018-04-24 Thread Robert Foss
Hey Chih-Wei, On 04/23/2018 04:17 AM, Chih-Wei Huang wrote: What's the impact to drm_gralloc? I'm not terribly familiar with drm_gralloc, but as far as I understand it depends on flink name support at the moment. The overarching idea here is to make mesa gralloc independent, but also at the

Re: [Mesa-dev] [PATCH] egl/android: remove flink name support

2018-04-25 Thread Robert Foss
Hey Emil & Chih-Wei, On 04/24/2018 01:59 PM, Emil Velikov wrote: On 24 April 2018 at 12:28, Emil Velikov wrote: On the topic of keeping the old code behind a #define or just removing it, it'll be great if interested parties can reach a consensus. Actually one can simply drop this code and

Re: [Mesa-dev] [PATCH] egl/android: remove flink name support

2018-04-26 Thread Robert Foss
On 04/26/2018 07:43 PM, Emil Velikov wrote: On 26 April 2018 at 18:34, Rob Herring wrote: On Thu, Apr 26, 2018 at 11:56 AM, Emil Velikov wrote: On 26 April 2018 at 03:30, Chih-Wei Huang wrote: 2018-04-25 19:55 GMT+08:00 Robert Foss : Hey Emil & Chih-Wei, On 04/24/2018 01:59 PM,

[Mesa-dev] [PATCH v1 0/2] egl/android: Remove dependencies on specific grallocs

2018-04-27 Thread Robert Foss
] https://patchwork.freedesktop.org/patch/219194/ Rob Herring (1): egl/android: #ifdef out flink name support Robert Foss (1): egl/android: Add DRM node probing and filtering src/egl/Android.mk | 6 +- src/egl/drivers/dri2/egl_dri2.h | 2 - src/egl/drivers

[Mesa-dev] [PATCH v1 2/2] egl/android: Add DRM node probing and filtering

2018-04-27 Thread Robert Foss
property. The filtering itself is done using the newly introduced libdrm drmHandleMatch() call. Signed-off-by: Robert Foss --- Changes since RFC: - Instead of removing code, #ifdef it out. src/egl/drivers/dri2/platform_android.c | 193 ++-- 1 file changed, 135 insertions(+)

[Mesa-dev] [PATCH v1 1/2] egl/android: #ifdef out flink name support

2018-04-27 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss --- Changes

Re: [Mesa-dev] [PATCH v1 1/2] egl/android: #ifdef out flink name support

2018-05-01 Thread Robert Foss
Hey, On 2018-05-01 08:29, Tomasz Figa wrote: On Tue, May 1, 2018 at 11:20 AM Rob Herring wrote: On Fri, Apr 27, 2018 at 6:57 AM, Robert Foss wrote: From: Rob Herring [snip] @@ -1228,20 +1254,31 @@ dri2_initialize_android(_EGLDriver *drv, _EGLDisplay *disp) dri2_dpy

Re: [Mesa-dev] [PATCH v1 1/2] egl/android: #ifdef out flink name support

2018-05-01 Thread Robert Foss
Hey Rob, On 2018-05-01 04:20, Rob Herring wrote: On Fri, Apr 27, 2018 at 6:57 AM, Robert Foss wrote: From: Rob Herring Maintaining both flink names and prime fd support which are provided by 2 different gralloc implementations is problematic because we have a dependency on a specific

Re: [Mesa-dev] [PATCH v1 1/2] egl/android: #ifdef out flink name support

2018-05-02 Thread Robert Foss
Heya, On 2018-05-01 18:44, Rob Herring wrote: On Tue, May 1, 2018 at 3:13 AM, Robert Foss wrote: Hey Rob, On 2018-05-01 04:20, Rob Herring wrote: On Fri, Apr 27, 2018 at 6:57 AM, Robert Foss wrote: From: Rob Herring Maintaining both flink names and prime fd support which are provided

[Mesa-dev] [PATCH 1/3] gallium/util: Fix build error due to cast to different size

2018-05-11 Thread Robert Foss
Signed-off-by: Robert Foss --- src/gallium/auxiliary/util/u_debug_stack_android.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/util/u_debug_stack_android.cpp b/src/gallium/auxiliary/util/u_debug_stack_android.cpp index b3d56aebe6..395a1fe911

[Mesa-dev] [PATCH 3/3] egl/android: Add DRM node probing and filtering

2018-05-11 Thread Robert Foss
property. The filtering itself is done using the newly introduced libdrm drmHandleMatch() call. Signed-off-by: Robert Foss --- Changes since v1: - Do not rely on libdrm for probing - Distinguish between errors and when no drm devices are found Changes since RFC: - Rebased on newer libdrm drmHan

[Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-05-11 Thread Robert Foss
: - Rebased work on the libdrm patch [2]. - Included patch from Rob Herring disabling drm_gralloc/flink support by default. - Added device handler driver probing. Rob Herring (1): egl/android: #ifdef out flink name support Robert Foss (2): gallium/util: Fix build error due to cast to

[Mesa-dev] [PATCH 2/3] egl/android: #ifdef out flink name support

2018-05-11 Thread Robert Foss
. The dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD remains for now, but the definition is added locally to remove the header dependency. drm_gralloc support can be enabled by setting BOARD_USES_DRM_GRALLOC=true in BoardConfig.mk. Signed-off-by: Rob Herring Signed-off-by: Robert Foss --- Changes

Re: [Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-05-14 Thread Robert Foss
Hey, After today I'll be out of the office until the 23rd, So if this series looks ok, I won't be able to re-spin it with more tags. So feel free to just push it if possible. Rob. On 2018-05-11 15:47, Robert Foss wrote: This series replaces the dep

Re: [Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-05-24 Thread Robert Foss
on. Rob. On 2018-05-11 15:47, Robert Foss wrote: This series replaces the dependency on GRALLOC_MODULE_PERFORM_GET_DRM_FD with DRM node probing and disables the support for drm_gralloc. The series has been tested on Qemu+AOSP, where a virtio gpu was successfully probed for and opened. Th

Re: [Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-05-25 Thread Robert Foss
Hey, On 2018-05-25 02:17, Rob Herring wrote: On Thu, May 24, 2018 at 6:23 AM, Robert Foss wrote: Hey, I don't think I've received any feedback on this version yet. If anyone has some time to spare, it would be nice to get it merged. Just to be clear about the libdrm branch lin

Re: [Mesa-dev] [PATCH 0/3] egl/android: Remove dependencies on specific grallocs

2018-05-25 Thread Robert Foss
On 2018-05-25 10:38, Tomasz Figa wrote: On Fri, May 25, 2018 at 5:33 PM Robert Foss wrote: Hey, On 2018-05-25 02:17, Rob Herring wrote: On Thu, May 24, 2018 at 6:23 AM, Robert Foss wrote: Hey, I don't think I've received any feedback on this version yet. If anyone has so

Re: [Mesa-dev] [PATCH] egl/android: rework device probing

2018-08-24 Thread Robert Foss
userspace will be able to create a separate EGL display for each device, query device details and make the conscious decision which one to use. Cc: Robert Foss Cc: Tomasz Figa Signed-off-by: Emil Velikov --- Thanks for the clarification Tomasz. The original code was using a fall-back even a

Re: [Mesa-dev] [PATCH] egl/android: rework device probing

2018-08-27 Thread Robert Foss
Hey, On 27/08/2018 11.47, Emil Velikov wrote: On 24 August 2018 at 18:55, Robert Foss wrote: Hey Emil, On 24/08/2018 14.21, Emil Velikov wrote: From: Emil Velikov Unlike the other platforms, here we aim do guess if the device that we somewhat arbitrarily picked, is supported or not. In

Re: [Mesa-dev] [PATCH] virgl: Use file descriptor instead of un-allocated object

2018-11-19 Thread Robert Foss
Hey Gert, Nice catch! Reviewed-by: Robert Foss On 2018-11-19 10:56, Gert Wollny wrote: From: Gert Wollny The structure qdws is not allocated at this point, nor is the file descriptor set to it's member. Use the fd directly instead. Fixes: d1a1c21e7621b5177febf191fcd3d3b8ef6

Re: [Mesa-dev] [PATCH] virgl: fix vtest regression since fencing changes.

2018-11-19 Thread Robert Foss
Hey Dave, Thanks for catching this, pushed! On 2018-11-19 06:47, Dave Airlie wrote: From: Dave Airlie The in_fence_fd needs to be initialised to -1. Fixes: d1a1c21e7 (virgl: native fence fd support) --- src/gallium/winsys/virgl/vtest/virgl_vtest_winsys.c | 1 + 1 file changed, 1 insertion

Re: [Mesa-dev] [PATCH mesa 1/2] virgl: add missing function parameter

2018-11-20 Thread Robert Foss
Hey Eric, On 2018-11-20 13:36, Eric Engestrom wrote: Fixes: d1a1c21e7621b5177feb "virgl: native fence fd support" Cc: Robert Foss Cc: Emil Velikov Signed-off-by: Eric Engestrom --- I don't know if something should be done with the fd type in this function, so one of you mig

[Mesa-dev] [PATCH v1] virgl: add assert and missing function parameter

2018-11-20 Thread Robert Foss
Verify the pipe_fd_type to be of PIPE_FD_TYPE_NATIVE_SYNC. Suggested-by: Eric Engestrom Signed-off-by: Robert Foss --- src/gallium/drivers/virgl/virgl_context.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/gallium/drivers/virgl/virgl_context.c b/src/gallium

Re: [Mesa-dev] [PATCH 1/2] virgl,vtest: Initialize return value

2018-11-27 Thread Robert Foss
This patch has been: Reviewed-by: Robert Foss On 2018-11-27 20:50, Gert Wollny wrote: From: Gert Wollny Avoids: Conditional jump or move depends on uninitialised value(s) at 0x9E2B39F: virgl_vtest_winsys_resource_cache_create (virgl_vtest_winsys.c:379) by 0x9E2725F

Re: [Mesa-dev] [PATCH 2/2] virgl: Don't try handling server fences when they are not supported

2018-11-27 Thread Robert Foss
This patch has been: Reviewed-by: Robert Foss On 2018-11-27 20:50, Gert Wollny wrote: From: Gert Wollny vtest doesn't implement the according API and would segfault: Program received signal SIGSEGV, Segmentation fault. #0 0x in ?? () #1 in virgl_fence_server

Re: [Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-02-20 Thread Robert Foss
Hey Tomasz, On 02/20/2018 09:55 AM, Tomasz Figa wrote: Hi Rob, On Fri, Feb 16, 2018 at 11:48 PM, Tomasz Figa wrote: On Fri, Feb 16, 2018 at 11:33 PM, Robert Foss wrote: Hey Tomasz, On 02/16/2018 05:10 AM, Tomaszzz Figa wrote: On Fri, Feb 9, 2018 at 11:06 PM, Rob Herring wrote: On

Re: [Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-01-25 Thread Robert Foss
Hey Tomasz, On 01/24/2018 11:04 AM, Tomasz Figa wrote: Hi Robert, On Wed, Jan 17, 2018 at 2:36 AM, Robert Foss wrote: This series moves {gbm,drm,cros}_gralloc_handle_t struct to libdrm, since at least 4 implementations exist, and share a lot of contents. The idea is to keep the common stuff

Re: [Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-01-29 Thread Robert Foss
On 01/25/2018 08:52 PM, Rob Herring wrote: On Thu, Jan 25, 2018 at 10:21 AM, Robert Foss wrote: Hey Tomasz, On 01/24/2018 11:04 AM, Tomasz Figa wrote: Hi Robert, On Wed, Jan 17, 2018 at 2:36 AM, Robert Foss wrote: This series moves {gbm,drm,cros}_gralloc_handle_t struct to libdrm

Re: [Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-01-29 Thread Robert Foss
b. On 01/29/2018 01:03 PM, Robert Foss wrote: On 01/25/2018 08:52 PM, Rob Herring wrote: On Thu, Jan 25, 2018 at 10:21 AM, Robert Foss wrote: Hey Tomasz, On 01/24/2018 11:04 AM, Tomasz Figa wrote: Hi Robert, On Wed, Jan 17, 2018 at 2:36 AM, Robert Foss wrote: This series moves {gbm,dr

[Mesa-dev] [PATCH v2 0/6] Implement commont gralloc_handle_t in libdrm

2018-01-29 Thread Robert Foss
in libdrm will make it easier for mesa and gralloc implementations to communicate. A second series is expected to be submitted, which will contain an accessor function implementation that should that would allow each gralloc to implementation to supply their own accessors. Robert Foss (6

[Mesa-dev] [PATCH v2 1/6] android: Move gralloc handle struct to libdrm

2018-01-29 Thread Robert Foss
: Robert Foss --- Changes since v1: Suggested by Rob Herring: - Fixed copyright statement - Moved FDs to be first in handle - Initialize native_handle_t using native_handle_create() Android.mk | 8 +++- Makefile.sources | 3 ++ android/gralloc_handle.h | 102

[Mesa-dev] [PATCH v2 4/6] android: Remove member name from gralloc_handle_t

2018-01-29 Thread Robert Foss
The name member of gralloc_handle_t is no longer needed and has been removed. The version field has also been bumped. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h

[Mesa-dev] [PATCH v2 3/6] android: Mark gralloc_handle_t magic variable as const

2018-01-29 Thread Robert Foss
Mark magic member of gralloc_handle_t as const. Sign-off-by: Robert Foss Signed-off-by: Robert Foss --- android/gralloc_handle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 8abc83de4626..64196c0b40e7 100644 --- a

[Mesa-dev] [PATCH v2 2/6] android: Add version variable to gralloc_handle_t

2018-01-29 Thread Robert Foss
The version variable will be used for versioning of this struct and the corresponding accessor functions. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index

[Mesa-dev] [PATCH v2 5/6] android: Change gralloc_handle_t format from Android format to fourcc

2018-01-29 Thread Robert Foss
version. Sign-off-by: Robert Foss --- android/gralloc_handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 1e738017d9cb..d437f7648fad 100644 --- a/android/gralloc_handle.h +++ b/android/gralloc_handle.h @@ -57,7

[Mesa-dev] [PATCH v2 6/6] android: Change gralloc_handle_t members to be fixed width

2018-01-29 Thread Robert Foss
In order to lessen future alignment issues, lets switch to fixed width integers where possible. This excludes the data_owner since it is a pid_t which in theory could be larger than 32 bits. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 20 +++- 1 file changed, 11

Re: [Mesa-dev] [PATCH v1 0/7] Implement commont gralloc_handle_t in libdrm

2018-01-30 Thread Robert Foss
On 01/30/2018 04:16 AM, Tomasz Figa wrote: Hi Rob, On Tue, Jan 30, 2018 at 1:17 AM, Robert Foss wrote: Hey Tomasz, I'm tempted to split this work into two parts. 1) Move gbm&drm gralloc struct Alright, if we look at this only as an attempt to converge gbm_ and drm_gralloc, it&#x

Re: [Mesa-dev] [PATCH v2 0/6] Implement commont gralloc_handle_t in libdrm

2018-02-05 Thread Robert Foss
Hey, I haven't seen any feedback, but am looking for an ACK/LGTM. If anyone has a cycle to spare, it would be helpful :) Thanks, Rob. On 01/29/2018 06:37 PM, Robert Foss wrote: This series moves {gbm,drm,cros}_gralloc_handle_t struct to libdrm, since at least 4 implementations exist

Re: [Mesa-dev] [PATCH v2 1/6] android: Move gralloc handle struct to libdrm

2018-02-06 Thread Robert Foss
On 02/06/2018 01:08 AM, Rob Herring wrote: On Mon, Jan 29, 2018 at 11:37 AM, Robert Foss wrote: This struct is used in mesa and drm_hwcomposer. Versions of if have been implemented in several grallocs: drm_gralloc, gbm_gralloc, minigbm and intel-minigbm. Other than the 1:1 move of the

[Mesa-dev] [PATCH v3 0/6] Implement commont gralloc_handle_t in libdrm

2018-02-06 Thread Robert Foss
in libdrm will make it easier for mesa and gralloc implementations to communicate. A second series is expected to be submitted, which will contain an accessor function implementation that should that would allow each gralloc to implementation to supply their own accessors. Robert Foss (6

[Mesa-dev] [PATCH v3 3/6] android: Mark gralloc_handle_t magic variable as const

2018-02-06 Thread Robert Foss
Mark magic member of gralloc_handle_t as const. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 7cbc8ee7cef3..5d8a19ea0c2e 100644 --- a/android/gralloc_handle.h

[Mesa-dev] [PATCH v3 6/6] android: Change gralloc_handle_t members to be fixed width

2018-02-06 Thread Robert Foss
In order to lessen future alignment issues, lets switch to fixed width integers where possible. This excludes the data_owner since it is a pid_t which in theory could be larger than 32 bits. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 20 +++- 1 file changed, 11

[Mesa-dev] [PATCH v3 2/6] android: Add version variable to gralloc_handle_t

2018-02-06 Thread Robert Foss
The version variable will be used for versioning of this struct and the corresponding accessor functions. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index

[Mesa-dev] [PATCH v3 1/6] android: Move gralloc handle struct to libdrm

2018-02-06 Thread Robert Foss
: Robert Foss --- Changes since v2: Suggested by Rob Herring: - Switch to gbm_gralloc copyright statement as a base Changes since v1: Suggested by Rob Herring: - Fixed copyright statement - Moved FDs to be first in handle - Initialize native_handle_t using native_handle_create() Android.mk

[Mesa-dev] [PATCH v3 4/6] android: Remove member name from gralloc_handle_t

2018-02-06 Thread Robert Foss
The name member of gralloc_handle_t is no longer needed and has been removed. The version field has also been bumped. Signed-off-by: Robert Foss --- android/gralloc_handle.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h

[Mesa-dev] [PATCH v3 5/6] android: Change gralloc_handle_t format from Android format to fourcc

2018-02-06 Thread Robert Foss
version. Sign-off-by: Robert Foss --- android/gralloc_handle.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 9648b006c982..60895a0a5255 100644 --- a/android/gralloc_handle.h +++ b/android/gralloc_handle.h @@ -56,7

[Mesa-dev] [PATCH v4 5/5] android: Change gralloc_handle_t members to be fixed width

2018-02-12 Thread Robert Foss
In order to lessen future alignment issues, lets switch to fixed width integers where possible. This excludes the data_owner since it is a pid_t which in theory could be larger than 32 bits. Signed-off-by: Robert Foss Reviewed-by: Rob Herring --- android/gralloc_handle.h | 20

[Mesa-dev] [PATCH v4 3/5] android: Mark gralloc_handle_t magic variable as const

2018-02-12 Thread Robert Foss
Mark magic member of gralloc_handle_t as const. Signed-off-by: Robert Foss Reviewed-by: Rob Herring --- android/gralloc_handle.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/gralloc_handle.h b/android/gralloc_handle.h index 7cbc8ee7cef3..5d8a19ea0c2e 100644 --- a

<    1   2   3   >