# uvesafb not working

## Juan Pablo

I'm using kernel 2.6.25-gentoo-r4, I understand it has the uvesafb patch included.

I followed the instructions here http://dev.gentoo.org/~spock/projects/uvesafb/ carefully and added video=uvesafb:1024x768-32,mtrr:3,ywrap in my menu.lst

When I configure the kernel "Userspace VESA VGA graphics support" doesn't appear anywhere so I added the option manually to my .config file.

dmesg shows that uvesafb is there but I don't get a nice, high-resolution console.

Any idea?Last edited by Juan Pablo on Sun Jun 15, 2008 3:38 am; edited 1 time in total

----------

## jeanfrancis

Hi there !

First of all, never add anything manually in your . config file...!

If the option isn't there, it may be because you miss something else that is required... I'll take a look at that somewhere this week and let you know if I manage to get it working  :Smile: 

----------

## Juan Pablo

Ok, I've investigated myself and didn't find much on the internet. My kernel contains uvesa because when I try to patch it, it says the patch is already there. However the option doesn't appear on menuconfig neither on the .config file. I can add the option manually on the .config file and it compiles and the driver is right there because dmesg shows these lines

```
uvesafb: ATI Technologies Inc., MS4 , 01.00, OEM: ATI RADEON XPRESS 200M Series, VBE v2.0

uvesafb: protected mode interface info at c000:535e

uvesafb: pmi: set display start = c00c53cc, set palette = c00c5406

uvesafb: pmi: ports = 9010 9016 9054 9038 903c 905c 9000 9004 90b0 90b2 90b4 

uvesafb: no monitor limits have been set, default refresh rate will be used

uvesafb: scrolling: ywrap using protected mode interface, yres_virtual=1536

uvesafb: framebuffer at 0xd8000000, mapped to 0xdc880000, using 6144k, total 16384k
```

grub contains 

```
video=uvesafb:1024x768-32,mtrr:3,ywrap
```

 as a kernel option BTW

I've tried with vanilla-sources and gentoo-sources with all the available versions from ~x86 and stable and none of them have UVESA on menuconfig or .config

http://pastebin.com/f6457afe2 my .config file

Any idea?

Thanks!

----------

## jel

 *Juan Pablo wrote:*   

> I'm using kernel 2.6.25-gentoo-r4, I understand it has the uvesafb patch included.
> 
> I followed the instructions here http://dev.gentoo.org/~spock/projects/uvesafb/ carefully and added video=uvesafb:1024x768-32,mtrr:3,ywrap in my menu.lst
> 
> When I configure the kernel "Userspace VESA VGA graphics support" doesn't appear anywhere so I added the option manually to my .config file.
> ...

 

I think you need "Device drivers -> Connector - unified userspace <-> kernel space linker", ie. CONFIG_CONNECTOR.

----------

## jfp

Juan Pablo,

I see in you .config that:

 *Quote:*   

> 
> 
> # CONFIG_FRAMEBUFFER_CONSOLE is not set
> 
> 

 

It should be here:

```

  Device Drivers  --->

    Graphics support  --->

      Console display driver support  ---> 

        <*> Framebuffer Console support 

        [*]   Support for the Framebuffer Console Decorations 

```

John Plesmid

----------

## timotheus25

Here's a quick hack as an example to get you started to have a hi-res frame buffer at near-zero boot-time.

In reality, it is could be more or less complex than this depending on your display driver.

Use genkernel to create your kernel.

Modify /usr/share/genkernel/x86/modules_load to include uvesafb last in the

MODULES_USB="" section.

Kernel config:

```

CONFIG_FB_UVESA=m

```

Modify /usr/share/genkernel/generic/linuxrc:

Find the statement:  splash 'init'

Just before this line add the following code:

```

myreal_mod_path() {

    find /lib/modules | grep /"${1}${KSUFF}"

}

${INSMOD} `real_mod_path cn`

${INSMOD} `real_mod_path uvesafb` mode=1280x1024-32 mtrr=3 scroll=ywrap

/bin/fbset -g 1280 1024 1280 1024 32

```

man genkernel.conf to find out how to create an overlay for your initramfs.

Now add the following binaries, all statically compiled:

bin/fbset

sbin/v86d

and device nodes:

dev/console

dev/zero

dev/tty0

dev/fb0

dev/tty

dev/mem

dev/fb

dev/fbcondecor

You may even want to add:

   sys-apps/915resolution

Good luck.

----------

## timotheus25

Simpler setup:

(1) Emerge sys-apps/v86d

```

emerge sys-apps/v86d

```

(2) Compile uvesafb as module in your kernel.

(3) Add uvesafb entry to /etc/modules.autoload.d/kernel-2.6

```

uvesafb

```

(4) Create file /etc/modprobe.d/uvesafb with contents:

```

options uvesafb mode=1280x1024-32 mtrr=3 scroll=yrap

```

(5) Run as root:

```

update-modules

```

(6) Reboot

This should be adequate for most setups. Only disadvantage is that you may not get your hi-res frame buffer until half-way through the bootup. If you want the hi-res frame buffer before even running INIT, this is more complex as demonstrated with my previous post.

----------

## billydv

I  have  always  had  it  and  now  after  recompiling  my  system,  updating  and  redoing  kernel  it  stopped  working.

----------

## Juan Pablo

Thanks jfp, I swear that option was enable but it appears it was not. Thanks to everybody who answered! Now I have a nice high-resolution framebuffer. Does anyone know if it is possible to make it widescreen? 1280x800 on a ATI Radeon Xpress200M

----------

## jeanfrancis

I would like it... but I never got it running  :Wink:  I used to do it with the old vesafb-tng in 32bits, but I couldn't at this time with vesafb (-tng wasn't usable in 64 bits). UVesaFB replaces both vesafb and vesafb-tng, but I never been able to have a widescreen resolution on my 64-bits box. Anybody got it working ?

----------

## jfp

Glad to hear it was something simple.

AFAIK, You are you are limited to the resolutions that come with each theme. But I also know that it is possible to create new resolutions for your favorite theme. I just don't know how to do it.... At one point I did see instructions on setting new resolutions but can't remember where... Spock's devsite had nothing that looked promising. 

Good luck

----------

## billydv

timotheus25,  It  shouldn't  be  necessary  to  do  any  of  that.  All  you  have  to  do  is  redo  your  kernel  with  genkernel  and  follow  the  kernel  config  requirements  on  the  uvesfb  website.  Afterwards  set  your  grub  config  as  recommended  and  all  should  be  fine.  But  a  word  of  warning,  on  x86  systems  right  now  there  is  a  bug  that  is  causing  v86d  to  segfault  on  startup  so  check  the  gentoo  bug  pages  for  possible  updates.  Editing  genkernel  files  that  will  get  updated  on  the  next  version  of  genkernel  is  not  the  way  to  go.  Uvesafb  should  be  built  into  the  kernel,  not  done  as  a  module.  If  you  are  on  amd64,  then  the  testing  versions  currently  available  should  work  without  any  fuss.

----------

