more logging, removed paneldetection bug

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@7242 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Rudolf Cornelissen 2004-04-19 13:57:31 +00:00
parent a7226c0a48
commit ccfb6b3711
4 changed files with 26 additions and 8 deletions

View File

@ -574,6 +574,8 @@
#define NVCRTCX_OWNER 0x44
#define NVCRTCX_FP_HTIMING 0x53
#define NVCRTCX_FP_VTIMING 0x54
#define NVCRTCX_0x59 0x59
#define NVCRTCX_0x9f 0x9f
/* Nvidia ATTRIBUTE indexed registers */
/* VGA standard registers: */

View File

@ -80,7 +80,7 @@ status_t nv_general_powerup()
{
status_t status;
LOG(1,("POWERUP: nVidia (open)BeOS Accelerant 0.10-11 running.\n"));
LOG(1,("POWERUP: nVidia (open)BeOS Accelerant 0.10-12 running.\n"));
/* preset no laptop */
si->ps.laptop = false;

View File

@ -268,6 +268,12 @@ static void detect_panels()
/* unlock CRTC1 */
CRTCW(LOCK, 0x57);
CRTCW(VSYNCE ,(CRTCR(VSYNCE) & 0x7f));
LOG(2,("INFO: Dumping flatpanel related CRTC registers:\n"));
LOG(2,("CRTC1: LCD register: $%02x\n", CRTCR(LCD)));
LOG(2,("CRTC1: register $59: $%02x\n", CRTCR(0x59)));
LOG(2,("CRTC1: register $9f: $%02x\n", CRTCR(0x9f)));
/* detect active slave device (if any) */
slaved_for_dev1 = (CRTCR(PIXEL) & 0x80);
if (slaved_for_dev1)
@ -280,19 +286,26 @@ static void detect_panels()
{
/* check secondary head: */
/* enable access to CRTC2 */
CRTCW(OWNER, 0x03);
CRTC2W(OWNER, 0x03);
/* unlock CRTC2 */
CRTCW(LOCK, 0x57);
CRTCW(VSYNCE ,(CRTCR(VSYNCE) & 0x7f));
CRTC2W(LOCK, 0x57);
CRTC2W(VSYNCE ,(CRTC2R(VSYNCE) & 0x7f));
LOG(2,("CRTC2: LCD register: $%02x\n", CRTC2R(LCD)));
LOG(2,("CRTC2: register $59: $%02x\n", CRTC2R(0x59)));
LOG(2,("CRTC2: register $9f: $%02x\n", CRTC2R(0x9f)));
/* detect active slave device (if any) */
slaved_for_dev2 = (CRTCR(PIXEL) & 0x80);
slaved_for_dev2 = (CRTC2R(PIXEL) & 0x80);
if (slaved_for_dev2)
{
/* if the panel isn't selected, tvout is.. */
tvout2 = !(CRTCR(LCD) & 0x01);
tvout2 = !(CRTC2R(LCD) & 0x01);
}
}
LOG(2,("INFO: End flatpanel related CRTC registers dump.\n"));
/* do some presets */
si->ps.panel1_width = 0;
si->ps.panel1_height = 0;
@ -384,6 +397,8 @@ static void detect_panels()
(si->ps.panel1_width == si->ps.panel2_width) &&
(si->ps.panel1_height == si->ps.panel2_height))
{
LOG(2,("INFO: correcting double detection of single panel!\n"));
if (DACR(FP_TG_CTRL) & 0x80000000)
{
/* LVDS panel is on CRTC2, so clear false primary detection */

View File

@ -4,7 +4,7 @@
</head>
<body>
<p><h2>Changes done for each driverversion:</h2></p>
<p><h1>head (0.10-11), (Rudolf)</h1></p>
<p><h1>head (0.10-12), (Rudolf)</h1></p>
<ul>
<li>Implemented laptop internal flatpanel presence and native resolution detection;
<li>Implemented external DVI flatpanel(s) presence and native resolution detection;
@ -18,7 +18,8 @@
<li>Added recognition for GeForce4 MX 4000, GeForceFX 5700LE and GeForceFX 5700VE cards; also modified a few others to be more correct;
<li>Updated panel detection code once more: pre NV18 DVI panels should be working again now;
<li>Added flatpanel DPMS support for both heads via powerup/powerdown of LVDS and TMDS transmitters;
<li>Added panel(s) native mode(s) to the modelist exported by the driver. You can now set it (them) by just selecting it from the Screenprefs app, <strong>except</strong> if you use the native R5 one. Use Dualhead setup instead (for example): the extra mode(s) will be at the bottom of the list.
<li>Added panel(s) native mode(s) to the modelist exported by the driver. You can now set it (them) by just selecting it from the Screenprefs app, <strong>except</strong> if you use the native R5 one. Use Dualhead setup instead (for example): the extra mode(s) will be at the bottom of the list;
<li>Removed a bug in the panel detection code and added a bit more logging.
</ul>
NOTE:<br>
dualhead switch mode is not yet operational for flatpanels...