dect
/
linux-2.6
Archived
13
0
Fork 0
Commit Graph

190890 Commits

Author SHA1 Message Date
Alex Deucher 84d88f4c92 drm/radeon/kms/pm: voltage fixes
- Enable GPIO voltage for non pm modes as well so resetting
the default voltage works.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03 13:13:31 +10:00
Alex Deucher 92645879d0 drm/radeon/kms/pm: radeon_set_power_state fixes
- wait for vbl for both profile and dynpm
- unify profile and dynpm code paths more
- call pm_misc before of after clocks to make
sure voltage is changed in the proper order.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03 13:13:30 +10:00
Alex Deucher c5e8ce61d6 drm/radeon/kms/pm: patch default power state with default clocks/voltages on r6xx+
The default power state does not always match the default clocks and voltage
for a particular card.  The information in the firmware info table is correct
and should be used in preference to the info the default power state.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03 13:13:29 +10:00
Alex Deucher 9349d5cc92 drm/radeon/kms/pm: enable SetVoltage on r7xx/evergreen
I missed these in the r6xx commit.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03 13:13:28 +10:00
Alex Deucher 7ac9aa5a1f drm/radeon/kms/pm: add support for SetVoltage cmd table (V2)
- This enables voltage adjustment on r6xx+ and certain
r5xx asics.
- Voltage drop support is already available for most
r1xx-r5xx asics.

V2: endian fix for voltage table.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-03 13:13:24 +10:00
Alex Deucher cb5fcbd540 drm/radeon/kms/evergreen: add initial CS parser
Advanced validation is not implemented yet.
The mesa code that uses this will be released soon.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 11:46:04 +10:00
Dave Airlie 36d1701c50 Merge remote branch 'nouveau/for-airlied' of ../drm-nouveau-next into drm-testing
* 'nouveau/for-airlied' of ../drm-nouveau-next:
  drm/nv50: cast IGP memory location to u64 before shifting
  drm/nv50: use alternate source of SOR_MODE_CTRL for DP hack
  drm/nouveau: fix dual-link displays when plugged into single-link outputs
  drm/nv50: obey dcb->duallink_possible
  drm/nv50: fix duallink_possible calculation for DCB 4.0 cards
  drm/nouveau: don't execute INIT_GPIO unless we're really running the table
  drm/nv40: allow cold-booting of nv4x chipsets
  drm/nouveau: fix POST detection for certain chipsets
  drm/nouveau: Add getparam for current PTIMER time.
  drm/nouveau: allow cursor image and position to survive suspend
2010-06-01 11:32:29 +10:00
Dave Airlie afa3b60c90 Merge branch 'drm-switcheroo-fixes' into drm-testing
* drm-switcheroo-fixes:
  drm/kms: disable/enable poll around switcheroo on/off
  drm/nouveau: fixup confusion over which handle the DSM is hanging off.
  drm/nouveau: attempt to get bios from ACPI v3
2010-06-01 11:32:06 +10:00
Dave Airlie c09a350285 Merge branch 'drm-vmware-fixes' into drm-testing
* drm-vmware-fixes:
  drm/vmwgfx: Remove some leftover debug messages.
  drm/vmwgfx: Print warnings in kernel log about bo pinning that fails.
  drm/vmwgfx: Unpause overlay on update.
  drm/vmwgfx: Some modesetting cleanups and fixes.
  drm/vmwgfx: Don't use SVGA_REG_ENABLE in modesetting code.
  drm/vmwgfx: Remove duplicate member from struct vmw_legacy_display_unit.
  drm/vmwgfx: Reserve first part of VRAM for framebuffer.
  drm/vmwgfx: Support older hardware.
  drm/vmwgfx: Get connector status from detection function.
  drm/vmwgfx: Add kernel throttling support. Bump minor.
  drm/vmwgfx: Make sure to unpin old and pin new framebuffer.
  drm/vmwgfx: Fix single framebuffer detection.
  drm/vmwgfx: Assume larger framebuffer max size.
2010-06-01 11:32:06 +10:00
Dave Airlie fbf81762e3 drm/kms: disable/enable poll around switcheroo on/off
Because we aren't in a suspend state the poll will still run when we have switcherooed a card off.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 10:36:02 +10:00
Dave Airlie fc5ea29d72 drm/nouveau: fixup confusion over which handle the DSM is hanging off.
This fixes the DSM setup correctly since vga switcheroo.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 10:24:30 +10:00
Dave Airlie afeb3e1114 drm/nouveau: attempt to get bios from ACPI v3
Some of the laptops with the switchable graphics, seem to not post the secondary GPU at all, and we can't find a copy of the BIOS anywhere except in the ACPI rom retrieval.

This adds support for ACPI ROM retrieval to nouveau.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 10:24:21 +10:00
Ben Skeggs 8b281db596 drm/nv50: cast IGP memory location to u64 before shifting
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-06-01 09:49:12 +10:00
Thomas Hellstrom 4abe438979 drm/ttm: Fix ttm_page_alloc.c
Fix a number of typos misspellings and checkpatch.pl warnings.
Replace "[ttm] " with TTM_PFX

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:39:49 +10:00
Thomas Hellstrom e8613c0e29 drm/ttm: Fix cached TTM page allocation.
This patch fixes a regression introduced with the pool page allocator
in the event that there are no highmem pages (for example x86_64),
in which case cached page allocation would fail.

Tested with the vmwgfx driver on a 64-bit vm.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:39:48 +10:00
Thomas Hellstrom 1ca14e75ca drm/vmwgfx: Remove some leftover debug messages.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:38:03 +10:00
Jakob Bornecrantz 316ab13ae2 drm/vmwgfx: Print warnings in kernel log about bo pinning that fails.
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:53 +10:00
Jakob Bornecrantz 792778e8e0 drm/vmwgfx: Unpause overlay on update.
The unpause codepath uses vmw_overlay_update() so we must
unset the paused status.

Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:47 +10:00
Jakob Bornecrantz 259600d593 drm/vmwgfx: Some modesetting cleanups and fixes.
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:36 +10:00
Jakob Bornecrantz d451f62a7c drm/vmwgfx: Don't use SVGA_REG_ENABLE in modesetting code.
We should not use SVGA_REG_ENABLE anywhere but in the fifo setup code,
since it controls whether the device is active.

Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:32 +10:00
Jakob Bornecrantz bbfad33663 drm/vmwgfx: Remove duplicate member from struct vmw_legacy_display_unit.
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:29 +10:00
Thomas Hellstrom 22ee861c81 drm/vmwgfx: Reserve first part of VRAM for framebuffer.
The host may be touching this part of VRAM at modesetting,
even if we never use it ourselves, since we blit screen updates from 3D
surfaces. Make sure no DMA buffers are placed in this part of VRAM.

V2: Fix an error check in vmw_surface_dmabuf_pin().

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:28 +10:00
Jakob Bornecrantz d7e1958dbe drm/vmwgfx: Support older hardware.
V2: Fix a couple of typos.

Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:25 +10:00
Jakob Bornecrantz 1ae1ddd5e9 drm/vmwgfx: Get connector status from detection function.
Also make sure the ldu::active member is properly initialized.
Part of fix by Michel Daenzer <daenzer@vmware.com>.

Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Michel Daenzer <daenzer@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:21 +10:00
Thomas Hellstrom 1925d45658 drm/vmwgfx: Add kernel throttling support. Bump minor.
The throttle_us member in the execbuf argument is now honored.
If the member is 0, no waiting for lag will occur, which
guarantees backwards compatibility with well-behaved clients.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:15 +10:00
Jakob Bornecrantz 04e9e94dba drm/vmwgfx: Make sure to unpin old and pin new framebuffer.
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:37:09 +10:00
Jakob Bornecrantz 6a591a96d7 drm/vmwgfx: Fix single framebuffer detection.
V2: Fix a typo.

Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:36:59 +10:00
Jakob Bornecrantz 7e71f8a59e drm/vmwgfx: Assume larger framebuffer max size.
Signed-off-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-06-01 09:36:36 +10:00
Dave Airlie cf22f20ade drm/radeon: fix the r100/r200 ums block 0 page fix
airlied -> brown paper bag.

I blame Hi-5 or the Wiggles for lowering my IQ, move the fix inside some
brackets instead of breaking everything in site.

Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-29 06:50:37 +10:00
Ben Skeggs becd214277 drm/nv50: use alternate source of SOR_MODE_CTRL for DP hack
Fixes module unload+reload on Dell M4500, where the "normal" registers
get reset to 0.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:59 +10:00
Ben Skeggs 26099a7480 drm/nouveau: fix dual-link displays when plugged into single-link outputs
When selecting the native mode for a display we weren't taking into account
whether or not it was actually supported on that particular output.

This patch modifies our native mode selection to run all modes through
mode_valid() first.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:51 +10:00
Ben Skeggs 2c58077541 drm/nv50: obey dcb->duallink_possible
It was once assumed that all G8x had dual-link TMDS everywhere, this isn't
actually the case - especially considering passive DP->DVI converters and
some HDMI connectors only support single-link.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:45 +10:00
Ben Skeggs 23484874e6 drm/nv50: fix duallink_possible calculation for DCB 4.0 cards
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:42 +10:00
Ben Skeggs 73db4bedc5 drm/nouveau: don't execute INIT_GPIO unless we're really running the table
This resulted in accidently switching off the eDP panel on certain laptops
since the default state in the GPIO table was off.

Fixes rh#582621

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:36 +10:00
Ben Skeggs f50c0b91e7 drm/nv40: allow cold-booting of nv4x chipsets
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:32 +10:00
Ben Skeggs d13102c6b4 drm/nouveau: fix POST detection for certain chipsets
We totally fail at detecting un-POSTed chipsets prior to G80.  This commit
changes the pre-G80 POST detection to read the programmed horizontal total
from CRTC 0, and assume the card isn't POSTed if it's 0.

NVIDIA use some other heuristics more similar to what we do on G80, but I
wasted quite a long time trying to figure out the exact specifics of what
they do so we can try this for a bit instead.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:28 +10:00
Marcin Kościelnicki 7fc74f17e6 drm/nouveau: Add getparam for current PTIMER time.
This will be useful for computing GPU-CPU latency, including
GL_ARB_timer_query extension.

Signed-off-by: Marcin Kościelnicki <koriakin@0x04.net>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:21 +10:00
Maarten Maathuis b334f2b3b6 drm/nouveau: allow cursor image and position to survive suspend
- This isn't triggered yet on a normal kernel, because it still does a VT
switch, but it seemed like a good idea to fix this now.

Tested-by: Maxim Levitsky <maximlevitsky@gmail.com>
Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-05-28 16:06:17 +10:00
Jiri Slaby 2101d6f7ac agp: amd64, fix pci reference leaks
Stanse found pci reference leaks in uli_agp_init and nforce3_agp_init
initialization functions.

The PCI devices are bridges, so it's not critical, but still worth fixing.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-26 12:54:39 +10:00
Adam Jackson 4a638b4e38 drm/edid: Allow non-fatal checksum errors in CEA blocks
Switches will try to update the topology address and not correctly fix
up the checksum, so just let it slide.

https://bugs.freedesktop.org/28229

Signed-off-by: Adam Jackson <ajax@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-26 10:29:58 +10:00
Stefan Richter 921d98b582 drm/radeon/kms: suppress a build warning (unused variable)
At least 'make CONFIG_DEBUG_SECTION_MISMATCH=y' causes
drivers/gpu/drm/radeon/atombios_crtc.c: In function 'atombios_crtc_set_pll':
drivers/gpu/drm/radeon/atombios_crtc.c:684: warning: 'pll' may be used uninitialized in this function
which has the looks of a falso positive.

Add a default: case so that gcc rests assured that all possible pll_id's are covered.
Keep the present cases that fall through to the default one for self-documentation.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-26 10:27:44 +10:00
Prarit Bhargava f49d273df9 drm: Fixes linux-next & linux-2.6 checkstack warnings:
drivers/gpu/drm/nouveau/nv40_graph.c: In function `nv40_graph_init':
drivers/gpu/drm/nouveau/nv40_graph.c:400: warning: the frame size of 1184 bytes is larger than 1024 bytes
drivers/gpu/drm/radeon/radeon_atombios.c: In function `radeon_get_atom_connector_info_from_supported_devices_table':
drivers/gpu/drm/radeon/radeon_atombios.c:857: warning: the frame size of 1872 bytes is larger than 1024 bytes

Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-24 10:24:07 +10:00
Randy Dunlap 579766020d nouveau: fix acpi_lid_open undefined
When CONFIG_ACPI_BUTTON=m (and probably when ACPI_BUTTON is not enabled)
and NOUVEAU is built-in (not as a loadable module):

nouveau_connector.c:(.text+0xe17ce): undefined reference to `acpi_lid_open'

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Acked-by: Ben Skeggs <bskeggs@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-24 10:21:47 +10:00
Jerome Glisse 10b06122af drm/radeon/kms: release AGP bridge at suspend
I think it's good to release the AGP bridge at suspend
and reacquire it at resume. Also fix :
https://bugzilla.kernel.org/show_bug.cgi?id=15969

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Cc: stable <stable@kernel.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-24 10:02:08 +10:00
Alex Deucher b486787ee4 drm/radeon/kms/pm/r600: select the mid clock mode for single head low profile
This saves some more power at the expense of performance.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-21 15:47:40 +10:00
Dave Airlie df696a6fe8 Merge remote branch 'nouveau/for-airlied' into drm-next
* nouveau/for-airlied:
  drm/nouveau: fix i2c-related init table handlers
  drm/nouveau: support init table i2c device identifier 0x81
  drm/nouveau: ensure we've parsed i2c table entry for INIT_*I2C* handlers
  drm/nouveau: display error message for any failed init table opcode
  drm/nouveau: fix init table handlers to return proper error codes
  drm/nv50: support fractional feedback divider on newer chips
  drm/nv50: fix monitor detection on certain chipsets
  drm/nv50: store full dcb i2c entry from vbios
  drm/nv50: fix suspend/resume with DP outputs
  drm/nv50: output calculated crtc pll when debugging on
  drm/nouveau: dump pll limits entries when debugging is on
  drm/nouveau: bios parser fixes for eDP boards
  drm/nouveau: fix a nouveau_bo dereference after it's been destroyed
  drm/nv40: remove some completed ctxprog TODOs
  drm/nv04: Implement missing nv04 PGRAPH methods in software.
  drm/nouveau: Use 0x5f instead of 0x9f as imageblit on original NV10.
2010-05-21 15:44:32 +10:00
Dave Airlie 5d9b7e2d2d drm/radeon: fix power supply kconfig interaction.
radeon needs power supply to get correct PM info so select it at the radeon
level not at the kms option.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-21 15:41:20 +10:00
Jerome Glisse e865275335 drm/radeon/kms: record object that have been list reserved
list reservation was too optimistic about ttm object reservation
and could think that an object reserved by some other process
as reserved by the list reservation which was false. Thus when
unreserving the list it might unreserve object that it didn't
reserved in the list. Sorry if it's hard to follow but this
kind of things are just causing headheck.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-21 15:07:24 +10:00
Michel Dänzer 365048ff7f drm/radeon: AGP memory is only I/O if the aperture can be mapped by the CPU.
Fixes AGP initialization failure with Apple UniNorth bridges due to trying to
ioremap() normal RAM.

Signed-off-by: Michel Dänzer <daenzer@vmware.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-21 15:06:45 +10:00
Alex Deucher 45737447ed drm/radeon/kms: don't default display priority to high on rs4xx
Seems to cause issues with the sound hardware.  Fixes kernel
bug 15982:
https://bugzilla.kernel.org/show_bug.cgi?id=15982

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-21 15:06:06 +10:00