Jump to content

Editing custom personalities for ATI Radeon HD[45]xx


bcc9
 Share

775 posts in this topic

Recommended Posts

Thanks, but with

martuzkis-mac:vbios Martuzki$ ./radeon_bios_decode < 1002_9553.rom > connector.txt

The Connector.txt is empty :(

 

And...

bash-3.2# ./Radeon_bios_decode > 1002_9553.rom

Takes a while?!

Link to comment
Share on other sites

./radeon_bios_decode <  1002_9553.rom

 

tryed that with his (martzukis) and get following out of it

rhdAtomGetDataTable: No AtomBios signature found

 

seems to me his rom file is corrupted somehow

Link to comment
Share on other sites

Maybe... but how can i get a working one? :)

The only one i can get:

martens-mac:vbios Marten$ ./radeondump -i
Found a device of class RadeonPCI: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/AGP@1/IOPCI2PCIBridge/VGA@0/RadeonPCI
it matched on name "ATY_GPU"
Detected unknown Card (device id: 0x9553)
It's not in known card list, treat as card with device id: 0x9511
Detect EDID may fail for this card.
Start I2C dump
ATOM BIOS detected
ATOM BIOS Rom: 
SubsystemVendorID: 0x1019 SubsystemID: 0x2379
IOBaseAddress: 0x9000
Filename: BR033553.004
BIOS Bootup Message: 
BR033553.004 M92 DDR2 64bit 500e/500m									   

object id 0005 01
src object id 2115 21
record type 1
rhdAtomParseI2CRecord:  I2C Record: GPIO_ID 9 EngineID: 0 I2CAddr: 0
ddc_line from ATOMBIOS: 0x0
record type 4
object id 000e 01
src object id 2121 33
record type 1
rhdAtomParseI2CRecord:  I2C Record: HW_Line 9 EngineID: 0 I2CAddr: 0
ddc_line from ATOMBIOS: 0x0
record type 4
martens-mac:vbios Marten$

Link to comment
Share on other sites

Hello bcc9,

 

I tried the kabyl bootloader from download link and svn, using AtiConfig with "Baboon" and "Eulemur" personality on OSX 10.6.7.

I have a HD4650 1GB with id 1002/9498. I tried it with 10.6.6 ATi kexts and 10.6.7 ones. The card has 1x HDMI and 1x DVI.

The display always remains black, on HDMI and also on DVI. What do I am missing?

BTW. where can I find a binary of radeondump?

Link to comment
Share on other sites

Hello bcc9,

 

I tried the kabyl bootloader from download link and svn, using AtiConfig with "Baboon" and "Eulemur" personality on OSX 10.6.7.

I have a HD4650 1GB with id 1002/9498. I tried it with 10.6.6 ATi kexts and 10.6.7 ones. The card has 1x HDMI and 1x DVI.

The display always remains black, on HDMI and also on DVI. What do I am missing?

BTW. where can I find a binary of radeondump?

 

Its now called radeon_bios_decode, check attachments in the first post.

Link to comment
Share on other sites

Its now called radeon_bios_decode, check attachments in the first post.

Thanks for this info.

 

EDIT: Dumped bios with GPUZ, here is my info. Strangely the bios supports 4 outs while the card has only 2.

ATOM BIOS Rom:

SubsystemVendorID: 0x174b SubsystemID: 0xe109

IOBaseAddress: 0x0000

Filename: B110852.201

BIOS Bootup Message:

113-AB93400-100-PC RV730 DDR2 128bit 600e/500m

 

PCI ID: 1002:9498

Connector at index 0

Type [@offset 44954]: VGA (1)

Encoder [@offset 44958]: INTERNAL_KLDSCP_DAC2 (0x16)

i2cid [@offset 45026]: 0x93, OSX senseid: 0x4

Connector at index 1

Type [@offset 44964]: HDMI-A (11)

Encoder [@offset 44968]: INTERNAL_UNIPHY1 (0x20)

i2cid [@offset 45049]: 0x94, OSX senseid: 0x5

Connector at index 2

Type [@offset 44974]: DVI-I (2)

Encoder [@offset 44978]: INTERNAL_KLDSCP_DAC1 (0x15)

i2cid [@offset 45078]: 0x90, OSX senseid: 0x1

Connector at index 3

Type [@offset 44984]: DVI-I (2)

Encoder [@offset 44988]: INTERNAL_UNIPHY (0x1e)

i2cid [@offset 45078]: 0x90, OSX senseid: 0x1

I tried "Baboon" and "Eulemur", because these have 1 hmdi and one dvi at pos 1 and 2.

But I have to choose a personality that reflects the order and types as in my bios?

 

EDIT: What bytes reflect a VGA connector?

 

EDIT2: I only want to fully enable HDMI, until now my patched ATI* are unable to wakeup the HDMI (and DVI) monitor after sleep or resolution change.

 

1002_9498.rom.zip

Link to comment
Share on other sites

EDIT: Dumped bios with GPUZ, here is my info. Strangely the bios supports 4 outs while the card has only 2.
Radeon_bios_dump shows 4 connector entries, but the two DVI ports are obviously just a dual-link DVI port. You can see this because the senseid value is the same for both ports.

 

 

But I have to choose a personality that reflects the order and types as in my bios?
I don't believe order matters (other than when the connector count exceeds the count set by chameleon). It's the senseid, connector type, and encoder info you need to focus on.
Link to comment
Share on other sites

I don't believe order matters (other than when the connector count exceeds the count set by chameleon). It's the senseid, connector type, and encoder info you need to focus on.

Personality: Peregrine
ConnectorInfo count in decimal: 2
Disk offset in decimal 69472
0000000	00  02  00  00  04  02  00  00  00  00  00  00  02  01  04  05
0000010	00  04  00  00  00  01  00  00  00  00  00  00  20  00  02  02

 

Ok, thanks for info. I understand that the column at pos 0xf is the sense id. What are bytes from pos 0x2 until 0xe then? Where do I have to write encoder value, and what are the encoder values of my hdmi & dvi of my bios? Are these 0x20 and 0x15?

 

I changed the first line now to:

00 08 00 00 00 02 00 00 00 01 00 00 22 05 05 05

EDIT: Doesn't work. Black screen only.

 

BTW. my problem is also that the display remains black if I change the resolution. Do you think this could be also caused by a wrong connector type?

Link to comment
Share on other sites

Personality: Peregrine
ConnectorInfo count in decimal: 2
Disk offset in decimal 69472
0000000	00  02  00  00  04  02  00  00  00  00  00  00  02  01  04  05
0000010	00  04  00  00  00  01  00  00  00  00  00  00  20  00  02  02

 

Ok, thanks for info. I understand that the column at pos 0xf is the sense id. What are bytes from pos 0x2 until 0xe then? Where do I have to write encoder value, and what are the encoder values of my hdmi & dvi of my bios? Are these 0x20 and 0x15?

 

I changed the first line now to:

00 08 00 00 00 02 00 00 00 01 00 00 22 05 05 05

 

BTW. my problem is also that the display remains black if I change the resolution. Do you think this could be also caused by a wrong connector type?

 

This post should explain everything you need to know about personalities:

 

http://www.insanelymac.com/forum/index.php?showtopic=252061

Link to comment
Share on other sites

This post should explain everything you need to know about personalities:

 

http://www.insanelymac.com/forum/index.php?showtopic=252061

Wow, that's detailed info by mucha :(

 

My card has 1 x HDMI and 1 x DVI (don't need duallink). So I came to these values. What do you think:

00 08 00 00 00 02 00 00 00 00 00 00 11 00 00 05
04 00 00 00 14 00 00 00 00 00 00 00 10 01 01 01

 

EDIT: HDMI output now looks like this:

post-39386-1304508953_thumb.jpg

But better than just black :)

 

EDIT 2: Also with RadeonHD.kext by Dong the screen looks like this. If I disable graphicsenabler, the boot log will stop.

 

EDIT 3: The hdmi output works with a hacked ATI*.kext-set with connectortyoe 0x200 and controlflags 0x204. Only resolution change / wakeup doesnt work. Does this mean that the hdmi output of the card is actually a DVI port?

Link to comment
Share on other sites

I have a question. is there a defined unique framebuffer personalitie for every card or is there a few generic that all cards fall under i say few but like a defined number say for examle.

 

Type A LVDS +DV1 +VGA (set ports set Encoder / Connector )

ext link a list

type B

Type C

 

Or are all cards unique in there conector info. no 2 cards are the same

Link to comment
Share on other sites

HI, I'm trying to add dp and hdmi output to my ati 4890. after some test my result is that I can hotplug my dp cable so my second monitor is detected but black. I've changed framebuffer from motmot to flicker on 10.6.7 cause I'm also trying to activate hdmi port (motmot can't do this).

here there are my connectors

ATOM BIOS Rom: 
SubsystemVendorID: 0x174b SubsystemID: 0xe115
IOBaseAddress: 0x0000
Filename: E115QA1G.S02
BIOS Bootup Message: 
WEKIVA RV790 B790 BOARD 850E/975M                                         

PCI ID: 1002:9460
Connector at index 0
Type [@offset 44460]: DVI-I (2)
Encoder [@offset 44464]: INTERNAL_KLDSCP_DAC1 (0x15)
i2cid [@offset 44568]: 0x93, OSX senseid: 0x4
Connector at index 1
Type [@offset 44470]: DVI-I (2)
Encoder [@offset 44474]: INTERNAL_KLDSCP_LVTMA (0x1f)
i2cid [@offset 44568]: 0x93, OSX senseid: 0x4
Connector at index 2
Type [@offset 44480]: VGA (1)
Encoder [@offset 44484]: INTERNAL_KLDSCP_DAC2 (0x16)
i2cid [@offset 44603]: 0x90, OSX senseid: 0x1
Connector at index 3
Type [@offset 44490]: HDMI-A (11)
Encoder [@offset 44494]: INTERNAL_UNIPHY (0x1e)
i2cid [@offset 44626]: 0x91, OSX senseid: 0x2
Connector at index 4
Type [@offset 44500]: DisplayPort (10)
Encoder [@offset 44504]: INTERNAL_UNIPHY (0x1e)
i2cid [@offset 44653]: 0x92, OSX senseid: 0x3

used personality

original

od -Ax -tx1 /tmp/Flicker
0000000    00  04  00  00  00  01  00  00  00  01  00  00  02  01  03  05
0000010    00  04  00  00  00  01  00  00  00  01  00  00  01  00  02  02
0000020    00  02  00  00  14  02  00  00  00  01  00  00  00  10  01  04
0000030

modified

0000000    00  04  00  00  00  01  00  00  00  01  00  00  02  01  03  03
0000010    00  08  00  00  00  01  00  00  00  01  00  00  01  00  02  02
0000020    04  00  00  00  14  02  00  00  00  01  00  00  01  11  01  04
0000030

original motmot DVI connector (working)

04  00  00  00  14  02  00  00  00  01  00  00  01  11  01  04

also Shrike should interest

0000000    02  00  00  00  40  00  00  00  09  01  00  00  02  01  00  03
0000010    02  00  00  00  00  01  00  00  09  01  00  00  20  01  02  02
0000020    00  04  00  00  04  03  00  00  00  01  00  00  10  00  01  01
0000030

ioreg

post-544968-1304904524_thumb.pngpost-544968-1304904530_thumb.png

10.6.2 framebuffer has native dp support but latest bootloaders seem are getting less and less compatible.don't ask me why. however I will also try to use hdmi port so I need newest framebuffers. any help is really appreciated :huh:

Link to comment
Share on other sites

I,m also tryng to extract connectorinfo from 10.6.2 framebuffer, but I personalyty script doesn't work. all framebuffer are signed to 0. maybe because are 20 byte long and not 10?

 

Ex:

Personality: Uakari

ConnectorInfo count in decimal: 0

Personality: Megalodon

ConnectorInfo count in decimal: 0

Link to comment
Share on other sites

I've found a solution to get dp and dvi ports active together for my ati ''4890 sapphire new edition'' on 10.6.7:

at

Personality: MotMot

ConnectorInfo count in decimal: 2

Disk offset in decimal 69024

0000000 00 04 00 00 04 01 00 00 00 01 00 00 10 00 02 03

0000010 04 00 00 00 14 02 00 00 00 01 00 00 01 11 01 04

0000020

i have changed the hotplugID of dp port from 0x02 to 0x03. sometimes the dp monitor appears garbled, remove and reconnect the cable and it works just fine. no hdmi I think there is no support.

Link to comment
Share on other sites

I,m also tryng to extract connectorinfo from 10.6.2 framebuffer, but I personalyty script doesn't work. all framebuffer are signed to 0. maybe because are 20 byte long and not 10?

Yes, per this post:

http://www.insanelymac.com/forum/index.php...t&p=1658305

the connectorinfo structure changed in length as of 10.6.4. I don't plan on trying to add support for versions of OSX older than that.

 

I'll add this info to post #1.

Link to comment
Share on other sites

ok so following the instructions and looking at my dumps

 

 

 

 

 

UakariInfo::createInfo(unsigned char, PlatformParameters&):

0001c59c pushl %ebp

0001c59d movl %esp,%ebp

0001c59f movl 0x0c(%ebp),%eax

0001c5a2 movl $0x00025bfc,0x08(%eax)

0001c5a9 movb $0x04,0x03(%eax)

0001c5ad xorl %ecx,%ecx

0001c5af movl $0x00026330,%edx

0001c5b4 movl %edx,0x0c(%eax,%ecx,4)

0001c5b8 addl $0x10,%edx

0001c5bb incl %ecx

0001c5bc cmpl $0x04,%ecx

0001c5bf jne 0x0001c5b4

0001c5c1 xorl %eax,%eax

0001c5c3 popl %ebp

0001c5c4 ret

0001c5c5 nop

 

2. otool -arch i386 -l ATI5000controller

 

Find the section whose address+size includes the above virtual address within its range (0x10)

 

3. So the address on disk for this virtual address is:

offset_in_file = start_offset_for_architecture + offset_for_segment + virtual_address - start_address_for_segment

 

where start_offset_for_architecture as reported by lipo above

start_address_for_segment, offset_for_segment as reported by otool above

virtual_address is the address obtained from the addl instruction.

 

Numerically, the address on disk is:

 

can some one help me with the math here im confused ... getting old i guss been 20 years or maby im stupid and just not getting the instructions this looks nuthing like what was in his example

Link to comment
Share on other sites

I have a question. is there a defined unique framebuffer personalitie for every card or is there a few generic that all cards fall under i say few but like a defined number say for examle.

 

Type A LVDS +DV1 +VGA (set ports set Encoder / Connector )

ext link a list

type B

Type C

 

Or are all cards unique in there conector info. no 2 cards are the same

Think of personality meaning board layout.

For a particular ATI chip, there are many board layouts (ATI's reference designs, sapphire's, XFX's, Apple's). The "personalities" in the driver represent board layouts apple ships. Some of these layouts may or may not exactly match any desktop card (for example apple imac layouts with LVDS displayport).

 

Several card models share identical layouts.

More than 1 apple layout may be a close enough match to your card that you have multiple personality choices.

 

 

can some one help me with the math here im confused ... getting old i guss been 20 years or maby im stupid and just not getting the instructions this looks nuthing like what was in his example
ati-personality.pl does the math for you, as of version 0.5 back on 3/26. I updated the instructions in post #1 to reflect as much around that time. You seem to be working off of older info from somewhere?

 

You can still manually do the math following the finding-patch-address.txt for details, and using my perl script to compare against if you get stuck.

Link to comment
Share on other sites

Think of personality meaning board layout.

For a particular ATI chip, there are many board layouts (ATI's reference designs, sapphire's, XFX's, Apple's). The "personalities" in the driver represent board layouts apple ships. Some of these layouts may or may not exactly match any desktop card (for example apple imac layouts with LVDS displayport).

 

Several card models share identical layouts.

More than 1 apple layout may be a close enough match to your card that you have multiple personality choices.

 

 

yea when i wrote that i was trying to grasp how port dection works in the kexts .... still not totaly sure anyone actualy understands how the ports are dected from start to finish and why the ports are not mapping correctly altho my understanding is not the best now im trying to get up to speed on how to hack them .... needless to say i take 2 steps foward and 3 back it seems i think im starting to understand then i am WTF all over again... eventualy im hopeing to fully understand the atisupport.kext and the individual framebuffers and how they play there parts ... sorry for the ramble

 

Think of personality meaning board layout.

For a particular ATI chip, there are many board layouts (ATI's reference designs, sapphire's, XFX's, Apple's). The "personalities" in the driver represent board layouts apple ships. Some of these layouts may or may not exactly match any desktop card (for example apple imac layouts with LVDS displayport).

 

Several card models share identical layouts.

More than 1 apple layout may be a close enough match to your card that you have multiple personality choices.

 

 

ati-personality.pl does the math for you, as of version 0.5 back on 3/26. I updated the instructions in post #1 to reflect as much around that time. You seem to be working off of older info from somewhere?

 

You can still manually do the math following the finding-patch-address.txt for details, and using my perl script to compare against if you get stuck.

 

 

the instructions were in the zip with the ati-personality.pl maby for some reason im using realy old version idk

Link to comment
Share on other sites

when i ran the script i got a lot of files the 3 im intrest in is the 5000controller ones right .... so looking at the files i got 2 that are 4k in size and one that is 1mb i guss this is where the directions are getting fuzzy as im not sure what to do at this point ..... i think im simi integlent but this is making me feel like a idiot ....sigh

 

 

.... ok i think i may be figureing some of this out

 

Fat header in: /System/Library/Extensions/ATI5000Controller.kext/Contents/MacOS/ATI5000Controller

fat_magic 0xcafebabe

nfat_arch 2

architecture x86_64

cputype CPU_TYPE_X86_64

cpusubtype CPU_SUBTYPE_X86_64_ALL

offset 4096

size 326128

align 2^12 (4096)

architecture i386

cputype CPU_TYPE_I386

cpusubtype CPU_SUBTYPE_I386_ALL

offset 331776

size 336300

align 2^12 (4096)

 

 

idk grrrrrr im getting flustered please some guidance

Link to comment
Share on other sites

the instructions were in the zip with the ati-personality.pl maby for some reason im using realy old version idk
The latest version is in post #1, version 0.6.

Per post #1:

"finding-patch-address.txt in the attached zip file for instructions if you wish to calculate the effective address & disk address yourself by hand."

Link to comment
Share on other sites

Did you check for the ATY,bin_image key in the ioregistry?

I detailed that method in post #28:

http://www.insanelymac.com/forum/index.php...t&p=1648201

thanks! I Dont know why it works now with RadeonDump :(

 

 

BIOS Dump:

 

mac$ ./radeondump < 9553.0301.00E0.vga.rom 
ATOM BIOS Rom: 
SubsystemVendorID: 0x1019 SubsystemID: 0x2379
IOBaseAddress: 0x9000
Filename: BR033553.004
BIOS Bootup Message: 
BR033553.004 M92 DDR2 64bit 500e/500m 

Connector at index 0 type: VGA (1)
Connector's i2cid: 90
Connector at index 1 type: LVDS (7)
Connector's i2cid: 91

 

 

./RadeonDump -i

Found a device of class RadeonPCI: IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/AGP@1/IOPCI2PCIBridge/VGA@0/RadeonPCI
it matched on name "display"
Detected unknown Card (device id: 0x9553)
It's not in known card list, treat as card with device id: 0x9511
Detect EDID may fail for this card.
0x1002:  00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
Start I2C dump
ATOM BIOS detected
ATOM BIOS Rom: 
SubsystemVendorID: 0x1019 SubsystemID: 0x2379
IOBaseAddress: 0x9000
Filename: BR033553.004
BIOS Bootup Message: 
BR033553.004 M92 DDR2 64bit 500e/500m									   

object id 0005 01
src object id 2115 21
record type 1
rhdAtomParseI2CRecord:  I2C Record: GPIO_ID 9 EngineID: 0 I2CAddr: 0
ddc_line from ATOMBIOS: 0x0
record type 4
object id 000e 01
src object id 2121 33
record type 1
rhdAtomParseI2CRecord:  I2C Record: HW_Line 9 EngineID: 0 I2CAddr: 0
ddc_line from ATOMBIOS: 0x0
record type 4

 

 

I allready tried this (Peregrine):

 

02 00 00 00 40 00 00 00 09 01 00 00 12 00 01 02 LVDS
10 00 00 00 10 00 00 00 00 01 00 00 00 10 00 01 VGA

 

But when i Boot it i got a Screen wich backlight is off ;)

 

I have a ATI 4570 Mobility (0x10029553)

 

Can someone help me?

 

EDIT: KExt loaded:

ATIFramebuffer.kext

ATIRadeonX2000.kext

ATI4600Controller.kext

ATISupport.kext

 

Aviable Res:

800x600

1024x768

1280x1024

1680x1050

 

Graka will be detected but no Screens/Outputs are working

 

EDIT2: With LionKexts i can use both Displays (VGA, Internal) with the right res. but no QE/CI and on the Internal Screen there are Crazy colours and a "nervous" screen

Link to comment
Share on other sites

Silly question but I can't find the 64 bit Vervet table in the ATIFrambuffer.

 

I can see the output in ati personality:

 

Personality: Vervet - 64 bit

ConnectorInfo count in decimal: 4

Disk offset in decimal 80000

0000000 00 04 00 00 00 04 00 00 00 01 00 00 12 04 04 02

0000010 04 00 00 00 14 00 00 00 00 01 00 00 01 12 01 04

0000020 00 02 00 00 14 00 00 00 00 01 00 00 00 00 06 03

0000030 00 08 00 00 00 02 00 00 00 01 00 00 22 05 05 01

0000040

 

 

The offset of 80000 = 0x13880

I look on that row using HexEditor and I can't see it there !

 

Can anyone help ? I'm analysis it in 10.6.7 normal update (not MBP or iMac kexts)

Link to comment
Share on other sites

 Share

×
×
  • Create New...