RANDR1.2 and LVDS
Hi!
I've written a small amount of code that gets the randr 1.2 branch much closer to working for me on a laptop. Most of the changes are fairly obvious, but a couple of comments:
1) The changes to nv_crtc.c are clearly bogus, but I'm not sure what on earth these registers do. I need to set them to get a moderately sane-looking picture
2) The fp registers poked in nv_output.c don't seem to do anything on lvds. No matter what I set them to, the picture is identical
3) This doesn't /quite/ work for me yet. I have a solid and recognisable picture, but it's only about the left two thirds of my screen, centred on the display with black borders. Clearly the panel programming isn't /quite/ right yet...
Signed-off-by Matthew Garrett <[email protected]>
src/nv_crtc.c +3 -2
@@ -945,8 +945,9 @@ nv_crtc_mode_set_regs(xf86CrtcPtr crtc, DisplayModePtr mode) }else regp->cursorConfig |=0x02000000 ; - regp->CRTC[NV_VGA_CRTCX_FP_HTIMING ] =0 ; - regp->CRTC[NV_VGA_CRTCX_FP_VTIMING ] =0 ; +// FIXME: Figure out what these actually do + regp->CRTC[NV_VGA_CRTCX_FP_HTIMING ] =0xa ; + regp->CRTC[NV_VGA_CRTCX_FP_VTIMING ] =0x2 ; regp->unk830 = mode->CrtcVDisplay -3 ; regp->unk834 = mode->CrtcVDisplay -1 ;
src/nv_output.c +75 -23
138 lines not on this page · raw message
src/nv_type.h +1 -0
@@ -309,6 +309,7 @@ typedef struct _NVRec {int dcb_entries;int analog_count; +int lvds_count;int digital_count;CARD32 dcb_table[NV40_NUM_DCB_ENTRIES ];/* 10 is a good limit */ } NVRec;
Signature · 1 line
Matthew Garrett | [email protected]