nouveau
16 years agorandr12: replace preferred_ramdac with preferred_output.
Maarten Maathuis [Wed, 5 Dec 2007 19:41:27 +0000 (20:41 +0100)] 
randr12: replace preferred_ramdac with preferred_output.

16 years agorandr12: Clean up the unneeded ramdac variable.
Maarten Maathuis [Wed, 5 Dec 2007 19:27:57 +0000 (20:27 +0100)] 
randr12: Clean up the unneeded ramdac variable.

16 years agorandr12: Pick right register set, to correctly "guess" the bios/VT clock.
Maarten Maathuis [Wed, 5 Dec 2007 18:03:52 +0000 (19:03 +0100)] 
randr12: Pick right register set, to correctly "guess" the bios/VT clock.

- A wrong register set leads to improper detection of crosswiring, thus selecting the wrong clock.
- I noticed a 0.675 MHz difference in the clock (which is vpll2), when instead i should have had vpll1.

16 years agorandr12: Small fix.
Maarten Maathuis [Wed, 5 Dec 2007 15:51:04 +0000 (16:51 +0100)] 
randr12: Small fix.

16 years agorandr12: Final commit, restore TMDS regs before everything else.
Maarten Maathuis [Wed, 5 Dec 2007 15:47:07 +0000 (16:47 +0100)] 
randr12: Final commit, restore TMDS regs before everything else.

- Use the bios to program the tmds registers.
- Restore TMDS registers in nv_crtc_restore, to make sure it's early enough (see code note).
- It works for me, let me know if it breaks stuff ;-)

16 years agorandr12: Intermediate bios based flat panel init commit, still a few minor issues.
Maarten Maathuis [Wed, 5 Dec 2007 06:57:30 +0000 (07:57 +0100)] 
randr12: Intermediate bios based flat panel init commit, still a few minor issues.

16 years agoAdd LVDS script function, and use it for DPMS
Stuart Bennett [Wed, 5 Dec 2007 00:35:35 +0000 (00:35 +0000)] 
Add LVDS script function, and use it for DPMS

16 years agoParse the LVDS Manufacturer table
Stuart Bennett [Wed, 5 Dec 2007 00:22:22 +0000 (00:22 +0000)] 
Parse the LVDS Manufacturer table

Use dual link flag to set bit 31 of FP_CONTROL properly

16 years agoModify DCB dual link flag, and DCB config parsing for LVDS
Stuart Bennett [Tue, 4 Dec 2007 20:31:06 +0000 (20:31 +0000)] 
Modify DCB dual link flag, and DCB config parsing for LVDS

The DCB duallink flag indicates that this setup may be used for duallink;
it obviously can't know whether a duallink display is plugged or not

Use LVDS DCB conf flags for mode detection / selection

16 years agorandr12: Add fullscreen gpu scaling (only as randr property for the moment).
Maarten Maathuis [Tue, 4 Dec 2007 08:06:10 +0000 (09:06 +0100)] 
randr12: Add fullscreen gpu scaling (only as randr property for the moment).

16 years agoBetter T table stuff.
Stuart Bennett [Tue, 4 Dec 2007 01:31:24 +0000 (01:31 +0000)] 
Better T table stuff.

Hopefully now usable by calling parse_t_table(...) at the appropriate place

Also collapse some messages, and add an array bound check

16 years agoAllow BIOS execution at runtime, if wanted
Stuart Bennett [Tue, 4 Dec 2007 01:40:37 +0000 (01:40 +0000)] 
Allow BIOS execution at runtime, if wanted

And comment the opcodes I haven't double checked yet

16 years agoMake the bios a bit more accessible
Stuart Bennett [Tue, 4 Dec 2007 01:31:24 +0000 (01:31 +0000)] 
Make the bios a bit more accessible

And make a few things use the new structure

16 years agorandr12: set CR58 appropriately for 0 and 2 cases
Stuart Bennett [Tue, 4 Dec 2007 00:00:40 +0000 (00:00 +0000)] 
randr12: set CR58 appropriately for 0 and 2 cases

16 years agorandr12: refactor dcb usage
Stuart Bennett [Mon, 3 Dec 2007 23:35:01 +0000 (23:35 +0000)] 
randr12: refactor dcb usage

heads is also a better name than head

16 years agorandr12: some code economy
Stuart Bennett [Mon, 3 Dec 2007 22:26:33 +0000 (22:26 +0000)] 
randr12: some code economy

Only addition is adding call to output2->funcs->commit when stealing a ramdac,
no logical changes otherwise AFAICT

16 years agorandr12: Improve CR57 and CR58 infrastructure and saving/restoration
Stuart Bennett [Tue, 4 Dec 2007 00:06:05 +0000 (00:06 +0000)] 
randr12: Improve CR57 and CR58 infrastructure and saving/restoration

16 years agorandr12: A few minor comment changes.
Maarten Maathuis [Mon, 3 Dec 2007 19:55:26 +0000 (20:55 +0100)] 
randr12: A few minor comment changes.

16 years agorandr12: Select CRTC 1 on pre-nv40 (stupid bug) + initial support choosing scaling...
Maarten Maathuis [Mon, 3 Dec 2007 19:51:16 +0000 (20:51 +0100)] 
randr12: Select CRTC 1 on pre-nv40 (stupid bug) + initial support choosing scaling method on tmds.

- The output property SCALING_MODE accepts "gpu" and "panel".
- The first obeys aspect ratio, the second always goes fullscreen.
- This is just a first attemp at exposing an output property.

16 years agoShow the id's of unknown bit structures in the bios.
Maarten Maathuis [Sun, 2 Dec 2007 21:10:56 +0000 (22:10 +0100)] 
Show the id's of unknown bit structures in the bios.

16 years agorandr12: dual-dvi cards need extra consideration.
Maarten Maathuis [Sun, 2 Dec 2007 11:02:08 +0000 (12:02 +0100)] 
randr12: dual-dvi cards need extra consideration.

16 years agoFix endian bug on BIT biosen
Stuart Bennett [Sun, 2 Dec 2007 02:33:57 +0000 (02:33 +0000)] 
Fix endian bug on BIT biosen

16 years agoDon't use PROM if the checksum is bad
Stuart Bennett [Sun, 2 Dec 2007 02:14:32 +0000 (02:14 +0000)] 
Don't use PROM if the checksum is bad

16 years agorandr12: print "or" _pre_ ffs-ing
Stuart Bennett [Sat, 1 Dec 2007 09:55:31 +0000 (09:55 +0000)] 
randr12: print "or" _pre_ ffs-ing

16 years agoDCB parsed flag for duallink outputs
Stuart Bennett [Sat, 1 Dec 2007 09:53:05 +0000 (09:53 +0000)] 
DCB parsed flag for duallink outputs

Light on proof, strong on suspicion with this one

16 years agorandr12: Always use vpll2_true on nv4x cards.
Maarten Maathuis [Sun, 2 Dec 2007 01:08:20 +0000 (02:08 +0100)] 
randr12: Always use vpll2_true on nv4x cards.

16 years agorandr12: A safer bet for TMDS register 0x2e.
Maarten Maathuis [Sun, 2 Dec 2007 00:48:01 +0000 (01:48 +0100)] 
randr12: A safer bet for TMDS register 0x2e.

16 years agorandr12: Remove preferred_crtc, since it's probably incorrect.
Maarten Maathuis [Sun, 2 Dec 2007 00:34:49 +0000 (01:34 +0100)] 
randr12: Remove preferred_crtc, since it's probably incorrect.

16 years agorandr12: Improve output register setting.
Maarten Maathuis [Sun, 2 Dec 2007 00:08:41 +0000 (01:08 +0100)] 
randr12: Improve output register setting.

16 years agorandr12: Fix up some dvi related issues, thanks to MighMoS.
Maarten Maathuis [Sat, 1 Dec 2007 17:40:46 +0000 (18:40 +0100)] 
randr12: Fix up some dvi related issues, thanks to MighMoS.

16 years agorandr12: Fix NV4x dvi clock selection, mostly affects G70 cards.
Maarten Maathuis [Sat, 1 Dec 2007 10:23:50 +0000 (11:23 +0100)] 
randr12: Fix NV4x dvi clock selection, mostly affects G70 cards.

16 years agoMake the debug variable global to all DMA calls.
Stephane Marchesin [Sat, 1 Dec 2007 09:33:53 +0000 (10:33 +0100)] 
Make the debug variable global to all DMA calls.

16 years agoThe BIT bios T table.
Stuart Bennett [Sat, 1 Dec 2007 06:29:09 +0000 (06:29 +0000)] 
The BIT bios T table.

T might stand for TMDS.
Parsing once on start may not be the correct answer, could be a runtime thing

16 years agoBump DCB table init so that INIT_50 can use it
Stuart Bennett [Sat, 1 Dec 2007 06:37:17 +0000 (06:37 +0000)] 
Bump DCB table init so that INIT_50 can use it

16 years ago"or" can be 0xc
Stuart Bennett [Sat, 1 Dec 2007 05:35:40 +0000 (05:35 +0000)] 
"or" can be 0xc

Quite what this means, or why Nvidia couldn't give it a more descriptive
variable name in the g80 driver is anyone's guess

16 years agoUse Nvidia's naming for CRTC_INDEX_COLOR
Stuart Bennett [Sat, 1 Dec 2007 05:17:47 +0000 (05:17 +0000)] 
Use Nvidia's naming for CRTC_INDEX_COLOR

16 years agoBios script code 0x50
Stuart Bennett [Sat, 1 Dec 2007 05:16:20 +0000 (05:16 +0000)] 
Bios script code 0x50

16 years agoAdd dcb "location" field. 0 for on-chip, !0 for external
Stuart Bennett [Sat, 1 Dec 2007 00:45:32 +0000 (00:45 +0000)] 
Add dcb "location" field. 0 for on-chip, !0 for external

16 years agorandr12: Don't unset bit 8-15 in sel_clk.
Maarten Maathuis [Fri, 30 Nov 2007 15:47:26 +0000 (16:47 +0100)] 
randr12: Don't unset bit 8-15 in sel_clk.

16 years agorandr12: Big commit, read message.
Maarten Maathuis [Fri, 30 Nov 2007 15:43:33 +0000 (16:43 +0100)] 
randr12: Big commit, read message.

- Outputs (on nv4x) should now select vpll2 instead of vpll1 when neccesary (this took a long time to figure out).
- Register 0x00680594 is now set correctly to allow analog secondary outputs to work (for me at least).
- I found the bit that triggers non-VGA modesetting in nv10reg, so in the future we could copy the blob in that area.
- Misc fixes to a lot of things.

16 years agorandr12: Make sure the vpll is properly set when we steal a ramdac from another output.
Maarten Maathuis [Mon, 26 Nov 2007 21:11:03 +0000 (22:11 +0100)] 
randr12: Make sure the vpll is properly set when we steal a ramdac from another output.

16 years agorandr12: Fixed a minor cursor bug.
Maarten Maathuis [Mon, 26 Nov 2007 18:40:59 +0000 (19:40 +0100)] 
randr12: Fixed a minor cursor bug.

16 years agorandr12: Set the value of sel_clk correctly (hopefully) for NV4x.
Maarten Maathuis [Mon, 26 Nov 2007 18:24:03 +0000 (19:24 +0100)] 
randr12: Set the value of sel_clk correctly (hopefully) for NV4x.

16 years agorandr12: cleanup + double register assignment (vga CRTC) removed.
Maarten Maathuis [Sun, 25 Nov 2007 21:08:23 +0000 (22:08 +0100)] 
randr12: cleanup + double register assignment (vga CRTC) removed.

16 years agorandr12: Convert premultiplied alpha cursors to normal alpha cursors.
Maarten Maathuis [Sun, 25 Nov 2007 17:15:27 +0000 (18:15 +0100)] 
randr12: Convert premultiplied alpha cursors to normal alpha cursors.

16 years agorandr12: Fix alpha cursor corruption.
Maarten Maathuis [Sun, 25 Nov 2007 15:49:01 +0000 (16:49 +0100)] 
randr12: Fix alpha cursor corruption.

16 years agorandr12: alpha cursors don't need background changes.
Maarten Maathuis [Sun, 25 Nov 2007 13:15:30 +0000 (14:15 +0100)] 
randr12: alpha cursors don't need background changes.

16 years agoReindent a few cursor functions.
Maarten Maathuis [Sun, 25 Nov 2007 12:06:10 +0000 (13:06 +0100)] 
Reindent a few cursor functions.

16 years agorandr12: Improve TMDS and LVDS registers (and enable for LVDS).
Maarten Maathuis [Sun, 25 Nov 2007 02:20:43 +0000 (03:20 +0100)] 
randr12: Improve TMDS and LVDS registers (and enable for LVDS).

16 years agorandr12: Optimize tmds_regs a little bit.
Maarten Maathuis [Sun, 25 Nov 2007 00:31:39 +0000 (01:31 +0100)] 
randr12: Optimize tmds_regs a little bit.

16 years agorandr12: use bus field to determine dvi pairs
Stuart Bennett [Sat, 24 Nov 2007 21:51:14 +0000 (21:51 +0000)] 
randr12: use bus field to determine dvi pairs

16 years agoRemove a load of unnecessary casts, and reorder functions by opcode
Stuart Bennett [Sat, 24 Nov 2007 20:44:27 +0000 (20:44 +0000)] 
Remove a load of unnecessary casts, and reorder functions by opcode

Plus a micro opt to checksum thing

16 years agoA bunch more cleaned up bios opcodes
Stuart Bennett [Sat, 24 Nov 2007 20:25:13 +0000 (20:25 +0000)] 
A bunch more cleaned up bios opcodes

Thanks to stillunknown for the bios trace

16 years agorandr12: Be more considerate of outputs that can only work on ramdac 1.
Maarten Maathuis [Sat, 24 Nov 2007 15:22:04 +0000 (16:22 +0100)] 
randr12: Be more considerate of outputs that can only work on ramdac 1.

16 years agorandr12: The result of another refinement of dvi crosswiring.
Maarten Maathuis [Sat, 24 Nov 2007 14:47:04 +0000 (15:47 +0100)] 
randr12: The result of another refinement of dvi crosswiring.

16 years agorandr12: Disable crt_load_detect for ramdac 1 and set some better valued for test_con...
Maarten Maathuis [Sat, 24 Nov 2007 12:12:49 +0000 (13:12 +0100)] 
randr12: Disable crt_load_detect for ramdac 1 and set some better valued for test_control.

16 years agorandr12: add bit30 to vpll register for nv4x cards
Maarten Maathuis [Fri, 23 Nov 2007 22:12:53 +0000 (23:12 +0100)] 
randr12: add bit30 to vpll register for nv4x cards

- This seems the most common situation, any idea what the bits do?

16 years agonv30: missing command
Patrice Mandin [Fri, 23 Nov 2007 21:25:47 +0000 (22:25 +0100)] 
nv30: missing command

16 years agonv30: another reference to an object
Patrice Mandin [Fri, 23 Nov 2007 21:25:06 +0000 (22:25 +0100)] 
nv30: another reference to an object

16 years agonv30: rename viewport clip
Patrice Mandin [Fri, 23 Nov 2007 21:24:19 +0000 (22:24 +0100)] 
nv30: rename viewport clip

16 years agonv30: was not using gart handle
Patrice Mandin [Fri, 23 Nov 2007 21:03:21 +0000 (22:03 +0100)] 
nv30: was not using gart handle

16 years agorandr12: Reenable a properly working crt load detect.
Maarten Maathuis [Fri, 23 Nov 2007 20:08:46 +0000 (21:08 +0100)] 
randr12: Reenable a properly working crt load detect.

16 years agorandr12: Remove some unneeded stuff.
Maarten Maathuis [Fri, 23 Nov 2007 17:58:49 +0000 (18:58 +0100)] 
randr12: Remove some unneeded stuff.

16 years agorandr12: fix comment typo
Maarten Maathuis [Fri, 23 Nov 2007 16:32:12 +0000 (17:32 +0100)] 
randr12: fix comment typo

16 years agorandr12: Allow arbitrary ramdac and crtc combinations.
Maarten Maathuis [Fri, 23 Nov 2007 15:40:02 +0000 (16:40 +0100)] 
randr12: Allow arbitrary ramdac and crtc combinations.

- Support for the misterious ramdac 2 still has to be reverse engineered.

16 years agorandr12: Move a lot of registers from output to crtc.
Maarten Maathuis [Fri, 23 Nov 2007 12:25:38 +0000 (13:25 +0100)] 
randr12: Move a lot of registers from output to crtc.

16 years agorandr12: There was more logic to sel_clk than previously thought.
Maarten Maathuis [Fri, 23 Nov 2007 09:32:08 +0000 (10:32 +0100)] 
randr12: There was more logic to sel_clk than previously thought.

16 years agorandr12: revert to old vpll regs on nv4x cards, because the others can't be written
Maarten Maathuis [Thu, 22 Nov 2007 21:18:47 +0000 (22:18 +0100)] 
randr12: revert to old vpll regs on nv4x cards, because the others can't be written

- If anyone knows the bit to allow those registers to be written, then please tell.
- This also fixes db1 vclk ratio issues, hopefully.

16 years agoBios CRTC head chosing fixed
Stuart Bennett [Thu, 22 Nov 2007 00:30:29 +0000 (00:30 +0000)] 
Bios CRTC head chosing fixed

Also, a slightly tighter limit on values for or, as I don't currently think
bit 4 being set makes any sense

16 years agorandr12: unbreak LVDS console restore by reverting tmds_regs change
Stuart Bennett [Wed, 21 Nov 2007 20:02:17 +0000 (20:02 +0000)] 
randr12: unbreak LVDS console restore by reverting tmds_regs change

16 years agoComplete init_index_addr_latched opcode
Stuart Bennett [Tue, 20 Nov 2007 19:02:17 +0000 (19:02 +0000)] 
Complete init_index_addr_latched opcode

16 years agoMore DCB entry output, and a default for DCB 1.4
Stuart Bennett [Wed, 21 Nov 2007 01:58:12 +0000 (01:58 +0000)] 
More DCB entry output, and a default for DCB 1.4

The table seems to be the same for all DCB 1.4 biosen I've seen, and
POST seems to make no effort to parse it. I wonder if it is in fact used at all

17 years agorandr12: better guess for ramdac register 670 (nv44 and up)
Maarten Maathuis [Tue, 20 Nov 2007 19:41:38 +0000 (20:41 +0100)] 
randr12: better guess for ramdac register 670 (nv44 and up)

17 years agorandr12: fix serious bug in vclk calculator for nv4x cards.
Maarten Maathuis [Tue, 20 Nov 2007 18:55:15 +0000 (19:55 +0100)] 
randr12: fix serious bug in vclk calculator for nv4x cards.

17 years agorandr12: Fix a small mistake that could cause blank screens for NV44 and up.
Maarten Maathuis [Tue, 20 Nov 2007 17:49:39 +0000 (18:49 +0100)] 
randr12: Fix a small mistake that could cause blank screens for NV44 and up.

17 years agorandr12: I hope i really fixed db1 vclk ratio this time (for nv4x).
Maarten Maathuis [Tue, 20 Nov 2007 11:56:28 +0000 (12:56 +0100)] 
randr12: I hope i really fixed db1 vclk ratio this time (for nv4x).

17 years agoNV50: Make a small mistake.
Maarten Maathuis [Tue, 20 Nov 2007 11:44:25 +0000 (12:44 +0100)] 
NV50: Make a small mistake.

17 years agoNV50: Some deobfuscation.
Maarten Maathuis [Tue, 20 Nov 2007 11:25:21 +0000 (12:25 +0100)] 
NV50: Some deobfuscation.

17 years agorandr12: Also enable DB1 vclk ratio if PLL_SELECT had it enabled.
Maarten Maathuis [Tue, 20 Nov 2007 08:52:47 +0000 (09:52 +0100)] 
randr12: Also enable DB1 vclk ratio if PLL_SELECT had it enabled.

17 years agorandr12: Proper support for db1 vclk ratio, thanks to Thunderbird for some info.
Maarten Maathuis [Mon, 19 Nov 2007 22:55:58 +0000 (23:55 +0100)] 
randr12: Proper support for db1 vclk ratio, thanks to Thunderbird for some info.

17 years agorandr12: Add a gamma_set hook.
Maarten Maathuis [Mon, 19 Nov 2007 08:23:37 +0000 (09:23 +0100)] 
randr12: Add a gamma_set hook.

17 years agorandr12: A first attempt at some lvds programming, not hooked up.
Maarten Maathuis [Sun, 18 Nov 2007 21:03:03 +0000 (22:03 +0100)] 
randr12: A first attempt at some lvds programming, not hooked up.

- This is a start for someone with a laptop to test and refine.

17 years agoEnable IFC uploads.
Benjamin Herrenschmidt [Sun, 18 Nov 2007 01:50:33 +0000 (02:50 +0100)] 
Enable IFC uploads.

17 years agorandr12: Final commit, switch to nv40 native vclk regs.
Maarten Maathuis [Sat, 17 Nov 2007 23:15:34 +0000 (00:15 +0100)] 
randr12: Final commit, switch to nv40 native vclk regs.

- I've also seperated the save load pll functions, to improve clarity.

17 years agorandr12: Intermediate commit (using the native nv40 vpll regs).
Maarten Maathuis [Sat, 17 Nov 2007 22:47:12 +0000 (23:47 +0100)] 
randr12: Intermediate commit (using the native nv40 vpll regs).

17 years agorandr12: Some comment fixes.
Maarten Maathuis [Sat, 17 Nov 2007 19:08:27 +0000 (20:08 +0100)] 
randr12: Some comment fixes.

17 years agorandr12: Reinstate m-divider limitations.
Maarten Maathuis [Sat, 17 Nov 2007 21:23:32 +0000 (22:23 +0100)] 
randr12: Reinstate m-divider limitations.

17 years agorandr12: Some minor changes.
Maarten Maathuis [Sat, 17 Nov 2007 17:36:24 +0000 (18:36 +0100)] 
randr12: Some minor changes.

17 years agorandr12: Change vpll handling, note that it still is a work in progress.
Maarten Maathuis [Sat, 17 Nov 2007 14:57:20 +0000 (15:57 +0100)] 
randr12: Change vpll handling, note that it still is a work in progress.

17 years agoEXA 1.4 pixmap hooks (disabled)
Ben Skeggs [Sat, 17 Nov 2007 09:59:25 +0000 (20:59 +1100)] 
EXA 1.4 pixmap hooks (disabled)

Really, you don't want to turn this on yet... :)

17 years agoAdd a user callback for when a channel hang is detected.
Ben Skeggs [Sat, 17 Nov 2007 06:17:34 +0000 (17:17 +1100)] 
Add a user callback for when a channel hang is detected.

17 years agoUse handles from grobj, instead of hardcoded vals from nv_dma.h
Ben Skeggs [Sat, 17 Nov 2007 06:02:23 +0000 (17:02 +1100)] 
Use handles from grobj, instead of hardcoded vals from nv_dma.h

17 years agoTurn vram/fb handles into "real" grobjs.
Ben Skeggs [Sat, 17 Nov 2007 05:43:05 +0000 (16:43 +1100)] 
Turn vram/fb handles into "real" grobjs.

17 years agoPut back memory barrier and write posting.
Stephane Marchesin [Sat, 17 Nov 2007 00:22:31 +0000 (01:22 +0100)] 
Put back memory barrier and write posting.

17 years agoAdd verbose debugging code to help with fixing push buffer issues.
Stephane Marchesin [Fri, 16 Nov 2007 22:38:49 +0000 (23:38 +0100)] 
Add verbose debugging code to help with fixing push buffer issues.

17 years agoOops. Correct either the header or the packet but not both.
Stephane Marchesin [Fri, 16 Nov 2007 22:37:10 +0000 (23:37 +0100)] 
Oops. Correct either the header or the packet but not both.

17 years agoUnmatched OUT_RING(0).
Stephane Marchesin [Fri, 16 Nov 2007 22:32:07 +0000 (23:32 +0100)] 
Unmatched OUT_RING(0).

17 years agofix typo.
Stephane Marchesin [Fri, 16 Nov 2007 20:59:53 +0000 (21:59 +0100)] 
fix typo.

17 years agofix 32/64 bit ism.
Stephane Marchesin [Fri, 16 Nov 2007 20:56:14 +0000 (21:56 +0100)] 
fix 32/64 bit ism.

17 years agorandr12: Minor change.
Maarten Maathuis [Fri, 16 Nov 2007 20:29:20 +0000 (21:29 +0100)] 
randr12: Minor change.