aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu
AgeCommit message (Collapse)AuthorFilesLines
2012-09-21Merge branch 'drm-fixes-3.6' of git://people.freedesktop.org/~agd5f/linux ↵Dave Airlie1-1/+2
into drm-fixes fixes a resume regression on pre-r6xx asics. * 'drm-fixes-3.6' of git://people.freedesktop.org/~agd5f/linux: drm/radeon: Prevent leak of scratch register on resume from suspend
2012-09-20drm/radeon: make non-DP PPLL sharing more robustAlex Deucher1-13/+14
Compare the adjusted clock as well as the crtc mode clock. This handles cases where the driver adjusts the clock for specific special cases. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: store the encoder in the radeon_crtcAlex Deucher2-208/+166
This saves lots of lookups later. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: rework crtc pll setup to better support PPLL sharingAlex Deucher2-103/+150
We need the calculate the pixel clock before allocating a PPLL in order to insure the clocks really match. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: allow PPLL sharing on non-DP displaysAlex Deucher1-6/+65
If several non-DP displays use the same pixel clock we can use the same PPLL for all of them. If all relevant displays have the same pixel clock, this allows the driver to: - use fewer PPLLs which saves power - support more than two non-DP displays on DCE4+ The current drm modesetting infrastructure doesn't really provide a good framework for validating combinations that work or won't work, so it's possible you could go from a working configuration to a non-working one by changing the mode a one of the displays. However, there this is better than what was there before. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon/dce3: use a single PPLL for all DP displaysAlex Deucher1-0/+24
If possible, use a single PPLL for multiple DP displays on DCE3.x. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: rework pll selection (v4)Alex Deucher1-34/+129
For DP we can use the same PPLL for all active DP encoders. Take advantage of that to prevent cases where we may end up sharing a PPLL between DP and non-DP which won't work. Also clean up the code a bit. v2: - fix missing pll_id assignment in crtc init v3: - fix DP PPLL check - document functions - break in main encoder search loop after matching. no need to keep checking additional encoders. v4: - same as v3, but re-apply to drm-next as the corner cases are fixed properly in subsequent patches. fixes: https://bugs.freedesktop.org/show_bug.cgi?id=54471 Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: fix typo in atombios_get_encoder_modeAlex Deucher1-1/+2
comparing the encoder mode to the encoder id for DVO. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon/atom: fix typo in SetPixelClock handlingAlex Deucher1-1/+4
MiscInfo field should be programmed with the crtc id rather than the pll id. However, at this point the two are the same for chips with this version of the table. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: white space cleanup in transmitter setupAlex Deucher1-8/+4
Makes it more consistent with the surrounding code. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: clean up encoder dp checksAlex Deucher1-4/+4
Use the proper struct in the union. That field has the same offset in every struct, so no functional change. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: rework the VM code a bit more (v2)Christian König4-72/+154
Roughly based on how nouveau is handling it. Instead of adding the bo_va when the address is set add the bo_va when the handle is opened, but set the address to zero until userspace tells us where to place it. This fixes another bunch of problems with glamor. v2: agd5f: fix build after dropping patch 7/8. Signed-off-by: Christian König <[email protected]>
2012-09-20drm/radeon: fix gem_close_object handlingChristian König1-2/+5
Make the reserve non interruptible. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: let bo_reserve take no_intr instead of no_wait paramChristian König2-5/+4
The no_wait param isn't used anywhere, and actually isn't very usefull at all. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: move and rename radeon_bo_va functionChristian König5-20/+33
It doesn't really belong into the object functions, also rename it to avoid collisions with struct radeon_bo_va. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: move IB pool to 1MB offsetChristian König3-4/+5
Even GPUs can have a null pointer dereference, so move the IB pool to another offset to catch those. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: fix VA overlap checkChristian König1-1/+1
Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: fix VA range checkChristian König1-1/+1
The end offset is exclusive not inclusive. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: fix VM syncing with multiple ringsChristian König1-1/+1
When a VM is used on more than one ring we need to sync to the last user. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: Remove unused functionsLauri Kasanen4-74/+0
This applies on top of drm/radeon: Mark all possible functions / structs as static. Signed-off-by: Lauri Kasanen <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: Mark all possible functions / structs as staticLauri Kasanen27-93/+93
Let's allow GCC to optimize better. This exposed some five unused functions, but this patch doesn't remove them. Signed-off-by: Lauri Kasanen <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: remove dead function defAlex Deucher1-2/+1
Was removed in the async VM update series. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: implement bounds checking on thermal controller lookupAlex Deucher1-2/+9
Don't read past the end of the array if we encounter an unknown thermal controller. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: document async VM changes in ni.cAlex Deucher1-0/+15
Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: make page table updates async v2Christian König5-25/+71
Currently doing the update with the CP. v2: Rebased on Jeromes bugfix. Make validity comparison more human readable. Signed-off-by: Christian König <[email protected]>
2012-09-20drm/radeon: make sure ib bo is properly bound and up to date in vm spaceJerome Glisse1-0/+5
Make sure that the ib bo is bound and is page table is up to date in the virtual address space. Signed-off-by: Jerome Glisse <[email protected]> Reviewed-by: Christian König <[email protected]>
2012-09-20drm/radeon: Move looping over the PTEs into chip codeChristian König5-34/+34
Makes it easier to move it into the rings. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: rework VM page table handlingChristian König4-116/+43
Removing the need to wait for anything. Still not ideal, since we need to free pt on va remove. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: rework VMID handlingChristian König8-76/+153
Move binding onto the ring, simplifying handling a bit. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: make VM flushs a ring operationChristian König8-38/+42
Move flushing the VMs as function into the rings. First step to make VM operations async. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: add sync helper functionChristian König1-6/+14
Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: remove vm_unbindChristian König5-29/+0
It actually isn't very useful. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: move VM funcs into asic structureChristian König3-47/+54
So it looks more like the rest of the driver. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon: cleanup VM id handling a bitChristian König7-26/+25
Store a reference to the VM into the IB structure, that makes calculating the IBs address a bit less complicated. Signed-off-by: Christian König <[email protected]> Reviewed-by: Jerome Glisse <[email protected]>
2012-09-20drm/radeon/atom: add consolidate bpc codeAlex Deucher1-67/+29
Several encoder setup functions had the same duplicated code for selecting the proper bpc setting for various atom tables. Consolidate it. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: rework the backlight control to be an asic callbackAlex Deucher7-33/+84
This cleans up the interface a bit as well. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: add initial support for ATCS ACPI methodsAlex Deucher2-1/+138
Just verify the interface and track what functions are supported. Not actually used yet. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: document radeon_atpx_handler.c (v2)Alex Deucher1-0/+111
v2: rebase updates Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: reorganize ATPX support (v2)Alex Deucher1-60/+110
- rework the acpi execute code - User proper parameters for ATPX functions v2: rebase fixes Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: update ATPX verify interface handling (v2)Alex Deucher1-17/+124
Verify the ATPX interface and track what ATPX functions are available for future use. v2: rework due to tree changes Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: document radeon_acpi.cAlex Deucher1-0/+101
Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: block the keypress on ATIF eventsLuca Tettamanti1-1/+6
The AMD ACPI interface may use ACPI_VIDEO_NOTIFY_PROBE to signal SBIOS requests; block the keypress in this case since the user did not actually press the mode switch key. Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: re-organize the acpi notifier callbackAlex Deucher4-43/+48
Move it out of the radeon_pm.c and into radeon_acpi.c since we use it for more than just pm now. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: implement handler for ACPI eventLuca Tettamanti7-11/+152
Set up an handler for ACPI events and respond to brightness change requests from the system BIOS. v2: fix notification when using device-specific command codes (tested by Pali Rohár <[email protected]>); cache the encoder controlling the backlight during the initialization to avoid searching it every time (suggested by Alex Deucher). v3: whitespace fixes (Alex Deucher). Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: implement wrapper for GET_SYSTEM_PARAMSLuca Tettamanti1-2/+83
Use GET_SYSTEM_PARAMS for retrieving the configuration for the system BIOS notifications. v2: packed struct (Lee, Chun-Yi <[email protected]>) v3: fix enable with device specific command code Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: implement radeon_atif_verify_interfaceLuca Tettamanti2-6/+113
Wrap the call to VERIFY_INTERFACE and add the parsing of the support vectors. v2: use a packed struct for handling the output of ACPI calls, hides ugly pointer arithmetics (Lee, Chun-Yi <[email protected]>). v3: fix radeon_atif_parse_functions handling (Alex Deucher) Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: refactor radeon_atif_callLuca Tettamanti1-15/+23
Don't hard-code function number, this will allow to reuse the function. v2: add support for the 2nd parameter (from Lee, Chun-Yi <[email protected]>). Signed-off-by: Luca Tettamanti <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: add backlight control for atom devices (v2)Alex Deucher3-16/+248
On systems that use the build in GPU backlight controller, we can use atom tables to change the brightness level. v2: use firmware flags Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: rework legacy backlight controlAlex Deucher2-13/+17
To better enable sharing with atom backlight control. Signed-off-by: Alex Deucher <[email protected]>
2012-09-20drm/radeon: track whether the GPU controls the backlight (v2)Alex Deucher2-0/+6
A table in the vbios tells us whether the GPU backlight controller is used or not. If the bit is set, the GPU backlight controller is used; if it is not set, an off-chip backlight controller is used. v2: store all the firmware flags, not just BL control Signed-off-by: Alex Deucher <[email protected]>