Received: by 10.213.65.68 with SMTP id h4csp676692imn; Fri, 6 Apr 2018 07:09:57 -0700 (PDT) X-Google-Smtp-Source: AIpwx48+5jaiTcjDkbEsWjyFu/6/hzdlBuNNLVOoYj7W1T9VDxBzx2Y3p3Mro4AxsoSrt7j5bcQZ X-Received: by 2002:a17:902:ac97:: with SMTP id h23-v6mr27867491plr.176.1523023797883; Fri, 06 Apr 2018 07:09:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1523023797; cv=none; d=google.com; s=arc-20160816; b=J3Tx4WlieCNB01Fk4/WbHV6t13eTM/1ANcwa3o34J44DmE9raR78f97nh5Hpx+lHBz KiQR+Bgv0iNovw3Iy/rtDj8HX6lXy5kSGnObPM4qUzUv9q9ODM+wQZanwvZIjvVDFaox 6cG0BXStRrBm2xvE95f0S+TD8RHTnRZu0E2ZbpCQ/WZmOyMcphQ2jJF8Q1CdtyfvgVRB VBx969Vm6/IuX/teo8RNsrDl0+954C3/iUHNzMdCBILQvIUoG0SU7Pwg1KD6Mx3DtYAK VMtUVKVyY+NNkcv4R2CAK1ImN/xB5w5PiLqJVfHa5MbEUuChnoJVWHwCF0WzFa7fydzN rbjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=ghNSbWmTo8n1gdPIa9xtAK+sNZgxkRBCTpcsGD32W/I=; b=GH4vzHW7lqMhZmCaYCsNOIZ3wRtBDD/QegCCAfun+HUHWTdQyUVNUBVb3RYucnM7U4 GArCbssKi9KLBR+6nviHkpMLwwAme0k3jbZKn45qdlZOUhTOxOX5Y0kbC07bGc32T6bx HE/2fvjaMtT1X0lUap5wTainJU+P/Os05IXaPJelbHkpbQApSeTdC1aMsiw4pWUy/GmN IleEqBRBXginnGcPFFcLhzhPRcRgP9dnYOHuDiscG7hD4pdnr4DeexcZtfMX9H6VHmum 3B8N5u1376S28GM0gVO3f29A5/FDSz94afoXmaDq6myvYYdhNTRZSaRAj4Oontckkbp8 dnHw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b72si8193003pfk.135.2018.04.06.07.09.44; Fri, 06 Apr 2018 07:09:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756463AbeDFOIi (ORCPT + 99 others); Fri, 6 Apr 2018 10:08:38 -0400 Received: from mx2.suse.de ([195.135.220.15]:39083 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753459AbeDFOIf (ORCPT ); Fri, 6 Apr 2018 10:08:35 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 272B0AB4B; Fri, 6 Apr 2018 14:08:33 +0000 (UTC) Date: Fri, 6 Apr 2018 14:08:32 +0000 From: "Luis R. Rodriguez" To: Lukas Wunner Cc: Peter Jones , Hans de Goede , "Luis R. Rodriguez" , Ard Biesheuvel , Greg Kroah-Hartman , Thomas Gleixner , Kalle Valo , Arend Van Spriel , Ingo Molnar , "H . Peter Anvin" , linux-kernel@vger.kernel.org, Dave Olsthoorn , x86@kernel.org, linux-efi@vger.kernel.org, Will Deacon , Andy Lutomirski , Matt Fleming , David Howells , Mimi Zohar , Josh Triplett , Matthew Garrett , One Thousand Gnomes , Linus Torvalds , dmitry.torokhov@gmail.com, mfuzzey@parkeon.com, keescook@chromium.org, nbroeking@me.com, bjorn.andersson@linaro.org, Torsten Duwe Subject: Re: [PATCH 2/2] efi: Add embedded peripheral firmware support Message-ID: <20180406140832.GF30543@wotan.suse.de> References: <78ae4d18-8964-5748-a69f-0017d0dca5f7@redhat.com> <20180404171835.xvllgcqirl3b5gd5@redhat.com> <20180405054349.GA25653@wunner.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180405054349.GA25653@wunner.de> User-Agent: Mutt/1.6.0 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 05, 2018 at 07:43:49AM +0200, Lukas Wunner wrote: > On Wed, Apr 04, 2018 at 01:18:36PM -0400, Peter Jones wrote: > > > On Tue, Apr 03, 2018 at 08:07:11PM +0200, Lukas Wunner wrote: > > > > * Add the EFI Firmware Volume Protocol to include/linux/efi.h: > > > > https://www.intel.com/content/dam/doc/reference-guide/efi-firmware-file-volume-specification.pdf > > > > > > > > * Amend arch/x86/boot/compressed/eboot.c to read the files with the > > > > GUIDs you're interested in into memory and pass the files to the > > > > kernel as setup_data payloads. > > > > To be honest, I'm a bit skeptical about the firmware volume approach. > > Tools like UEFITool[0] and uefi-firmware-parser[1] have existed for > > years, still don't seem to reliably parse firmware images I see in the > > wild, and have a fairly regular need for fixes. These are tools > > maintained by smart people who are making a real effort, and it still > > looks pretty hard to do a good job that applies across a lot of > > platforms. > > > > So I'd rather use Hans's existing patches, at least for now, and if > > someone is interested in hacking on making an efi firmware volume parser > > for the kernel, switch them to that when such a thing is ready. > > Hello? As I've written in the above-quoted e-mail the kernel should > read the files using EFI_FIRMWARE_VOLUME_PROTOCOL.ReadFile(). > > *Not* by parsing the firmware volume! > > Parsing the firmware volume is only necessary to find out the GUIDs > of the files you're looking for. You only do that *once*. How do you get the GUIDs for each driver BTW? Hans, I do believe we should *try* this approach at the very least. Why not? Otherwise it would be wise to provide a technical reason for why we'd choose one custom mechanism which would only serve a few tablets over a mechanism which could serve more devices. Luis