aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_rlc_reset()Tom St Denis1-6/+2
Use new WREG32_FIELD15 macro Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_rlc_start()Tom St Denis1-3/+1
Use new WREG32_FIELD15 macro Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: simplify gfx_v9_0_cp_gfx_enable()Tom St Denis1-8/+4
Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_kiq_init_register()Tom St Denis1-9/+3
Use new WREG32_FIELD macro Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Drop gfx_v9_0_print_status()Tom St Denis1-174/+1
It's not used in gfx 6/7/8 so drop it from gfx 9 as well. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_set_gfx_eop_interrupt_state()Tom St Denis1-12/+3
Use new WREG32_FIELD15 macro. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_set_priv_reg_fault_state()Tom St Denis1-11/+3
Use new WREG32_FIELD15 macro. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_set_priv_inst_fault_state()Tom St Denis1-12/+3
Use new WREG32_FIELD15 macro. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: cleanup gfx_v9_0_init_queue()Tom St Denis2-8/+6
Introduce WREG32_FIELD15 macro for SOC15 architectures. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: Move function amdgpu_has_atpx near other similar functionsAlex Xie2-6/+2
Signed-off-by: Alex Xie <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: fix over allocating of IRQ sourcesChristian König1-3/+4
We need an array of pointers to IRQ sources, not an array of sources. Signed-off-by: Christian König <[email protected]> Reported-by: Dan Carpenter <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Clean up psp reload_quirk()Tom St Denis1-8/+4
Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Fix psp_v3_1 compare sramTom St Denis1-1/+1
Had the wrong sense in the loop Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: cleanup get_invalidate_req v2Christian König8-49/+27
The two hubs are just instances of the same hardware, so the register bits are identical. v2: keep the function pointer Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: fix vm size and block size for VMPT (v5)Zhang, Jerry9-35/+52
Set reasonable defaults per family. v2: set both of them in gmc v3: move vm size and block size in vm manager v4: squash in warning fix from Alex Xie v5: squash in min() warning fix Signed-off-by: Junwei Zhang <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Fix srbm_indexing in init/inactive hqd codeTom St Denis1-0/+5
Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Clean up gfx_v8_0_mqd_init()Tom St Denis1-8/+4
Clean up a toggle with ?:. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: de-numberify HQD_ACTIVE check.Tom St Denis1-2/+2
Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: clean up gfx_v8_0_kiq_init_register()Tom St Denis1-9/+3
Swap read/write pattern for WREG32_FIELD() Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Clean up gfx_v8_0_inactive_hqd()Tom St Denis1-5/+1
Swap read/write pattern for WREG32_FIELD() Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amd/amdgpu: Clean up gfx_v8_0_kiq_set_interrupt_state()Tom St Denis2-28/+15
Use new WREG32_FIELD_OFFSET() to clean up code. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu/gfx8: KIQ is also disabled when MEC is disabledAlex Deucher1-0/+1
Set the ready flag to reflect this. Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: cleanup VMHUB bit definitions v2Christian König4-29/+8
The two hubs are just instances of the same hardware, so the register bits are identical. v2: only remove get_vm_protection_bits for now Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-06drm/amdgpu: handle CPU access for split VRAM buffers (v2)Christian König2-7/+13
This avoids merging them together on page fault. v2: squash in 64-bit division fix Signed-off-by: Christian König <[email protected]> Acked-by: Michel Dänzer <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: use TTM_PL_FLAG_CONTIGUOUS v2Christian König2-10/+18
Implement AMDGPU_GEM_CREATE_VRAM_CONTIGUOUS using TTM_PL_FLAG_CONTIGUOUS instead of a placement limit. That allows us to better handle CPU accessible placements. v2: prevent virtual BO start address from overflowing Signed-off-by: Christian König <[email protected]> Acked-by: Michel Dänzer <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: move adjust_mc_addr into amdgpu_gart_funcsChristian König3-23/+9
We should probably rename amdgpu_gart_funcs sooner or later. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: cleanup logic in amdgpu_vm_flushChristian König1-10/+10
Remove some of the extra checks where they don't hurt us. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: cleanup coding style in amdgpu_vm_flushChristian König1-43/+45
Abort early if there is nothing todo and correctly indent the "if"s. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: coding style of amdgpu_vm_is_gpu_resetChristian König1-7/+14
The name is a bit confusing and the extra "? true : false" is superflous. Additional to that remove setting the reset counter directly after checking it. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: remove VMID first trackingChristian König2-5/+0
Not used any more. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: move VM related defines into amdgpu_vm.hChristian König2-8/+8
Try to clean up amdgpu.h. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: fix VMHUB order to match the hardwareChristian König2-11/+5
Match our defines with what the hw uses. Reviewed-by: Junwei Zhang <[email protected]> Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: drop alpha supportChristian König1-25/+0
We will probably never see this combination. Signed-off-by: Christian König <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/ttm: add TTM_PL_FLAG_CONTIGUOUS v2Christian König2-1/+4
This allows drivers to specify if they need a contiguous allocation or not. v2: use space instead of tab Signed-off-by: Christian König <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/ttm: add io_mem_pfn callbackChristian König13-1/+39
This allows the driver to handle io_mem mappings on their own. Signed-off-by: Christian König <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/ttm: cleanup and optimize ttm_bo_mem_compat v2Christian König1-20/+25
No need to implement the same logic twice. Also check if the busy placements are identical to the already scanned placements before checking them. v2: improve check even more as suggested by Michel. Signed-off-by: Christian König <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu/vi: add defines for KIQ packetsAlex Deucher1-0/+82
Make it clearer how these packets work. Acked-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu/soc15: Fix static checker warningsAlex Deucher1-0/+4
vega10 is the only soc15 asic at the moment so these warnings are invalid, but add a default case to silence the warnings. Fixes: 220ab9bd1ccf: "drm/amdgpu: soc15 enable (v3)" Reviewed-by: Junwei Zhang <[email protected]> Reviewed-by: Harry Wentland <[email protected]> Reported-by: Dan Carpenter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: Read vram width from integrated system info tableHarry Wentland4-82/+123
On KB, KV, CZ we should read the vram width from integrated system table, if we can. The NOOFCHAN in MC_SHARED_CHMAP is not accurate. With this change we can enable two 4k displays on CZ again. This use case was broken sometime in January when we started looking at vram_width for bandwidth calculations instead of hardcoding this value. v2: Return 0 if integrated system info table is not available. Tested-by: Roman Li <[email protected]> Signed-off-by: Harry Wentland <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: create a func to check vm sizeZhang, Jerry1-20/+31
break it out from the check parameters function. Signed-off-by: Junwei Zhang <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: Fix a NULL deref in amdgpu_vm_add_prt_cb()Dan Carpenter1-1/+1
We accidentally dereference "cb" if the kmalloc() fails. Fixes: 451bc8eb8fe6 ("drm/amdgpu: fix PRT teardown on VM fini v3") Reviewed-by: Christian König <[email protected]> Reviewed-by: Harry Wentland <[email protected]> Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amd/powerplay: fix a couple locking issuesDan Carpenter1-2/+4
We should return unlock on the error path in pp_dpm_dispatch_tasks() and there is a double lock bug in pp_dpm_set_sclk_od(). Fixes: 2a5071056e6a ("drm/amd/powerplay: add global PowerPlay mutex.") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amd/powerplay: fix pp_dpm_get_current_power_state() (v2)Dan Carpenter1-0/+4
This switch statement is missing breaks. v2: agd: break in default case as well Fixes: 2a5071056e6a ("drm/amd/powerplay: add global PowerPlay mutex.") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: various cleanups for uvd/vce.Rex Zhu7-103/+22
Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: when resume failed, return error to avoid system hang.Rex Zhu1-2/+3
Continuing if the GPU fails to resume will end in pain. Signed-off-by: Rex Zhu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: use a 64bit interval tree for VM management v2Christian König7-62/+71
This only makes a difference for 32-bit systems. The idea is to have a fixed virtual address space size with 4-level page tables and to minimize differences between 32 and 64-bit systems. v2: Update commit message. Signed-off-by: Christian König <[email protected]> Reviewed-by: Felix Kuehling <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu: fix semicolon.cocci warningskbuild test robot1-1/+1
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c:133:2-3: Unneeded semicolon Remove unneeded semicolon. Generated by: scripts/coccinelle/misc/semicolon.cocci Acked-by: Huang Rui <[email protected]> CC: Huang Rui <[email protected]> Signed-off-by: Fengguang Wu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04drm/amdgpu/powerplay: fix locking typoAlex Deucher1-1/+1
Fixes: 2a5071056e6a601e ("drm/amd/powerplay: add global PowerPlay mutex.") Reported-by: Julia Lawall <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Harry Wentland <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2017-04-04Merge tag 'omapdrm-4.12' of ↵Dave Airlie26-540/+802
git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux into drm-next omapdrm changes for 4.12 Main changes include: * Add support for render nodes. * Refactor omapdss code to allow multiple DISPC implementations. This is pre-work for DSS6 support. * Fix replication logic bug, which caused RGB565 fb to be shown too dark on a 24bit display. * Improve detection of display stack readiness, which should remove the probe order issues. * Link panel-dpi with its backlight, so that they are turned on/off in sync. * Fix possibly incorrect setup of sync and data-enable signals. * Get rid of DRM_OMAP_NUM_CRTCS config option. * tag 'omapdrm-4.12' of git://git.kernel.org/pub/scm/linux/kernel/git/tomba/linux: (34 commits) drm/omap: Major omap_modeset_init() cleanup drm/omap: Remove the obsolete #define omap_plane _omap_plane hack drm/omap: Fix one ugly indentation style break left by coccinelle drm/omap: Rename enum omap_plane to enum omap_plane_id drm/omap: Get rid of DRM_OMAP_NUM_CRTCS config option drm/omap: fix crash on module unload drm/omap: use drm_atomic_helper_shutdown() drm/omap: fix display SYNC/DE flags drm/omap: dispc: improve debug print of display flags drm/omap: displays: panel-dpi: Support for handling backlight devices drm/omap: poll only connectors where the connect/disconnect can be checked drm/omap: display: Add displays in sorted order to the panel_list drm/omap: Use omapdss_stack_is_ready() to check that the display stack is up drm/omap: dss: Support for detecting display stack readiness drm/omap: dss: Functions to check components in the display/output list drm/omap: fix replication logic drm/omap: remove unused dispc_wb_enable & dispc_wb_is_enabled drm/omap: remove all EXPORT_SYMBOLs from dispc.c drm/omap: use dispc_ops drm/omap: fill dispc_ops ...
2017-04-03drm/omap: Major omap_modeset_init() cleanupJyri Sarha4-139/+86
Cleanup overly complex omap_modeset_init(). The function is trying to support many unusual configuration, that have never been tested and are not supported by other parts of the dirver. After cleanup the init function creates exactly one connector, encoder, crtc, and primary plane per each connected dss-device. Each connector->encoder->crtc chain is expected to be separate and each crtc is connect to a single dss-channel. If the configuration does not match the expectations or exceeds the available resources, the configuration is rejected. Signed-off-by: Jyri Sarha <[email protected]> Signed-off-by: Tomi Valkeinen <[email protected]>