summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-08-03Add support for DRM_MODE_PAGE_FLIP_TARGET_* flagsHEADmasterMichel Dänzer4-4/+40
2016-08-02list: fix an issue with android build using clangRob Clark1-1/+1
Sorry, I don't understand the android build system enough to say *which* version of clang this effects, but either "clang-2812033" or "clang-3016494" (probably the later). But when 'sample' is undefined (ie. unitialized variable), the result is not as well defined as it is with gcc. Instead use a typeof() cast with a defined value (ie. zero). This fixes a crash that was reported on android. Reported-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-24Simplify the RELEASING steps based on current release.sh.Eric Anholt1-20/+6
Since release.sh creates and pushes a libdrm-$VERSION tag for us, there's no need to also have the user manually generating a $VERSION tag as well. I also dropped the "optional" part of distcheck. You shouldn't have pushed master with a version bump that hasn't passed distcheck. Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23Bump version for releaseRob Clark1-1/+1
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-23radeon: Fix typo in stderr messageAndreas Boll1-1/+1
Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23man: Fix typoAndreas Boll1-1/+1
Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23automake: Include virtgpu_drm.h in the release tarballAndreas Boll1-1/+2
The 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 Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23virtgpu: Update kernel headerAndreas Boll1-51/+58
Generated 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 Suggested-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23automake: Don't include Android Makefiles in the release tarballAndreas Boll7-9/+4
Currently 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. Suggested-by: Emil Velikov <emil.l.velikov@gmail.com> Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-23radeon: Wire up radeon-symbol-check to make checkAndreas Boll1-0/+1
This was missed in 552de225bf2740ba0cb52312c21353d71d934b8c Signed-off-by: Andreas Boll <andreas.boll.dev@gmail.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-21freedreno: fix warningsRob Clark1-2/+2
Signed-off-by: Rob Clark <robclark@freedesktop.org> Tested-by: Rob Herring <robh@kernel.org>
2016-07-21freedreno: fix android build breakRob Clark1-2/+2
The 'deprecated' #define was causing problems with bionic system headers which used __attribute__((deprecated)). Signed-off-by: Rob Clark <robclark@freedesktop.org> Tested-by: Rob Herring <robh@kernel.org>
2016-07-21freedreno: fix distcheck errorsRob Clark1-0/+4
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: move legacy kgsl related READMERob Clark1-0/+10
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno/msm: use hashtable to track bo idxRob Clark2-23/+31
Note: cache the last ring the bo was emitted on, to avoid excess hashtable lookups. We do this by tracking ring seqno to avoid problems with dangling pointers. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: support growable cmdstream buffersRob Clark5-36/+166
The issue that userspace needed to solve is that there is ~two orders of magnitude size difference in cmdstream buffers (both for gmem commands and for draw commands), and that the previous practice of allocating worst-case sizes is quite wasteful. Previously a submit would be constructed (for example) like: CMD TARGET DESCRIPTION g0 N gmem/tiling commands b0 Y binning commands d0 Y draw commands Which, after the one non-IB-target cmd buffer is inserted into the kernel controlled ringbuffer, looks like (not to scale): b0: d0: +-----+ +-----+ IB1 | ... | | ... | +-----+ +-----+ ^ ^ | | +-----+ +-+---------+ g0: | | | +----+----+----+----+----+----+---- IB0 | .. | IB | .. | IB | .. | IB | ... +----+----+----+----+----+----+---- ^ tile0 tile1 | +-----------+ userspace | ~~~~~~~~~~~~~~~~~~~|~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel | ----+----+---- ringbuffer ... | IB | ... ----+----+---- Now, multiple physical cmdstream buffers per fd_ringbuffer are supported, so this becomes: CMD TARGET DESCRIPTION g0 N ... N gmem/tiling commands gN N b0 Y ... Y binning commands bN Y d0 Y ... Y draw commands dN Y Which, after the non-IB-target cmd buffers (g0..gN) are inserted into the kernel controlled ringbuffer, looks like: b0: b1 d0: d1 +-----+ +-----+ +-----+ +-----+ IB1 | ... | | ... | ... | ... | | ... | ... +-----+ +-----+ +-----+ +-----+ ^ ^ ^ ^ | | | | | +-+ | +-----+------+ +-----+ | | | | | | +--+----------+ | g0: | | | | | | +----+----+----+----+----+----+---+----+----+---- IB0 | .. | IB | IB | .. | IB | IB |.. | IB | IB |... +----+----+----+----+----+----+---+----+----+---- ^ tile0 tile1 | to b0 to b1 | | | to|d0 to|d1 | | +----+ | +-+-----------+ | | | | | | | +------+ | +-+-------------+ | | g1: | | | | | | | +----+----+----+----+----+----+---+----+----+---- IB0 | | .. | IB | IB | .. | IB | IB |.. | IB | IB |... | +----+----+----+----+----+----+---+----+----+---- | ^ tileX tileY | | | +-----------+ +-----------+ | userspace | | ~~~~~~~~~~~~~~~~~~~|~~~~|~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ kernel | | ----+----+----+---- ringbuffer ... | IB | IB | ... ----+----+----+---- Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno/msm: split out dump_submit() helperRob Clark1-18/+24
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20list: add first/last entry macrosRob Clark1-0/+6
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno/msm: split out cmd buffer tracking from ringRob Clark1-45/+83
First step towards supporting a single logical ringbuffer mapping to multiple physical cmd buffers, which will enable dynamically growing ringbuffers. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno/msm: drop return from get_cmd()Rob Clark1-20/+16
Not actually needed. It just needs to ensure that there is a corresponding entry in the submit's cmds table. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno/msm: use private bo-cache for ringbuffer bo'sRob Clark3-2/+39
Since they get vmap'd on the kernel side, they are a bit more costly. Don't let them mingle with the riffraff. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: fix potential leak at freeRob Clark2-6/+7
If user has emit'd reloc's, and then resets or deletes the ring, we want to drop the ref's that the ring holds to the bo's to avoid a leak. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: ocdRob Clark2-7/+5
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: support either coarse or fine-grained bucket sizesRob Clark3-7/+14
The normal bo cache uses some intermediate steps between power of two jumps to reduce memory wastage. But for a ringbuffer bo cache, we do not need this. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: expose kernel driver versionRob Clark4-2/+12
gallium needs to know if the kernel is new enough to support explicit fencing, dynamically grown ringbuffers, etc. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: fix potential fd leak in error pathRob Clark1-1/+4
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: add madvise supportRob Clark5-0/+55
With a new enough drm/msm, we can let the kernel know about buffers that are in the bo cache, so the kernel can free them under memory pressure. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: sync uapiRob Clark1-39/+70
(from drm-next for 4.8) Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: move bo-cache to it's own fileRob Clark4-178/+209
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: refactor bo-cache APIRob Clark3-33/+58
Split out interface to allocate from and release to bo-cache, and get rid of direct usage of bucket level API from fd_bo/etc. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: split out fd_bo_cacheRob Clark3-34/+37
Eventually we'll want a separate bo-cache for ringbuffer bo's, since ringbuffer bo's get vmap'd on the kernel side, it is preferrable to re-use them as ringbuffers rather than something else. Plus should help to add madvise support if it is a bit better decoupled from bo allocation (next patch). Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: add simpler ring-relocRob Clark3-7/+28
Provide a way to insert a reference (ie. OUT_IB()) to a target ring, executing all the cmds in the target ring from the start. Sometimes the ringmarker stuff is just overkill. And it will won't really work properly once we support multiple physical cmdstream buffers per fd_ringbuffer. So in the future the old ringmarker related APIs will be deprecated in a few releases. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20freedreno: rework internal ring->emit_reloc_ring()Rob Clark4-18/+23
No need for it to deal with ringmarkers. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-20tests/drmdevice: be move verbose when using open()Emil Velikov1-2/+7
Print out the node we're attempting to open and a message if/why we fail to do so. Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-20tests/drmdevice: print out the full 'bus' and 'dev' stringsEmil Velikov1-2/+2
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-20drm: fix drmFreeDevices memory leak on multi GPU setupsQiang Yu1-2/+3
When in multi GPU case, devices array may have some NULL "hole" in between two devices. So check all array elements and free non-NULL device. Signed-off-by: Qiang Yu <Qiang.Yu@amd.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-20drm: drmGetDevice return correct device on multi GPU setupsQiang Yu1-5/+15
Currently drmGetDevice always returns the first device it finds under /dev/dri/. Move the target device to the start of the list during iteration. This way during deduplication it'll preserve its place and will be returned to the user. v2: Keep the memory leak separate. v3: Move the drmFoldDuplicatedDevices description Signed-off-by: Qiang Yu <Qiang.Yu@amd.com> [Emil Velikov: move drmFoldDuplicatedDevices description, add changelog, reword commit message] Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-07-20Bump version to 2.4.69 for release.Eric Anholt1-1/+1
Signed-off-by: Eric Anholt <eric@anholt.net>
2016-07-15vc4: Update kernel headers for getparam addition.Eric Anholt1-0/+21
This also brings over the C++ guard introduced recently in the kernel headers. Signed-off-by: Eric Anholt <eric@anholt.net>
2016-07-06pull in sys/sysmacros.h when availableMike Frysinger3-4/+11
This header provides major/minor/makedev funcs under most Linux C libs. Pull it in to fix building with newer versions that drop the implicit include via sys/types.h. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=94231 Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2016-07-06xf86drm.c: Fix mix of tabs and spacesJan Vesely1-723/+721
Remove whitespace at the end of line.
2016-07-06Android: strip out header files from sources listRob Herring10-11/+11
AOSP master now errors if LOCAL_SRC_FILES contains headers, so filter out header files from the source lists. Signed-off-by: Rob Herring <robh@kernel.org>
2016-06-29intel: Removing PCI IDs that are no longer listed as Kabylake.Rodrigo Vivi1-13/+3
This is unusual. Usually IDs listed on early stages of platform definition are kept there as reserved for later use. However these IDs here are not listed anymore in any of steppings and devices IDs tables for Kabylake on configurations overview section of BSpec. So it is better removing them before they become used in any other future platform. v2: Rebase. Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com> Acked-by: Kenneth Graunke <kenneth@whitecape.org> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
2016-06-29intel: Add more Kabylake PCI IDs.Rodrigo Vivi1-4/+10
The spec has been updated adding new PCI IDs. v2: Avoid using "H" instead of HALO to keep names uniform - DK. Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com> Acked-by: Kenneth Graunke <kenneth@whitecape.org> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
2016-06-14radeon: use SAMPLE_SPLIT=2 for better MSAA perf on EG/CMMarek Olšák1-2/+4
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
2016-06-13freedreno/msm: fix memory leak on ringbuffer freeRob Clark1-0/+5
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-06-10xf86drm: ensure proper alignment of pointers in drmProcessPciDeviceNicolai Hähnle1-1/+1
Previously, (*device)->businfo.pci would end up misaligned, which results in undefined behavior. Signed-off-by: Nicolai Hähnle <nicolai.haehnle@amd.com> Reviewed-by: Emil Velikov <emil.l.velikov@gmail.com>
2016-06-06drm: fix multi GPU drmGetDevices only return one deviceQiang Yu1-1/+4
When multi GPU present, after drmFoldDuplicatedDevices merge same busid deveces, two different devices may be seperated by zero in local_devices[]. The for loop should check all local_devices instead of exit when meet a zero. Reviewed-by: Jim Qu <Jim.Qu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Qiang Yu <Qiang.Yu@amd.com>
2016-06-02amdgpu: fix fence status queryChristian König1-0/+6
Not initializing the ip instance leads to sporadic fails in the tests. Signed-off-by: Christian König <christian.koenig@amd.com> Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
2016-05-13tests/amdgpu: adapt to new polaris10/11 uvd fwSonny Jiang1-6/+42
Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Sonny Jiang <sonny.jiang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>