From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 31 22:42:28 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8606892E for ; Fri, 31 Oct 2014 22:42:28 +0000 (UTC) Received: from mail.ambrisko.com (mail.ambrisko.com [70.91.206.90]) by mx1.freebsd.org (Postfix) with ESMTP id 69B91EB1 for ; Fri, 31 Oct 2014 22:42:28 +0000 (UTC) X-Ambrisko-Me: Yes Received: from server2.ambrisko.com (HELO internal.ambrisko.com) ([192.168.1.2]) by ironport.ambrisko.com with ESMTP; 31 Oct 2014 15:46:00 -0700 Received: from ambrisko.com (localhost [127.0.0.1]) by internal.ambrisko.com (8.14.4/8.14.4) with ESMTP id s9VMgMQi077997 for ; Fri, 31 Oct 2014 15:42:22 -0700 (PDT) (envelope-from ambrisko@ambrisko.com) Received: (from ambrisko@localhost) by ambrisko.com (8.14.4/8.14.4/Submit) id s9VMgMZK077995 for freebsd-hackers@freebsd.org; Fri, 31 Oct 2014 15:42:22 -0700 (PDT) (envelope-from ambrisko) Date: Fri, 31 Oct 2014 15:42:22 -0700 From: Doug Ambrisko To: freebsd-hackers@freebsd.org Subject: UEFI PXE booting bug? Message-ID: <20141031224222.GA76176@ambrisko.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4.2.3i X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 31 Oct 2014 22:42:28 -0000 I've been testing UEFI PXE booting on a couple of machines. The loader.efi works just fine on a Dell R710 ... the kernel has issues but the loader.efi works fine. On two other machines it fails and hangs after the 2nd NFS lookup (the 2nd being the .gz format of the file). If I add a debug line as follows then it works instead of failing. I was wondering if anyone might see the obvious problem. Here is the patch: Index: open.c =================================================================== --- open.c (revision 273823) +++ open.c (working copy) @@ -146,6 +146,11 @@ f->f_dev->dv_close(f); if (error) devclose(f); +//printf("HELLO fail: %s %d %s\n",__FUNCTION__,__LINE__,fname); // works +//printf("fail: %s\n",fname); // works +printf(fname); // works +//printf("/boot/defaults/loader.conf\n"); // fails +//printf("/boot/defaults/loader.conf jjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjjj\n"); // fails err: f->f_flags = 0; Notice that combinations of printf and fname works. Just a printf fails. I haven't dumped the resulting assembler code etc. This is on -current. I was wondering if someone might know what the issue could be? FYI, the -current kernel fails to boot but a FreeBSD 9.2 with old UEFI support back ported to it works. Thanks, Doug A.