Clang, EFI and bad offsets

2012-07-10 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 In the process of the EFI on intel work, I ran across a strange issue. The procedure for creating loader.efi goes something like this: 1) compile to ELF object files 2) generate an ELF executable with -Bsymbolic and a custom linker script that puts

Fwd: UEFI, Qemu and emulating the secure boot interfaces

2012-06-28 Thread Eric McCorkle
Received this yesterday, about Linux's plans for supporting secure booting with EFI. I've looked into it as a possibility for FreeBSD, but I won't be in a position to do anything about it for some time. But the possibilities are enticing to say the least. Original Message Su

Re: EFI development tools

2012-06-17 Thread Eric McCorkle
On 6/17/12 8:43 PM, Mike Meyer wrote: Eric McCorkle wrote: The -m32 flag seems to be the culprit; removing it fixes the problem. This is why I was having problems, as the offsets in EFI_SYSTEM_TABLE were wrong. In any case, this is a pretty serious error, and someone should try to

Re: EFI development tools

2012-06-17 Thread Eric McCorkle
On 6/17/12 8:26 PM, Adrian Chadd wrote: Hiya, don't suppose you could file a PR for this? Typing one up just now, after figuring out the root cause. The short version is this: __uint64_t gets defined in as unsigned long. This breaks when you use -m32, in which case sizeof(unsigned long)

Re: EFI development tools

2012-06-17 Thread Eric McCorkle
On 6/17/12 6:45 PM, Eric McCorkle wrote: On 6/15/12 6:44 PM, Eric McCorkle wrote: int main() { printf("%d\n", UINT64); return 0; } Correction: it should be sizeof(UINT64) ___ freebsd-hackers@freebsd.org mailing

Re: EFI development tools

2012-06-17 Thread Eric McCorkle
On 6/15/12 6:44 PM, Eric McCorkle wrote: However, the EFI programs I produce using the EDK system work properly, and don't have the same issues as the ones I produce using what's in the base system. Okay, after a whole lot of slogging, I figured out the root of the problems I'

Re: EFI development tools

2012-06-16 Thread Eric McCorkle
On 06/16/12 06:03, Andrey V. Elsukov wrote: > Hi, Eric. > > Did you try the GNU EFI toolchain? It contains a good descriptions > on how to build EFI application and we probably can use some > suggestions even without importing it. > > http://sourceforge.net/projects/gnu-efi/ > I did. It looks

EFI development tools

2012-06-15 Thread Eric McCorkle
I've been working on EFI support for intel platforms. I've managed to build the EFI Development Kit (EDK II) and the IASL compiler for FreeBSD, which raises the possibility of integrating them either as ports, or possibly into the base system. Here is some background: Right now, there is only on

Re: GSoC Project: EFI on amd64/i386

2012-05-17 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 05/08/12 13:35, Eric McCorkle wrote: > Hello everyone, > > I'm going to be working on EFI boot support on the amd64/i386 > platforms as a GSoC project. The idea is to allow booting from > EFI (as opposed to legacy BIOS) on

Re: GSoC Project: EFI on amd64/i386

2012-05-17 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 05/17/12 10:36, John Baldwin wrote: >> Do the kernel and modules actually do anything that depends on >> being in a contiguous space in some way (ie some relocation >> trick)? Because it seems like it shouldn't really matter >> otherwise. > > The

Re: GSoC Project: EFI on amd64/i386

2012-05-17 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 05/16/12 01:32, Andrey V. Elsukov wrote: > As i see we already have sys/boot/efi/libefi/efipart.c that uses > EFI BLOCK_IO_PROTOCOL to make "part" devsw. EFI BLOCK_IO_PROTOCOL > provides access to each disk and partition. AFAIK it supports only > G

Re: GSoC Project: EFI on amd64/i386

2012-05-16 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 05/15/12 11:44, John Baldwin wrote: > The i386 kernel assumes it starts out with a flat 32-bit mode with > the kernel loaded into a contiguous memory region at a fixed > physical address. If we need a relocatable kernel (as Marcel > hinted at I thi

Re: GSoC Project: EFI on amd64/i386

2012-05-14 Thread Eric McCorkle
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 05/10/12 07:45, Marcel Moolenaar wrote: > > On May 8, 2012, at 1:35 PM, Eric McCorkle wrote: > >> Here are some specific points to be decided: >> >> * An EFI boot service could potentially function similarly to >

GSoC Project: EFI on amd64/i386

2012-05-08 Thread Eric McCorkle
s on these matters. - -- Eric McCorkle Computer Science Ph.D Student e...@shadowsun.net -BEGIN PGP SIGNATURE- Version: GnuPG v2.0.19 (FreeBSD) iQIcBAEBAgAGBQJPqVlgAAoJENSCzbQ+koZ7CpYP/27NtM6Vz1069OLjV/+BRUt0 yxW4t8Tl5QXmMUroNAwhnABMKnFG7HAkYxa0twMLudalQVRxCPhyY3

Re: FreeBSD on MacBook

2012-05-07 Thread Eric McCorkle
on, containing a BSDlabel. Inside that, there is a swap partition, and a single ZFS instance. When installing, you'll need to use dd to install the first part of zfsboot to the bsdlabel, and the remaining portion to the free space after the ZFS header (there's a guide on how

Re: GSoC: EFI on intel

2012-04-03 Thread Eric McCorkle
On 04/03/12 13:22, Doug Ambrisko wrote: > Eric McCorkle writes: > | I'm assessing possible summer of code projects, and the EFI work caught > | my attention. I've been running FreeBSD on a macbook for a little under > | a year now, and booting on EFI is definitely an

Re: GSoC: EFI on intel

2012-04-03 Thread Eric McCorkle
it to a partition reserved for that purpose. Anyway, if I'm going to propose this, I need to list possible mentors. Skill-wise, I'm well equipped to take it on. I anticipate needing someone who's a committer, preferably with good knowledge of the kernel sources. -- Eric

GSoC: EFI on intel

2012-04-02 Thread Eric McCorkle
I'm assessing possible summer of code projects, and the EFI work caught my attention. I've been running FreeBSD on a macbook for a little under a year now, and booting on EFI is definitely an interest to me. Does anyone know if this is still a viable project proposal? I certainly have the skills

CUDA porting effort?

2012-02-15 Thread Eric McCorkle
Given that NVidia is releasing the CUDA platform source on a limited basis, is anyone actively working to port it to FreeBSD? The reason I ask is that to get access to the source, you have to submit a request explaining what you intend to use it for. It might be a good idea to get ahold of the so