Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1M1Jh1-0001hR-C7 for mharc-grub-devel@gnu.org; Tue, 05 May 2009 08:24:15 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1M1Jgu-0001gK-BQ for grub-devel@gnu.org; Tue, 05 May 2009 08:24:08 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1M1Jgp-0001f0-GY for grub-devel@gnu.org; Tue, 05 May 2009 08:24:07 -0400 Received: from [199.232.76.173] (port=57466 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1M1Jgo-0001eo-Mp for grub-devel@gnu.org; Tue, 05 May 2009 08:24:02 -0400 Received: from mail-ew0-f162.google.com ([209.85.219.162]:41674) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1M1Jgn-0005PU-LT for grub-devel@gnu.org; Tue, 05 May 2009 08:24:02 -0400 Received: by ewy6 with SMTP id 6so5041226ewy.42 for ; Tue, 05 May 2009 05:24:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=9cxe/JegIBWJKNqinyKq9B0Maqh01uOmJLdNqzuyZOY=; b=hwS1WLtILS7WnsJ15LYUfuZhRb8YDkPt+f1JnWi5G/46y5fMK3sDBEUNXX1SLfCzw3 EaYpI6re/UWcy6xiPWe6SLgYhx5bUsyoyeDGmDKbCOSfQ59LYndzFQ5GINV4IK4LK0HL 5iiPXpxUShayG3EoU0Uv2wL4mi2rnLI5O/V7k= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=CNLxurFgUWyxI/HRlRaoLECI1K4bDrE8Tk0sfPOn+irCvbuQ9/8E4veue4Kixua3qy dyGqRDbJo29e0qUGbr/spr0mddbqoJE9uKLLGxxSwsQz97sYIXgNrid0tTDOu63IDYU6 yUUYjZxA2JOjeH3RUh4wLcUBmCixIMYgdiO0Y= MIME-Version: 1.0 Received: by 10.211.177.12 with SMTP id e12mr6998ebp.37.1241526239957; Tue, 05 May 2009 05:23:59 -0700 (PDT) In-Reply-To: References: <20090504192725.GA19518@thorin> <20090504203911.GC6649@thorin> Date: Tue, 5 May 2009 14:23:59 +0200 Message-ID: From: "Vladimir 'phcoder' Serbinenko" To: The development of GRUB 2 Content-Type: multipart/alternative; boundary=0015174c3ef08315940469295ae5 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: Re: grub-dumpbios X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 May 2009 12:24:09 -0000 --0015174c3ef08315940469295ae5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit > ... as Stefan points out (thanks Stefan) this may not be so > > straightforwarded. I don't think this kind of tweaking is suitable > > for a setup that "Joe user" will get by default. > > > > Btw, if the video rom can be obtained directly from memory, why doesn't > > GRUB read it in runtime instead? > > Actually, the modified rom is what we need, as it contains information > such as DDC table which is detected on POST, the original rom is not > very useful in this respect. > > A better approach would be to fetch the rom from pci, then emulate the > POST process in grub2. But this need to port code from x86emu. > Default boot.efi passes to OSX kernel a blob device-properties containing some information about graphic and sound card. I'm nearly sure that it's retrieved from EFI and have an idea how but am not entirely sure yet. Here is an example from Florian Idelberger's dump from MBA who kindly permitted me to publish it device-path (like in EFI specifications): 02 01 0c 00 d0 41 03 0a 00 00 00 00 01 01 06 00 00 02 7f ff 04 00 "saved-timing0" length: 160 bytes: 13 00 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 80 9b 82 07 00 00 00 00 80 9b 82 07 00 00 00 00 80 9b 82 07 00 00 00 00 00 05 00 00 90 01 00 00 10 00 00 00 90 00 00 00 c0 03 00 00 28 00 00 00 01 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 "saved-timing1" length: 160 bytes: 00 10 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 20 43 52 04 00 00 00 00 20 43 52 04 00 00 00 00 20 43 52 04 00 00 00 00 00 05 00 00 a0 00 00 00 30 00 00 00 20 00 00 00 20 03 00 00 17 00 00 00 03 00 00 00 06 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 "saved-config" length: 256 bytes: 00 00 00 00 01 00 00 00 09 d1 00 00 c4 76 00 00 01 00 00 00 80 9b 82 07 90 06 00 00 00 05 00 00 90 06 00 00 10 05 00 00 a0 05 00 00 e8 03 00 00 c0 03 00 00 e8 03 00 00 c1 03 00 00 c4 03 00 00 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 13 00 00 80 06 10 00 00 73 9c 00 00 00 00 00 00 20 43 52 04 a0 05 00 00 00 05 00 00 a0 05 00 00 30 05 00 00 50 05 00 00 37 03 00 00 20 03 00 00 37 03 00 00 23 03 00 00 29 03 00 00 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 00 00 00 00 1a 00 00 00 00 10 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 "AAPL,backlight-control" length: 4 bytes: 01 00 00 00 "AAPL,NumDisplays" length: 4 bytes: 04 00 00 00 "AAPL,DisplayConfig" length: 32 bytes: 13 00 00 00 00 00 00 01 21 00 00 00 00 00 00 00 41 00 00 00 00 00 00 00 81 00 00 00 00 00 00 00 "AAPL,HasPanel" length: 4 bytes: 01 00 00 00 "AAPL,HasLid" length: 4 bytes: 01 00 00 00 "AAPL,NumFramebuffers" length: 4 bytes: 02 00 00 00 "AAPL,SelfRefreshSupported" length: 4 bytes: 01 00 00 00 "AAPL,BacklightRestore" length: 4 bytes: 01 00 00 00 "AAPL,BacklightMax" length: 4 bytes: 56 00 00 00 "AAPL,aux-power-connected" length: 4 bytes: 01 00 00 00 "AAPL01,T1" length: 4 bytes: 00 00 00 00 "AAPL01,T2" length: 4 bytes: 01 00 00 00 "AAPL01,T3" length: 4 bytes: c8 00 00 00 "AAPL01,T4" length: 4 bytes: c8 00 00 00 "AAPL01,T5" length: 4 bytes: 01 00 00 00 "AAPL01,T6" length: 4 bytes: 00 00 00 00 "AAPL01,T7" length: 4 bytes: 90 01 00 00 "AAPL01,InverterFrequency" length: 4 bytes: aa 01 00 00 "AAPL01,LinkType" length: 4 bytes: 00 00 00 00 "AAPL01,DualLink" length: 4 bytes: 00 00 00 00 "AAPL01,DataJustify" length: 4 bytes: 01 00 00 00 "AAPL01,LinkFormat" length: 4 bytes: 00 00 00 00 "AAPL01,PixelFormat" length: 4 bytes: 00 00 00 00 "AAPL01,Inverter" length: 4 bytes: 00 00 00 00 "AAPL01,Dither" length: 4 bytes: 00 00 00 00 "AAPL01,InverterCurrent" length: 4 bytes: 00 00 00 00 "AAPL01,BacklightIntensity" length: 4 bytes: 1a 00 00 00 "AAPL01,CurrentDisplay" length: 4 bytes: 00 00 00 00 "AAPL01,Height" length: 4 bytes: 20 03 00 00 "AAPL01,Width" length: 4 bytes: 00 05 00 00 "AAPL01,Depth" length: 4 bytes: 20 00 00 00 "AAPL01,Refresh" length: 4 bytes: 3d 00 00 00 "AAPL01,Interlace" length: 4 bytes: 00 00 00 00 "AAPL01,Stretched" length: 4 bytes: 00 00 00 00 "AAPL01,EDID" length: 128 bytes: 00 ff ff ff ff ff ff 00 06 10 73 9c 01 01 01 01 10 11 01 03 80 1d 12 78 0a 90 b5 99 58 52 8e 26 1e 50 54 00 00 00 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 52 1c 00 a0 50 20 17 30 30 20 36 00 1e b3 10 00 00 18 00 00 00 01 00 06 10 20 00 00 00 00 00 00 00 00 0a 20 00 00 00 fe 00 42 31 33 33 45 57 30 33 20 56 30 0a 20 00 00 00 fe 00 43 6f 6c 6f 72 20 4c 43 44 0a 20 20 20 00 d4 "AAPL01,IODisplayMode" length: 4 bytes: 00 10 00 80 "AAPL01,Pipe" length: 4 bytes: 01 00 00 00 "AAPL01,BootDisplay" length: 4 bytes: 01 00 00 00 "AAPL01,blackscreen-preferences" length: 4 bytes: 00 00 00 08 "AAPL00,blackscreen-preferences" length: 4 bytes: 00 00 00 08 -- Regards Vladimir 'phcoder' Serbinenko --0015174c3ef08315940469295ae5 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

> ... as Stefan points out (thanks = Stefan) this may not be so
> straightforwarded. =A0I don't think this kind of tweaking is suita= ble
> for a setup that "Joe user" will get by default.
>
> Btw, if the video rom can be obtained directly from memory, why doesn&= #39;t
> GRUB read it in runtime instead?

Actually, the modified rom is what we need, as it contains informatio= n
such as DDC table which is detected on POST, the original rom is not
very useful in this respect.

A better approach would be to fetch the rom from pci, then emulate the
POST process in grub2. But this need to port code from x86emu.
Default boot.efi passes to OSX kernel a blob device-prope= rties containing some information about graphic and sound card. I'm nea= rly sure that it's retrieved from EFI and have an idea how but am not e= ntirely sure yet. Here is an example from Florian Idelberger's dump fro= m MBA who kindly permitted me to publish it
device-path (like in EFI specifications): 02 01 0c 00 d0 41 03 0a 00 00 00 = 00 01 01 06 00 00 02 7f ff 04 00

"saved-timing0"
length= : 160
bytes: 13 00 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 80 9b 82 07 00= 00 00 00 80 9b 82 07 00 00 00 00 80 9b 82 07 00 00 00 00 00 05 00 00 90 01= 00 00 10 00 00 00 90 00 00 00 c0 03 00 00 28 00 00 00 01 00 00 00 03 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00= 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

"saved-timing1"
length: 160
bytes: 00 10 00 80 00 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00= 00 00 00 00 00 00 00 00 20 43 52 04 00 00 00 00 20 43 52 04 00 00 00 00 20= 43 52 04 00 00 00 00 00 05 00 00 a0 00 00 00 30 00 00 00 20 00 00 00 20 03= 00 00 17 00 00 00 03 00 00 00 06 00 00 00 00 00 00 00 00 00 00 00 00 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 00 00 00= 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00= 00 00 00

"saved-config"
length: 256
bytes: 00 00 00 00 01 00 00 = 00 09 d1 00 00 c4 76 00 00 01 00 00 00 80 9b 82 07 90 06 00 00 00 05 00 00 = 90 06 00 00 10 05 00 00 a0 05 00 00 e8 03 00 00 c0 03 00 00 e8 03 00 00 c1 = 03 00 00 c4 03 00 00 00 00 00 00 03 00 00 00 00 00 00 00 00 00 00 00 02 00 = 00 00 00 00 00 00 00 00 00 00 00 00 00 00 13 00 00 80 06 10 00 00 73 9c 00 = 00 00 00 00 00 20 43 52 04 a0 05 00 00 00 05 00 00 a0 05 00 00 30 05 00 00 = 50 05 00 00 37 03 00 00 20 03 00 00 37 03 00 00 23 03 00 00 29 03 00 00 01 = 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 02 00 00 00 00 00 00 00 00 00 = 00 00 1a 00 00 00 00 10 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 = 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 = 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

"AAPL,backlight-control"
length: 4
bytes: 01 00 00 00
"AAPL,NumDisplays"
length: 4
bytes: 04 00 00 00
"AAPL,DisplayConfig"
length: 32
bytes: 13 00 00 00 00 00 = 00 01 21 00 00 00 00 00 00 00 41 00 00 00 00 00 00 00 81 00 00 00 00 00 00 = 00

"AAPL,HasPanel"
length: 4
bytes: 01 00 00 00

&qu= ot;AAPL,HasLid"
length: 4
bytes: 01 00 00 00

"AAPL,N= umFramebuffers"
length: 4
bytes: 02 00 00 00

"AAPL,S= elfRefreshSupported"
length: 4
bytes: 01 00 00 00

"AAPL,BacklightRestore"length: 4
bytes: 01 00 00 00

"AAPL,BacklightMax"
le= ngth: 4
bytes: 56 00 00 00

"AAPL,aux-power-connected" length: 4
bytes: 01 00 00 00

"AAPL01,T1"
length: 4bytes: 00 00 00 00

"AAPL01,T2"
length: 4
bytes: 01= 00 00 00

"AAPL01,T3"
length: 4
bytes: c8 00 00 00
"AAPL01,T4"
length: 4
bytes: c8 00 00 00

"A= APL01,T5"
length: 4
bytes: 01 00 00 00

"AAPL01,T6&qu= ot;
length: 4
bytes: 00 00 00 00

"AAPL01,T7"
length: 4
bytes: 90 01 00 00

"AAPL01,InverterFrequency"=
length: 4
bytes: aa 01 00 00

"AAPL01,LinkType"
l= ength: 4
bytes: 00 00 00 00

"AAPL01,DualLink"
length= : 4
bytes: 00 00 00 00

"AAPL01,DataJustify"
length: 4
by= tes: 01 00 00 00

"AAPL01,LinkFormat"
length: 4
bytes= : 00 00 00 00

"AAPL01,PixelFormat"
length: 4
bytes: = 00 00 00 00

"AAPL01,Inverter"
length: 4
bytes: 00 00 00 00

&= quot;AAPL01,Dither"
length: 4
bytes: 00 00 00 00

"AA= PL01,InverterCurrent"
length: 4
bytes: 00 00 00 00

"= AAPL01,BacklightIntensity"
length: 4
bytes: 1a 00 00 00

"AAPL01,CurrentDisplay"length: 4
bytes: 00 00 00 00

"AAPL01,Height"
length= : 4
bytes: 20 03 00 00

"AAPL01,Width"
length: 4
bytes: 00 05 00 00

"AAPL01,Depth"
length: 4
bytes: 2= 0 00 00 00

"AAPL01,Refresh"
length: 4
bytes: 3d 00 0= 0 00

"AAPL01,Interlace"
length: 4
bytes: 00 00 00 00=

"AAPL01,Stretched"
length: 4
bytes: 00 00 00 00

= "AAPL01,EDID"
length: 128
bytes: 00 ff ff ff ff ff ff 00 06= 10 73 9c 01 01 01 01 10 11 01 03 80 1d 12 78 0a 90 b5 99 58 52 8e 26 1e 50= 54 00 00 00 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 01 52 1c 00 a0 50= 20 17 30 30 20 36 00 1e b3 10 00 00 18 00 00 00 01 00 06 10 20 00 00 00 00= 00 00 00 00 0a 20 00 00 00 fe 00 42 31 33 33 45 57 30 33 20 56 30 0a 20 00= 00 00 fe 00 43 6f 6c 6f 72 20 4c 43 44 0a 20 20 20 00 d4

"AAPL01,IODisplayMode"
length: 4
bytes: 00 10 00 80
=
"AAPL01,Pipe"
length: 4
bytes: 01 00 00 00

"= ;AAPL01,BootDisplay"
length: 4
bytes: 01 00 00 00

"A= APL01,blackscreen-preferences"
length: 4
bytes: 00 00 00 08

"AAPL00,blackscreen-preferences= "
length: 4
bytes: 00 00 00 08

=
--
Regards
Vladimir 'phcoder' Serbinenko
--0015174c3ef08315940469295ae5--