drm: Branch 'master' - 5 commits
[email protected] (Eric Engestr??m) Wed, 31 Jan 2018 11:26:02 +0000 (UTC)
| Newsgroups | gmane.comp.video.dri.patches |
|---|---|
| Message-ID | <[email protected]> |
configure.ac | 6 +++++- meson.build | 2 +- tests/exynos/exynos_fimg2d_test.c | 4 ++-- xf86drmHash.c | 6 ------ 4 files changed, 8 insertions(+), 10 deletions(-) New commits: commit ba17673eed0383cc41ed49e8c9841b6b819fdfd3 Author: Eric Engestrom <[email protected]> Date: Fri Jan 26 11:18:03 2018 +0000 meson,configure: turn undefined preprocessor tokens warnings into errors Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> diff --git a/configure.ac b/configure.ac index f7620268..321ab2c0 100644 --- a/configure.ac +++ b/configure.ac @@ -197,7 +197,7 @@ dnl skipped and all flags rechecked. So there's no need to do anything dnl else. If for any reason you need to force a recheck, just change dnl MAYBE_WARN in an ignorable way (like adding whitespace) -MAYBE_WARN="-Wall -Wextra -Wundef \ +MAYBE_WARN="-Wall -Wextra -Werror=undef \ -Wsign-compare -Werror-implicit-function-declaration \ -Wpointer-arith -Wwrite-strings -Wstrict-prototypes \ -Wmissing-prototypes -Wmissing-declarations -Wnested-externs \ diff --git a/meson.build b/meson.build index e249ea0f..1342a5b3 100644 --- a/meson.build +++ b/meson.build @@ -203,7 +203,7 @@ if cc.has_function('open_memstream') endif warn_c_args = [] -foreach a : ['-Wall', '-Wextra', '-Wsign-compare', '-Wundef', +foreach a : ['-Wall', '-Wextra', '-Wsign-compare', '-Werror=undef', '-Werror-implicit-function-declaration', '-Wpointer-arith', '-Wwrite-strings', '-Wstrict-prototypes', '-Wmissing-prototypes', '-Wmissing-declarations', '-Wnested-externs', '-Wpacked', commit 440e6ad0702a912dc61e19aba179e13903767a9a Author: Eric Engestrom <[email protected]> Date: Fri Jan 5 15:27:17 2018 +0000 exynos/tests: use #ifdef for never-defined token Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> diff --git a/tests/exynos/exynos_fimg2d_test.c b/tests/exynos/exynos_fimg2d_test.c index 14d304d3..dcb2e35a 100644 --- a/tests/exynos/exynos_fimg2d_test.c +++ b/tests/exynos/exynos_fimg2d_test.c @@ -536,7 +536,7 @@ fail: return ret; } -#if EXYNOS_G2D_USERPTR_TEST +#ifdef EXYNOS_G2D_USERPTR_TEST static int g2d_blend_test(struct exynos_device *dev, struct exynos_bo *src, struct exynos_bo *dst, @@ -880,7 +880,7 @@ int main(int argc, char **argv) * * Disable the test for now, until the kernel code has been sanitized. */ -#if EXYNOS_G2D_USERPTR_TEST +#ifdef EXYNOS_G2D_USERPTR_TEST ret = g2d_blend_test(dev, src, bo, G2D_IMGBUF_USERPTR); if (ret < 0) fprintf(stderr, "failed to test blend operation.\n"); commit 0db36bdec8a1b2caac0046c22eb477ba19c2b43c Author: Eric Engestrom <[email protected]> Date: Fri Jan 5 15:25:31 2018 +0000 configure: always define HAVE_LIBDRM_ATOMIC_PRIMITIVES and HAVE_LIB_ATOMIC_OPS Fixes #if undefined warnings Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> diff --git a/configure.ac b/configure.ac index 5396c841..f7620268 100644 --- a/configure.ac +++ b/configure.ac @@ -259,9 +259,13 @@ AC_CACHE_CHECK([for native atomic primitives], drm_cv_atomic_primitives, [ if test "x$drm_cv_atomic_primitives" = xIntel; then AC_DEFINE(HAVE_LIBDRM_ATOMIC_PRIMITIVES, 1, [Enable if your compiler supports the Intel __sync_* atomic primitives]) +else + AC_DEFINE(HAVE_LIBDRM_ATOMIC_PRIMITIVES, 0) fi if test "x$drm_cv_atomic_primitives" = "xlibatomic-ops"; then AC_DEFINE(HAVE_LIB_ATOMIC_OPS, 1, [Enable if you have libatomic-ops-dev installed]) +else + AC_DEFINE(HAVE_LIB_ATOMIC_OPS, 0) fi dnl Print out the approapriate message considering the value set be the commit 7797751cf7bbbcffdb1003f3a38479388dc4d7f9 Author: Eric Engestrom <[email protected]> Date: Fri Jan 5 14:57:59 2018 +0000 xf86drmHash: remove always-false #if guards Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> diff --git a/xf86drmHash.c b/xf86drmHash.c index f287e61f..b2fa414e 100644 --- a/xf86drmHash.c +++ b/xf86drmHash.c @@ -98,9 +98,6 @@ static unsigned long HashHash(unsigned long key) } hash %= HASH_SIZE; -#if DEBUG - printf( "Hash(%lu) = %lu\n", key, hash); -#endif return hash; } @@ -201,9 +198,6 @@ int drmHashInsert(void *t, unsigned long key, void *value) bucket->value = value; bucket->next = table->buckets[hash]; table->buckets[hash] = bucket; -#if DEBUG - printf("Inserted %lu at %lu/%p\n", key, hash, bucket); -#endif return 0; /* Added to table */ } commit 75758d2ccf608de5774863d3bb7ae36c50197355 Author: Eric Engestrom <[email protected]> Date: Fri Jan 26 11:17:33 2018 +0000 meson,configure: add warning when using undefined preprocessor tokens Signed-off-by: Eric Engestrom <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Dylan Baker <[email protected]> diff --git a/configure.ac b/configure.ac index a0246fe5..5396c841 100644 --- a/configure.ac +++ b/configure.ac @@ -197,7 +197,7 @@ dnl skipped and all flags rechecked. So there's no need to do anything dnl else. If for any reason you need to force a recheck, just change dnl MAYBE_WARN in an ignorable way (like adding whitespace) -MAYBE_WARN="-Wall -Wextra \ +MAYBE_WARN="-Wall -Wextra -Wundef \ -Wsign-compare -Werror-implicit-function-declaration \ -Wpointer-arith -Wwrite-strings -Wstrict-prototypes \ -Wmissing-prototypes -Wmissing-declarations -Wnested-externs \ diff --git a/meson.build b/meson.build index e05db1cd..e249ea0f 100644 --- a/meson.build +++ b/meson.build @@ -203,7 +203,7 @@ if cc.has_function('open_memstream') endif warn_c_args = [] -foreach a : ['-Wall', '-Wextra', '-Wsign-compare', +foreach a : ['-Wall', '-Wextra', '-Wsign-compare', '-Wundef', '-Werror-implicit-function-declaration', '-Wpointer-arith', '-Wwrite-strings', '-Wstrict-prototypes', '-Wmissing-prototypes', '-Wmissing-declarations', '-Wnested-externs', '-Wpacked', ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot --