Misc libdrm fixes
Subsystems (2)
While packaging the latest libdrm release I've fixed some issues noticed by Debian's Lintian.
Please review.
Thanks,
Andreas
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 1/6 radeon: Wire up radeon-symbol-check to make check
This was missed in 552de225bf2740ba0cb52312c21353d71d934b8c
--- radeon/Makefile.am | 1 + 1 file changed, 1 insertion(+)
radeon/Makefile.am +1 -0
@@ -43,4 +43,5 @@ libdrm_radeoninclude_HEADERS = $(LIBDRM_RADEON_H_FILES) pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm_radeon.pc +TESTS = radeon-symbol-check EXTRA_DIST = Android.mk $(LIBDRM_RADEON_BOF_FILES) $(TESTS)
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 2/6 automake: Pick up all Android files for distribution
In reply to Andreas BollCurrently only some Android Makefiles are included in the release tarball. Add all remaining files to be more consistent.
--- Makefile.am | 2 +- amdgpu/Makefile.am | 2 +- tests/Makefile.am | 2 ++ tests/proptest/Makefile.am | 2 ++ tests/util/Makefile.am | 2 ++ 5 files changed, 8 insertions(+), 2 deletions(-)
Makefile.am +1 -1
@@ -120,7 +120,7 @@ libdrm_la_SOURCES = $(LIBDRM_FILES) libdrmincludedir = ${includedir} libdrminclude_HEADERS = $(LIBDRM_H_FILES) -EXTRA_DIST = Android.mk +EXTRA_DIST = CleanSpec.mk Android.mk klibdrmincludedir = ${includedir}/libdrm klibdrminclude_HEADERS = $(LIBDRM_INCLUDE_H_FILES)
amdgpu/Makefile.am +1 -1
@@ -44,4 +44,4 @@ pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm_amdgpu.pc TESTS = amdgpu-symbol-check -EXTRA_DIST = $(TESTS) +EXTRA_DIST = Android.mk $(TESTS)
tests/Makefile.am +2 -0
@@ -73,3 +73,5 @@ TESTS += \ endif check_PROGRAMS += $(TESTS) + +EXTRA_DIST = Android.mk
tests/proptest/Makefile.am +2 -0
@@ -19,3 +19,5 @@ proptest_SOURCES = $(PROPTEST_FILES) proptest_LDADD = \ $(top_builddir)/libdrm.la \ $(top_builddir)/tests/util/libutil.la + +EXTRA_DIST = Android.mk
tests/util/Makefile.am +2 -0
@@ -11,3 +11,5 @@ libutil_la_CFLAGS = \ $(CAIRO_CFLAGS) libutil_la_SOURCES = $(UTIL_FILES) + +EXTRA_DIST = Android.mk
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 3/6 libdrm: Fix drm.h include path in virtgpu drm header file
In reply to Andreas BollA similar change was made to mesa's copy of virtgpu_drm.h by the following commit:
commit c1bf71f77c9d4bc83fa7dc987b56f98350430d7c
Author: Emil Velikov <[email protected]> Date: Wed Oct 28 11:47:18 2015 +0000
virgl: fix drm.h include path
The drm/ prefix is required, if using the kernel provided headers. As most distros don't ship them it and we already depend on libdrm (which adds the relevant -I flag) just drop the drm/ from the include.
Once a libdrm release with the virtgpu_drm.h header is released, we can drop our local copy of the file.
This matches the include path used by all other drm header files.
--- include/drm/virtgpu_drm.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/drm/virtgpu_drm.h +1 -1
@@ -25,7 +25,7 @@#define VIRTGPU_DRM_H #include <stddef.h> -#include "drm/drm.h" +#include "drm.h" /* Please note that modifications to all structs defined here are * subject to backwards-compatibility constraints.
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 4/6 automake: Include virtgpu_drm.h in the release tarball.
In reply to Andreas BollThe plan is to use this version of virtgpu_drm.h in mesa and drop mesa's local copy.
To actually use this header it needs to be shipped in the tarball.
This was missed in c745e541a9d8dfd3fb5e1ac57297e58d34d9328f
--- Makefile.sources | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Makefile.sources +2 -1
@@ -33,7 +33,8 @@ LIBDRM_INCLUDE_H_FILES := \ include/drm/sis_drm.h \ include/drm/tegra_drm.h \ include/drm/vc4_drm.h \ - include/drm/via_drm.h + include/drm/via_drm.h \ + include/drm/virtgpu_drm.h LIBDRM_INCLUDE_VMWGFX_H_FILES := \ include/drm/vmwgfx_drm.h
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 5/6 man: Fix typo
In reply to Andreas Boll--- man/drm-kms.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
man/drm-kms.xml +1 -1
@@ -126,7 +126,7 @@ <listitem> <para><emphasis>Framebuffers</emphasis> are abstract memory objects that provide a source of pixel data to scanout to a CRTC. - Applications explicitely request the creation of framebuffers + Applications explicitly request the creation of framebuffers and can control their behavior. Framebuffers rely on the underneath memory manager for low-level memory operations. When creating a framebuffer, applications pass a memory handle
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 6/6 radeon: Fix typo in stderr message
In reply to Andreas Boll--- radeon/radeon_cs_gem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
radeon/radeon_cs_gem.c +1 -1
@@ -323,7 +323,7 @@ static int cs_gem_end(struct radeon_cs_int *cs,return -EPIPE ; }if (cs->section_ndw != cs->section_cdw) { -fprintf (stderr,"CS section size missmatch start at (%s,%s,%d) %d vs %d\n" , +fprintf (stderr,"CS section size mismatch start at (%s,%s,%d) %d vs %d\n" , cs->section_file, cs->section_func, cs->section_line, cs->section_ndw, cs->section_cdw);fprintf (stderr,"CS section end at (%s,%s,%d)\n" , file, func, line);
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH libdrm 3/6] libdrm: Fix drm.h include path in virtgpu drm header file
In reply to Andreas BollQuoted 3 lines · Andreas Boll
A similar change was made to mesa's copy of
virtgpu_drm.hby the following commit:
Please sync this using the approach shown in commit c745e541a9d8dfd3fb5e1ac57297e58d34d9328f.
Namely:
- Use make header_install and copy the resulting file over.
- Mention the tree/branch and sha where it is based on.
Adding details about the kernel changes are a bonus, but not necessary unless they remove/change existing code.
Thanks
Emil
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH libdrm 2/6] automake: Pick up all Android files for distribution
In reply to Andreas BollQuoted 3 lines · Andreas Boll
Currently only some Android Makefiles are included in the release tarball. Add all remaining files to be more consistent.
Since Android folk never fully bought the idea of using actual releases/release tarballs, one could just drop all the existing Android.mk instances from the Makefiles.
If the Debian build system warnings about files not included in the tarball go ahead with this patch.
Thanks
Emil
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Emil Velikov
Reviewed-byQuoted 5 lines · Andreas Boll
While packaging the latest libdrm release I've fixed some issues noticed by Debian's Lintian.
Please review.
I'm a huge fan of patches 1 and 4 :-)
There's a couple of minor suggestions and with those the series is
Thanks !
Emil
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 1/1 automake: Don't include Android Makefiles in the release tarball
In reply to Emil VelikovCurrently only some Android Makefiles are included in the release tarball. To be more consistent one could either add the remaining files or don't ship Android Makefiles altogether.
According to Emil the Android folk doesn't use our release tarballs. Thus it makes sense to remove those files from distribution which also means less work for maintenance in the future.
--- Makefile.am | 2 -- freedreno/Makefile.am | 2 +- intel/Makefile.am | 1 - libkms/Makefile.am | 2 +- nouveau/Makefile.am | 2 +- radeon/Makefile.am | 2 +- tests/modetest/Makefile.am | 2 -- 7 files changed, 4 insertions(+), 9 deletions(-)
Makefile.am +0 -2
@@ -120,8 +120,6 @@ libdrm_la_SOURCES = $(LIBDRM_FILES) libdrmincludedir = ${includedir} libdrminclude_HEADERS = $(LIBDRM_H_FILES) -EXTRA_DIST = Android.mk - klibdrmincludedir = ${includedir}/libdrm klibdrminclude_HEADERS = $(LIBDRM_INCLUDE_H_FILES)
freedreno/Makefile.am +1 -1
@@ -27,4 +27,4 @@ pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm_freedreno.pc TESTS = freedreno-symbol-check -EXTRA_DIST = Android.mk $(TESTS) +EXTRA_DIST = $(TESTS)
intel/Makefile.am +0 -1
@@ -66,7 +66,6 @@ EXTRA_DIST = \ $(BATCHES:.batch=.batch-ref.txt) \ $(BATCHES:.batch=.batch-ref.txt) \ tests/test-batch.sh \ - Android.mk \ $(TESTS) test_decode_LDADD = libdrm_intel.la ../libdrm.la
libkms/Makefile.am +1 -1
@@ -44,4 +44,4 @@ pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libkms.pc TESTS = kms-symbol-check -EXTRA_DIST = Android.mk $(TESTS) +EXTRA_DIST = $(TESTS)
nouveau/Makefile.am +1 -1
@@ -30,4 +30,4 @@ pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm_nouveau.pc TESTS = nouveau-symbol-check -EXTRA_DIST = Android.mk $(TESTS) +EXTRA_DIST = $(TESTS)
radeon/Makefile.am +1 -1
@@ -44,4 +44,4 @@ pkgconfigdir = @pkgconfigdir@ pkgconfig_DATA = libdrm_radeon.pc TESTS = radeon-symbol-check -EXTRA_DIST = Android.mk $(LIBDRM_RADEON_BOF_FILES) $(TESTS) +EXTRA_DIST = $(LIBDRM_RADEON_BOF_FILES) $(TESTS)
tests/modetest/Makefile.am +0 -2
@@ -22,5 +22,3 @@ modetest_LDADD = \ $(top_builddir)/tests/util/libutil.la \ $(CAIRO_LIBS) \ -lpthread - -EXTRA_DIST = Android.mk
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 1/1 virtgpu: Update kernel header
In reply to Emil VelikovGenerated using make headers_install.
This brings the C++ guard, proper include path for drm.h and the switching to kernel types for fixed-with integers.
Generated from drm-next commit c11dea5b0290984fa48111957ba3fdc5b3bdae5a
--- include/drm/virtgpu_drm.h | 109 ++++++++++++++++++++++++---------------------- 1 file changed, 58 insertions(+), 51 deletions(-)
include/drm/virtgpu_drm.h +58 -51
@@ -24,13 +24,16 @@ #ifndef VIRTGPU_DRM_H #define VIRTGPU_DRM_H -#include <stddef.h> -#include "drm/drm.h" +#include "drm.h" + +#if defined(__cplusplus) +extern "C" { +#endif /* Please note that modifications to all structs defined here are * subject to backwards-compatibility constraints. * -* Do not use pointers, use uint64_t instead for 32 bit / 64 bit user/kernel + * Do not use pointers, use __u64 instead for 32 bit / 64 bit user/kernel * compatibility Keep fields aligned to their size */
@@ -45,88 +48,88 @@#define DRM_VIRTGPU_GET_CAPS 0x09struct drm_virtgpu_map { -uint64_t offset;/* use for mmap system call */ -uint32_t handle; -uint32_t pad; +__u64 offset;/* use for mmap system call */ +__u32 handle; +__u32 pad; };struct drm_virtgpu_execbuffer { -uint32_t flags;/* for future use */ -uint32_t size; -uint64_t command;/* void* */ -uint64_t bo_handles; -uint32_t num_bo_handles; -uint32_t pad; +__u32 flags;/* for future use */ +__u32 size; +__u64 command;/* void* */ +__u64 bo_handles; +__u32 num_bo_handles; +__u32 pad; };#define VIRTGPU_PARAM_3D_FEATURES 1/* do we have 3D features in the hw */ struct drm_virtgpu_getparam { -uint64_t param; -uint64_t value; +__u64 param; +__u64 value; };/* NO_BO flags? NO resource flag? */ /* resource flag for y_0_top */ struct drm_virtgpu_resource_create { -uint32_t target; -uint32_t format; -uint32_t bind; -uint32_t width; -uint32_t height; -uint32_t depth; -uint32_t array_size; -uint32_t last_level; -uint32_t nr_samples; -uint32_t flags; -uint32_t bo_handle;/* if this is set - recreate a new resource attached to this bo ? */ -uint32_t res_handle;/* returned by kernel */ -uint32_t size;/* validate transfer in the host */ -uint32_t stride;/* validate transfer in the host */ +__u32 target; +__u32 format; +__u32 bind; +__u32 width; +__u32 height; +__u32 depth; +__u32 array_size; +__u32 last_level; +__u32 nr_samples; +__u32 flags; +__u32 bo_handle;/* if this is set - recreate a new resource attached to this bo ? */ +__u32 res_handle;/* returned by kernel */ +__u32 size;/* validate transfer in the host */ +__u32 stride;/* validate transfer in the host */ };struct drm_virtgpu_resource_info { -uint32_t bo_handle; -uint32_t res_handle; -uint32_t size; -uint32_t stride; +__u32 bo_handle; +__u32 res_handle; +__u32 size; +__u32 stride; };struct drm_virtgpu_3d_box { -uint32_t x; -uint32_t y; -uint32_t z; -uint32_t w; -uint32_t h; -uint32_t d; +__u32 x; +__u32 y; +__u32 z; +__u32 w; +__u32 h; +__u32 d; };struct drm_virtgpu_3d_transfer_to_host { -uint32_t bo_handle; +__u32 bo_handle;struct drm_virtgpu_3d_box box; -uint32_t level; -uint32_t offset; +__u32 level; +__u32 offset; };struct drm_virtgpu_3d_transfer_from_host { -uint32_t bo_handle; +__u32 bo_handle;struct drm_virtgpu_3d_box box; -uint32_t level; -uint32_t offset; +__u32 level; +__u32 offset; };#define VIRTGPU_WAIT_NOWAIT 1/* like it */ struct drm_virtgpu_3d_wait { -uint32_t handle;/* 0 is an invalid handle */ -uint32_t flags; +__u32 handle;/* 0 is an invalid handle */ +__u32 flags; };struct drm_virtgpu_get_caps { -uint32_t cap_set_id; -uint32_t cap_set_ver; -uint64_t addr; -uint32_t size; -uint32_t pad; +__u32 cap_set_id; +__u32 cap_set_ver; +__u64 addr; +__u32 size; +__u32 pad; };#define DRM_IOCTL_VIRTGPU_MAP \
@@ -164,4 +167,8 @@ struct drm_virtgpu_get_caps {DRM_IOWR (DRM_COMMAND_BASE +DRM_VIRTGPU_GET_CAPS , \ struct drm_virtgpu_get_caps) +#if defined(__cplusplus) +} +#endif +#endif
Signature · 6 lines
2.8.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH libdrm 2/6] automake: Pick up all Android files for distribution
In reply to Emil Velikov2016-07-21 18:14 GMT+02:00 Emil Velikov <[email protected]>:
Quoted 7 lines · Andreas Boll
Quoted 3 lines
Currently only some Android Makefiles are included in the release tarball. Add all remaining files to be more consistent.
Since Android folk never fully bought the idea of using actual releases/release tarballs, one could just drop all the existing Android.mk instances from the Makefiles.
Ok I've just sent a new patch to drop all Android files from the release tarball.
Quoted 4 lines
If the Debian build system warnings about files not included in the tarball go ahead with this patch.
No problem, I'll just extend the ignore rule like I did for mesa.
Thanks,
Andreas
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH libdrm 3/6] libdrm: Fix drm.h include path in virtgpu drm header file
In reply to Emil Velikov2016-07-21 18:10 GMT+02:00 Emil Velikov <[email protected]>:
Quoted 11 lines · Andreas Boll
Quoted 3 lines
A similar change was made to mesa's copy of
virtgpu_drm.hby the following commit:Please sync this using the approach shown in commit
c745e541a9d8dfd3fb5e1ac57297e58d34d9328f.Namely:
- Use makeheader_installand copy the resulting file over.
- Mention the tree/branch and sha where it is based on.
Quoted 5 lines
Adding details about the kernel changes are a bonus, but not necessary unless they remove/change existing code.
Thanks
Emil
I've replaced this patch with a new one that syncs from the kernel header.
Thanks,
Andreas
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 1/1 virtgpu: Update kernel header
In reply to Andreas BollQuoted 11 lines · On 22 July 2016 at 12:26, Andreas Boll <[email protected]…
Generated using make
headers_install.This brings the C++ guard, proper include path for
drm.hand the switching to kernel types for fixed-with integers.Generated from drm-next commit
c11dea5b0290984fa48111957ba3fdc5b3bdae5aSuggested-by Emil Velikov <[email protected] <javascript:;>>Signed-off-by Andreas Boll <[email protected] <javascript:;>>--- include/drm/virtgpu_drm.h | 109
++++++++++++++++++++++++----------------------
Quoted 2 lines
1 file changed, 58 insertions(+), 51 deletions(-)
Smashing, thanks !
For both patches (this and the remove Android.mk from EXTRA_DIST)
-Emil
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel