Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Changing Memory Allocation in BIOS? [SOLVED-Bad Idea]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
UberPinguin
Guru
Guru


Joined: 20 Nov 2005
Posts: 510
Location: 2416.94 Miles From Home

PostPosted: Fri Nov 03, 2006 3:43 pm    Post subject: Changing Memory Allocation in BIOS? [SOLVED-Bad Idea] Reply with quote

I have a Compaq Evo N610c notebook. It has an integrated ATI Radeon Mobility 7500 graphics card with shared memory. I've got 1024MB of RAM in the thing, but the BIOS will only allocate 32MB to video. There is no place in the setup menu to change this value.

The challenge: hack the BIOS to change the memory mappings and give more RAM to the video card. It should be able to handle 128MB.

Relevant details:
Code:
# lspci -vv
00:00.0 Host bridge: Intel Corporation 82845 845 (Brookdale) Chipset Host Bridge (rev 04)
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort+ >SERR- <PERR-
   Latency: 0
   Region 0: Memory at 60000000 (32-bit, prefetchable) [size=256M]
   Capabilities: [e4] Vendor Specific Information
   Capabilities: [a0] AGP version 2.0
      Status: RQ=32 Iso- ArqSz=0 Cal=0 SBA+ ITACoh- GART64- HTrans- 64bit- FW+ AGP3- Rate=x1,x2,x4
      Command: RQ=1 ArqSz=0 Cal=0 SBA+ AGP+ GART64- 64bit- FW- Rate=x4

00:01.0 PCI bridge: Intel Corporation 82845 845 (Brookdale) Chipset AGP Bridge (rev 04) (prog-if 00 [Normal decode])
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap- 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 64
   Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
   I/O behind bridge: 00003000-00003fff
   Memory behind bridge: 40400000-404fffff
   Prefetchable memory behind bridge: 48000000-4fffffff
   Secondary status: 66MHz+ FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort+ <SERR- <PERR-
   BridgeCtl: Parity- SERR- NoISA+ VGA+ MAbort- >Reset- FastB2B-

00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev 42) (prog-if 00 [Normal decode])
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 0
   Bus: primary=00, secondary=02, subordinate=0a, sec-latency=32
   I/O behind bridge: 00002000-00002fff
   Memory behind bridge: 40000000-403fffff
   Prefetchable memory behind bridge: 50000000-53ffffff
   Secondary status: 66MHz- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort+ <SERR- <PERR-
   BridgeCtl: Parity- SERR+ NoISA+ VGA- MAbort- >Reset- FastB2B-

00:1f.0 ISA bridge: Intel Corporation 82801CAM ISA Bridge (LPC) (rev 02)
   Control: I/O+ Mem+ BusMaster+ SpecCycle+ MemWINV- VGASnoop- ParErr- Stepping- SERR+ FastB2B-
   Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 0

00:1f.1 IDE interface: Intel Corporation 82801CAM IDE U100 (rev 02) (prog-if 8a [Master SecP PriP])
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 0
   Interrupt: pin A routed to IRQ 11
   Region 0: I/O ports at <unassigned>
   Region 1: I/O ports at <unassigned>
   Region 2: I/O ports at <unassigned>
   Region 3: I/O ports at <unassigned>
   Region 4: I/O ports at 4440 [size=16]
   Region 5: Memory at 54000000 (32-bit, non-prefetchable) [size=1K]

00:1f.5 Multimedia audio controller: Intel Corporation 82801CA/CAM AC'97 Audio Controller (rev 02)
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O+ Mem- BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap- 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 0
   Interrupt: pin B routed to IRQ 11
   Region 0: I/O ports at 4000 [size=256]
   Region 1: I/O ports at 4400 [size=64]

01:00.0 VGA compatible controller: ATI Technologies Inc Radeon Mobility M7 LW [Radeon Mobility 7500] (prog-if 00 [VGA])
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping+ SERR- FastB2B-
   Status: Cap+ 66MHz+ UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 66 (2000ns min), Cache Line Size: 32 bytes
   Interrupt: pin A routed to IRQ 11
   Region 0: Memory at 48000000 (32-bit, prefetchable) [size=128M]
   Region 1: I/O ports at 3000 [size=256]
   Region 2: Memory at 40400000 (32-bit, non-prefetchable) [size=64K]
   [virtual] Expansion ROM at 40420000 [disabled] [size=128K]
   Capabilities: [58] AGP version 2.0
      Status: RQ=48 Iso- ArqSz=0 Cal=0 SBA+ ITACoh- GART64- HTrans- 64bit- FW- AGP3- Rate=x1,x2,x4
      Command: RQ=32 ArqSz=0 Cal=0 SBA+ AGP+ GART64- 64bit- FW- Rate=x4
   Capabilities: [50] Power Management version 2
      Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
      Status: D0 PME-Enable- DSel=0 DScale=0 PME-

02:04.0 Communication controller: Agere Systems LT WinModem (rev 02)
   Subsystem: AMBIT Microsystem Corp. Evo N600c
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 66 (63000ns min, 3500ns max)
   Interrupt: pin A routed to IRQ 11
   Region 0: Memory at 40280000 (32-bit, non-prefetchable) [size=256]
   Region 1: I/O ports at 2440 [size=8]
   Region 2: I/O ports at 2000 [size=256]
   Capabilities: [f8] Power Management version 2
      Flags: PMEClk- DSI+ D1- D2+ AuxCurrent=160mA PME(D0-,D1-,D2+,D3hot+,D3cold+)
      Status: D0 PME-Enable- DSel=0 DScale=0 PME-

02:06.0 CardBus bridge: Texas Instruments PCI1420
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 168, Cache Line Size: 128 bytes
   Interrupt: pin A routed to IRQ 11
   Region 0: Memory at 40000000 (32-bit, non-prefetchable) [size=4K]
   Bus: primary=02, secondary=03, subordinate=06, sec-latency=176
   Memory window 0: 50000000-51fff000 (prefetchable)
   Memory window 1: 56000000-57fff000
   I/O window 0: 00002800-000028ff
   I/O window 1: 00002c00-00002cff
   BridgeCtl: Parity- SERR- ISA- VGA- MAbort- >Reset+ 16bInt+ PostWrite+
   16-bit legacy interface ports at 0001

02:06.1 CardBus bridge: Texas Instruments PCI1420
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 168, Cache Line Size: 128 bytes
   Interrupt: pin A routed to IRQ 11
   Region 0: Memory at 40080000 (32-bit, non-prefetchable) [size=4K]
   Bus: primary=02, secondary=07, subordinate=0a, sec-latency=176
   Memory window 0: 52000000-53fff000 (prefetchable)
   Memory window 1: 58000000-59fff000
   I/O window 0: 00001400-000014ff
   I/O window 1: 00001800-000018ff
   BridgeCtl: Parity- SERR- ISA- VGA- MAbort- >Reset+ 16bInt+ PostWrite+
   16-bit legacy interface ports at 0001

02:08.0 Ethernet controller: Intel Corporation 82801CAM (ICH3) PRO/100 VM (KM) Ethernet Controller (rev 42)
   Subsystem: Compaq Computer Corporation Evo N600c
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 66 (2000ns min, 14000ns max), Cache Line Size: 32 bytes
   Interrupt: pin A routed to IRQ 10
   Region 0: Memory at 40100000 (32-bit, non-prefetchable) [size=4K]
   Region 1: I/O ports at 2400 [size=64]
   Capabilities: [dc] Power Management version 2
   Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 66 (2000ns min, 14000ns max), Cache Line Size: 32 bytes
   Interrupt: pin A routed to IRQ 10
   Region 0: Memory at 40100000 (32-bit, non-prefetchable) [size=4K]
   Region 1: I/O ports at 2400 [size=64]
   Capabilities: [dc] Power Management version 2
      Flags: PMEClk- DSI+ D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
      Status: D0 PME-Enable- DSel=0 DScale=2 PME-

02:0e.0 USB Controller: NEC Corporation USB (rev 41) (prog-if 10 [OHCI])
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 64 (250ns min, 10500ns max), Cache Line Size: 32 bytes
   Interrupt: pin A routed to IRQ 10
   Region 0: Memory at 40180000 (32-bit, non-prefetchable) [size=4K]
   Capabilities: [40] Power Management version 2
      Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
      Status: D0 PME-Enable- DSel=0 DScale=0 PME-

02:0e.1 USB Controller: NEC Corporation USB (rev 41) (prog-if 10 [OHCI])
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 64 (250ns min, 10500ns max), Cache Line Size: 32 bytes
   Interrupt: pin B routed to IRQ 10
   Region 0: Memory at 40200000 (32-bit, non-prefetchable) [size=4K]
   Capabilities: [40] Power Management version 2
      Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
      Status: D0 PME-Enable- DSel=0 DScale=0 PME-

02:0e.2 USB Controller: NEC Corporation USB 2.0 (rev 02) (prog-if 20 [EHCI])
   Subsystem: Compaq Computer Corporation Unknown device 00b7
   Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV+ VGASnoop- ParErr- Stepping- SERR- FastB2B-
   Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR-
   Latency: 64 (4000ns min, 8500ns max), Cache Line Size: 128 bytes
   Interrupt: pin C routed to IRQ 10
   Region 0: Memory at 40300000 (32-bit, non-prefetchable) [size=256]
   Capabilities: [40] Power Management version 2
      Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
      Status: D0 PME-Enable- DSel=0 DScale=0 PME-

Memory map according to the Service Manual:
Code:

Size    Memory Address       System Function
640 KB  00000000 - 0009FFFF  Base memory
128 KB  000A0000 - 000BFFFF  Video memory
048 KB  000C0000 - 000CBFFF  Video BIOS
160 KB  000C8000 - 000E7FFF  Unused
064 KB  000E8000 - 000FFFFF  System BIOS
015 MB  00100000 - 00FFFFFF  Extended memory
058 MB  01000000 - 047FFFFF  Super extended memory
058 MB  04800000 - 07FFFFFF  Unused
002 MB  08000000 - 080FFFFF  Video memory (direct access)
004 GB  08200000 - FFFEFFFF  Unused
064 KB  FFFF0000 - FFFFFFFF  System BIOS

There's also an option in the BIOS to save settings to floppy, but I can't make any sense of the output in a hex editor.

If anyone knows where I need to proceed from here, I'd appreciate a little guidance. I don't expect to be spoon-fed answers, but I'm not very experienced at this sort of thing and could use a few hints.
_________________
aidanjt wrote:
You see, instead of arguing from ignorance, and fear, there is only one way to verify a theory. And that's not by clutching a black book and begging the sky fairy for deliverance from the mad scientists and their big machines.


Last edited by UberPinguin on Sun Nov 05, 2006 6:09 am; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


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

PostPosted: Fri Nov 03, 2006 4:09 pm    Post subject: Reply with quote

UberPinguin,

What are you trying to achieve ?

The pixel buffer requires HorDots x VertDots X ColourBytes x 2 bytes per independent display surface. Thats 15360000 bytes for 1600x1200 in 32 bit colour. or 15Mb in round numbers. With the graphics pixel buffer in shared main memory, more dedicate RAM than you need is wasted.

With a dedicated memory graphics card, excess on card RAM is used to hold 3D textures, which is only useful for 3D applications.
When on card RAM is used up, the graphics card requests some of main memory, via the AGP Aperture. This is slower than on card RAM.
However, you have zero on card RAM. By allocating more graphics RAM than you need for your pixel buffers, you prevent the kernel from allocating this RAM to applications and you have no speed loss using the AGP Aperture, since its effectively all you have anyway.
_________________
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
UberPinguin
Guru
Guru


Joined: 20 Nov 2005
Posts: 510
Location: 2416.94 Miles From Home

PostPosted: Fri Nov 03, 2006 4:23 pm    Post subject: Reply with quote

When you put it like that, it almost seems pointless...
I guess I'm a little confused. I've seen other systems where the BIOS has a setting for increasing or decreasing the amount of RAM dedicated to the video card. On these systems, changing the value definitely had an impact on video performance.
My main objective is to achieve better rendering speed/quality in X. Right now, with EXA enabled, everything is very choppy - even moving terminal windows around when no other applications are open. Changing to XAA gives slight speed improvements, but is ugly compared to EXA and still pretty slow. I thought that by increasing the amount of RAM reserved for video, I could improve this performance.

Your point that there is zero on card RAM and all the memory operations are running through the AGP aperture clarifies something for me: I've seen other machines (notably a PowerBook I have) with the same (at least, nominally) video card in them that perform far better. Perhaps they are, in fact, built differently.

BTW, thanks for the quick response. I wasn't expecting anything for at least a few hours!
_________________
aidanjt wrote:
You see, instead of arguing from ignorance, and fear, there is only one way to verify a theory. And that's not by clutching a black book and begging the sky fairy for deliverance from the mad scientists and their big machines.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


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

PostPosted: Fri Nov 03, 2006 4:36 pm    Post subject: Reply with quote

UberPinguin,

What graphics driver are you using ?
If ati-drivers works for you, it will give the best performance.

What applications are choppy ?
What screen resolution and refresh rate are you using?

For some video drivers Xorg can change the amount of RAM allocated.
Code:
Read man <driver>
and
Code:
man xorg.conf
the option is VideoRAM <kbytes> and goes in the Device Section. Not all drivers support it though.
_________________
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
UberPinguin
Guru
Guru


Joined: 20 Nov 2005
Posts: 510
Location: 2416.94 Miles From Home

PostPosted: Fri Nov 03, 2006 5:09 pm    Post subject: Reply with quote

I'm using the open-source radeon driver. ATI's binary driver doesn't support my card. I tried setting VideoRAM, but it didn't seem to have any effect.

I'm using a dual-headed MergedFB setup: 1024x768 on the built-in LCD and 1280x1024 on an external CRT. Both monitors are running at 60Hz refresh.

I'm trying some options from the radeon man page, will report results..

[EDIT]Adding
Code:
Option "VideoRam" "131072"
Option "AccelDFS" "true"
Option "FBTexPercent" "0"
does not seem to aid performance.

As far as which applications are choppy - it's not really a specific app. Anything that causes a window to be redrawn is problematic - moving windows around, changing virtual desktops, minimizing, maximizing, resizing. And heaven forbid I should try to use compositing!

[EDIT 2]Also, FWIW, even with VideoRam set to 131072 and GARTSize set to 128, rovclock -i still reports 32768kb of video memory.

[EDIT 3]I used the rovclock utility to fix the memory timings and clock speeds to something a little snappier. Significantly improved performance. In fact, I turned on the 'Bling' extension for e17 (does compositing), and everthing is actually running faster than without Bling!

Changing topic to 'Solved' - changing the memory mapping appears to be useless and unnecessary.
_________________
aidanjt wrote:
You see, instead of arguing from ignorance, and fear, there is only one way to verify a theory. And that's not by clutching a black book and begging the sky fairy for deliverance from the mad scientists and their big machines.
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
Page 1 of 1

 
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