From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1Vz9dR-00062Q-Fw for mharc-grub-devel@gnu.org; Fri, 03 Jan 2014 13:38:17 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49455) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vz9dL-00061O-OZ for grub-devel@gnu.org; Fri, 03 Jan 2014 13:38:16 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vz9dH-0005Qk-1E for grub-devel@gnu.org; Fri, 03 Jan 2014 13:38:11 -0500 Received: from mail-qc0-x22c.google.com ([2607:f8b0:400d:c01::22c]:43475) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vz9dG-0005Qf-T1 for grub-devel@gnu.org; Fri, 03 Jan 2014 13:38:06 -0500 Received: by mail-qc0-f172.google.com with SMTP id e16so15094796qcx.17 for ; Fri, 03 Jan 2014 10:38:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type:content-transfer-encoding; bh=CRDVH6HvrO2SAhn1ZsTLsXmFlM0FRZPJ52A+RXS02Fk=; b=cHrzRl+PzRXxJXNERoHZHhymo5+hcztMZ9LojFgggXD7FpdwlkFrbLGijeTPizEUR1 dwlmVDOA1cTikgePYpJxeAQ6YC/yPz4ajoH1/ZSOaoy5M8P4JsYTXegmCZnWF76gJuiV /aohMcsBcj3Sn1OeCOK4BpynP3HtDPhIZ9WtHKpnr4iYnhQ+AnKEx0jRCzXEP36qi9Vr YIc4aQe+8oTqSi9F5Uv2847SXZy5NDbsyF8gAPHeRBdi1KwtsKTRvGJkDSlwhpS3sZ9i ugF87dGmxmuEYrpPuX4B2tjqyDDYXVNIf3BYD8lHFXf7G6Jov8u8pdbrhlYfy0oYJZdu /xPg== X-Received: by 10.224.167.139 with SMTP id q11mr109636096qay.71.1388774286425; Fri, 03 Jan 2014 10:38:06 -0800 (PST) Received: from [10.0.0.9] (c-50-169-245-128.hsd1.nh.comcast.net. [50.169.245.128]) by mx.google.com with ESMTPSA id ki4sm91461092qeb.0.2014.01.03.10.38.05 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 03 Jan 2014 10:38:05 -0800 (PST) Message-ID: <52C7038C.3090404@gmail.com> Date: Fri, 03 Jan 2014 13:38:04 -0500 From: SevenBits User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0 MIME-Version: 1.0 To: grub-devel@gnu.org Subject: Re: [PATCH] Add apple_set_os command References: <1388419466-2023-1-git-send-email-andreas@heider.io> <52C65CCF.7070801@gmail.com> In-Reply-To: <52C65CCF.7070801@gmail.com> X-Enigmail-Version: 1.6 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400d:c01::22c X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 03 Jan 2014 18:38:16 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 01/03/2014 01:46 AM, Vladimir '?-coder/phcoder' Serbinenko wrote: > On 31.12.2013 00:11, SevenBits wrote: >> On Monday, December 30, 2013, Andreas Heider wrote: >> >> The EFI on current macbooks configures hardware differently >> depending on wether it is booting Mac OS X or a different os, for >> example disabling the internal GPU completely on some models. >> >> Mac OS X identifies itself using a custom EFI protocol. >> >> This adds a command that fakes the os identification, making all >> hardware accessible. >> >> >> Just a question: I do a lot of booting Linux on MacBooks, and I >> frequently suffer from this issue. How do we know that this code >> actually works? > Run on a mac with this code and without and compare results. The > ship of "works by sane design" has long since sailed away. For > most manufacturers it's somewhere in Moon orbit but for apple it > has long since left solar system. So, Andreas, I tried your patch, and... no dice. The Mac behaves exactly as before. I'm afraid it didn't appear to do anything for me. Furthermore, your patch didn't print any output. There wasn't any error message returned (i.e your "Could not locate the apple set os protocol." message on line 52-53). When I invoked your command from the GRUB normal prompt, it DID print the message however. Perhaps it doesn't fail if called from within a grub.cfg, or maybe it simply doesn't print. The Mac that I tested on was a MacBook Pro from early 2008. Clearly, this function isn't present on all models. I can try it on others and seeing if it works on them, however. Also, why the if statements on lines 59 and 65, which indicate whether the OS version and/or vendor was set. What is the point of them? Why not just call the functions directly? > > > > _______________________________________________ Grub-devel mailing > list Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel > -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.14 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBAgAGBQJSxwOMAAoJEFbRvtGxmFPELWoH+QGu7aLuDam0vY+xW8h4TdFw ckY51K8vgEGlpUNvK2fwQnnAt57W3jH14HBIRY1IaC+c9XA3mooqp748xh0jfoV/ D95lZJuYu3XP4iFYtCehcCVOiz+x4DNXMnT6WA6hd5FjPT9xqbBqf/9RxSpN9O+i ZGbSe/ZQkOvTyLXJ11L3SeTlNi9jqA03mLaMrMi7Ehb7AU3hBkiSMpiiIcUjnP3o ZskQrSkguqt9Kt+FlHheTJkpAitqqJR/GpHkegg3bNGLrflacVGITMFFw0EsJP4R h0fsEocfYnvSVPrw07SJVFvt2TzPGB69p5QXy11cU1ZBYUhILcG7rDTAmVctZig= =wKye -----END PGP SIGNATURE-----