Jump to content

fluid | fixed

donovan6000

donovan6000

Member Since 03 Dec 2009
Offline Last Active May 15 2013 07:33 AM
-----

In Topic: [PMPatch] UEFI patching utility

10 March 2013 - 11:20 AM

View PostCodeRush, on 10 March 2013 - 07:56 AM, said:

Before I go deep into programming, I must make a summary post about BIOSes we don't know how to patch now.
Probably, people capable of finding the way to patch by themselves, like donovan6000, will help me to find the way to patch this hard boiled pieces of binary.

1, by lunux, Phoenix SCT 2.1 from chinese OEM board.
Attachment PhoenixTechnologiesLtd.-11D.rom.zip
No signs of normal locking code, appears to be a variation of old CpuPei patch in different module, but I don't know for sure.

2., by dajs, AMI UEFI from ECS P67H2-A3.
Attachment ECS.zip
No sings of normal locking code at all. Can be CpuPei patch too.

3. X79/C062 BIOSes - no BIOS patch can provide native PM support, the kext itself needs to be patched. Nothing to do here now.

If anyone could help I'll be happy.

Hope this helps. After disassembling each of the bios's modules and searching through them for instances of 0xE2, this is what I've concluded.

Phoenix SCT 2.1's MSR lock probably happens in either:
PowerManagement2.efi F7731B4C-58A2-4DF4-8980-5645D39ECE58
SysemHddPwdDxe.efi ABAA46B8-84A3-4E74-882F-6368F6EDC9B8

AMI UEFI ECS P67H2-A3's MSR lock probably happens in:
CpuPei 2BB5AFA9-FF33-417B-8497-CB773C2B93BF

In Topic: Laptop thinks vga is always connected

08 March 2013 - 12:55 AM

View PostBumpy Knuckles, on 07 March 2013 - 11:54 AM, said:

Thank you very much, that's excatly the Tutorial i was looking for,
When work's over i will test this.
When i'm struggeling at some point, may i ask for some additional advice?

Edit: i have the same machine like the guy in this thread
http://www.insanelym...th-personality/
or this
http://www.osx86.net...n-10-7-2-a.html

Feel free to ask for help any time.

In Topic: Laptop thinks vga is always connected

07 March 2013 - 08:27 AM

View Postfreeuser16, on 07 March 2013 - 07:02 AM, said:

I have the same problem on my HD7670. I also have senseid 08 for VGA and I think this is causing the problem. No idea how to solve it yet :(
The easiest solution probably would be to disable VGA port and buy HDMI->VGA converter. But it costs quite a lot, so not really a good idea.

After testing out a few thing, this makes it so that vga isn't always connected. Unfortunately it might also break vga and hdmi, but I haven't tested them yet.

02 00 00 00 40 00 00 00 09 01 00 00 10 00 00 07 LVDS
00 08 00 00 00 02 00 00 00 71 00 00 21 03 01 02 HDMI
10 00 00 00 10 00 00 00 00 00 00 00 00 10 02 01 VGA


In Topic: [PMPatch] UEFI patching utility

07 March 2013 - 03:14 AM

View Postdonovan6000, on 14 February 2013 - 03:13 AM, said:

Doesn't work with my bios. Is this only for sandy bridge cpus? Or has it worked on any Nehalem ones? I've looked through my bios and I think it might be locking bit 15 in the smmplatform module instead of the usual places because of this function that's in smmplatform. I'd prefer to have someone with more expirence look it over before I change anything. Thanks. I've attached my bios, the powermanagement2 module, and the smmplatform module.    Posted Image

Just to let you guys know, I changed the jump opcode from a jb to a jmp and it works. No more patched AICPM for me :king:
So for anyone with HP insyde bios that are 2 - 4 years old, the MSR locking subroutine might be in the smmplatform module.

In Topic: Laptop thinks vga is always connected

06 March 2013 - 10:09 PM

View PostBumpy Knuckles, on 06 March 2013 - 03:11 PM, said:

OffTopic:
I have a question, i see that you've got running a 5650m with 1600x900,
How do you managed to get a picture on the internal LVDS?
All i got with this configuration was as scrumbled or blackscreen.
Would you be so kind to provide a little tutorial?

This graphics card was one of the most difficult I've ever had to get working. It took me a total of 2 years, 3 months, and 8 days before I for anything to display on the internal LVDS. So since I wanted to try to get my hackintosh to be as vanilla as possible, I decided to try editing my DSDT in order to get it working instead of using Chameleon's GraphicsEnabler. I discovered that my graphics card was being controller through PEGP in POP2 in my DSDT, so i edited it and this is what it's final result is:

			 Device (PEGP)
			 {
				 Name (_ADR, 0xFFFF)
				 Name (_PRW, Package (0x02)
				 {
					 0x09,
					 0x04
				 })
				 Method (_DSM, 4, NotSerialized)
				 {
					 Store (Package (0x56)
						 {
							 "@0,AAPL,boot-display",
							 Buffer (0x04)
							 {
									 0x01, 0x00, 0x00, 0x00
							 },
							 "@0,ATY,EFIDisplay",
							 Buffer (0x05)
							 {
								 "LVDS"
							 },
							 "@0,compatible",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "@0,device_type",
							 Buffer (0x08)
							 {
								 "display"
							 },
							 "@0,built-in",
							 Buffer (One)
							 {
									 0x01
							 },
							 "@0,display-dual-link",
							 Buffer (0x04)
							 {
									 0x01, 0x00, 0x00, 0x00
							 },
							 "@0,display-type",
							 Buffer (0x04)
							 {
								 "LCD"
							 },
							 "@0,name",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "@1,device_type",
							 Buffer (0x08)
							 {
								 "display"
							 },
							 "@1,compatible",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "@1,connector-type",
							 Buffer (0x04)
							 {
									 0x00, 0x08, 0x00, 0x00
							 },
							 "@1,display-type",
							 Buffer (0x05)
							 {
								 "HDMI"
							 },
							 "@1,name",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "@2,device_type",
							 Buffer (0x08)
							 {
								 "display"
							 },
							 "@2,compatible",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "@2,connector-type",
							 Buffer (0x04)
							 {
									 0x10, 0x00, 0x00, 0x00
							 },
							 "@2,display-type",
							 Buffer (0x04)
							 {
								 "VGA"
							 },
							 "@2,name",
							 Buffer (0x0C)
							 {
								 "ATY,Eulemur"
							 },
							 "AAPL,backlight-control",
							 Buffer (0x04)
							 {
									 0x00, 0x00, 0x00, 0x00
							 },
							 "AAPL00,DualLink",
							 Buffer (0x04)
							 {
									 0x01, 0x00, 0x00, 0x00
							 },
							 "@0,display-link-component-bits",
							 Buffer (0x04)
							 {
									 0x06, 0x00, 0x00, 0x00
							 },
							 "AAPL,EMC-Display-List",
							 Buffer (0x40)
							 {
								 /* 0000 */ 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0010 */ 0x06, 0x10, 0x00, 0x00, 0x1B, 0x92, 0x00, 0x00,
								 /* 0018 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0020 */ 0x06, 0x10, 0x00, 0x00, 0x1C, 0x92, 0x00, 0x00,
								 /* 0028 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0030 */ 0x06, 0x10, 0x00, 0x00, 0x21, 0x92, 0x00, 0x00,
								 /* 0038 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
							 },
							 "AAPL,aux-power-connected",
							 Buffer (0x04)
							 {
									 0x01, 0x00, 0x00, 0x00
							 },
							 "ATY,bin_image",
							 Buffer (0xF000)
							 {
							 **You need to put your vbios here
							 }
							 "ATY,Card#",
							 Buffer (0x0E)
							 {
								 "109-B77101-00"
							 },
							 "ATY,Copyright",
							 Buffer (0x33)
							 {
								 "Copyright AMD Inc. All Rights Reserved. 2005-2012"
							 },
							 "ATY,EFICompileDate",
							 Buffer (0x0F)
							 {
								 "March 31, 2011"
							 },
							 "ATY,EFIDriverType",
							 Buffer (One)
							 {
									 0x02
							 },
							 "ATY,EFIEnabledMode",
							 Buffer (One)
							 {
									 0x02
							 },
							 "ATY,EFIHWInitStatus",
							 Buffer (0x08)
							 {
									 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
							 },
							 "ATY,EFIOrientation",
							 Buffer (0x02)
							 {
									 0x00, 0x01
							 },
							 "ATY,EFIVersion",
							 Buffer (0x0B)
							 {
								 "01.00.3180"
							 },
							 "ATY,EFIVersionB",
							 Buffer (0x0F)
							 {
								 "113-B77101-012"
							 },
							 "ATY,EFIVersionE",
							 Buffer (0x0F)
							 {
								 "113-B7710A-318"
							 },
							 "ATY,MemRevisionID",
							 Buffer (0x02)
							 {
									 0x09, 0x00
							 },
							 "ATY,MemVendorID",
							 Buffer (0x02)
							 {
									 0x02, 0x00
							 },
							 "ATY,PlatformInfo",
							 Buffer (0x80)
							 {
								 /* 0000 */ 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0008 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0010 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0018 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0020 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0028 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0030 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0038 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0040 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0048 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0050 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0058 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0060 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0068 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0070 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
								 /* 0078 */ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
							 },
							 "ATY,Rom#",
							 Buffer (0x10)
							 {
								 "113-B7710C-176"
							 },
							 "device_type",
							 Buffer (0x12)
							 {
								 "ATY,EulemurParent"
							 },
							 "VRAM,totalsize",
							 Buffer (0x04)
							 {
									 0x00, 0x00, 0x00, 0x40
							 },
							 "model",
							 Buffer (0x1C)
							 {
								 "Ati Mobility Radeon HD 5650"
							 },
							 "hda-gfx",
							 Buffer (0x0A)
							 {
								 "onboard-1"
							 },
							 "AAPL00,override-has-edid",
							 Buffer (0x80)
							 {
								 **Your need to put your EDID here
							 }
						 }, Local0)
					 DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
					 Return (Local0)
				 }
			 }
			 Device (HDAU)
			 {
				 Name (_ADR, One)
				 Method (_DSM, 4, NotSerialized)
				 {
					 Store (Package (0x02)
						 {
							 "hda-gfx",
							 Buffer (0x0A)
							 {
								 "onboard-1"
							 }
						 }, Local0)
					 DTGP (Arg0, Arg1, Arg2, Arg3, RefOf (Local0))
					 Return (Local0)
				 }
			 }

This injects your EDID, dual-link, your vbios, you port information, graphics card information, and HDMI audio into your system. I mark the important things that are unique to your system with **. These are your vbios rom and your EDID. I've attached my DSDT , vbios, and EDID so you can see how it should be formatted.

After that you you need to edit a frame buffer to match the information contained in your vbios. Here's the output from radeon_bios_decoder on mine:

ATOM BIOS Rom:
SubsystemVendorID: 0x103c SubsystemID: 0x1448
IOBaseAddress: 0x4000
Filename: BR37005.001
BIOS Bootup Message:
MADISON Lenovo-Yx60-Madison Pro DDR3 64Mx16 500E/600M								
PCI ID: 1002:68c1
Connector at index 0
Type [@offset 45634]: LVDS (7)
Encoder [@offset 45638]: INTERNAL_UNIPHY (0x1e)
i2cid [@offset 45708]: 0x96, OSX senseid: 0x7
Connector at index 1
Type [@offset 45644]: HDMI-A (11)
Encoder [@offset 45648]: INTERNAL_UNIPHY1 (0x20)
i2cid [@offset 45731]: 0x90, OSX senseid: 0x1
Connector at index 2
Type [@offset 45654]: VGA (1)
Encoder [@offset 45658]: INTERNAL_KLDSCP_DAC1 (0x15)
i2cid [@offset 45758]: 0x97, OSX senseid: 0x8


The important parts from this are your sensed. Mine are 7 LVDS, 1 HDMI, 8 VGA

Here's the output from red sock_bios_decoder:

BR37005.001 :
MADISON Lenovo-Yx60-Madison Pro DDR3 64Mx16 500E/600M								
Subsystem Vendor ID: 103c
		 Subsystem ID: 1448
Object Header Structure Size: 199
Connector Object Table Offset: 34
Router Object Table Offset: 0
Encoder Object Table Offset: 99
Display Path Table Offset: 12
Connector Object Id [14] which is [LVDS]
encoder obj id [0x1e] which is [INTERNAL_UNIPHY (osx txmit 0x10 [duallink 0x0] enc 0x0)] linkb: false
Connector Object Id [12] which is [HDMI_TYPE_A]
encoder obj id [0x20] which is [INTERNAL_UNIPHY1 (osx txmit 0x21 [duallink 0x1]enc 0x3)] linkb: true
Connector Object Id [5] which is [VGA]
encoder obj id [0x15] which is [INTERNAL_KLDSCP_DAC1 (osx txmit 0x00 enc 0x10?)] linkb: false


The important parts from this are the txmit and enc values. Mine are 10 0 LVDS, 21 3 HDMI, 0 10 VGA. You can look up some tutorials on this forum if this is unclear.

Here's what Eulemur frame buffer looked like before
Personality: Eulemur
Disk offset in decimal 166336
04 00 00 00 14 00 00 00 00 01 00 00 01 02 01 04 LVDS
00 08 00 00 00 02 00 00 00 71 00 00 12 04 04 02 HDMI
10 00 00 00 10 00 00 00 00 00 00 00 00 10 00 01 VGA


Here's what it looked like after:
Personality: Eulemur
Disk offset in decimal 166336

02 00 00 00 40 00 00 00 09 01 00 00 10 00 00 07 LVDS
00 08 00 00 00 02 00 00 00 71 00 00 21 03 01 01 HDMI
10 00 00 00 10 00 00 00 00 00 00 00 00 10 02 08 VGA


So edit ATI5000Controller.kext/Contents/MacOS/AMD5000Controller at decimal offset 166336 using a hexeditor for your correct framebuffer.

Thats it. Repair permission with diskutility and restart. Then test out dvdplayer and see it you have a tranparent menu bar. If they both work then you have QE/CL working. I hope this helps. If some things aren't clear enough then let me know.

© 2013 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   Web hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy