Port-powerpc archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Where arch/bebox/pci/pfb.c?



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello,

On May 14, 2008, at 14:54, Robert Swindells wrote:

Michael Lorenz wrote:
On May 14, 2008, at 01:29, KIYOHARA Takashi wrote:

I make the frame buffer of bebox a console.  And, I made boot,
boot_com0,
and boot_vga.  I booted Matrox Millenium with boot_vga, And S3
Trio64 V+
with boot.

  see. arch/bebox/stand/README


However, I learnt pfb (PCI Frame buffer) had disappeared.  Did you
delete arch/bebox/pc/pfb.c and arch/bebox/pci/pfbvar.h at the time of
merging ppc-oearenovation?  Or, did you move?

Did it ever exist? Somehow I doubt it since I can't think of a
generic way to deal with a PCI framebuffer without firmware help. For
instance, which BAR maps the framebuffer? Or, if you want to use it
as generic VGA you still need firmware help to enable it, nowhere
near all PCI graphics chips power up in VGA mode.
If the BeBox firmware sets up a graphics mode of some sort and you
can get parameters like video memory address, width, height, stride
and depth you can simply use genfb.

Do you need the video memory address ?

Well, of course - how would rasops draw characters into video memory without knowing where it is? genfb at pci wants the bus address in case it's different from the CPU's view, like for instance on sparc64.

I tried using genfb on ibmnws today. I hardwired the width, height and
depth properties to match the firmware settings but just entered a dummy
value of 1024 for 'address'. On booting I get:

genfb0 at pci0 dev 4 function 0: S3 Trio64V2/DX
genfb0: framebuffer at 0xc0000400, size 1024x768, depth 8, stride 1024

The screen colours are a bit strange but it does seem to work.

genfb needs a callback to change colours, there is no generic way to do that. On sparc64 and macppc we call OpenFirmware for that.

It isn't even obvious that the BARs have been configured, pcictl just shows
them all as "not implemented(?)".

Then they're probably all zero which is why 1024 for address kind of worked - your framebuffer appears to be at PCI address 0.

have fun
Michael

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)

iQEVAwUBSCtWnMpnzkX8Yg2nAQItUAf/cwAT2m1rpEULvHA/3kXSfk540GdSKf0w
3vOYcEEwheIa1NPejTcyz3yii07OE7TMXUb5a4NlwzfUg1CyGW2ajUygwTamZ0bX
fcV5Ia4gk+BddKxQDbL3CY8LWfDHrbjdShsexkOJi//jufkFBMGrXQew1zFIMoYs
IYlf2uDHGeJxRfoDKKb1b4bxtCUrcCXZeWcToLCiWG1JhvX/Vo68BTN/mrzRayYJ
BKxtW9DY76O0OQFf1juiMxzp3oeQwrMNuOH95l6HlGWkyNaU1nX7mvohcSZ/df6o
avt3oGN7UQou5ZpKW2Ifs9zQSovmCM/AEeDRgyEXuap6oBu/L+7tZg==
=zXI/
-----END PGP SIGNATURE-----


Home | Main Index | Thread Index | Old Index