Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Virtual frame buffer? [Solved]
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Mon Jun 26, 2017 12:37 pm    Post subject: Virtual frame buffer? [Solved] Reply with quote

NOTICE: To anyone searching for a true solution, I didn't really solve the underlying problem; I cheated. There is a lot of good information here, but don't bother skipping to the end hoping for a real solution.

Okay, strange issues here. I'm using an nvidia 8600gts (G84) pcie card with Nouveau.

When I compile in legacy fb everything "works" fine, just in this horrible 1990's 1024x768 CRT virtual resolution.

I've tried disabling the legacy fb to use KMS (following the Gentoo wiki Xorg/Guide) and the monitor goes into standby the instant the fb switches from EFI VGA to the nouveaufb, so I'm keeping legacy fb enabled so I don't have to login & startx blind -- yeah, X still works in KMS.

Here's the rub, the tty STILL isn't defaulting to native resolution. Well, that isn't entirely accurate:

Code:

satori@noyfb ~ $ fbset

mode "1024x768"
    geometry 1024 768 1680 1050 32
    timings 0 0 0 0 0 0 0
    accel true
    rgba 8/16,8/8,8/0,0/0
endmode


Seems like it is using the native resolution (1680x1050), but it's imposing that nasty 1024x768 virtual tty inside of it. Any ideas how I can get rid of that? Or, get KMS working properly? I'd be very grateful either way.

Thanks,

Scott

Update: I have figured out how to set things properly with fbset and /etc/fb.modes, but I don't know how to make it stick between reboots.


Last edited by Satori80a on Fri Jun 30, 2017 3:35 pm; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Mon Jun 26, 2017 3:40 pm    Post subject: Reply with quote

Satori80a,

Welcome to gentoo.

I suspect that the console may not detect your screens capabilities properly.
Some have faulty EDID data.

The kernel allows you to put working EDID data in a file and it will use this instead of data read from your monitor.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Jun 26, 2017 3:53 pm    Post subject: Reply with quote

I have to add AFAIK no open source Xorg video driver works without KMS, it is likely falling back to VESA without KMS.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Mon Jun 26, 2017 3:54 pm    Post subject: Reply with quote

@NeddySeagoon:

That doesn't seem right as X works correctly and the console is setting a virtual size inside the native resolution. Also, dmesg shows the EDID data and native resolution.

@Jaglover:

That very well may be. How does that help?

Thanks,

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Mon Jun 26, 2017 4:06 pm    Post subject: Reply with quote

Satori80a,

Put your /var/log/Xorg.0.log onto a pastebin site please.

Tell us the make and model of your display.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Mon Jun 26, 2017 7:04 pm    Post subject: Reply with quote

Sorry this took a while:

https://pastebin.com/ZaT9Kfhz

The display is a Samsung SyncMaster 226cw.

Thanks,

Scott

P.S. not really important but "welcome back" would be more accurate. I couldn't get into my old account, hence the noob status :). And thanks for the welcome!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Mon Jun 26, 2017 8:15 pm    Post subject: Reply with quote

Satori80a,

Welcome back then :)

Your EDID data looks OK. The native resolution is listed first.
Code:
[  1788.396] (II) NOUVEAU(0): Supported standard timings:
[  1788.396] (II) NOUVEAU(0): #0: hsize: 1680  vsize 1050  refresh: 60  vid: 179
[  1788.396] (II) NOUVEAU(0): #1: hsize: 1280  vsize 1024  refresh: 60  vid: 32897
[  1788.396] (II) NOUVEAU(0): #2: hsize: 1280  vsize 960  refresh: 60  vid: 16513
[  1788.396] (II) NOUVEAU(0): #3: hsize: 1152  vsize 864  refresh: 75  vid: 20337

A favourite problem was to have it second in the list. That indicates that its not worth trying to feed the kernel EDID data from a file.

Can you pastebin your dmesg taken after a startup showing the issue and the kernel .config too please.

How in the display connected to the video card?
A Blue (VGA 15 pin D) connector or a DVI connector?

Hmm.
Code:
[  1788.396] (II) NOUVEAU(0): Printing probed modes for output DVI-I-1
[  1788.396] (II) NOUVEAU(0): Modeline "1680x1050"x59.9  119.00  1680 1728 1760 1840  1050 1053 1059 1080 +hsync -vsync (64.7 kHz UeP)
...
[  1788.428] (II) NOUVEAU(0): Printing probed modes for output DVI-I-2
[  1788.428] (II) NOUVEAU(0): Modeline "1024x768"x60.0   65.00  1024 1048 1184 1344  768 771 777 806 -hsync -vsync (48.4 kHz e)

Xorg thinks you have two displays connected. Is that correct?
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Mon Jun 26, 2017 11:02 pm    Post subject: Reply with quote

NeddySeagoon wrote:

Can you pastebin your dmesg taken after a startup showing the issue and the kernel .config too please.


Well, I can but I can't assure you that it is very telling. It doesn't seem to mention any resolutions:

https://pastebin.com/vPu7rijN

NeddySeagoon wrote:

How in the display connected to the video card?
A Blue (VGA 15 pin D) connector or a DVI connector?


DVI.

NeddySeagoon wrote:

Xorg thinks you have two displays connected. Is that correct?


No, and I wondered about that. The second port is empty.

And, I believe you wanted a peek at my kernel config:

https://pastebin.com/5Ft7FLKM

I feel compelled to explain that I started with genkernel and I'm weeding out things as I go. Last time I had a non-binary Linux, it was a 2.x kernel.

Thanks,

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Tue Jun 27, 2017 9:45 am    Post subject: Reply with quote

Satori80a,

A few lines from dmesg
Code:
[    0.000000] Command line: BOOT_IMAGE=/boot/kernel-genkernel-x86_64-4.9.16-gentoo root=UUID=d00b87f2-f3e6-48b7-8b2d-b0b2e5e8b9ce ro video=nouveaufb:1680x1050-24
[    2.782322] efifb: mode is 1024x768x32, linelength=4096, pages=1
[   17.185255] fb: switching to nouveaufb from EFI VGA
[   17.185277] Console: switching to colour dummy device 80x25
[   17.185392] nouveau 0000:01:00.0: NVIDIA G84 (084000a2)
[   17.285732] nouveau 0000:01:00.0: bios: version 60.84.18.00.06
[   17.306624] nouveau 0000:01:00.0: fb: 256 MiB GDDR3


Your Xorg.0.log was a useful check on your monitors EDID data but it has nothing to do with console issues.
Heres what's happening.
Your EFI framebuffer console comes up in 1024x768x32 mode, then when nouveau loads, it changes the screen size to your native resolution but does not resize the framebuffer to fit, so you have a 1680x1050 display with a 1024x768 image in it.
I do something similar but with vesa and nouveau.

Your video=nouveaufb:1680x1050-24 cannot work an you have nouveau built as a module. The kernel command line is applied before root is mounted.
Making nouveau as a built in means including the firmware too.

Looking at your kernel,
Code:
CONFIG_FB_NVIDIA=y
and
Code:
CONFIG_FB_NVIDIA_I2C
must both be off. It grabs the nvidia chip set, then you end up with two or more drivers fighting over the hardware. Its harmless to the hardware but neither driver works properly. All the CONFIG_FB_<HARDWARE> drivers in that menu must be off.
CONFIG_FB_EFI and/or CONFIG_FB_SIMPLE are OK.

I don't think making nouveau a built in will change the behaviour, the switch to the nouveaufb will happen sooner. Anyway thats step two.

First thing to try is a new kernel with the CONFIG_FB_NVIDIA removed.
Check your
Code:
uname -a
when you reboot. The date and time should be after Sat Jun 24 06:21:34 MST 2017, which is the build time of the kernel used in dmesg.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Tue Jun 27, 2017 4:37 pm    Post subject: Reply with quote

Okay, all but CONFIG_FB_EFI is off, everything nvidia is off, and nouveau is built in (again).

uname -a shows this morning's build.

Now all that's left is to figure out that resolution issue?

Thanks,

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Tue Jun 27, 2017 8:38 pm    Post subject: Reply with quote

Satori80a,

Pastebin your dmesg and kernel .config as they are now please.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Tue Jun 27, 2017 10:32 pm    Post subject: Reply with quote

dmesg:

https://pastebin.com/LZcHzzu5

.config:

https://pastebin.com/PwihVTUa
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Wed Jun 28, 2017 8:42 am    Post subject: Reply with quote

Satori80a,

That all looks good.

In place of your
Code:
video=nouveaufb:1680x1050-24
on the kernel command line, try
Code:
video=nouveaufb:mtrr,ywrap,1680x1050-24@60


I'm also tempted to suggest drapping the EFI framebuffer from the kernel as nouveau is built in now.
However, if that goes horribly wrong, you may be left with no console. Thats OK if you can ssh in to fix the damage, or you have another known kernel in your boot menu.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Wed Jun 28, 2017 11:01 am    Post subject: Reply with quote

I always have a knoppix DVD around to chroot in if need be, so I'm not afraid to experiment a bit.

So, I changed the 'video=' as suggested, and tried ditching the EFI fb. No joy. I still have a working console, but it's still stuck in that 1024 fb.

At this point I'm wondering if it might not be simpler to add fbset as an rc service, I'm just not sure how to get started on that.

Thanks,

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Wed Jun 28, 2017 11:54 am    Post subject: Reply with quote

Satori80a,

Post dmesg again please. This should justwork or the forums would be full the this.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Wed Jun 28, 2017 12:07 pm    Post subject: Reply with quote

https://pastebin.com/2PFb8rHJ

I really appreciate all your effort on this.

Thanks again,

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Wed Jun 28, 2017 2:12 pm    Post subject: Reply with quote

Satori80a

That looks OK.
Code:
[    3.018411] nouveau 0000:01:00.0: DRM: allocated 1680x1050 fb: 0x70000, bo ffff880205fd7400


Your kernel has. CONFIG_FB_CON_DECOR=y

Are you actually using framebuffer decorations?
From your kernel command line it appears not. You would have the quiet option, so you don't get kernel messages trampling your wallpaper.

That option supports a pretty startup screen if you also provide the userspace tools in the initrd, like progress icons and wallpaper.
The LiveDVD shows it off.

Long shot ... turn off CONFIG_FB_CON_DECOR. Changing the framebuffer image resolution during booting would break framebuffer decorations as its a very simple thing. Nothing gets scaled. Wallpaper and icons all have to be pre scaled.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Wed Jun 28, 2017 5:33 pm    Post subject: Reply with quote

Code:
# CONFIG_FB_CON_DECOR is not set


Recompiled and reboot: no difference.

Scott
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Wed Jun 28, 2017 5:44 pm    Post subject: Reply with quote

Satori80a,

I'm out of ideas. I'll think about it some more and post back if I get more ideas.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Wed Jun 28, 2017 6:10 pm    Post subject: Reply with quote

Satori80a,

Lets try a diff of your kerne settings and mine. My working .config

Pastebin your latest .config and we can both do a diff.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Wed Jun 28, 2017 6:34 pm    Post subject: Reply with quote

Sorry, a diff?yup I'm afraid I'm not familiar with that process.

Update: duh! Man diff. Yeah, I'll be home in a couple hours.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Wed Jun 28, 2017 8:45 pm    Post subject: Reply with quote

Here is mine again: https://pastebin.com/4FxDeqXg.

I did a diff against the one you posted, and that's a lot of information to sift through. Should I just be considered with the fb stuff, mostly?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Thu Jun 29, 2017 8:40 am    Post subject: Reply with quote

Satori80a,

Its morning here, I'm still on my first coffee.

Its anything that can affect the console driver. That's framebuffer, DRM, memory management, ... more.
You can't borrow my kernel .config as is as I run a very peculiar Gentoo so my kernel will not run under your install. That would be the next step though.

-- edit --

To go from my 4.11 to your 4.9 kernel, heres what I think might be significant. The - means remove form mine, the + means added in yours.
Code:
-CONFIG_X86_MSR=y
+CONFIG_X86_MSR=m

MSR means Model Specific Registers. I have it built in, you have it as a loadable module. That's probably OK as long as its actually loaded. Look in lsmod.

Code:
-# CONFIG_EFI is not set
+CONFIG_EFI=y
+CONFIG_EFI_STUB=y
I don't have EFI, you do.

Code:
+CONFIG_PCCARD=y
+CONFIG_PCMCIA=y

PCMCIA is the original 16 bit plugin card bus for laptops.
PCCARD was its 32 bit successor. As far as no know, they were both obsolete well before EFI was introduced. YENTA was a popular PCI to PCCARD bridge interface.

Lets skip networking, bluetooth and wifi, its not that. Nor is it MTD.
Its not
Code:
 #
 # SCSI support type (disk, tape, CD-ROM)
 #
The main differences here are the ones you need are modules and are loaded from your initrd. Mine are built in, so my initrd will work with any kernel.

more ...

-- edit 2 --

Do you have a tablet?
If not,
Code:
CONFIG_INPUT_TABLET=y
builds lots of junk.

Now it gets interesting. Neither of us has AGP
Code:
-CONFIG_AGP=y
-CONFIG_AGP_AMD64=y
+# CONFIG_AGP is not set
I have AGP support for my AMD motherboard, even though there is no AGP port fitted.
Your AGP support is off. Try turning that on and going into the menu underneath and choosing support for your chipset.

Code:
-CONFIG_FB_BOOT_VESA_SUPPORT=y
+# CONFIG_FB_BOOT_VESA_SUPPORT is not set
I have no idea what that does.

Code:
-CONFIG_FB_TILEBLITTING=y
+# CONFIG_FB_TILEBLITTING is not set
That should be on, its a framebuffer redraw speedup. Not all framebuffers use it but its a good thing to have if its needed.

Code:
-CONFIG_FB_VESA=y
+# CONFIG_FB_VESA is not set
+# CONFIG_FB_EFI is not set
my FB_VESA dates from the days when I used the nvidia binary blob. I don't need it any more.
You only have nouveau, that should be plenty.

Nothing else seems to matter.

I ran
Code:
diff -u roy.config satori80a.config > roy_satori80a.patch

The -u gets 3 lines of context before differences, which is what patch expects, then reviewed roy_satori80a.patch. A bare diff is very hard to read.Theres not a lot there.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Satori80a
n00b
n00b


Joined: 06 Jun 2017
Posts: 46

PostPosted: Thu Jun 29, 2017 3:10 pm    Post subject: Reply with quote

I'm starting to strongly feel like we're barking up the wrong tree with this kernel stuff.

I've begun to look into the boot loader (grub2 in this case). When I get to a grub command-line and type: videoinfo, it shows a couple of virtual adapters which don't apply to me, and an efi gop driver. This one shows 640x480, 800x600, 1024x768 which is the default here, then it shows my edid info with the reported preferred size of 1680x1050, but I can't select it.

I'm about to blame all this on efi.

Any thoughts?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54097
Location: 56N 3W

PostPosted: Thu Jun 29, 2017 3:18 pm    Post subject: Reply with quote

Satori80a,

Grub does indeed set up a framebuffer for itself.
However, I would expect the kernel to reset the framebuffer completely when it switches drivers, not just put the grub size is the middle of a new window.

I don't have a grub2 nor an EFI system to test on.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum