Chameleon

Issue 132: Gigabyte radeon 5770 bat mobile framebuffer problem

Reported by Seunghun Cha, Jul 27, 2011

when i install snow leopard 10.6.8 and lion 10.7, i found my 
graphics frame buffer was not working. so a few days ago, downloaded 
netkas aty_lnit.kext and i applied it. at last, my framebuffers 
working as a Uakari. and it has appeared 5700 series.(before it was 
5000)

i just wondering, if you guys apply this kext to chameleon
, it'll be very comfortable to give the option GE and fix the 
monitor connect port. 

thanks anyway i put the my graphics information over here.

Comment 1 by Cosmosis Jones, Jul 28, 2011

we dont' have the source for that.. is your device id in ati.c in 
chameleon?

Comment 2 by Seunghun Cha, Jul 29, 2011

yes i found my device in ati.c. but if i give the option GE=Yes, 
frame buffer didn't work. my device id is 100268b8
21d71458 kvervet . and i replaced Uakari with Vervet the netkas's 
aty_init.kext. it was working too. so now i'm using Vetvet.

Comment 3 by Azimutz, Jul 31, 2011

Hi Seunghun Cha,

can you try latest Chameleon build without aty_init?.. and
use AtiPorts=2 at the boot prompt or

<key>AtiPorts</key>
<string>2</string>
on Boot.plist.

Comment 4 by Seunghun Cha, Aug 1, 2011

Hi Charles.
It's not working either.

Comment 5 by Azimutz, Aug 1, 2011

Ok... well, your card's info is correct on the booter and the device 
id is on both accelerator and controller kexts.
For now, there's nothing on the booter that can help your case and 
as Cosmosis pointed, there's no aty_init source.
Did you tried another framebuffer with AtiConfig key?
Your rom doesn't show any lvds, so if you are on a laptop, the 
screen must be connected via dvi. Follow bcc9's guide to patch a 
framebuffer personality

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

i'd say you need either dvi, dvi, hdmi, dp or
dvi, hdmi, dp, depending on the nr of physical connectors... just 
guessing :P

I'm going to close the issue. Check this topic if you need help or 
info, :

http://forum.voodooprojects.org/index.php/topic,1959.0.html
Status: WontFix

Comment 6 by nozyczek, Aug 13, 2011

Seeing same thing. Vervet not loading for GIGABYTE GV-R577UD-1GD 
Radeon HD 5770 1GB 

I see device_id and subsys_id in ati.c but it doesn't load Vervet. 
    { 0x68B8,    0x21D71458, CHIP_FAMILY_JUNIPER,    "ATI 
Radeon HD 5770",                kVervet        },

./bdmesg 
Darwin/x86 boot v5.0.132 - Chameleon v2.0-RC5 r1331
Build date: 2011-08-08 09:08:59
ATI Juniper ATI Radeon HD 5770 1024MB (Vervet) [1002:68b8] (subsys 
[1458:21d7]):: PciRoot(0x0)/Pci(0x3,0x0)/Pci(0x0,0x0)


ioreg | grep ATY
    | |   |   | +-o ATY,ATY,RadeonFramebuffer@0  <class 
AtiFbStub, id 0x100000285, registered, matched, active, busy 0 (112 
ms), retain 7>
    | |   |   | | +-o ATY_ATY,RadeonFramebuffer  <class 
ATIFramebuffer, id 0x100000289, registered, matched, active, busy 0 
(78 ms), retain 17>
    | |   |   | +-o ATY,ATY,RadeonFramebuffer@1  <class 
AtiFbStub, id 0x100000286, registered, matched, active, busy 0 (6 
ms), retain 7>
    | |   |   | | +-o ATY_ATY,RadeonFramebuffer  <class 
ATIFramebuffer, id 0x10000028f, registered, matched, active, busy 0 
(6 ms), retain 16>
    | |   |   | +-o ATY,ATY,RadeonFramebuffer@2  <class 
AtiFbStub, id 0x100000287, registered, matched, active, busy 0 (5 
ms), retain 7>
    | |   |   | | +-o ATY_ATY,RadeonFramebuffer  <class 
ATIFramebuffer, id 0x100000295, registered, matched, active, busy 0 
(4 ms), retain 13>
    | |   |   | +-o ATY,ATY,RadeonFramebuffer@3  <class 
AtiFbStub, id 0x100000288, registered, matched, active, busy 0 (5 
ms), retain 7>
    | |   |   | | +-o ATY_ATY,RadeonFramebuffer  <class 
ATIFramebuffer, id 0x10000029b, registered, matched, active, busy 0 
(4 ms), retain 13>

I also tried with trunk 1227 with the same results.

Let me know if I can provide any info to help with this problem.
Thanks
nozyczek

Comment 7 by Cosmosis Jones, Aug 13, 2011

This is identifical to the XFX 5770. You'll need to bin patch the 
ati controller.

Have you tried using ATY_Init?

Comment 8 by nozyczek, Aug 13, 2011

Yes it does work with 
com.dong.driver.ATY_Init (1.0.0d1)
I changed the framebuffer from Uakari to Vervet in 
ATY_Init.kext/Contents/Info.plist 

Aug 13 09:52:13 localhost kernel[0]: ATY_Init: Starting
Aug 13 09:52:13 localhost kernel[0]: ATY_Init: Checking dev-id 68b8
Aug 13 09:52:13 localhost kernel[0]: ATY_Init: Card 0x68b8 was 
posted
Aug 13 09:52:13 localhost kernel[0]: ATY_Init: Card was posted, 
reading rom from legacy address
Aug 13 09:52:13 localhost kernel[0]: ATY_Init: Quiting for card 
0x68b8

ioreg | grep ATY
    | |   |   | +-o ATY,Vervet@0  <class AtiFbStub, id 
0x100000274, registered, matched, active, busy 0 (370 ms), retain 
7>
    | |   |   | | +-o ATY_Vervet  <class ATIFramebuffer, id 
0x10000027e, registered, matched, active, busy 0 (233 ms), retain 
17>
    | |   |   | +-o ATY,Vervet@1  <class AtiFbStub, id 
0x100000275, registered, matched, active, busy 0 (160 ms), retain 
7>
    | |   |   | | +-o ATY_Vervet  <class ATIFramebuffer, id 
0x1000002ab, registered, matched, active, busy 0 (10 ms), retain 
16>

Is there anything that could be done on Chameleon end to make this 
graphics card work?

Comment 9 by Cosmosis Jones, Aug 13, 2011

Someone that understands ati cards is going to have to do it..
Kabyl did the original one, and netkas did the kext.. So if netkas 
could fix it or kabyl that'd be great.

Can u post a full IOREG and bdmesg from using ATY_Init and using 
Chameleon?

Maybe we can locate the discrepency in the ioreg file
Labels: Target:2.1
Status: Accepted

Comment 10 by nozyczek, Aug 13, 2011

Files attached. Let me know if you need anything else to help with 
this issue. 
Thanks
nozyczek

Comment 11 by Cosmosis Jones, Aug 14, 2011

i only see 1 ioreg from using aty_init

Can you give me 1 file for each ioreg (once with no aty_init and 
just GE, and then 1 for aty_init)

So 2 sets of your zip kinda..

zip 1: bdmesg, ioreg using aty init
zip 2: bdmesg, ioreg not using aty_init

Comment 12 by Cyrus The Great, Aug 14, 2011

i am also have problem with GE that ATY_Int doest has this 
problem.after wake up from sleep my screen goes scrambled with 
GE.but ATY_Init every thing is normal.i look at the source of some 
kext like iondrv in lion and its changed .but related one in 
chameleon iokit/ndrvsupport does not changed .i thing some file in 
chameleon must be updated because lion has change the kext .netkas 
update the ATY_Init for lion .the main author of ATY_Init is dong 
after dong netkas maintained it.

Comment 13 by nozyczek, Aug 14, 2011

Files attached.

01.zip
        <key>GraphicsEnabler</key>
        <string>no</string>
no ATY_Init.kext


02.zip
        <key>GraphicsEnabler</key>
        <string>yes</string>
no ATY_Init.kext


03.zip
        <key>GraphicsEnabler</key>
        <string>no</string>
with ATY_Init.kext

Let me know if you need anything else.

Comment 14 by nozyczek, Aug 14, 2011

Forgot files ...

Comment 15 by Azimutz, Aug 16, 2011

Hi Nozyczek. Try a later Chameleon rev (i369 +). There's basically 
no difference between the 01 and 02 ioreg's and there should be; the 
only thing i can think of atm is the PCI-Root-UID value, it was not 
being read from your custom dsdt:

...
Loading kernel /mach_kernel
Read HFS+ file: [hd(0,2)/mach_kernel] 4096 bytes.
Read HFS+ file: [hd(0,2)/mach_kernel] 7948352 bytes.
ACPI table not found: DSDT.aml
No DSDT found, using 0 as uid value.
...

this should be fixed now.
One thing i'm sure, you really shouldn't be getting 
ATY,RadeonFramebuffer instead of ATY,Vervet!!
Check it out and report :)

Comment 16 by Azimutz, Aug 16, 2011

opss... (i369 +) should read (1369 +) :P

Comment 17 by nozyczek, Aug 16, 2011

Charles,
You were right! 
Just tested with r1409 and it worked. Can't show bdmesg because it 
is broke. I will open new bug.
This bug can be closed now.
Thanks

Comment 18 by nozyczek, Aug 16, 2011

I was able to get bdmesg to work. Here it is: 

Darwin/x86 boot v5.0.132 - Chameleon v2.1svn r1409
Build date: 2011-08-16 15:11:49
16375MB memory
VESA v3.0 16MB (ATI ATOMBIOS)
Scanning device 80...Press any key to enter startup options.(5) (4) 
(3) (2) (1) (0) Read HFS+ file: 
[hd(0,2)/Library/Preferences/SystemConfiguration/com.apple.Boot.plist
] 232 bytes.
Read HFS+ file: [hd(0,2)/Extra/org.chameleon.Boot.plist] 917 bytes.
Setting boot-uuid to: 9450E1FF-4A50-344A-9397-1AE6F50B212A
Read HFS+ file: 
[hd(0,2)/System/Library/CoreServices/SystemVersion.plist] 475 bytes.
Loading Darwin 10.7
Loading kernel /mach_kernel
Read HFS+ file: [hd(0,2)/mach_kernel] 4096 bytes.
Read HFS+ file: [hd(0,2)/mach_kernel] 7948352 bytes.
Read HFS+ file: [hd(0,2)/Extra/dsdt/DSDT_no_Vervet.aml] 20814 bytes.
Using PCI-Root-UID value: 1
Framebuffer @0xE0000000  MMIO @0xFBBC0000	I/O Port @0x0000EE00 ROM 
Addr @0x00000000
ATI card POSTed, reading VBIOS from legacy space
Framebuffer set to device's default: Vervet
Nr of ports set to framebuffer's default: 4
ATI Juniper ATI Radeon HD 5770 1024MB (Vervet) [1002:68b8] (subsys 
[1458:21d7]):: PciRoot(0x1)/Pci(0x3,0x0)/Pci(0x0,0x0)

Comment 19 by Azimutz, Aug 17, 2011

Nice :D
I had doubts because i'm used to get kp when PCI-Root-UID defaults 
to 0; mine is also 1.
Does everything work properly? Do you need to patch the framebuffer 
personality?
Would like to take a look at your rom; a readeon_bios_decode dump of 
it would be enough, for documentation; the tool can be found here:
http://www.insanelymac.com/forum/index.php?showtopic=249642

Thanks

Comment 20 by nozyczek, Aug 18, 2011

Everything seems to be OK. I have two 27' monitors connected via DVI 
and they both work. I didn't test other ports yet.

I'm bit new to the graphics hacks under OSX so i'm not sure if i'm 
doing it right.
I downloaded bios for my card from gigabyte.com and then ran it like 
this:

./radeon_bios_decode < vga_bios_gvr577ud-1gd_f11
ATOM BIOS Rom: 
	SubsystemVendorID: 0x1458 SubsystemID: 0x21d7
	IOBaseAddress: 0x0000
	Filename: R577UDAD.F11
	BIOS Bootup Message: 
GV-R577UD-1GD/F11                                              
             
PCI ID: 1002:68b8
Connector at index 0
	Type [@offset 44646]: DisplayPort (10)
	Encoder [@offset 44650]: INTERNAL_UNIPHY2 (0x21)
	i2cid [@offset 44766]: 0x91, OSX senseid: 0x2
Connector at index 1
	Type [@offset 44656]: HDMI-A (11)
	Encoder [@offset 44660]: INTERNAL_UNIPHY2 (0x21)
	i2cid [@offset 44793]: 0x94, OSX senseid: 0x5
Connector at index 2
	Type [@offset 44666]: DVI-I (2)
	Encoder [@offset 44670]: INTERNAL_UNIPHY1 (0x20)
	i2cid [@offset 44830]: 0x93, OSX senseid: 0x4
Connector at index 3
	Type [@offset 44676]: DVI-I (2)
	Encoder [@offset 44680]: INTERNAL_KLDSCP_DAC2 (0x16)
	i2cid [@offset 44830]: 0x93, OSX senseid: 0x4
Connector at index 4
	Type [@offset 44686]: DVI-I (2)
	Encoder [@offset 44690]: INTERNAL_UNIPHY (0x1e)
	i2cid [@offset 44867]: 0x92, OSX senseid: 0x3
Connector at index 5
	Type [@offset 44696]: DVI-I (2)
	Encoder [@offset 44700]: INTERNAL_KLDSCP_DAC1 (0x15)
	i2cid [@offset 44867]: 0x92, OSX senseid: 0x3


The bios file I got from gigabyte.com is F11 and I have no idea what 
is currently loaded on my card. I don't know how to check bios 
version on my card or flash new bios in OS X. I will need to read on 
it.
Let me know if the results i'm getting are correct.
Again, I will need to read more about the whole graphics hacks in 
OSX. Looks like the link you posted would be a good starting point. 
I would appreciate other links if you have any.
And as always let me know if you need anything else.
Thanks

Comment 21 by Azimutz, Aug 18, 2011

Well, i'm no graphics expert but, Vervet seems a good match for your 
card; it has dp, dvi-i dl, dvi-i sl and hdmi ports. It would be nice 
if you could test the other ports, to check if they work ootb.
Interesting how you can connect a 27' monitor to a port that seems 
to be single-link, but that doesn't surprise me, looking at the 
number of dvi ports on your rom...
How many physical ports does you card have?

You can dump the rom on Windows with Everest; usually doesn't fail. 
On OS X it's a bit trickier; i usually get them from ioreg, using 
IORegistryExplorer that comes with XCode. On the one retrieved over 
Terminal (ioreg -lfw0) it's a pain in to extract from all that 
output.

Comment 22 by nozyczek, Aug 18, 2011

The card has 
2x DVI
1x HDMI
1x Display Port

The specs on gigabyte.com show that DVI is dual-link:
Dual-link DVI-I * 2 / HDMI / DisplayPort

Can you explain why do I see 4x DVI-I after
./radeon_bios_decode < vga_bios_gvr577ud-1gd_f11

Comment 23 by Azimutz, Aug 18, 2011

That's a mystery to me :P
Need more knowledge, but i suspect they all work with the same 2 
physical ports, depending on the connected display.

I will close the issue now; if you want to trade more info meet me 
at this topic:
http://forum.voodooprojects.org/index.php/topic,1959.0.html

Thanks for your great feedback :)
See ya...
Status: Fixed

Comment 24 by Joel Calado, Aug 29, 2011

Hi. Sorry for resurrecting this bug, but i'm running latest trunk 
and getting "Framebuffer set to device's default: Vervet" 
etc.

Still, when running ioreg | grep ATY, i'm getting ATY, 
RadeonFramebuffer instead of ATY,Vervet.

Could there be something i'm overlooking?

Comment 25 by Azimutz, Aug 29, 2011

Hi Joel,
did you checked nozyczek's problem with PCI root, above?
Also, were's the info about your card?... i can only assume your 
card is similar to the ones above, but assumptions are not helpful :)

Comment 26 by Joel Calado, Aug 29, 2011

Hi.

My problem is "solved". Just saw a recent bug report, and 
the first user (dev?) to answer it mentioned you can't use GE and 
device-properties injection at the same time (?).

I was using LAN device-properties because of app store login woes. I 
removed it and all is well.

Comment 27 by Azimutz, Aug 30, 2011

yep, if i do remember, that's correct.
But i think you can retrieve the device-properties data injected by 
Chameleon via ioreg, merge it with the LAN data!?.. and use just 
device-properties key.

Comment 28 by Cosmosis Jones, Aug 30, 2011

this is closed. Please stop commenting on this "issue"

Open a new one or bring this to the forums

Created: 12 years 8 months ago by Seunghun Cha

Updated: 12 years 7 months ago

Status: Fixed

Followed by: 5 persons

Labels:
Priority:Medium
Type:Defect
Target:2.1