aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu
AgeCommit message (Collapse)AuthorFilesLines
2016-01-11drm/nouveau/nvif: split out perfmon interface definitionsBen Skeggs4-77/+75
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: split out device control interface definitionsBen Skeggs4-49/+49
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: split out fifo interface definitionsBen Skeggs23-78/+132
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: split out display interface definitionsBen Skeggs30-222/+261
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: split out nvsw interface definitonsBen Skeggs7-22/+30
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: split out fermi interface definitionsBen Skeggs3-54/+53
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvif: move internal class identifiers to class.hBen Skeggs11-31/+28
Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/gr/gm107-: make use of gpc_addr() macro for tpc ramchain setupBen Skeggs2-170/+167
Should be no functional change here. Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/instmem/gk20a: use DMA API CPU mappingAlexandre Courbot1-92/+62
Commit 69c4938249fb ("drm/nouveau/instmem/gk20a: use direct CPU access") tried to be smart while using the DMA-API by managing the CPU mappings of buffers allocated with the DMA-API by itself. In doing so, it relied on dma_to_phys() which is an architecture-private function not available everywhere. This broke the build on several architectures. Since there is no reliable and portable way to obtain the physical address of a DMA-API buffer, stop trying to be smart and just use the CPU mapping that the DMA-API can provide. This means that buffers will be CPU-mapped for all their life as opposed to when we need them, but anyway using the DMA-API here is a fallback for when no IOMMU is available so we should not expect optimal behavior. This makes the IOMMU and DMA-API implementations of instmem diverge enough that we should maybe put them into separate files... Signed-off-by: Alexandre Courbot <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/instmem/gk20a: fix race conditionsAlexandre Courbot1-29/+37
The LRU list used for recycling CPU mappings was handling concurrency very poorly. For instance, if an instobj was acquired twice before being released once, it would end up into the LRU list even though there is still a client accessing it. This patch fixes this by properly counting how many clients are currently using a given instobj. While at it, we also raise errors when inconsistencies are detected, and factorize some code. Signed-off-by: Alexandre Courbot <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/gk20a: Add MODULE_FIRMWARE for gk20aNicolas Chauvet1-0/+11
This patch is needed by initramfs tools to detect the required firmware files for the module. This patch tests for either TEGRA_124_SOC or TEGRA_132_SOC for the firmwares related to the Tegra K1 generation. v2: move the MODULE_FIRMWARE to the nvidia_platform.c file. This will avoid to test for NOUVEAU_PLATFORM_DRIVER Signed-off-by: Nicolas Chauvet <[email protected]> Reviewed-by: Alexandre Courbot <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/fifo/gk104: fix engine status register offsetVince Hsu1-1/+1
The offset should be 8 on Kepler and later. Signed-off-by: Vince Hsu <[email protected]> Reviewed-by: Alexandre Courbot <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/ce/gk104: attempt at better handling of LAUNCHERRBen Skeggs1-4/+50
Very rough, no idea how correct it is at this point, but it prevents getteximage-depth from piglit from hanging the GPU. v2: updated with NV_PCE_FE_LAUNCHERR_REPORT values provided by NVIDIA Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/fifo/gf100: fix race condition when updating engine runlistsBen Skeggs3-7/+26
Similar in spirit to the gk104 fix with a similar title. Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/fifo/gk104: fix race condition when updating engine runlistsBen Skeggs3-7/+26
The CPU-side tracking of engine runlists was not protected by a lock, leading to list corruption, eventually causing runlist_update() to overrun the GPU-side runlist, triggering an OOPS. Fixes some of the issues noticed during parallel piglit runs. Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/nvkm: add/remove 0's to make 7 (or 9)-nibble constants use 8 nibblesIlia Mirkin3-6/+6
Signed-off-by: Ilia Mirkin <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/kms: no need to check for empty edid before drm_detect_hdmi_monitorIlia Mirkin1-1/+0
Signed-off-by: Ilia Mirkin <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/core: fix return in error path of device probeAlexandre Courbot1-1/+2
We want to unlock nv_devices_mutex in this error path as well. Signed-off-by: Alexandre Courbot <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/kms: allow 225/297MHz pixel clocks for HDMI on Fermi/KeplerIlia Mirkin1-3/+21
Some Fermi's apparently alow allow 297MHz clocks, so create a parameter which allows end-users to set it themselves until we have a reliable way to determine the board's maximum pixel clocks. Signed-off-by: Ilia Mirkin <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-11drm/nouveau/disp: activate dual link TMDS links only when possibleHauke Mehrtens3-6/+13
Without this patch a pixel clock rate above 165 MHz on a TMDS link is assumed to be dual link. This is true for DVI, but not for HDMI. HDMI supports no dual link, but it supports pixel clock rates above 165 MHz. Only activate Dual Link mode when it is actually possible and requested. Signed-off-by: Hauke Mehrtens <[email protected]> [imirkin: check for hdmi monitor for computing proto, use sor ctrl to enable extra config bit] Signed-off-by: Ilia Mirkin <[email protected]> Signed-off-by: Ben Skeggs <[email protected]>
2016-01-08Merge branch 'for-linus' into work.miscAl Viro2-5/+9
2016-01-08drm/radeon: fix trivial typo in warning messageAlexandre Demers1-1/+1
Reviewed-by: Christian König <[email protected]> Signed-off-by: Alexandre Demers <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08radeon: r100: Silence 'may be used uninitialized' warningsTim Gardner1-2/+3
CC [M] drivers/gpu/drm/radeon/r100.o In file included from drivers/gpu/drm/radeon/radeon_mode.h:37:0, from drivers/gpu/drm/radeon/radeon.h:80, from drivers/gpu/drm/radeon/r100.c:33: drivers/gpu/drm/radeon/r100.c: In function 'r100_bandwidth_update': include/drm/drm_fixed.h:64:13: warning: 'crit_point_ff.full' may be used uninitialized in this function [-Wmaybe-uninitialized] u64 tmp = ((u64)A.full << 13); ^ drivers/gpu/drm/radeon/r100.c:3153:63: note: 'crit_point_ff.full' was declared here fixed20_12 peak_disp_bw, mem_bw, pix_clk, pix_clk2, temp_ff, crit_point_ff; ^ drivers/gpu/drm/radeon/r100.c:3583:42: warning: 'disp_drain_rate.full' may be used uninitialized in this function [-Wmaybe-uninitialized] temp_ff.full = read_return_rate.full - disp_drain_rate.full; gcc version 5.3.1 20151219 (Ubuntu 5.3.1-4ubuntu1) Cc: Alex Deucher <[email protected]> Cc: "Christian König" <[email protected]> Cc: David Airlie <[email protected]> Signed-off-by: Tim Gardner <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amdgpu: add warning to amdgpu_bo_gpu_offset() v2Christian König1-0/+1
Check if there really is a valid offset for the BO. v2: user WARN_ON_ONCE Signed-off-by: Christian König <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Reviewed-by: Alex Deucher <[email protected]> (v1) Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: implement power down asic task for CZRex Zhu1-0/+55
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: enable power down asic task. (v2)Rex Zhu4-5/+23
v2: AGD: rebase on upstream Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: enable set boot state taskRex Zhu3-5/+6
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: add thermal control task when resume.Rex Zhu1-0/+1
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amdgpu: fix hex/decimal bug when show gpu load.Rex Zhu2-10/+10
Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amdgpu: Show gpu load when display gpu performance for Fiji of VI.Rex Zhu1-1/+10
Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amdgpu: Show gpu load when display gpu performance for Ci.Rex Zhu1-2/+12
Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: Reload and initialize the smc firmware on powerplay resume.Rex Zhu1-0/+17
Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Rex Zhu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: add powerplay valid check to avoid null point. (v2)Rex Zhu2-3/+15
In case CONFIG_DRM_AMD_POWERPLAY is defined and amdgpu.powerplay=0. some functions in powrplay can also be called by DAL. and the input parameter is *adev. if just check point not NULL was not enough and will lead to NULL point error. V2: AGD: rebase on upstream Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: fix Smatch static checker warningsRex Zhu8-32/+51
1. return -1 instead of -ENOMEM 2. The struct type mismatch warnings. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Ken Wang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: fix Smatch static checker warnings with indenting (v2)Rex Zhu6-317/+312
v2: AGD: rebase on upstream Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Ken Wang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm/amd/powerplay: fix bug that NULL checks are reversed.Rex Zhu1-5/+5
&& was used instead of ||. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Ken Wang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2016-01-08drm: move MODULE_PARM_DESC to other fileDan Carpenter2-4/+3
We moved the module options from drm_drv.c to drm_irq.c in 18882995713d ('drm: Move vblank related module options into drm_irq.c'). Let's move the MODULE_PARM_DESC()s as well so they're together. Signed-off-by: Dan Carpenter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/20160108110045.GF32195@mwanda Signed-off-by: Daniel Vetter <[email protected]>
2016-01-08drm/edid: index CEA/HDMI mode tables using the VICJani Nikula1-41/+53
Add a dummy entry to CEA/HDMI mode tables so they can be indexed directly using the VIC, avoiding a +1/-1 dance here and there. This adds clarity to the error checking for various functions that return the VIC on success and zero on failure; we can now explicitly check for 0 instead of just subtracting one from an unsigned type. Also add drm_valid_cea_vic() and drm_valid_hdmi_vic() helpers for checking valid VICs. v2: add drm_valid_cea_vic and drm_valid_hdmi_vic helpers (Ville) use { } instead of { 0 } for initializing the dummy modes Cc: Ville Syrjälä <[email protected]> Cc: Alex Deucher <[email protected]> Signed-off-by: Jani Nikula <[email protected]> Reviewed-by: Ville Syrjälä <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Daniel Vetter <[email protected]>
2016-01-08PM / Domains: add setter for dev.pm_domainTomeu Vizoso1-5/+6
Adds a function that sets the pointer to dev_pm_domain in struct device and that warns if the device has already finished probing. The reason why we want to enforce that is because in the general case that can cause problems and also that we can simplify code quite a bit if we can always assume that. This patch also changes all current code that directly sets the dev.pm_domain pointer. Signed-off-by: Tomeu Vizoso <[email protected]> Reviewed-by: Ulf Hansson <[email protected]> Signed-off-by: Rafael J. Wysocki <[email protected]>
2016-01-07drm/etnaviv: fix workaround for GC500Lucas Stach1-2/+5
The hardware description macros define the mask and shifts the wrong way around for the intended use, leading to the condition never being true and the chip revision ending up with the wrong value. Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Lucas Stach <[email protected]> Acked-by: Christian Gmeiner <[email protected]>
2016-01-07Merge branch 'linux-4.4' of git://github.com/skeggsb/linux into drm-fixesDave Airlie1-0/+1
single nv40 oops fix. * 'linux-4.4' of git://github.com/skeggsb/linux: drm/nouveau/gr/nv40: fix oops in interrupt handler
2016-01-06Merge branch 'for-linus' into for-nextTakashi Iwai11-88/+212
Conflicts: drivers/gpu/drm/i915/intel_display.c sound/soc/intel/skylake/skl.h
2016-01-06drm/atomic: Remove drm_atomic_connectors_for_crtc.Maarten Lankhorst3-37/+5
Now that connector_mask is reliable there's no need for this function any more. Signed-off-by: Maarten Lankhorst <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/1451908400-25147-6-git-send-email-maarten.lankhorst@linux.intel.com Signed-off-by: Daniel Vetter <[email protected]>
2016-01-06drm/i915: Update connector_mask during readout, v2.Maarten Lankhorst1-1/+16
drm/i915: Update connector_mask during readout, v2. The connector_mask may be used any time during the non-atomic .crtc_disable which is called before the full atomic state is set up and needs to be accurate for that reason. Changes since v1: - Update connector_mask in readout_hw_state and add a comment. Signed-off-by: Maarten Lankhorst <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] Signed-off-by: Daniel Vetter <[email protected]>
2016-01-06amdkfd: don't open-code memdup_user()Al Viro1-26/+7
Signed-off-by: Al Viro <[email protected]>
2016-01-06drm/etnaviv: unlock on error in etnaviv_gem_get_iova()Dan Carpenter1-2/+4
We have to drop a lock before returning -ENOMEM here. Fixes: a8c21a5451d8 ('drm/etnaviv: add initial etnaviv DRM driver') Signed-off-by: Dan Carpenter <[email protected]> Acked-by: Russell King <[email protected]>
2016-01-06drm: rockchip: Support Synopsys DW MIPI DSIChris Zhong4-0/+1208
Add support for Synopsys DesignWare MIPI DSI controller which is embedded in the rk3288 SoCs. Signed-off-by: Chris Zhong <[email protected]> Acked-by: Mark Yao <[email protected]>
2016-01-06drm/rockchip: return a true clock rate to adjusted_modeChris Zhong1-0/+5
Since the mipi dsi driver need to use the clock of vop to make the calculation of Blanking. But sometimes the clock driver can not set a accurate clock_rate for vop, get it by clk_round_rate before mode_set, so we can get the true value. Signed-off-by: Chris Zhong <[email protected]> Acked-by: Mark Yao <[email protected]>
2016-01-05drm: Remove opencoded drm_gem_object_release_handle()Chris Wilson1-31/+24
drm_gem_handle_delete() contains its own version of drm_gem_object_release_handle(), so lets just call the release method instead. Reported-by: Ville Syrjälä <[email protected]> Signed-off-by: Chris Wilson <[email protected]> Cc: Ville Syrjälä <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Thierry Reding <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>
2016-01-05drm: Do not set outparam on error during GEM handle allocationChris Wilson1-2/+4
Good practice dictates that we do not leak stale information to our callers, and should avoid overwriting an outparam on an error path. Reported-by: Ville Syrjälä <[email protected]> Signed-off-by: Chris Wilson <[email protected]> Cc: Ville Syrjälä <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected] Reviewed-by: Thierry Reding <[email protected]> Signed-off-by: Daniel Vetter <[email protected]>