[Mesa-dev] [PATCH 4/4] util/os_misc: os_get_available_system_memory() for OpenBSD

2019-12-05 Thread Jonathan Gray
Return the smallest value of available non-kernel physical memory and the static per process data size limit as the amount of available system memory on OpenBSD. Signed-off-by: Jonathan Gray --- src/util/os_misc.c | 20 1 file changed, 20 insertions(+) diff --git a/src

[Mesa-dev] [PATCH 2/4] util/os_misc: add os_get_available_system_memory()

2019-12-05 Thread Jonathan Gray
Add os_get_available_system_memory() derived from src/intel/vulkan/anv_device.c get_available_system_memory() Signed-off-by: Jonathan Gray --- src/util/os_misc.c | 31 +++ src/util/os_misc.h | 6 ++ 2 files changed, 37 insertions(+) diff --git a/src/util

[Mesa-dev] [PATCH 3/4] anv: use os_get_available_system_memory()

2019-12-05 Thread Jonathan Gray
Replace local get_available_system_memory() function with os_get_available_system_memory(). Signed-off-by: Jonathan Gray --- src/intel/vulkan/anv_device.c | 30 -- 1 file changed, 4 insertions(+), 26 deletions(-) diff --git a/src/intel/vulkan/anv_device.c b/src

[Mesa-dev] [PATCH 1/4] anv: use os_get_total_physical_memory()

2019-12-05 Thread Jonathan Gray
Replace non-portable sysinfo() use with Mesa's os_get_total_physical_memory() Signed-off-by: Jonathan Gray --- src/intel/vulkan/anv_device.c | 9 - 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c

Re: [Mesa-dev] CVE-2019-19520: Local privilege escalation via xlock

2019-12-04 Thread Jonathan Gray
On Thu, Dec 05, 2019 at 01:59:50PM +1000, Dave Airlie wrote: > On Thu, 5 Dec 2019 at 13:42, Jonathan Gray wrote: > > > > Until very recently OpenBSD built xlockmore against Mesa. xlock is > > setgid auth. As described by Qualys in their advisory > > https://

[Mesa-dev] CVE-2019-19520: Local privilege escalation via xlock

2019-12-04 Thread Jonathan Gray
Until very recently OpenBSD built xlockmore against Mesa. xlock is setgid auth. As described by Qualys in their advisory https://marc.info/?l=oss-security&m=157549260013521&w=2 "CVE-2019-19520: Local privilege escalation via xlock" the setuid check in the loader for LIBGL_DRIVERS_PATH does not ha

[Mesa-dev] [PATCH] util: unbreak endian detection on OpenBSD

2019-12-04 Thread Jonathan Gray
under the endian.h block did not check if symbols were defined before equating them so '#if __BYTE_ORDER == __LITTLE_ENDIAN' would turn into '#if 0 == 0' which is always true. Signed-off-by: Jonathan Gray Fixes: cbee1bfb342 ("meson/configure: detect endian.h instead of t

Re: [Mesa-dev] [PATCH 2/2] anv: implement OpenBSD get_available_system_memory()

2019-11-30 Thread Jonathan Gray
On Sun, Dec 01, 2019 at 03:22:01AM +1100, Jonathan Gray wrote: > On Sun, Dec 01, 2019 at 02:21:49AM +1100, Jonathan Gray wrote: > > map linux /proc/meminfo "MemAvailable" to uvm free pages > > On second thought HW_USERMEM64 may be a better fit here. > > "The a

Re: [Mesa-dev] [PATCH 2/2] anv: implement OpenBSD get_available_system_memory()

2019-11-30 Thread Jonathan Gray
On Sun, Dec 01, 2019 at 02:21:49AM +1100, Jonathan Gray wrote: > map linux /proc/meminfo "MemAvailable" to uvm free pages On second thought HW_USERMEM64 may be a better fit here. "The amount of available non-kernel memory in bytes" Which ends up being physmem - uvmexp.w

[Mesa-dev] [PATCH 2/2] anv: implement OpenBSD get_available_system_memory()

2019-11-30 Thread Jonathan Gray
map linux /proc/meminfo "MemAvailable" to uvm free pages Signed-off-by: Jonathan Gray --- src/intel/vulkan/anv_device.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index 81e3905ae99..ce93718c106 100644

[Mesa-dev] [PATCH 1/2] anv: get total system memory on OpenBSD

2019-11-30 Thread Jonathan Gray
Use sysctl to get total ram on OpenBSD where sysinfo() is not available. Signed-off-by: Jonathan Gray --- src/intel/vulkan/anv_device.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/src/intel/vulkan/anv_device.c b/src/intel/vulkan/anv_device.c index 250f75e9936

[Mesa-dev] [PATCH] util/futex: use futex syscall on OpenBSD

2019-11-30 Thread Jonathan Gray
Make use of the futex syscall added in OpenBSD 6.2. Signed-off-by: Jonathan Gray --- src/util/futex.h | 18 ++ 1 file changed, 18 insertions(+) diff --git a/src/util/futex.h b/src/util/futex.h index 268af92882a..cf8dd0206c9 100644 --- a/src/util/futex.h +++ b/src/util/futex.h

[Mesa-dev] [PATCH] util/anon_file: add OpenBSD shm_mkstemp() path

2019-11-30 Thread Jonathan Gray
memfd_create() is a linux syscall replace the use of it with shm_mkstemp() on OpenBSD. unconditionally include stdlib.h for mkstemp()/mkostemp() Signed-off-by: Jonathan Gray --- src/util/anon_file.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/util

[Mesa-dev] [PATCH] util/u_thread: don't restrict u_thread_get_time_nano() to __linux__

2019-11-30 Thread Jonathan Gray
pthread_getcpuclockid() and clock_gettime() are also available on at least OpenBSD, FreeBSD, NetBSD, DragonFly, Cygwin. Signed-off-by: Jonathan Gray --- src/util/u_thread.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/u_thread.h b/src/util/u_thread.h index

[Mesa-dev] [PATCH] i965: update Makefile.sources for perf changes

2019-11-27 Thread Jonathan Gray
brw_performance_query_metrics.h was removed in 134e750e16bfc53480e0bba6f0ae3e1d2a7fb87c and brw_performance_query.h was removed in 8ae6667992ccca41d08884d863b8aeb22a4c4e65 remove reference to these files from Makefile.sources Signed-off-by: Jonathan Gray Cc: 19.2 19.3 --- src/mesa/drivers/dri

[Mesa-dev] [PATCH] winsys/amdgpu: avoid double simple_mtx_unlock()

2019-11-27 Thread Jonathan Gray
-by: Jonathan Gray Cc: 19.2 19.3 --- src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c b/src/gallium/winsys/amdgpu/drm/amdgpu_winsys.c index a89432d8594..2fe227c9213 100644 --- a/src/gallium/winsys

Re: [Mesa-dev] [PATCH v2] mapi: avoid text relocation in x86 tsd stubs

2019-11-27 Thread Jonathan Gray
On Sun, Nov 11, 2018 at 03:47:35PM +1100, Jonathan Gray wrote: > Make similiar changes to libglvnd to avoid a text relocation in > x86 tsd stubs fixing the build with lld. > > v2: > - store the address of the GOT in ebx required before calling PLT stub > - change .bali

Re: [Mesa-dev] [PATCH] intel: Add more PCI Device IDs for Coffee Lake and Ice Lake.

2019-02-17 Thread Jonathan Gray
Compared to linux and libdrm Mesa is missing a VLV and ICL id. 0x0f30 ff049b6ce21d2814451afd4a116d001712e0116b drm/i915: bind driver to ValleyView chipsets 0x8A70 d55cb4fa2cf0105bfb16b60a2846737b91fdc173 drm/i915/icl: Add the ICL PCI IDs The Intel Media SDK describes these as /* VLV */

Re: [Mesa-dev] [PATCH] autotools: Deprecate the use of autotools

2019-01-17 Thread Jonathan Gray
On Thu, Jan 17, 2019 at 05:05:41PM -0500, Rob Clark wrote: > On Thu, Jan 17, 2019 at 3:56 PM Jonathan Gray wrote: > > > > On Mon, Jan 14, 2019 at 03:46:35PM +0200, Eero Tamminen wrote: > > > Hi, > > > > > > On 13.1.2019 9.44, Jonathan Gray wrote: > >

Re: [Mesa-dev] [PATCH] autotools: Deprecate the use of autotools

2019-01-17 Thread Jonathan Gray
On Mon, Jan 14, 2019 at 03:46:35PM +0200, Eero Tamminen wrote: > Hi, > > On 13.1.2019 9.44, Jonathan Gray wrote: > ...> As we can not depend on python to build Mesa in OpenBSD I will have to > > go back to maintaining a local Mesa build system if autotools is removed. &g

Re: [Mesa-dev] [PATCH] autotools: Deprecate the use of autotools

2019-01-12 Thread Jonathan Gray
On Fri, Jan 11, 2019 at 02:11:28PM -0800, Matt Turner wrote: > From: Gert Wollny > > Since Meson will eventually be the only build system deprecate autotools > now. It can still be used by invoking configure with the flag > --enable-autotools > > NAKed-by: Ilia Mirkin > Acked-by: Eric Engestr

[Mesa-dev] [PATCH v2] mapi: avoid text relocation in x86 tsd stubs

2018-11-10 Thread Jonathan Gray
Make similiar changes to libglvnd to avoid a text relocation in x86 tsd stubs fixing the build with lld. v2: - store the address of the GOT in ebx required before calling PLT stub - change .balign values to match X86_ENTRY_SIZE Signed-off-by: Jonathan Gray Cc: mesa-sta

Re: [Mesa-dev] [Mesa-stable] [PATCH] mapi: avoid text relocation in x86 tsd stubs

2018-11-10 Thread Jonathan Gray
On Fri, Nov 09, 2018 at 10:30:42PM +1100, Jonathan Gray wrote: > On Thu, Nov 08, 2018 at 03:54:20PM +, Emil Velikov wrote: > > On Fri, 2 Nov 2018 at 00:02, Jonathan Gray wrote: > > > > > > On Thu, Nov 01, 2018 at 12:26:34PM -0700, Ian Romanick wrote: > > >

Re: [Mesa-dev] [Mesa-stable] [PATCH] mapi: avoid text relocation in x86 tsd stubs

2018-11-09 Thread Jonathan Gray
On Thu, Nov 08, 2018 at 03:54:20PM +, Emil Velikov wrote: > On Fri, 2 Nov 2018 at 00:02, Jonathan Gray wrote: > > > > On Thu, Nov 01, 2018 at 12:26:34PM -0700, Ian Romanick wrote: > > > On 10/31/2018 09:08 PM, Jonathan Gray wrote: > > > > Make similiar

Re: [Mesa-dev] [Mesa-stable] [PATCH] mapi: avoid text relocation in x86 tsd stubs

2018-11-01 Thread Jonathan Gray
On Thu, Nov 01, 2018 at 12:26:34PM -0700, Ian Romanick wrote: > On 10/31/2018 09:08 PM, Jonathan Gray wrote: > > Make similiar changes to libglvnd to avoid a text relocation in > > x86 tsd stubs fixing the build with lld. > > > > Signed-off-by: Jona

Re: [Mesa-dev] [PATCH] intel/aubinator_error_decode: link libm

2018-11-01 Thread Jonathan Gray
Patch: https://patchwork.freedesktop.org/patch/259176/ > > On Thu, Nov 1, 2018 at 6:12 AM Jonathan Gray wrote: > > > aubinator_error_decode needs to link libm to build on OpenBSD/i386 > > ../../src/util/.libs/libmesautil.a(libmesautil_la-half_float.o): In > > function `_mesa_float

[Mesa-dev] [PATCH] mapi: avoid text relocation in x86 tsd stubs

2018-10-31 Thread Jonathan Gray
Make similiar changes to libglvnd to avoid a text relocation in x86 tsd stubs fixing the build with lld. Signed-off-by: Jonathan Gray Cc: mesa-sta...@lists.freedesktop.org Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=108541 --- src/mapi/entry_x86_tsd.h | 14 +- 1 file

[Mesa-dev] [PATCH] intel/tools: include stdarg.h in error2aub

2018-10-31 Thread Jonathan Gray
Include stdarg.h in error2aub.c otherwise it fails to build on OpenBSD due to not finding definitions for va_list va_start va_end. Signed-off-by: Jonathan Gray Cc: mesa-sta...@lists.freedesktop.org --- src/intel/tools/error2aub.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/intel

[Mesa-dev] [PATCH] intel/aubinator_error_decode: link libm

2018-10-31 Thread Jonathan Gray
27; Signed-off-by: Jonathan Gray Cc: mesa-sta...@lists.freedesktop.org --- src/intel/Makefile.tools.am | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/intel/Makefile.tools.am b/src/intel/Makefile.tools.am index 4809962b188..da49d37a728 100644 --- a/src/intel/Makefile.too

[Mesa-dev] [PATCH] util/xmlpool: avoid using a GNU make pattern rule

2018-10-31 Thread Jonathan Gray
% pattern rules are a GNU extension. Convert the use of one to a inference rule to allow this to build on OpenBSD. Signed-off-by: Jonathan Gray --- src/util/xmlpool/Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/xmlpool/Makefile.am b/src/util/xmlpool

Re: [Mesa-dev] [PATCH mesa] u_endian: use non-underscore-prefixed BYTE_ORDER names

2018-04-09 Thread Jonathan Gray
What happened with this patch? It seems the problem it is fixing got cherry-picked into 17.3 but the fix for master (and now 17.3) is still not merged? On Wed, Mar 28, 2018 at 06:05:12PM +0100, Eric Engestrom wrote: > Cc: Jonathan Gray > Signed-off-by: Eric Engestrom > --- > Not

Re: [Mesa-dev] [PATCH mesa] meson/configure: detect endian.h instead of trying to guess when it's available

2018-03-27 Thread Jonathan Gray
On Tue, Mar 27, 2018 at 07:36:17PM +0100, Emil Velikov wrote: > On 25 March 2018 at 09:06, Jonathan Gray wrote: > > On Wed, Mar 21, 2018 at 05:09:17PM +, Eric Engestrom wrote: > >> Cc: Maxin B. John > >> Cc: Khem Raj > >> Suggested-by: Jon Turney

Re: [Mesa-dev] [PATCH mesa] meson/configure: detect endian.h instead of trying to guess when it's available

2018-03-25 Thread Jonathan Gray
On Wed, Mar 21, 2018 at 05:09:17PM +, Eric Engestrom wrote: > Cc: Maxin B. John > Cc: Khem Raj > Suggested-by: Jon Turney > Signed-off-by: Eric Engestrom > --- > configure.ac| 1 + > meson.build | 2 +- > src/util/u_endian.h | 2 +- > 3 files changed, 3 insertions(+), 2 del

Re: [Mesa-dev] [PATCH] util: use clock_gettime() on PIPE_OS_BSD

2018-03-01 Thread Jonathan Gray
On Wed, Feb 28, 2018 at 08:22:57AM -0700, Brian Paul wrote: > On 02/28/2018 03:19 AM, Jonathan Gray wrote: > > OpenBSD, FreeBSD, NetBSD and DragonFlyBSD all have clock_gettime() > > so use it when PIPE_OS_BSD is defined. > > > > Signed-off-by: Jonathan Gray > >

[Mesa-dev] [PATCH] gallium/util: use sockets on PIPE_OS_UNIX in u_network

2018-02-28 Thread Jonathan Gray
Instead of listing all the UNIX PIPE_OS platforms just use PIPE_OS_UNIX. Makes BSD sockets available on PIPE_OS_BSD. Signed-off-by: Jonathan Gray --- src/gallium/auxiliary/util/u_network.c | 9 +++-- src/gallium/auxiliary/util/u_network.h | 5 + 2 files changed, 4 insertions(+), 10

[Mesa-dev] [PATCH] util: use clock_gettime() on PIPE_OS_BSD

2018-02-28 Thread Jonathan Gray
OpenBSD, FreeBSD, NetBSD and DragonFlyBSD all have clock_gettime() so use it when PIPE_OS_BSD is defined. Signed-off-by: Jonathan Gray --- src/util/os_time.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/util/os_time.c b/src/util/os_time.c index 72dc7e49c0..ac488b2287

Re: [Mesa-dev] [PATCH 02/14] vc4, vc5: add ETIME fallback define

2018-02-28 Thread Jonathan Gray
On Fri, Jan 19, 2018 at 12:51:30AM +0300, Greg V wrote: > On 01/18/2018 22:49, Dylan Baker wrote: > > Quoting Emil Velikov (2018-01-18 10:40:40) > > > On 18 January 2018 at 17:13, Dylan Baker wrote: > > > > I'm not sure how Emil feels about this (and the related patches) but I > > > > think it >

[Mesa-dev] [PATCH] configure.ac: pthread-stubs not present on OpenBSD

2018-02-19 Thread Jonathan Gray
pthread-stubs is no longer required on OpenBSD and has been removed. libpthread parts involved moved to libc. Signed-off-by: Jonathan Gray Cc: 17.3 18.0 --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 89c5e74127

Re: [Mesa-dev] [PATCH] Android: define PIPE_OS_BSD

2017-06-07 Thread Jonathan Gray
On Wed, Jun 07, 2017 at 11:18:53PM +0800, Chih-Wei Huang wrote: > 2017-06-07 22:47 GMT+08:00 Jonathan Gray : > > On Wed, Jun 07, 2017 at 10:30:49PM +0800, Chih-Wei Huang wrote: > >> 2017-06-07 21:54 GMT+08:00 Jonathan Gray : > >> > On Wed, Jun 07, 2017 at 02:45:

Re: [Mesa-dev] [PATCH] Android: define PIPE_OS_BSD

2017-06-07 Thread Jonathan Gray
On Wed, Jun 07, 2017 at 10:30:49PM +0800, Chih-Wei Huang wrote: > 2017-06-07 21:54 GMT+08:00 Jonathan Gray : > > On Wed, Jun 07, 2017 at 02:45:15PM +0100, Emil Velikov wrote: > >> On 6 June 2017 at 07:30, Chih-Wei Huang wrote: > >> >>> These are are

Re: [Mesa-dev] [PATCH] Android: define PIPE_OS_BSD

2017-06-07 Thread Jonathan Gray
On Wed, Jun 07, 2017 at 02:45:15PM +0100, Emil Velikov wrote: > On 6 June 2017 at 07:30, Chih-Wei Huang wrote: > > 2017-06-06 13:06 GMT+08:00 Chih-Wei Huang : > >> 2017-06-05 21:04 GMT+08:00 Emil Velikov : > >>> On 4 June 2017 at 04:31, Chih-Wei Huang wrote: > Android bionic is derived from

Re: [Mesa-dev] Fix __atomic* builtins detection for Clang

2017-05-13 Thread Jonathan Gray
On Sat, May 13, 2017 at 09:01:49AM +0200, Jan Beich wrote: > Jonathan Gray writes: > > > On Sat, May 13, 2017 at 02:22:30AM +0200, Jan Beich wrote: > > > >> "int" isn't large enough and lack of builtins only manifests at link time. > >> This

Re: [Mesa-dev] Fix __atomic* builtins detection for Clang

2017-05-12 Thread Jonathan Gray
On Sat, May 13, 2017 at 02:22:30AM +0200, Jan Beich wrote: > "int" isn't large enough and lack of builtins only manifests at link time. > This was breaking build on FreeBSD 11.0 i386 with Clang 3.8.0. You should be building with -march=i586 on i386 for CX8. The diff is wrong as it will break othe

Re: [Mesa-dev] [PATCH v2] intel: genxml: fix out of tree builds

2017-03-31 Thread Jonathan Gray
On Fri, Mar 31, 2017 at 04:53:21PM +0100, Emil Velikov wrote: > On 31 March 2017 at 16:33, Lionel Landwerlin > wrote: > > On 31/03/17 16:21, Emil Velikov wrote: > >> > >> On 31 March 2017 at 14:40, Lionel Landwerlin > >> wrote: > >>> > >>> v2: use Emil's recommendation > >>> change rule to c

Re: [Mesa-dev] [PATCH] util/u_atomic: provide 64bit atomics where they're missing

2017-03-29 Thread Jonathan Gray
On Wed, Mar 29, 2017 at 04:55:54PM -0700, Matt Turner wrote: > On Wed, Mar 29, 2017 at 4:13 PM, Grazvydas Ignotas wrote: > > There are still some distributions trying to support unfortunate people > > with old or exotic CPUs that don't have 64bit atomic operations. When > > compiling for such a ma

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-23 Thread Jonathan Gray
On Tue, Mar 21, 2017 at 04:00:37PM +1100, Jonathan Gray wrote: > On Tue, Mar 21, 2017 at 08:28:22AM +1100, Timothy Arceri wrote: > > > > > > On 21/03/17 06:39, Emil Velikov wrote: > > > On 20 March 2017 at 18:30, Matt Turner wrote: > > > > On

Re: [Mesa-dev] [PATCH v2] util/rand_xor: seed with getentropy when available

2017-03-22 Thread Jonathan Gray
On Thu, Mar 23, 2017 at 03:24:16PM +1100, Jonathan Gray wrote: > Instead of using using /dev/urandom on Linux and time(NULL) elsewhere > for a seed first use getentropy() for systems that have a kernel > interface to get a seed such as OpenBSD. This interface is also > present in o

Re: [Mesa-dev] [PATCH v2] util/rand_xor: seed with getentropy when available

2017-03-22 Thread Jonathan Gray
On Thu, Mar 23, 2017 at 03:24:16PM +1100, Jonathan Gray wrote: > Instead of using using /dev/urandom on Linux and time(NULL) elsewhere > for a seed first use getentropy() for systems that have a kernel > interface to get a seed such as OpenBSD. This interface is also > present in o

[Mesa-dev] [PATCH v2] util/rand_xor: seed with getentropy when available

2017-03-22 Thread Jonathan Gray
for/use the different header Solaris and glibc use Signed-off-by: Jonathan Gray --- configure.ac| 4 src/util/rand_xor.c | 17 +++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index bc9c304c8d..c27646ca4c 100644 --- a

[Mesa-dev] [PATCH] util/rand_xor: seed with getentropy when available

2017-03-22 Thread Jonathan Gray
-off-by: Jonathan Gray --- configure.ac| 3 +++ src/util/rand_xor.c | 11 +-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index bc9c304c8d..1a2f58feaf 100644 --- a/configure.ac +++ b/configure.ac @@ -788,6 +788,9 @@ esac dnl See if

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-22 Thread Jonathan Gray
On Wed, Mar 22, 2017 at 01:10:14PM -0700, Dylan Baker wrote: > On Wed, Mar 22, 2017 at 12:40 PM, Alex Deucher wrote: > > I guess I'm a little late to the party here, but I haven't had time to > > really let all of this sink in and actually look at meson. It doesn't > > seem so bad with a quick lo

Re: [Mesa-dev] [PATCH V2 2/3] util/rand_xor: add function to seed rand

2017-03-21 Thread Jonathan Gray
If a proper PRNG like arc4random backed by a syscall like getentropy were used this would already handle reseeding on fork and fd exhaustion. And look people have already gone out of their way to provide fallbacks for these interfaces. https://github.com/libressl-portable/openbsd/tree/master/src/

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-21 Thread Jonathan Gray
On Tue, Mar 21, 2017 at 09:22:50AM -0700, Dylan Baker wrote: > Quoting Jani Nikula (2017-03-21 07:44:55) > > On Thu, 16 Mar 2017, Dylan Baker wrote: > > > First it's written in python, [...] > > > > How does meson handle python 2 vs. 3? How do you avoid issues in the > > build files wrt this? On

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-20 Thread Jonathan Gray
On Mon, Mar 20, 2017 at 11:30:25AM -0700, Matt Turner wrote: > On Mon, Mar 20, 2017 at 6:55 AM, Emil Velikov > wrote: > > Seems like we ended up all over the place, so let me try afresh. > > > > Above all: > > - Saying "I don't care" about your users is arrogant - let us _not_ > > do that, pleas

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-20 Thread Jonathan Gray
pt regenerated to make this work or Mesa won't build due to libtool.m4 looking for specific strings in ld -v produced by bfd binutils or gold... And yes if you change the configure script to check for a newer version I'll revert it locally like I did with the zlib one. As I get the impre

Re: [Mesa-dev] [PATCH] i965: Shut up major()/minor() warnings.

2017-03-20 Thread Jonathan Gray
On Mon, Mar 20, 2017 at 04:05:04PM -0700, Kenneth Graunke wrote: > Recent glibc generates this warning: > > brw_performance_query.c:1648:13: warning: In the GNU C Library, "minor" is > defined > by . For historical compatibility, it is > currently defined by as well, but we plan to > remove t

Re: [Mesa-dev] [PATCH] configure.ac: Use POSIX word boundary regex.

2017-03-17 Thread Jonathan Gray
On Fri, Mar 17, 2017 at 03:45:08PM +0900, Michel D??nzer wrote: > On 17/03/17 07:42 AM, Vinson Lee wrote: > > Fixes: fe56c745b8cb ("Convert sed(1) syntax to be compatible with FreeBSD > > and OpenBSD") > > Not sure how, since \> was already used (way) before that. Indeed FreeBSD and OpenBSD libc

[Mesa-dev] [PATCH] glapi: avoid using $< in non-suffix make rules

2017-03-16 Thread Jonathan Gray
Using $< in non-suffix make rules is a GNU extension. Explicitly use the name of the python script to fix the build on OpenBSD. Signed-off-by: Jonathan Gray --- src/mapi/glapi/gen/Makefile.am | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mapi/glapi/gen/Makefile

Re: [Mesa-dev] [RFC libdrm 0/2] Replace the build system with meson

2017-03-16 Thread Jonathan Gray
On Thu, Mar 16, 2017 at 09:12:38PM -0700, Dylan Baker wrote: > quoting jason ekstrand (2017-03-16 19:03:15) > > on march 16, 2017 5:41:24 pm emil velikov wrote: > > > and meson is not a thing on neither bsd(s), solaris (and derivatives) nor > > > android :-\ > > > > i have trouble bringing mysel

[Mesa-dev] [PATCH] i965: avoid using a GNU make pattern rule

2017-03-15 Thread Jonathan Gray
% pattern rules are a GNU extension. As there is only one file here avoid patterns and globbing entirely to fix the build on non-GNU make. Signed-off-by: Jonathan Gray --- src/mesa/drivers/dri/i965/Makefile.am | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mesa

[Mesa-dev] [PATCH] i965: remove uneeded asm/unistd.h include

2017-03-15 Thread Jonathan Gray
Fix the build on OpenBSD by removing an uneeded include for asm/unistd.h. Signed-off-by: Jonathan Gray --- src/mesa/drivers/dri/i965/brw_performance_query.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_performance_query.c b/src/mesa/drivers/dri/i965

Re: [Mesa-dev] [PATCH v2] i965: Implement INTEL_performance_query backend

2017-02-26 Thread Jonathan Gray
On Thu, Feb 16, 2017 at 01:20:37PM +, Robert Bragg wrote: > diff --git a/src/mesa/drivers/dri/i965/brw_performance_query.c > b/src/mesa/drivers/dri/i965/brw_performance_query.c > new file mode 100644 > index 00..f1b6f583bf > --- /dev/null > +++ b/src/mesa/drivers/dri/i965/brw_performan

[Mesa-dev] [PATCH] util/build-id: define ElfW and NT_GNU_BUILD_ID if needed

2017-02-17 Thread Jonathan Gray
Define ElfW() and NT_GNU_BUILD_ID if needed as these defines are not present on at least OpenBSD and FreeBSD. Fixes the build on OpenBSD. Signed-off-by: Jonathan Gray --- src/util/build_id.c | 8 1 file changed, 8 insertions(+) diff --git a/src/util/build_id.c b/src/util/build_id.c

Re: [Mesa-dev] [PATCH 1/2] util: Add utility build-id code.

2017-02-17 Thread Jonathan Gray
On Fri, Feb 17, 2017 at 08:30:17AM -0800, Matt Turner wrote: > On Fri, Feb 17, 2017 at 5:39 AM, Emil Velikov > wrote: > > On 17 February 2017 at 01:10, Jonathan Gray wrote: > >> On Thu, Feb 16, 2017 at 04:25:02PM +, Emil Velikov wrote: > >>> On 16 Febr

Re: [Mesa-dev] [PATCH 1/2] util: Add utility build-id code.

2017-02-16 Thread Jonathan Gray
On Thu, Feb 16, 2017 at 04:25:02PM +, Emil Velikov wrote: > On 16 February 2017 at 14:23, Jonathan Gray wrote: > > On Wed, Feb 15, 2017 at 11:11:50AM -0800, Matt Turner wrote: > >> Provides the ability to read the .note.gnu.build-id section of ELF > >> binarie

Re: [Mesa-dev] [PATCH 1/2] util: Add utility build-id code.

2017-02-16 Thread Jonathan Gray
On Wed, Feb 15, 2017 at 11:11:50AM -0800, Matt Turner wrote: > Provides the ability to read the .note.gnu.build-id section of ELF > binaries, which is inserted by the --build-id=... flag to ld. > > Reviewed-by: Emil Velikov I don't have time to dig into details right now but this broke the Mesa

Re: [Mesa-dev] [PATCH] util: import sha1 implementation from OpenBSD

2017-01-13 Thread Jonathan Gray
desktop.org/show_bug.cgi?id=94904 > Bugzilla [2]: https://bugs.freedesktop.org/show_bug.cgi?id=97967 > Cc: Mark Janes > Cc: Vinson Lee > Cc: Tapani P??lli > Cc: Jonathan Gray > Signed-off-by: Emil Velikov > --- > configure.ac | 161 +

Re: [Mesa-dev] [PATCH] mesa: don't attempt to unlock an unlocked debug state mutex

2016-12-21 Thread Jonathan Gray
On Tue, Dec 20, 2016 at 11:52:26AM -0800, Kenneth Graunke wrote: > On Tuesday, December 20, 2016 12:08:06 PM PST Jonathan Gray wrote: > > Can someone push this to master? > > Pushed: > > To ssh://git.freedesktop.org/git/mesa/mesa >ab8ea1b..62b8bcd master -> m

Re: [Mesa-dev] [PATCH] mesa: don't attempt to unlock an unlocked debug state mutex

2016-12-19 Thread Jonathan Gray
Can someone push this to master? On Sun, Dec 11, 2016 at 07:21:36PM +0100, Eduardo Lima Mitev wrote: > Looks good. > > Reviewed-by: Eduardo Lima Mitev > > On 12/11/2016 04:42 PM, Jonathan Gray wrote: > > Commit 929fcee47e46781c57f2a354ce0a013915c033d1 introduced code

Re: [Mesa-dev] [Mesa-maintainers] Proposal of date-based Mesa versioning for 2017

2016-12-12 Thread Jonathan Gray
On Mon, Dec 12, 2016 at 03:28:45PM +, Emil Velikov wrote: > [adding mesa-maintainers to the mix] > > On 1 October 2016 at 20:46, Marek Olk wrote: > > Hi, > > > > I propose that we use versioning in the form of "year.quarter". > > > > 2017 would start with 17.0, then 17.1, 17.2, 17.3 for f

Re: [Mesa-dev] [PATCH] mesa: don't attempt to unlock an unlocked debug state mutex

2016-12-11 Thread Jonathan Gray
te: > > Looks good. > > > > Reviewed-by: Eduardo Lima Mitev > > > > On 12/11/2016 04:42 PM, Jonathan Gray wrote: > >> Commit 929fcee47e46781c57f2a354ce0a013915c033d1 introduced code that > >> attempts to unlock an unlocked mutex which is undefined

[Mesa-dev] [PATCH] mesa: don't attempt to unlock an unlocked debug state mutex

2016-12-11 Thread Jonathan Gray
=0x7f7be2b4) at drisw_glx.c:476 10 0x124d8e104b4a in glXCreateContextAttribsARB (dpy=0x124d533f, config=0x124d7a0e7300, share_context=0x0, direct=1, attrib_list=0x7f7be300) at create_context.c:78 Signed-off-by: Jonathan Gray --- src/mesa/main/debug_output.c | 5 ++--- 1 file changed, 2

Re: [Mesa-dev] [PATCH libdrm v2 5/5] xf86drm: implement an OpenBSD specific drmGetDevice2

2016-12-05 Thread Jonathan Gray
On Mon, Dec 05, 2016 at 05:56:40PM +, Emil Velikov wrote: > On 1 December 2016 at 04:18, Jonathan Gray wrote: > > DRI devices on OpenBSD are not in their own directory. They reside in > > /dev with a large number of statically generated /dev nodes. > > > > Av

Re: [Mesa-dev] Mesa 13.0.2 release candidate

2016-11-24 Thread Jonathan Gray
On Thu, Nov 24, 2016 at 05:25:26PM +, Emil Velikov wrote: > Hello list, > > The candidate for the Mesa 13.0.2 is now available. Currently we have: > - 49 queued > - 4 nominated (outstanding) > - and 1 rejected patch(es) > > > With this series we have - fixes for vc4, i965 and radeon drive

Re: [Mesa-dev] [PATCH 1/1] Fix endianess detection with musl-based toolchains

2016-11-04 Thread Jonathan Gray
On Fri, Nov 04, 2016 at 07:53:25PM +0100, Bernd Kuhls wrote: > Musl does not define __GLIBC__ and will not provide a __MUSL__ macro: > http://wiki.musl-libc.org/wiki/FAQ#Q:_why_is_there_no_MUSL_macro_.3F > > This patch checks for the presence of endian.h and promotes the result > to src/amd/Makefi

[Mesa-dev] [PATCH] mapi: automake: set VISIBILITY_CFLAGS for shared glapi

2016-10-22 Thread Jonathan Gray
were being exported. Signed-off-by: Jonathan Gray Cc: "11.2 12.0 13.0" --- src/mapi/Makefile.am | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mapi/Makefile.am b/src/mapi/Makefile.am index 5a58ca2..f35cedc 100644 --- a/src/mapi/Makefile.am +++ b/src/mapi/Makefile.am

Re: [Mesa-dev] [PATCH 02/16] loader: slim down loader_get_pci_id_for_fd implementation(s)

2016-10-20 Thread Jonathan Gray
On Thu, Oct 20, 2016 at 11:44:46AM +0100, Emil Velikov wrote: > On 20 October 2016 at 05:35, Jonathan Gray wrote: > > On Sat, Oct 15, 2016 at 01:32:02PM +0100, Emil Velikov wrote: > >> On Saturday, 15 October 2016, Jonathan Gray wrote: > >> > >> > On Tue,

Re: [Mesa-dev] [PATCH 02/16] loader: slim down loader_get_pci_id_for_fd implementation(s)

2016-10-19 Thread Jonathan Gray
On Sat, Oct 15, 2016 at 01:32:02PM +0100, Emil Velikov wrote: > On Saturday, 15 October 2016, Jonathan Gray wrote: > > > On Tue, Oct 11, 2016 at 07:31:46PM +0100, Emil Velikov wrote: > > > From: Emil Velikov > > > > > > > Currently mesa has three

Re: [Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-19 Thread Jonathan Gray
On Wed, Oct 19, 2016 at 03:17:07PM +0100, Emil Velikov wrote: > On 19 October 2016 at 14:16, Jonathan Gray wrote: > > On Wed, Oct 19, 2016 at 10:29:47AM +0100, Emil Velikov wrote: > >> On 19 October 2016 at 01:05, Jonathan Gray wrote: > >> > On Tue, Oct 18, 2016 at

Re: [Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-19 Thread Jonathan Gray
On Wed, Oct 19, 2016 at 10:29:47AM +0100, Emil Velikov wrote: > On 19 October 2016 at 01:05, Jonathan Gray wrote: > > On Tue, Oct 18, 2016 at 04:24:20PM +0100, Emil Velikov wrote: > >> On 18 October 2016 at 00:58, Jonathan Gray wrote: > >> > On Mon, Oct 17, 2016 at

Re: [Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-18 Thread Jonathan Gray
On Tue, Oct 18, 2016 at 04:24:20PM +0100, Emil Velikov wrote: > On 18 October 2016 at 00:58, Jonathan Gray wrote: > > On Mon, Oct 17, 2016 at 05:34:02PM +0100, Emil Velikov wrote: > >> On 17 October 2016 at 16:39, Eric Engestrom > >> wrote: > >> > On Mond

Re: [Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-17 Thread Jonathan Gray
On Mon, Oct 17, 2016 at 05:34:02PM +0100, Emil Velikov wrote: > On 17 October 2016 at 16:39, Eric Engestrom wrote: > > On Monday, 2016-10-17 22:53:20 +1100, Jonathan Gray wrote: > >> On Mon, Oct 17, 2016 at 12:39:11PM +0100, Emil Velikov wrote: > >> > On 17 October

Re: [Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-17 Thread Jonathan Gray
On Mon, Oct 17, 2016 at 12:39:11PM +0100, Emil Velikov wrote: > On 17 October 2016 at 10:53, Eric Engestrom wrote: > > On Sunday, 2016-10-16 16:38:35 +1100, Jonathan Gray wrote: > >> On OpenBSD try to dlopen 'libglapi.so', ld.so will find > >> the highest ma

Re: [Mesa-dev] [PATCH] genxml: add generated headers to EXTRA_DIST

2016-10-16 Thread Jonathan Gray
On Sun, Oct 16, 2016 at 11:08:42PM +1100, Jonathan Gray wrote: > Building the Mesa 12.0.3 distfile failed on a system without python > as generated files were not included in the distfile. > > Cc: "12.0" > Signed-off-by: Jonathan Gray > --- > src/intel/Makefi

[Mesa-dev] [PATCH] mesa: automake: include mesa_glinterop.h in distfile

2016-10-16 Thread Jonathan Gray
Add mesa_glinterop.h to the list of headers that will get included in the distfile as it is required to build Mesa itself. Corrects a regression introduced in a89faa2022fd995af2019c886b152b49a01f9392. Signed-off-by: Jonathan Gray --- src/Makefile.am | 3 ++- 1 file changed, 2 insertions(+), 1

[Mesa-dev] [PATCH] genxml: add generated headers to EXTRA_DIST

2016-10-16 Thread Jonathan Gray
Building the Mesa 12.0.3 distfile failed on a system without python as generated files were not included in the distfile. Cc: "12.0" Signed-off-by: Jonathan Gray --- src/intel/Makefile.genxml.am | 4 1 file changed, 4 insertions(+) diff --git a/src/intel/Makefile.genxml.am b

[Mesa-dev] [PATCH] egl: remove docs directory from EXTRA_DIST

2016-10-16 Thread Jonathan Gray
The egl docs directory no longer exists as of 88b5c36fe1a1546bf633ee161a6715efc593acbd. Remove it from EXTRA_DIST to unbreak 'make dist' Signed-off-by: Jonathan Gray --- src/egl/Makefile.am | 1 - 1 file changed, 1 deletion(-) diff --git a/src/egl/Makefile.am b/src/egl/Makefil

[Mesa-dev] [PATCH] genxml: avoid using a GNU make pattern rule

2016-10-15 Thread Jonathan Gray
% pattern rules are a GNU extension. Convert the use of one to a inference rule to allow this to build on OpenBSD. This is a related change to the one made in e3d43dc5eae5271e2c87bab702aa7409d3dd0b23 Signed-off-by: Jonathan Gray --- src/intel/Makefile.genxml.am | 5 - 1 file changed, 4

[Mesa-dev] [PATCH] egl/dri2: add a libname to dlopen for OpenBSD

2016-10-15 Thread Jonathan Gray
On OpenBSD try to dlopen 'libglapi.so', ld.so will find the highest major/minor version and open it in this case. Avoids '#error Unknown glapi provider for this platform' at build time. Signed-off-by: Jonathan Gray --- src/egl/drivers/dri2/egl_dri2.c | 2 +- 1 file change

Re: [Mesa-dev] [PATCH 02/16] loader: slim down loader_get_pci_id_for_fd implementation(s)

2016-10-14 Thread Jonathan Gray
m drm device API. The latter can be implemented in any way > depending on the platform and can be reused by others. > > Cc: Jonathan Gray > Cc: Jean-S??bastien P??dron > Signed-off-by: Emil Velikov > --- > Jonathan, Jean-S??bastien I believe I've prodded you guys for

Re: [Mesa-dev] [PATCH 1/2] aubinator: rework print_help()

2016-09-12 Thread Jonathan Gray
POSIX (can modify string, > always pass a copy) and GNU (never modifies the string). > > Just printout the complete program name, esp. since the program is not > meant to be installed, thus using $basename is unlikely to work, not to > mention it is misleading. > > Cc: Jonathan G

Re: [Mesa-dev] [PATCH 3/3] aubinator: only use program_invocation_short_name with glibc/cygwin

2016-09-11 Thread Jonathan Gray
On Mon, Sep 12, 2016 at 09:28:58AM +1000, Timothy Arceri wrote: > On Thu, 2016-09-08 at 18:39 +0100, Emil Velikov wrote: > > On 1 September 2016 at 18:12, Jonathan Gray wrote: > > > > > > program_invocation_short_name is a gnu extension.Limit use of it > > &g

Re: [Mesa-dev] [PATCH] Disable the code that allocates W|X memory on OpenBSD

2016-09-08 Thread Jonathan Gray
On Thu, Sep 08, 2016 at 06:57:44PM +0100, Emil Velikov wrote: > On 1 September 2016 at 18:23, Jonathan Gray wrote: > > OpenBSD now has strict W^X enforcement. Processes that violate > > the policy get killed by the kernel. Don't attempt to use > > executable memor

Re: [Mesa-dev] [PATCH 1/5] mesa: bump required GCC version to 4.8.0

2016-09-07 Thread Jonathan Gray
On Wed, Sep 07, 2016 at 11:52:39PM +1000, Timothy Arceri wrote: > On Wed, 2016-09-07 at 19:26 +1000, Jonathan Gray wrote: > > LLVM was imported yes, but the integration of it has only > > started around the same time and it is not enabled by default yet. > > And it was onl

Re: [Mesa-dev] [PATCH 1/5] mesa: bump required GCC version to 4.8.0

2016-09-07 Thread Jonathan Gray
Red Hat Enterprise Linux 6 which ships with 4.4.7. However > Dave reported that they build Mesa with GCC 4.8. > > Cc: Jonathan Gray > --- > configure.ac | 18 +++--- > include/c99_compat.h | 17 +++-- > 2 files changed, 10 insertions(+), 2

[Mesa-dev] [PATCH 2/3] aubinator: include libgen.h for basename(3)

2016-09-01 Thread Jonathan Gray
Include libgen.h for basename as required by posix. The definition is not found on at least OpenBSD otherwise. Signed-off-by: Jonathan Gray --- src/intel/tools/aubinator.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/intel/tools/aubinator.c b/src/intel/tools/aubinator.c index

[Mesa-dev] [PATCH] Disable the code that allocates W|X memory on OpenBSD

2016-09-01 Thread Jonathan Gray
OpenBSD now has strict W^X enforcement. Processes that violate the policy get killed by the kernel. Don't attempt to use executable memory on OpenBSD to avoid this. Patch from Mark Kettenis. Cc: 11.2 12.0 Signed-off-by: Mark Kettenis Signed-off-by: Jonathan Gray --- src/gallium/auxi

[Mesa-dev] [PATCH 3/3] aubinator: only use program_invocation_short_name with glibc/cygwin

2016-09-01 Thread Jonathan Gray
program_invocation_short_name is a gnu extension. Limit use of it to glibc and cygwin and otherwise use getprogname() which is available on BSD and OS X. Signed-off-by: Jonathan Gray --- src/intel/tools/aubinator.c | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src

[Mesa-dev] [PATCH 1/3] aubinator: stop using non portable error() function

2016-09-01 Thread Jonathan Gray
error() is a gnu extension and is not present on OpenBSD and likely other systems. Convert use of error to fprintf/strerror/exit. Signed-off-by: Jonathan Gray --- src/intel/tools/aubinator.c | 46 + 1 file changed, 30 insertions(+), 16 deletions

Re: [Mesa-dev] [PATCH 01/13] i965: Add a dependency on libisl

2016-05-05 Thread Jonathan Gray
On Fri, Apr 22, 2016 at 11:19:04AM -0700, Chad Versace wrote: > On 04/22/2016 10:50 AM, Jason Ekstrand wrote: > > > > > > On Fri, Apr 22, 2016 at 10:15 AM, Jonathan Gray > <mailto:j...@jsg.id.au>> wrote: > > > > On Fri, Apr 22, 2016 at 05:31:29P

  1   2   3   >