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

68 Commits

Author SHA1 Message Date
Alex Deucher 8e36ed0084 drm/radeon/kms: hpd cleanup
- Use radeon hpd enum consistently (in both hotplug and dp)
- Legacy r100 with DVI should be HPD_1 not NONE

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-19 10:31:41 +10:00
Alex Deucher 2bfcc0fc69 drm/radeon/kms: reset ddc_bus in object header parsing
Some LVDS connectors don't have a ddc bus, so reset the
ddc bus to invalid before parsing the next connector
to avoid using stale ddc bus data.  Should fix
fdo bug 28164.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-19 10:31:16 +10:00
Dave Airlie 05ea893c46 Merge remote branch 'anholt/drm-intel-next' into drm-next
* anholt/drm-intel-next: (515 commits)
  drm/i915: Fix out of tree builds
  drm/i915: move fence lru to struct drm_i915_fence_reg
  drm/i915: don't allow tiling changes on pinned buffers v2
  drm/i915: Be extra careful about A/D matching for multifunction SDVO
  drm/i915: Fix DDC bus selection for multifunction SDVO
  drm/i915: cleanup mode setting before unmapping registers
  drm/i915: Make fbc control wrapper functions
  drm/i915: Wait for the GPU whilst shrinking, if truly desperate.
  drm/i915: Use spatio-temporal dithering on PCH
  [MTD] Remove zero-length files mtdbdi.c and internal.ho
  pata_pcmcia / ide-cs: Fix bad hashes for Transcend and kingston IDs
  libata: Fix several inaccuracies in developer's guide
  slub: Fix bad boundary check in init_kmem_cache_nodes()
  raid6: fix recovery performance regression
  KEYS: call_sbin_request_key() must write lock keyrings before modifying them
  KEYS: Use RCU dereference wrappers in keyring key type code
  KEYS: find_keyring_by_name() can gain access to a freed keyring
  ALSA: hda: Fix 0 dB for Packard Bell models using Conexant CX20549 (Venice)
  ALSA: hda - Add quirk for Dell Inspiron 19T using a Conexant CX20582
  ALSA: take tu->qlock with irqs disabled
  ...
2010-05-19 09:35:51 +10:00
Alex Deucher d7311171c4 drm/radeon/kms/pm: add support for no display power states
The lowest power states often cause display problems, so only enable
them when all displays are off.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 18:21:50 +10:00
Alex Deucher 79daedc942 drm/radeon/kms: minor pm cleanups
- remove non_clock_info struct
- track power state misc flags

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 18:21:08 +10:00
Alex Deucher 678e7dfa9e drm/radeon/kms/atom: load hwmon drivers
Hook the atom table parsing up to module loading, so we can automatically
load the appropriate hwmon drivers.

Based on initial patch for r6xx from Matthew Garrett

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 18:21:02 +10:00
Alex Deucher a48b9b4edb drm/radeon/kms/pm: add asic specific callbacks for getting power state (v2)
This also simplifies the code and enables reclocking with multiple heads
active by tracking whether the power states are single or multi-head
capable.

Eventually, we will want to select a power state based on external
factors (AC/DC state, user selection, etc.).

(v2) Update for evergreen

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 18:20:58 +10:00
Alex Deucher 02b17cc053 drm/radeon/kms/atom/pm: rework power mode parsing
On pre-r6xx, the power mode array is usually ordered:
low
...
high
default

On r6xx+:
default
low
...
high

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 18:20:52 +10:00
Alex Deucher 1ff26a3604 drm/radeon/kms/atom: fix typo in LVDS panel info parsing
Fixes LVDS issues on some laptops; notably laptops with
2048x1536 panels.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-05-18 15:53:52 +10:00
Eric Anholt 34dc4d4423 Merge remote branch 'origin/master' into drm-intel-next
Conflicts:
	drivers/gpu/drm/i915/i915_dma.c
	drivers/gpu/drm/i915/i915_drv.h
	drivers/gpu/drm/radeon/r300.c

The BSD ringbuffer support that is landing in this branch
significantly conflicts with the Ironlake PIPE_CONTROL fix on master,
and requires it to be tested successfully anyway.
2010-05-10 13:36:52 -07:00
Dan Carpenter 0031c41be5 drivers/gpu/drm/radeon/radeon_atombios.c: range check issues
This change makes the array larger, "MAX_SUPPORTED_TV_TIMING_V1_2" is 3
and the original size "MAX_SUPPORTED_TV_TIMING" is 2.

Also there were checks that were off by one.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-04-28 18:41:54 +10:00
Alex Deucher 49f6598277 drm/radeon/kms: add support for evergreen power tables
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-04-09 10:15:27 +10:00
Alex Deucher 95beb69017 drm/radeon/kms/atom: fix gpio i2c table overrun (v2)
The GPIO_I2C_INFO table does not always have
ATOM_MAX_SUPPORTED_DEVICE entries. Limit
the number of indices to the size of the
table.

Should fix Novell bug 589022.

v2: fix typo

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: Stable <stable@kernel.org>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-04-06 09:59:31 +10:00
Alex Deucher e1e8a5dd4f drm/radeon/kms: fix macbookpro connector quirk
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-31 13:12:45 +10:00
Alex Deucher a084e6ee6e drm/radeon/kms/atom: make sure tables are valid (v2)
Check that atom cmd and data tables are valid
before using them.

(v2)
- fix some whitespace errors noticed by Rafał Miłecki
- check a few more cases

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-31 13:11:29 +10:00
Alex Deucher c1bcad9d16 drm/radeon/kms: remove lvds quirks
- no longer needed with the latest new pll algo fixes.
- also don't use lcd pll limits.  They don't seem
to work well for all systems.  If we have a case where
they are useful, we can set the flag for that case.

fixes fdo bug 27083

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-31 13:11:23 +10:00
Alex Deucher 06abdb0ec6 drm/radeon/kms/pm: fix typo in power table parsing
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-31 09:54:02 +10:00
Alex Deucher 29fb52ca78 drm/radeon/kms: expose thermal/fan i2c buses
Look up i2c bus in the power table and expose it.
You'll need to load a hwmon driver for any chips
on the bus, this patch just exposes the bus.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2010-03-31 09:38:06 +10:00
Alex Deucher 86cb2bbfda drm/radeon/kms: use lcd pll limits when available
The bios has alternate pll output limits for LCD panels.
If available, use these for pll divider calculations.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-15 09:56:46 +10:00
Dave Airlie eb6b6d7cdd Merge remote branch 'korg/drm-radeon-testing' into drm-next-stage
* korg/drm-radeon-testing: (62 commits)
  drm/radeon/kms: update new pll algo
  drm/radeon/kms: add support for square microtiles on r3xx-r5xx
  drm/radeon/kms: force pinning buffer into visible VRAM
  drm/radeon/kms/evergreen: fix typo in cursor code
  drm/radeon/kms: implement reading active PCIE lanes on R600+
  drm/radeon/kms: for downclocking non-mobility check PERFORMANCE state
  drm/radeon/kms: simplify storing current and requested PM mode
  drm/radeon: fixes for r6xx/r7xx gfx init
  drm/radeon/rv740: fix backend setup
  drm/radeon/kms: fix R3XX/R4XX memory controller initialization
  [rfc] drm/radeon/kms: pm debugging check for vbl.
  drm/radeon: Fix memory allocation failures in the preKMS command stream checking.
  drm: Add generic multipart buffer.
  drm/radeon/kms: simplify memory controller setup V2
  drm/radeon: Add asic hook for dma copy to r200 cards.
  drm/radeon/kms: Create asic structure for r300 pcie cards.
  drm/radeon/kms: remove unused r600_gart_clear_page
  drm/radeon/kms: remove HDP flushes from fence emit (v2)
  drm/radeon/kms: add LVDS pll quirk for Dell Studio 15
  drm/radeon/kms: simplify picking power state
  ...

Conflicts:
	drivers/gpu/drm/radeon/atom.c
	drivers/gpu/drm/radeon/atombios.h
	drivers/gpu/drm/radeon/atombios_dp.c
	drivers/gpu/drm/radeon/r600.c
	drivers/gpu/drm/radeon/r600_audio.c
	drivers/gpu/drm/radeon/r600_cp.c
	drivers/gpu/drm/radeon/radeon.h
	drivers/gpu/drm/radeon/radeon_connectors.c
	drivers/gpu/drm/radeon/radeon_ring.c
	drivers/gpu/drm/radeon/rv770.c
2010-02-26 16:23:23 +10:00
Alex Deucher 383be5d178 drm/radeon/kms: update new pll algo
- add support for pre-avivo chips
- add support for fixed post/ref dividers
- add support for non-fractional fb dividers

By default avivo chips use the new algo and
pre-avivo chips use the old algo. Use the "new_pll"
module option to toggle between them.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-25 11:38:06 +10:00
Rafał Miłecki 9038dfdf69 drm/radeon/kms: simplify storing current and requested PM mode
We kept pointers to requested and current clock modes in every power state.
That was useless, more /global/ pointers in power struct are enough.

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-23 09:46:51 +10:00
Alex Deucher c86a903836 drm/radeon/kms/rs600: add connector quirk
rs600 board lists DVI port as HDMI.

Fixes fdo bug 26605

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-20 07:28:05 +10:00
Alex Deucher 8e0d84a63a drm/radeon/kms: add LVDS pll quirk for Dell Studio 15
fixes fdo bug 26358

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-18 14:29:13 +10:00
Rafał Miłecki 2745932495 drm/radeon/kms: accept slightly overclocked power modes
Fixes fdo bug #26329

Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Tested-by: Tobias Jakobi <liquid.acid@gmx.net>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-18 14:25:08 +10:00
Alex Deucher bcc1c2a1d2 drm/radeon/kms: add initial Evergreen support (Radeon HD 5xxx)
This adds initial Evergreen KMS support, it doesn't include
any acceleration features or interrupt handling yet.

Major changes are DCE4 handling for PLLs for the > 2 crtcs.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:44:02 +10:00
Alex Deucher 6d7f2d8da1 drm/radeon/kms: dynclks fixes
- only r4xx/r5xx/rs6xx/rs740 have clock gating atom table,
so disable it on r6xx.  it's already disabled on r7xx
- check to make sure the clock_gating hook exists before
calling it.  This avoids a segfault on asics without
that function.
- remove unused static power management function.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:32:31 +10:00
Alex Deucher 0ec0e74f78 drm/radeon/kms: add a power state type based on power state flags
The idea is to flag a power state with a certain type and use
that type to decide on what state to select.  On r6xx+, we
select a state and then transition between clock modes in that
state.  On pre-r6xx, we transition between states directly.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:32:28 +10:00
Rafał Miłecki 845db70da0 drm/radeon/kms: don't set pcie lanes for ignored power_state
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:32:28 +10:00
Alex Deucher 56278a8eda drm/radeon/kms: pull power mode info from bios tables (v3)
The general idea is to validate the current hw state
against the set of power states and select a power
state based on that.  This patch just pulls the power
states from the bios and prints the information.  It
is not currently hooked up in the actual power management
code.  Hooking it up will require reworking the the current
power state selection code and will be handled in a future
patch.

Additionally, we'd need to decide on some default lower
power states for cards without power tables.

v2 - increment state_index after checking for default state
v3 - fix typo in pm init on pre-atom cards, handle pre-atom
cards without x86 bioses

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:32:27 +10:00
Alex Deucher 093972788f drm/radeon/kms: add pll quirk for toshiba laptop panel
The panel on the Toshiba A300-1BU laptop does not like the
PLL dividers selected by the avivo pll algo, but works fine
using the older method.  Add a quirk to handle it.

Should fix fdo bug 26358.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2010-02-09 09:31:22 +10:00
Alex Deucher 7c27f87d2b drm/radeon/kms: rework pll algo selection
Rework the pll algo selection so that the pll algo
in use can be selected more easily.  This allows
us to select different pll divider selection algos
for specific monitors that work better with one algo
or the other.  This is needed for the next patch which
adds an LVDS pll quirk for a specific notebook.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:31:21 +10:00
Dave Airlie efa8450f6c drm/radeon/kms: add quirk for VGA without DDC on rv730 XFX card.
Reported on irc by nirbheek.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-09 09:06:00 +10:00
Alex Deucher 06b6476d6b drm/radeon/kms: detect sideport memory on IGP chips
This detects if the sideport memory is enabled and
if it is VRAM is evicted on suspend/resume.

This should fix s/r issues on some IGPs.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-08 13:08:56 +10:00
Alex Deucher 196c58d21f drm/radeon/kms: add support for eDP (embedded DisplayPort)
This is displayport used for internal connections such
as laptop panels and systems with integrated monitors.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-08 13:04:09 +10:00
Alex Deucher 1d3d51b6d2 drm/radeon/kms: add missing breaks in i2c and ss lookups
Should fix fdo bug 25741

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-06 11:31:56 +10:00
Alex Deucher f56cd64f5f drm/radeon/kms: never combine LVDS with another encoder
When linking multiple encoders to a connector, make sure
to not link LVDS with another connector.  Some bioses
have the same i2c line for LVDS and VGA.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-23 11:14:05 +10:00
Alex Deucher d79766fab9 drm/radeon/kms: set proper default tv standard
we were just using 1 before.

reported on irc by soreau

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-23 11:14:03 +10:00
Alex Deucher b27b63750d drm/radeon/kms/avivo: add support for new pll selection algo
Supported on all AVIVO-based asics.
Can be disabled via the new_pll module parameter:
new_pll=0 - disable
new_pll=1 - enable
enabled by default

[airlied: fixed to use do_div]
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@linux.ie>
2009-12-10 15:09:05 +10:00
Alex Deucher d3f420d108 drm/radeon/kms: make sure i2c id matches
Entries in the i2c table aren't always ordered
by id.  This allows us to remove some quirks
that are no longer needed.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-09 13:31:10 +10:00
Alex Deucher 279b215ecb drm/radeon/kms: make sure ss id matches
entries in the ss table aren't always ordered
by id.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-09 13:31:07 +10:00
Alex Deucher eed45b30cd drm/radeon/kms: get HPD info for connectors
This populates the connectors with HPD (Hot Plug Detect)
information.  This will be used in subsequent patches
for automatic digital monitor connect/disconnect handling.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-08 10:46:28 +10:00
Alex Deucher 6a93cb250a drm/radeon/kms: i2c reorg
- keep the atom i2c id in the i2c rec
- fix gpio regs for GPIO and MDGPIO on pre-avivo chips
- track whether the i2c line is hw capable
- track whether the i2c line uses the multimedia i2c block

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-08 10:22:41 +10:00
Dave Airlie 746c1aa4d1 drm/radeon/kms: initial radeon displayport porting
This is enough to retrieve EDID and DPCP.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-08 10:22:31 +10:00
Dave Airlie aa1a750ecb drm/radeon/kms: quirk for Gigabyte RV515 card, DVI+VGA not 2xDVI.
Similiar to other quirks for RV515, this card has no second DVI port.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-04 11:56:28 +10:00
Alex Deucher 4e3f9b78ff drm/radeon/kms: Add quirk for HIS X1300 board
Board is DVI+VGA, not DVI+DVI

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Cc: stable@kernel.org
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-04 10:31:53 +10:00
Alex Deucher 7dde8a1965 drm/radeon/kms/atom: pull misc mode info for lvds from bios tables
sync polarity, etc.  This will likely fix LVDS problems
on some laptops.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-02 11:37:15 +10:00
Alex Deucher 3e5f8ff3a9 drm/radeon/kms: add quirk for Acer laptop
DVI-I port is actually DVI-D

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-02 11:36:44 +10:00
Alex Deucher 9b9fe72488 drm/radeon/kms: clean up i2c
- Change reg/mask names to match what we use internally
and in the bios
- Clarify how i2c over gpio on radeon actually works

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-02 11:36:39 +10:00
Rafał Miłecki 7433874e31 drm/radeon/kms: add debugfs for power management for AtomBIOS devices
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-06 14:13:25 +10:00