Jump to content

EFI booting thread


kinkadius
 Share

148 posts in this topic

Recommended Posts

Thomasology - If(When) you can install XP, it will either detect the card (doubtful with Firewire and XP). But there should be a driver that is supplied by the card manufacturer. So if it is installed in the iMac, as long as a driver is available, you should be able to use it.

 

Kcoyrhs - I doubt Mac's would be able to use anyting differently. But honestly I don't know. But I guess it would be as likely as XP booting on GPT.

 

Corey

Link to comment
Share on other sites

Ok, no excuses now. Here is the url to build grub 2 for x86 using gpt. Scroll down a bit. I would work on doing it myself but don't have a machine to do it on. Anybody want to team up with me? :star_smile: If you do let me know... I am in Spokane WA. Let's get a move on it!

Isaac.S

 

http://grub.enbug.org/TestingOnX86

 

 

{censored}. i'm in seattle. you're more than welcome to stop over sometime and we can work on it with my intel mac

Link to comment
Share on other sites

I stumbled across this link today....

 

http://support.ap.dell.com/support/topics/...5173&l=zh&s=lca

 

DellTMPowerEdgeTM7250 Server

Processors Up to four Intel® Itanium® 2 processors

Chipset Intel E8870

sorry, this was discused before - we know there is full EFI support for itaniumII

but thanks for interest anyway :)

Link to comment
Share on other sites

As for getting any OS on the iMac/Macbook, it seems as though its not only the issue of booting it. We know that EFI booting is supported by Vista Beta, but what we don't know is if EFI compatibility is completed on Vista. All bios calls in the OS have to be modularized so that when the OS wants to request 'bios' information, it can get information from the EFI thing.

 

Reaching towards $7g prize money for XP: Frankly, I know I'm not winning it anyways, so heres for anyone who is trying: Windows XP will not operate on an EFI without the bios compatibility set. The best method of attacking this is by running it in a sandbox or emulation environment, in which the bios calls by windows are converted into EFI calls and responses similarly converted. Yes: its a pain in the neck, but seems like its necessary. If the vista EFI loader works, and supports launching executables after its loaded, it can be hacked to load any windows executable file, namely, a bios software compatibility layer to launch the windows executables. Please tell me I'm not crazy, and correct me if I'm wrong, thanks.

Link to comment
Share on other sites

i don't get why the "legacy boot" doesn't work.

could someone explain this?

i mean, even with the EFI booting from a diskette on a non-mac system, legacy just isn't supported.

Shouldn't it be? Is this version a beta or something???

Link to comment
Share on other sites

Windows requires certian BIOS interrupts to be present. See http://www.missl.cs.umd.edu/winint/index2.html. Even though Vista can boot from EFI it 1) Requires UDF supprt & 2) Once NTDETECT is loaded it needs BIOS interrupts. What somebody needs todo is rip the BIOS out of a core duo laptop and write an EFI program that copies that BIOS into memory then lets it take over. This would result in a Mac with PC BIOS :D Either that or tear apart the BIOS and copy over the interrupt routines. Just my $0.02

Link to comment
Share on other sites

Windows requires certian BIOS interrupts to be present. See http://www.missl.cs.umd.edu/winint/index2.html. Even though Vista can boot from EFI it 1) Requires UDF supprt & 2) Once NTDETECT is loaded it needs BIOS interrupts. What somebody needs todo is rip the BIOS out of a core duo laptop and write an EFI program that copies that BIOS into memory then lets it take over. This would result in a Mac with PC BIOS :D Either that or tear apart the BIOS and copy over the interrupt routines. Just my $0.02

Or just get the compatibility module for EFI working (as it pretends to be a BIOS for any OS that needs a BIOS).

Link to comment
Share on other sites

As for getting any OS on the iMac/Macbook, it seems as though its not only the issue of booting it. We know that EFI booting is supported by Vista Beta, but what we don't know is if EFI compatibility is completed on Vista. All bios calls in the OS have to be modularized so that when the OS wants to request 'bios' information, it can get information from the EFI thing.

 

Reaching towards $7g prize money for XP: Frankly, I know I'm not winning it anyways, so heres for anyone who is trying: Windows XP will not operate on an EFI without the bios compatibility set. The best method of attacking this is by running it in a sandbox or emulation environment, in which the bios calls by windows are converted into EFI calls and responses similarly converted. Yes: its a pain in the neck, but seems like its necessary. If the vista EFI loader works, and supports launching executables after its loaded, it can be hacked to load any windows executable file, namely, a bios software compatibility layer to launch the windows executables. Please tell me I'm not crazy, and correct me if I'm wrong, thanks.

 

efi is not working in vista build 5270, the bootloader is just a stub with the press anykey msg and without anything else.

 

Hopefully beta 2 will have a working efi module

Link to comment
Share on other sites

It's too bad my (at my desk at work) ice doesn't support the Intel Duo processor/socket. I have the P4/P3/M pods but those wouldn't do me much good.

 

The way I see it, there are three ways to skin this cat. If this has already been discussed, I'm sorry for repeating it.

 

First, find a hardware compatible mobo with the same chipset which has a legacy BIOS. Extract the shadowed, decompressed bios image (easy). On the intel mac box, you could write an EFI module that would load the bios into memory (easy) and the convince the northbridge to write protect the area (hard without the chipset specs but perhaps not necessary) and then jump to the image's entry point (easy). That would boot a legacy bios.

 

The second approach is to use the EFI compatibility module. Apparently this does not work for some reason. I assume its already been tried. The only way to really do much here is to hook up an ICE and figure out what is going wrong. Or, I suppose, someone could write an EFI debugger.

 

The third approach is to wait for Vista. Supposedly Vista will support booting natively from EFI. Where this applies to XP is whether or not Vista's NTLDR will boot XP. My guess is that it probably will. All of the EFI support will be localized to NTLDR. The interface between NTLDR and ntoskrnl.exe is pretty simple. I've done a lot of reverse engineering of NTLDR so I'm quite familiar with how it works.

 

BTW, EFI supports legacy partition tables in conjunction with GPT partition tables. GPT tables aren't restricted to legacy 'track' boundaries like legacy partition tables. But if you create a partition that satifies the track boundary requirements of a legacy partition table, you can put that partition in the legacy partition table as well as the GPT partition table. That way, the legacy OS doesn't have to support GPT.

 

If Intel Mac EFI doesn't support ACPI, then that will be problematic booting Vista as well as XP. My guess is that the option that has the highest probability of success is, assuming you can find one, just going the legacy bios route. If a compatible bios can be found, I've got the tools for extracting the shadow bios. Then all that would be left would be writing the EFI loader.

 

Phil

Link to comment
Share on other sites

 

Great :lol: Seems like this guy just pimped his giro account to plus 7500,-$ <ritschinng> :D

 

But it is really interesting to read his steps. Maybe we can

recapitulate whathe was actually doing to retransmit it for

osx on peecees.

Link to comment
Share on other sites

The second approach is to use the EFI compatibility module. Apparently this does not work for some reason. I assume its already been tried. The only way to really do much here is to hook up an ICE and figure out what is going wrong. Or, I suppose, someone could write an EFI debugger.

 

But i think to be able to use CSM, we need a BIOS image that the CSM module will load in memory

the CSM sourcecode is included in the TianoCore.org EDK,

then the only additional need, is an image of a legacy BIOS that will be compatible with the iMac mobo !

Link to comment
Share on other sites

Below is the artilce mentioned above, as well as a mirror of the files, just in case something happened to them.

 

The Required Programs and Stuff

 

Acronis Disk Director Bootable CD

Acronis True Image

Another computer with a clean install of XP. No programs installed at all.

A MacBook obviously!

A Windows Vista DVD (not for installation purposes!)

Vista boot files

bcdedit.exe

BCDedit restore file

 

Most of the problems can be theoretically quickly dealt with.

Using the Bootable Acronis Disk Director CD on the MacBook, shrink the Mac partition. Create a new partition of type NTFS/HPFS in the remaining space.

Setup a clean version of XP on a PC.

Extract Boot.7z to the root drive of your XP installation.. So you have C:\Boot\

Copy bcdedit.exe to the root drive of your XP installation. C:\BCDedit.exe

Copy MacBook.bcd to the root drive of your XP installation

Use sysprep to “reseal” your XP install and remove all hardware info from the setup (thanks Kristan for pointing that out!).

Use Acronis TrueImage CD to make an image of your XP install.

Use the bootable Acronis True Image CD to recreate the image on the partition you just made on your MacBook.

Use the Bootable Vista DVD to boot on the MacBook.

Select “Repair Startup” -> Next -> CMD -> Run too.

Browse to drive C:\Boot (which is the partition you created on the MacBook and then extracted the Acronis TrueImage file to). (cd C:\boot)

Run “fixntfs.exe -lh” without the quotes

Browse back to drive C:\ (cd \)

Run “bcdedit.exe /import MacBook.bcd” without the quotes

Eject the CD and restart.

In Mac now, hack the Darwin Bootloader to add another entry that chainloads Drive(0) Partition(2). With GRUB it would look something like this… I’m not sure if Darwin is the same, but this step is very simple, and has nothing to do with EFI.

title Windows XP

rootnoverify (hd0,1)

chainloader +1

 

Restart

By selecting “Windows XP” on the Darwin Bootloader you should be chainloaded to the Vista bootloader, which should in turn boot the entry “NeoSmart Windows XP”

If everything has gone well, XP will boot!!

 

EFI.zip

Link to comment
Share on other sites

Using the Bootable Acronis Disk Director CD on the MacBook, shrink the Mac partition. Create a new partition of type NTFS/HPFS in the remaining space.

 

Is this soft " Acronis Disk Director CD" can boot on the iMac intel ?? i'm not sure :)

someone have to test ...

Link to comment
Share on other sites

 

I just registered because being able to run Windows on a macbook pro will decide if that will be my new laptop or not.

 

The instructions look fine, except:

 

# Use the Bootable Vista DVD to boot on the MacBook.

# Select “Repair Startup” -> Next -> CMD -> Run too.

 

That simply doesn't work, right? Didn't the person who managed to convince his imac on this forum to boot the Vista cd only have it hang on a blank screen?

 

Also, judging by his phrasings on the last few instructions, it doesn't actually sound like he has tried it (it sounds like he is guessing).

Link to comment
Share on other sites

Also, judging by his phrasings on the last few instructions, it doesn't actually sound like he has tried it (it sounds like he is guessing).

 

Look at the firstpage of his site. He speaks it out that he hasn't tried it because he doesn't own a macBook (noone outside apple is!).

Link to comment
Share on other sites

Theoretically?

 

Roughtly translated, that means he's guessing :)

 

If you forgive the ramblings of this noob, I can't really see this idea working. Too many "if's"

 

1. If acronis disk director works on the macintel. AFAICS there's a win32 and linux version. The linux version *might* run on darwin due to it's bsd roots, but given the fact this app is low level, I have my reservations

2. Does disk director support GPT partitioning? Seems unlikely. That said, it might given the problems he lists at the beginning of the article.

 

However both of these are pretty much academic. The same thing could be achived by placing the Mac in question into firewire target mode, hooking it up to a linux boxen, and running using parted to create the GPt based fat32 type partitions on the imac. Problem is AFAIK parted does not yet support HFS+ partitions, so you'll lose the OSX partition. However if you leave enough unpartitioned space the OSX installer should be able to use that.

 

3. The mac can only boot from APM or GPT disks. XP cannot read either. Shoehorning the vista bootloader onto xp won't fix that, only some serious hardcore hacking will. Now, the author of this method is attempting to bypass this problem by having a classic mbr based partion table and a GPT one hosted in the same disk. This is impossible.

 

The GPT spec states that LBA 0 must hold a dummy MBR. This dummy MBR fools legacy disk utilities into thinking that the disk contains 1 unknown partiton taking up the full disk. This is to prevent them from hosing your system. In addition, the *real* mbr is stored in two locations for recovery purposes, LBA 1 and the last LBA of the disk. These are hard coded. Thus if one was to eg// hack the dummy MBR to tell the computer that the GPT area is smaller than 100% of the hard disk will result in a hosed system.

 

Sorry, but IMHO the only way to get XP to run on the mac is to have 2 hard disks and use some funky bootloader magic, hack efi on the mac to boot non gpt disks, or hack in gpt support onto xp.

 

4. Item no. 9. The vista dvd doesn't boot on the mac.

 

5. No. 16 assumes that darwins bootloader supports chainloading. I can't see any reason why apple would add chainloading support to it. The opendarwin folks possibily, but then again I've never come across such an option. Only way to go here IMHO is elilo(most likely) or grub2 (unfinished).

 

No offense meant to anyone, but personally given the difficulties I feel that xp is a waste of time. Vista is the way to go, or even better would be to attempt linux first. The open sourced nature makes it easier to adapt, and the knowledge learned could then be applied to the windows world.

 

Of course, please don't let this post stop anyone from attempting this idea or others, as I would be pleasantly surprised to be proved wrong :).

Link to comment
Share on other sites

Look at the firstpage of his site. He speaks it out that he hasn't tried it because he doesn't own a macBook (noone outside apple is!).

 

Oh, pooh... I only saw the Macintel heading he used, so I assumed he was testing it on an iMac. Bah, then the information there is worthless. :)

 

Well, I called the Apple store and they have a running 5 week waiting period now, so I guess I'll order one anyway and cross my fingers that a solution is found until it arrives (otherwise I'll have a very expensive toy sitting on my desk). :)

Link to comment
Share on other sites

3. The mac can only boot from APM or GPT disks. XP cannot read either. Shoehorning the vista bootloader onto xp won't fix that, only some serious hardcore hacking will. Now, the author of this method is attempting to bypass this problem by having a classic mbr based partion table and a GPT one hosted in the same disk. This is impossible.

 

The GPT spec states that LBA 0 must hold a dummy MBR. This dummy MBR fools legacy disk utilities into thinking that the disk contains 1 unknown partiton taking up the full disk. This is to prevent them from hosing your system. In addition, the *real* mbr is stored in two locations for recovery purposes, LBA 1 and the last LBA of the disk. These are hard coded. Thus if one was to eg// hack the dummy MBR to tell the computer that the GPT area is smaller than 100% of the hard disk will result in a hosed system.

 

It is true that XP does not have GPT support. While the GPT spec does state that LBA 0 is a dummy MBR for legacy reasons, EFI states that LBA 0 can be used to describe a legacy partition for booting a legacy BIOS OS in conjunction with the legacy boot module. It places some restrictions on the placement of the legacy partition iirc. In other words, it is completely allowed by EFI to mix legacy partition tables and GPT. Mixing them will NOT hose the GPT partition table. A legacy partition is not allowed to extend to the very last sector of the drive which is *most of the time* academic since legacy partition must end on a cylinder boundary and most drives have a residual number of sectors modulo the track size.

 

Getting APM or ACPI support would be much more difficult. I'm fairly certain, though, that XP will boot without APM or ACPI support. You just won't get their benefits.

 

 

As for using Vista's NTLDR, well this is more theoretical. NTLDR does its job by detecting hardware (ntdetect.com), loading ntoskrnl.exe hal.dll and all boot loaded drivers into memory. It initializes protected mode, sets up paging. And then passes, in a single structure, a load of information about memory, where drivers are loaded, hardware detected, etc, to ntoskrnl's entry point. The state of the machine at the transition from to ntoskrnl has been almost identical throughout most versions of windows. The only notable difference was with the introduction of XP, NTLDR was more aggressive about unpaging unneccessary memory.

 

That said, NTLDR's job is to abstract the boot environment and create a very well defined state for ntoskrnl to run in. In that aspect NTLDR/ntoskrnl is very similar in function to GRUB/multiboot OS.

 

Phil

Link to comment
Share on other sites

Most of the problems can be theoretically quickly dealt with.

Using the Bootable Acronis Disk Director CD on the MacBook, shrink the Mac partition. Create a new partition of type NTFS/HPFS in the remaining space.

I just tried this part.

Acronis Disc Director couldn't resize the HFS+ partition of my drive, so that part does no work at all, you need to repartition the disk with a smaller HFS+ partition in order to alocate a Win XP partition.

 

So that part of the theory does no work.

Link to comment
Share on other sites

 Share

×
×
  • Create New...