2001-03-30 20:16:47

by Panagiotis Papadakos

[permalink] [raw]
Subject: Matrox G400 Dualhead

Does anyone know why fualhead is not working anymore?
I just get a screen with rubbish on the second head.
Also when kernel loads and and registers fb1 I lose signal
on the second head.

Thanks for your help.



2001-03-30 21:14:57

by Panagiotis Papadakos

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

Dualhead is not working with the current kernel(2.4.3).
With 2.4.2 it was working just fine.
I have not used any special compiler flags,just the usual ones
and I am not loading XFree.
Also does anyone know why when I change from Xfree to console
most of the times the console is corrupted..?
This is a problem which I have noticed from Xfree-4.0 and after.

Thanks in advance.



2001-03-30 20:32:57

by alan

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

On Fri, 30 Mar 2001, mythos wrote:

> Does anyone know why fualhead is not working anymore?
> I just get a screen with rubbish on the second head.
> Also when kernel loads and and registers fb1 I lose signal
> on the second head.

Probably a question for the xpert list ([email protected])...

What kernel version are you using?

Kernel compile options?

Version of XFree86?

Have to looked for error messages in /var/log/XFree86.0.log?

[email protected] | Note to AOL users: for a quick shortcut to reply
Alan Olsen | to my mail, just hit the ctrl, alt and del keys.
"In the future, everything will have its 15 minutes of blame."

2001-03-30 23:10:01

by J Brook

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

> Does anyone know why fualhead is not working anymore?
> I just get a screen with rubbish on the second head.
> Also when kernel loads and and registers fb1 I lose signal
> on the second head.

...

>With 2.4.2 it was working just fine.

I have also noticed problems with the 2.4.3 release. I have a G450
32Mb, that I use in single-head mode. The console framebuffer runs
fine at boot time, but when I load X (4.0.3 compiled with Matrox HAL
library) and then return to the console, I get a blank screen (signal
lost).

I don't know what the problem is. I can confirm with Mythos that
under
2.4.2 it was working just fine :-)

Petr Vandrovec is the man who knows... what do you say Petr?!

John
----------------
[email protected]

2001-03-31 02:03:19

by Petr Vandrovec

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

J Brook wrote:
>
> > Does anyone know why fualhead is not working anymore?
> > I just get a screen with rubbish on the second head.
> > Also when kernel loads and and registers fb1 I lose signal
> > on the second head.

On G400 there is no signal on second head after poweron. So you cannot
lose it ;-) On G450 there is same signal on both heads - but you are
talking about G400. Or no? They are very different (they have different
everything except PCI device ID register :-( ). You should add
'Option "UseFBDev"' into your XF86Config-4 - probably together with
'Option "NoHWCursor"'.

> ...
>
> >With 2.4.2 it was working just fine.
>
> I have also noticed problems with the 2.4.3 release. I have a G450
> 32Mb, that I use in single-head mode. The console framebuffer runs
> fine at boot time, but when I load X (4.0.3 compiled with Matrox HAL
> library) and then return to the console, I get a blank screen (signal
> lost).

It is easy - do not do that. Matroxfb really does not expect that
someone
will powerdown parts of chip which matroxfb needs, but which XFree does
not use (for example clock source for secondary head) or that it will
change
some undocumented registers (for example Matrox HAL driver changes
memory
clock speed).

> I don't know what the problem is. I can confirm with Mythos that
> under
> 2.4.2 it was working just fine :-)

I have no idea what changed between 2.4.2 and 2.4.3 - I do not
remember that I was doing some changes into the matroxfb during
last few weeks - so maybe that source of these problems is in XFree
4.0.3 ?
Petr Vandrovec
[email protected]

2001-03-31 07:12:35

by Rafael E. Herrera

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

J Brook wrote:
>
> >With 2.4.2 it was working just fine.
>
> I have also noticed problems with the 2.4.3 release. I have a G450
> 32Mb, that I use in single-head mode. The console framebuffer runs
> fine at boot time, but when I load X (4.0.3 compiled with Matrox HAL
> library) and then return to the console, I get a blank screen (signal
> lost).

In my case, when lilo boots my G450 on any video mode other than
'normal', going into X and then back into console, leads to a blank
screen. I've observed this behavior in 2.2 and 2.4. Otherwise, I've no
problem using the card in single or dual head.

Since the HAL lib is a binary, we might have to wait for Matrox to fix
this problem.

--
Rafael

2001-03-31 17:17:40

by J Brook

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

> I have a similar problem with my G450, booting into the framebuffer,
> then loading xdm and working in X, and then switching back to the
> console. I may have another detail to add in that when I switch back
> to the console from X, my monitor blanks and displays the warning
> that the frequencies are out of range.

I think I have a work around. Boot up 2.4.3 with the framebuffer
enabled as normal. Log in as root and use the fbset program to change
the settings for all the framebuffers.
eg.

fbset -a 1024x768-70

or whatever works for you. fbset has its own man page.

This makes everything hunky-dory for me, in that after running fbset
I
can go in and out of X without ever losing the video signal.

Petr, I had a look at the drivers/video/matrox subdir and there's no
difference between 2.4.2 and 2.4.3, however there are differences in
the drivers/video dir to do with framebuffers. The files that have
been changed in drivers/video/ are:
creatorfb.c
fbmem.c
fonts.c
modedb.c
sbus.c

I know nothing about the nature of the changes that have been made
though!

It does seem to be a kernel problem rather than a X4.0.3 problem
seeing as how 4.0.3 works fine under 2.4.2, and that using fbset on
the framebuffer console in 2.4.3 solves the problem.

John
----------------
[email protected]

2001-04-01 00:09:02

by Trevor Hemsley

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

On Sat, 31 Mar 2001 07:17:19, "Rafael E. Herrera"
<[email protected]> wrote:

> J Brook wrote:
> >
> > >With 2.4.2 it was working just fine.
> >
> > I have also noticed problems with the 2.4.3 release. I have a G450
> > 32Mb, that I use in single-head mode. The console framebuffer runs
> > fine at boot time, but when I load X (4.0.3 compiled with Matrox HAL
> > library) and then return to the console, I get a blank screen (signal
> > lost).
>
> In my case, when lilo boots my G450 on any video mode other than
> 'normal', going into X and then back into console, leads to a blank
> screen. I've observed this behavior in 2.2 and 2.4. Otherwise, I've no
> problem using the card in single or dual head.

I get this as well on my G200. From observation it appears that the
refresh rate is being doubled when you exit X and that's why the
console appears blank. On my system I normally use

modprobe matroxfb vesa=263 fv=85

to give a large text console. On return from X, if I blindly type

fbset "640x480-60"

then I get a visible screen back but my monitor tells me that it's
running at 640x480@119Hz. Same thing for 800x600-60 only this one says
120Hz.

Base system is SuSE 7.1 using XFree86 4.0.2. If I switch to 3.3.6 then
it works OK. If I don't load matroxfb then it also works OK.

--
Trevor Hemsley, Brighton, UK.
[email protected]

2001-04-01 08:51:22

by jurriaan

[permalink] [raw]
Subject: Re: [lkml]Re: Matrox G400 Dualhead

On Sat, Mar 31, 2001 at 05:46:38PM +0000, J Brook wrote:
> > I have a similar problem with my G450, booting into the framebuffer,
> > then loading xdm and working in X, and then switching back to the
> > console. I may have another detail to add in that when I switch back
> > to the console from X, my monitor blanks and displays the warning
> > that the frequencies are out of range.
>
> I think I have a work around. Boot up 2.4.3 with the framebuffer
> enabled as normal. Log in as root and use the fbset program to change
> the settings for all the framebuffers.
> eg.
>
> fbset -a 1024x768-70
>
> or whatever works for you. fbset has its own man page.
>
> This makes everything hunky-dory for me, in that after running fbset
> I
> can go in and out of X without ever losing the video signal.
>
Well, that certainly doesn't work for me (2.4.2-ac28, G400):

fbset -i:

mode "1600x1200-80"
# D: 205.846 MHz, H: 99.347 kHz, V: 79.989 Hz
geometry 1600 1200 1600 5241 16
timings 4858 272 48 32 5 152 5
accel true
rgba 5/11,6/5,5/0,0/0
endmode

Frame buffer device information:
Name : MATROX
Address : 0xd4000000
Size : 16773120
Type : PACKED PIXELS
Visual : TRUECOLOR
XPanStep : 8
YPanStep : 1
YWrapStep : 0
LineLength : 3200
MMIO Address: 0xd6000000
MMIO Size : 16384
Accelerator : Matrox G400

01:00.0 VGA compatible controller: Matrox Graphics, Inc. MGA G400 AGP (rev 03) (prog-if 00 [VGA])
Subsystem: Matrox Graphics, Inc. Millennium G400 32Mb SGRAM
Flags: bus master, medium devsel, latency 32, IRQ 10
Memory at d4000000 (32-bit, prefetchable) [size=32M]
Memory at d6000000 (32-bit, non-prefetchable) [size=16K]
Memory at d7000000 (32-bit, non-prefetchable) [size=8M]
Expansion ROM at <unassigned> [disabled] [size=64K]
Capabilities: <available only to root>

If I use X on an accelerated, normal Matrox screen, my monitor complains
on exit:

fH 49.4 KHz, fV 39.8 Hz

(and it doesn't sync at 40 Hz vertical refresh :-( ).

This is _half_ of the normal 80 Hz. Using fbset -a "1600x1200-80" before
X, of after X, doesn't do anything. Does anybody know what to hack out
in X to get it to _not_ reset my G400 to some unusable state? 3.3.6 was
didn't do this. I can use the framebuffer-screen just fine, but I miss
the DGA extension.

Thanks,
Jurriaan
--
BOFH excuse #329:

Server depressed, needs Prozak
GNU/Linux 2.4.2-ac28 SMP/ReiserFS 2x1743 bogomips load av: 0.20 0.05 0.01

2001-04-01 20:26:44

by Panagiotis Papadakos

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

I solved the problem with dualhead!!!
Second head from 2.4.3 is /dev/fb2 rather than /dev/fb1.
Just had to look to the messages.
About matroxfb + X11 what I have seen is that if you use the same
resolution with the same number of colors as in X11 ,most of the times it will
work(except if I am in the login manager kdm!Then if I change to console
it will have the same screen).

P.S. Petr on the second head if I put mouse in the right-corner at the
bottom of the screen I will have a nice white border around the screen.
Also cursor blinks very strange if there is a lot of move on another
framebuffer on the first head and leaves some white blocks around.
I have used software and hardware cursor.

Mythos


2001-04-02 17:37:59

by Petr Vandrovec

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

mythos wrote:
>
> I solved the problem with dualhead!!!
> Second head from 2.4.3 is /dev/fb2 rather than /dev/fb1.
> Just had to look to the messages.

And who is /dev/fb1? You must change your configuration...

> P.S. Petr on the second head if I put mouse in the right-corner at the
> bottom of the screen I will have a nice white border around the screen.

It is feature. Secondary head does not have any blanking, it just
repeats
last 64bits (last memory fetch cycle) again and again through whole
vertical
blanking interval (try 'setterm -bgcolor red' and you'll see). There are
two possible workarounds:
(1) create screen with width = 648 instead of 640 (it must be visible
width!)
and fill this column with black.
This brokes too many apps because of they expect that they can
horizontally
scroll for vxres - xres pixels :-(
This is what Windows drivers do.
(2) create screen with height = 481 instead of 480 and fill this line
with
black. Unfortunately, you cannot use virtual scrolling then :-(
So I decided just to live with it... You can just try 'fbset -yres 481
-vyres 481'
- it should implement (2).

> Also cursor blinks very strange if there is a lot of move on another
> framebuffer on the first head and leaves some white blocks around.

You are not using 'video=scrollback:0', do you? You should... There were
some
changes in console_lock recently, maybe that someone now forgets to grab
lock
when doing scrolling/putcs?
Petr

2001-04-02 17:40:39

by Petr Vandrovec

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

Trevor Hemsley wrote:

> I get this as well on my G200. From observation it appears that the
> refresh rate is being doubled when you exit X and that's why the
> console appears blank. On my system I normally use
>
> modprobe matroxfb vesa=263 fv=85
>
> to give a large text console. On return from X, if I blindly type
>
> fbset "640x480-60"
>
> then I get a visible screen back but my monitor tells me that it's
> running at 640x480@119Hz. Same thing for 800x600-60 only this one says
> 120Hz.

Unfortunately Matrox datasheet says that it is impossible :-( Can you
try 'fbset -depth 0; fbset -depth 8' ?
Petr

2001-04-02 22:18:50

by Trevor Hemsley

[permalink] [raw]
Subject: Re: Matrox G400 Dualhead

On Mon, 2 Apr 2001 17:43:42, Petr Vandrovec <[email protected]>
wrote:

> Trevor Hemsley wrote:
>
> > I get this as well on my G200. From observation it appears that the
> > refresh rate is being doubled when you exit X and that's why the
> > console appears blank. On my system I normally use
> >
> > modprobe matroxfb vesa=263 fv=85
> >
> > to give a large text console. On return from X, if I blindly type
> >
> > fbset "640x480-60"
> >
> > then I get a visible screen back but my monitor tells me that it's
> > running at 640x480@119Hz. Same thing for 800x600-60 only this one says
> > 120Hz.
>
> Unfortunately Matrox datasheet says that it is impossible :-( Can you
> try 'fbset -depth 0; fbset -depth 8' ?

Yes, that fixes it. Issuing the first fbset command brings me back
some sort of display, all fsck'ed up but vaguely readable with
shimmering bits of text all over it in the wrong places. The second
fbset gets it back correctly at the right resolution and right refresh
rate. Thanks, a workaround at least.

--
Trevor Hemsley, Brighton, UK.
[email protected]