aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
Commit message (Collapse)AuthorAgeFilesLines
* drm/amd/amdgpu: Added more named DRM info messages for debuggingTom St Denis2016-05-111-10/+10
| | | | | | Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amd/amdgpu: Add name field to amd_ip_funcs (v2)Tom St Denis2016-05-111-1/+1
| | | | | | | | | | | Add name that we can print out in kernel messages to aid in debugging. v2: drop DAL changes for upstream Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amd: cleanup remaining spaces and tabs v2Christian König2016-05-111-1/+1
| | | | | | | | | | | | | | This is the result of running the following commands: find drivers/gpu/drm/amd/ -name "*.h" -exec sed -i 's/[ \t]\+$//' {} \; find drivers/gpu/drm/amd/ -name "*.c" -exec sed -i 's/[ \t]\+$//' {} \; find drivers/gpu/drm/amd/ -name "*.h" -exec sed -i 's/ \+\t/\t/' {} \; find drivers/gpu/drm/amd/ -name "*.c" -exec sed -i 's/ \+\t/\t/' {} \; v2: drop changes to DAL and internal headers Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* Merge tag 'v4.6-rc7' into drm-nextDave Airlie2016-05-091-7/+1
|\ | | | | | | | | Merge this back as we've built up a fair few conflicts, and I have some newer trees to pull in.
| * Revert "drm/amdgpu: disable runtime pm on PX laptops without dGPU power control"Alex Deucher2016-04-271-7/+1
| | | | | | | | | | | | | | | | This reverts commit bedf2a65c1aa8fb29ba8527fd00c0f68ec1f55f1. See the radeon revert for an extended description. Cc: [email protected]
* | drm/amd/amdgpu: Add debugfs entries for smc/didt/pcieTom St Denis2016-05-051-8/+222
| | | | | | | | | | | | | | | | | | This adds 3 new files that can be read/written to access indirect GPU registers. Signed-off-by: Tom St Denis <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: change ELM/BAF to Polaris10/Polaris11Flora Cui2016-05-051-4/+4
| | | | | | | | | | | | | | | | Adjust to preferred code names. Signed-off-by: Flora Cui <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: update the core VI support for ELM/BAFFlora Cui2016-05-051-0/+2
| | | | | | | | | | | | Signed-off-by: Flora Cui <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: ungate SMC clockgating first before suspendFlora Cui2016-05-051-4/+13
| | | | | | | | | | | | | | | | | | | | 46c34bcb6a15dd85329a39a5e72c62108626acdc put all block’s clockgating support in SMC. The sequence in suspend routine should be adjusted accordingly, otherwise it causes asic hang. Signed-off-by: Flora Cui <[email protected]> Reviewed-by: Eric Huang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: add ELM/BAF asic typesAlex Deucher2016-05-051-0/+2
| | | | | | | | | | | | | | | | New asic types for ellesmere and baffin. Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
* | drm/amdgpu: Mark all instances of struct drm_info_list as constNils Wallménius2016-05-051-1/+1
| | | | | | | | | | | | | | | | | | | | All these are compile time constand and the drm_debugfs_create/remove_files functions take a const pointer argument. Reviewed-by: Christian König <[email protected]> Signed-off-by: Nils Wallménius <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: drop the GTT power of two limitChristian König2016-05-021-5/+1
|/ | | | | | | | As far as I can see that isn't neccessary any more. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* Merge branch 'drm-next-4.6' of git://people.freedesktop.org/~agd5f/linux ↵Dave Airlie2016-03-161-1/+7
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into drm-next A few more fixes and cleanups for 4.6: - DCE code cleanups - HDP flush/invalidation fixes - GPUVM fixes - switch to drm_vblank_[on|off] - PX fixes - misc bug fixes * 'drm-next-4.6' of git://people.freedesktop.org/~agd5f/linux: (50 commits) drm/amdgpu: split pipeline sync out of SDMA vm_flush() as well drm/amdgpu: Revert "add mutex for ba_va->valids/invalids" drm/amdgpu: Revert "add lock for interval tree in vm" drm/amdgpu: Revert "add spin lock to protect freed list in vm (v3)" drm/amdgpu: reserve the PD during unmap and remove drm/amdgpu: Fix two bugs in amdgpu_vm_bo_split_mapping drm/radeon: Don't drop DP 2.7 Ghz link setup on some cards. MAINTAINERS: update radeon entry to include amdgpu as well drm/amdgpu: disable runtime pm on PX laptops without dGPU power control drm/radeon: disable runtime pm on PX laptops without dGPU power control drm/amd/amdgpu: Fix indentation in do_set_base() (DCEv8) drm/amd/amdgpu: make afmt_init cleanup if alloc fails (DCEv8) drm/amd/amdgpu: Move config init flag to bottom of sw_init (DCEv8) drm/amd/amdgpu: Don't proceed into audio_fini if audio is disabled (DCEv8) drm/amd/amdgpu: Fix identation in do_set_base() (DCEv10) drm/amd/amdgpu: Make afmt_init cleanup if alloc fails (DCEv10) drm/amd/amdgpu: Move initialized flag to bottom of sw_init (DCEv10) drm/amd/amdgpu: Don't proceed in audio_fini if disabled (DCEv10) drm/amd/amdgpu: Fix indentation in dce_v11_0_crtc_do_set_base() drm/amd/amdgpu: Make afmt_init() cleanup if alloc fails (DCEv11) ...
| * drm/amdgpu: disable runtime pm on PX laptops without dGPU power controlAlex Deucher2016-03-091-1/+7
| | | | | | | | | | | | | | | | | | | | Some PX laptops don't provide an ACPI method to control dGPU power. On those systems, the driver is responsible for handling the dGPU power state. Disable runtime PM on them until support for this is implemented. Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
* | Merge drm-fixes into drm-next.Dave Airlie2016-03-131-67/+89
|\ \ | |/ |/| | | Nouveau wanted this to avoid some worse conflicts when I merge that.
| * drm/amdgpu: fix s4 resumeFlora Cui2016-02-101-4/+9
| | | | | | | | | | | | | | | | | | No need to re-init asic if it's already been initialized. Skip IB tests since kernel processes are frozen in thaw. Signed-off-by: Flora Cui <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Cc: [email protected]
| * drm/amdgpu: add pcie cap module parameters (v2)Alex Deucher2016-02-081-63/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allows the user to force the supported pcie gen and lane config on both the asic and the chipset. Useful for debugging pcie problems and for virtualization where we may not be able to query the pcie bridge caps. Default to: gen: chipset 1/2, asic 1/2/3 lanes: 1/2/4/8/16 v2: fix bare metal case Reviewed-by: monk liu <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: cleanup gem init/finitChristian König2016-02-161-1/+0
| | | | | | | | | | | | | | | | Remove the double housekeeping and use something sane to forcefuly delete BOs on unload. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* | drm/amdgpu: nuke the kernel contextChristian König2016-02-121-6/+0
| | | | | | | | | | | | | | Not used any more. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* | drm/amdgpu: use SDMA round robin for VM updates v3Christian König2016-02-121-1/+1
| | | | | | | | | | | | | | | | | | | | Distribute the load on both rings. v2: use a loop for the initialization v3: agd: rebase on upstream Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* | drm/amdgpu: always repost cards that support SR-IOVAlex Deucher2016-02-101-1/+2
| | | | | | | | | | | | | | | | | | | | Generally a good idea between VM sessions. We need a way to detect VM pass-through in general and always run asic_init in that case. Reviewed-by: Monk Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: track whether the asic supports SR-IOVAlex Deucher2016-02-101-0/+4
| | | | | | | | | | | | | | | | Required to make desicions about certain code pathes. Reviewed-by: Monk Liu <[email protected]> Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: remove unused functionAlex Deucher2016-02-101-25/+0
| | | | | | | | | | | | | | | | | | amdgpu_boot_test_post_card() is not used anywhere. Probably a leftover from the original port from radeon. Reviewed-by: Christian König <[email protected]> Reviewed-by: Tom St Denis <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: remove power of two limit for vramlimitChristian König2016-02-101-6/+0
| | | | | | | | | | | | | | | | That works with other values as well. Signed-off-by: Christian König <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: remove the ring lock v2Christian König2016-02-101-1/+0
| | | | | | | | | | | | | | | | | | | | | | It's not needed any more because all access goes through the scheduler now. v2: Update commit message. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: grab VMID before submitting job v5Christian König2016-02-101-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows the scheduler to handle the dependencies on ID contention as well. v2: grab id only once v3: use a separate lock for the VMIDs v4: cleanup after semaphore removal v5: minor coding style change Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Acked-by: Alex Deucher <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* | drm/amdgpu: post card after hard resetAlex Deucher2016-02-101-0/+3
|/ | | | | | | | | Posting is required after a pci config reset. Reviewed-by: Junwei Zhang <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Ken Wang <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: store pcie gen mask and link widthAlex Deucher2015-12-211-0/+78
| | | | | | | We'll need this later for pcie dpm. Reviewed-by: Jammy Zhou <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: restrict the sched jobs number to power of twoChunming Zhou2015-12-181-0/+9
| | | | | | Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> CC: [email protected]
* drm/amdgpu: add more debugging output for driver failuresAlex Deucher2015-12-111-16/+57
| | | | | | | Add more fine grained debugging output for init/fini/suspend/ resume failures. Signed-off-by: Alex Deucher <[email protected]>
* drm/amd: abstract kernel rq and normal rq to priority of run queueChunming Zhou2015-12-021-1/+1
| | | | | | | | Allows us to set priorities in the scheduler. Signed-off-by: Chunming Zhou <[email protected]> Reviewed-by: Christian König <[email protected]> Reviewed-by: Junwei Zhang <[email protected]>
* drm/amdgpu: call hpd_irq_event on resumeAlex Deucher2015-12-021-0/+1
| | | | | | | | Need to call this on resume if displays changes during suspend in order to properly be notified of changes. Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
* drm/amdgpu: update the core VI support for StoneySamuel Li2015-10-211-1/+2
| | | | | | | Add core VI enablement for Stoney. Signed-off-by: Samuel Li <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: add Stoney chip familySamuel Li2015-10-211-0/+1
| | | | | | | Stoney is based on Carrizo with some IP upgrades. Signed-off-by: Samuel Li <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: remove the exclusive lockChristian König2015-10-211-4/+0
| | | | | | Finally getting rid of it. Signed-off-by: Christian König <[email protected]>
* drm/amdgpu: remove old lockup detection infrastructureChristian König2015-10-211-6/+0
| | | | | | | | It didn't worked to well anyway. Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> Reviewed-by: Junwei Zhang <[email protected]>
* drm/amdgpu: unpin cursor BOs on suspend and pin them again on resumeAlex Deucher2015-10-141-1/+30
| | | | | | | | | | | | Everything is evicted from VRAM before suspend, so we need to make sure all BOs are unpinned and re-pinned after resume. Fixes broken mouse cursor after resume introduced by commit b9729b17. Port of radeon commit: f3cbb17bcf676a2fc6aedebe9fbebd59e550c51a Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: Spell vga_switcheroo consistentlyLukas Wunner2015-10-021-1/+1
| | | | | | | | | | | | Currently everyone and their dog has their own favourite spelling for vga_switcheroo. This makes it hard to grep dmesg for log entries relating to vga_switcheroo. It also makes it hard to find related source files in the tree. vga_switcheroo.c uses pr_fmt "vga_switcheroo". Use that everywhere. Signed-off-by: Lukas Wunner <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: Sprinkle drm_modeset_lock_all to appease locking checksAlex Deucher2015-09-231-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | In commit 7a3f3d6667f5f9ffd1517f6b21d64bbf5312042c Author: Daniel Vetter <[email protected]> Date: Thu Jul 9 23:44:28 2015 +0200 drm: Check locking in drm_for_each_connector I added locking checks to drm_for_each_connector but failed that through drm_helper_connector_dpms -> drm_helper_choose_encoder_dpms it's used in a few more places in the amdgpu resume/suspend code. Fix them up. Note that we could use the connector iterator macros in there too, but that's for the future. Port of radeon commit: drm/radeon: Sprinkle drm_modeset_lock_all to appease locking checks Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: export reservation_object from dmabuf to ttm (v2)Christian König2015-09-231-2/+3
| | | | | | | | | | | | Adds an extra argument to amdgpu_bo_create, which is only used in amdgpu_prime.c. Port of radeon commit 831b6966a60fe72d85ae3576056b4e4e0775b112. v2: fix up kfd. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* drm/amdgpu: be explicit about cpu vram access for driver BOs (v2)Alex Deucher2015-09-031-1/+2
| | | | | | | | | | | For kernel driver BOs, be explicit about whether we need vram access up front. This avoids unecessary migrations and avoids using visible vram for buffers were it's not needed. v2: line wrap fixes Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: cleanup amdgpu_ctx inti/fini v2Christian König2015-08-171-8/+5
| | | | | | | | | Cleanup the kernel context handling. v2: rebased Signed-off-by: Christian König <[email protected]> Reviewed-by: Chunming Zhou <[email protected]> (v1)
* drm/amdgpu: add kernel ctx support (v2)Chunming Zhou2015-08-171-0/+9
| | | | | | | | v2: rebase against kfd changes Signed-off-by: Chunming Zhou <[email protected]> Acked-by: Christian K?nig <[email protected]> Reviewed-by: Jammy Zhou <[email protected]>
* drm/amdgpu: Add Fiji DID 0x7300 common supportDavid Zhang2015-08-171-0/+2
| | | | | | | Signed-off-by: David Zhang <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Reviewed-by: Jammy Zhou <[email protected]> Reviewed-by: Christian König <[email protected]>
* drm/amdgpu: merge amdgpu_family.h into amd_shared.h (v2)Jammy Zhou2015-08-171-2/+2
| | | | | | | | | Make the definitions common for all driver components v2: fix kfd Signed-off-by: Jammy Zhou <[email protected]> Reviewed-by: Alex Deucher <[email protected]>
* drm/amdgpu: add fence suspend/resume functionsAlex Deucher2015-08-171-17/+4
| | | | | | | | | | | | | | | | Added to: - handle draining the ring on suspend - properly enable/disable interrupts on suspend and resume Fix breakages from: commit 467ee3be53d240d08beed2e82a941e820c1ac323 Author: Chunming Zhou <[email protected]> Date: Mon Jun 1 14:14:32 2015 +0800 drm/amdgpu: always enable EOP interrupt v2 Tested-by: Audrey Grodzovsky <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: clean up init sequence for failuresAlex Deucher2015-07-291-16/+22
| | | | | | | | | | If we fail during device init, record what state each block is in so that we can tear down clearly. Fixes various problems on device init failure. Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: disable the IP module if early_init returns -ENOENT (v2)Alex Deucher2015-07-161-2/+7
| | | | | | | | | | If we run into a part with a harvest configuration where the entire IP block is unusable, just disable the IP block. v2: fix logic as noted by Christian Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* gpu/drm/amdgpu: Fix build when CONFIG_DEBUG_FS is not setAlexander Kuleshov2015-06-291-0/+6
| | | | | | | | | | | | | | If the CONFIG_DEBUG_FS is not selected, compilation of the drivers/gpu/drm/amd/amdgpu/amdgpu_device.c provides two warnings that amdgpu_debugfs_regs_init and amdgpu_debugfs_regs_cleanup are used but never defined. And as result: ERROR: "amdgpu_debugfs_regs_cleanup" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ERROR: "amdgpu_debugfs_regs_init" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] undefined! ^ Reviewed-by: Christian König <[email protected]> Signed-off-by: Alexander Kuleshov <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* drm/amdgpu: allocate ip_block_enabled memory in common codeAlex Deucher2015-06-291-1/+3
| | | | | | | | Remove duplication across asic families and make it symmetric with the freeing of the code in amdgpu_device.c Reviewed-by: Christian König <[email protected]> Signed-off-by: Alex Deucher <[email protected]>