From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.1 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 1C789C433EF for ; Thu, 9 Sep 2021 08:59:04 +0000 (UTC) Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 9A49A61051 for ; Thu, 9 Sep 2021 08:59:03 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 9A49A61051 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id CB209832AA; Thu, 9 Sep 2021 10:58:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="P1Pt4t4t"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C79168323E; Thu, 9 Sep 2021 10:57:54 +0200 (CEST) Received: from mail-wr1-x434.google.com (mail-wr1-x434.google.com [IPv6:2a00:1450:4864:20::434]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 298168319C for ; Thu, 9 Sep 2021 10:57:41 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@google.com Received: by mail-wr1-x434.google.com with SMTP id m9so1448662wrb.1 for ; Thu, 09 Sep 2021 01:57:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=VzvOHIbROzIR5jkTiTAgoFysqoiKA9xBhX7zbhGczrc=; b=P1Pt4t4tdMh01p3zFBmOHByCIz5dol67L/GnUUhd/FSIRHQM4bkJWxsGEQEbHsS0DN xsvrWW9Jv0XplEUY41g9uNouhYwbzpJgVCtxfD7kMreclmDmlcKGJqCGN2/nPdwMtID0 k7b2TWB3eUlL7WwjtyDLtVPzxoIHDJqAH9rxs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=VzvOHIbROzIR5jkTiTAgoFysqoiKA9xBhX7zbhGczrc=; b=BR8Hp08+B+gXwxqdxzMLFIIqLRyKCmRCj9f2J/mJQsLqTIg8Yh5koLc6WezWx100zm Jc2eFRpB75eMp0i0W2aXFkeLC5j+PZ70AKUtLP6Lxsl4/IdPKew0tQGoyMkSnUGhjF4t dPUC5v9kqpX38Jj0wOfHRlRUGNxxtd5IxnxLodYhWSCfYKGj9gDufBJ/9LNPJyyreCvE Kyizk9DkceG5MvqkEBGuGNdlxDR14NK0Fk+H2wqVJSyUtG3IiJO5/yncEIwZMEllkCQA tg+gOnW/jH403v/RMWWwvV6P07dPvGBEv5KXGe0l46n9EYgRDowLa+vgLZwXV9MWDiKL JHyA== X-Gm-Message-State: AOAM530kwtPje63eAmcYOQr59/g0pOXakfwpn1H5knSRdqIGNRnVs0nZ wQek8exmLQf5iHuDG8kB2SstkZSfuZrOnet7tcgXSA== X-Google-Smtp-Source: ABdhPJw+JKze/CwpJwITptWxAPT8IaeMCc2mODlZvLNr6ZFaACZIcQXPDGuvFrJzawq4gSVOPAlZoEKXLDOdCvlYTLU= X-Received: by 2002:a5d:4591:: with SMTP id p17mr2169345wrq.59.1631177860298; Thu, 09 Sep 2021 01:57:40 -0700 (PDT) MIME-Version: 1.0 References: <20210908133405.696481-1-sjg@chromium.org> <20210908073355.13.I9b48fe5f6b8c61348f16a1b5df114282240238c0@changeid> <21126ea8-9842-49fd-c01d-6408b5a28218@gmx.de> In-Reply-To: <21126ea8-9842-49fd-c01d-6408b5a28218@gmx.de> From: Simon Glass Date: Thu, 9 Sep 2021 02:57:26 -0600 Message-ID: Subject: Re: [PATCH 13/35] efi: Add a media/block driver for EFI block devices To: Heinrich Schuchardt Cc: Ilias Apalodimas , Bin Meng , Tom Rini , Christian Melki , Alexander Graf , U-Boot Mailing List Content-Type: text/plain; charset="UTF-8" X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.2 at phobos.denx.de X-Virus-Status: Clean Hi Heinrich, On Wed, 8 Sept 2021 at 12:04, Heinrich Schuchardt wrote: > > > > On 9/8/21 3:33 PM, Simon Glass wrote: > > Add a block driver which handles read/write for EFI block devices. This > > driver actually already exists ('efi_block') but is not really suitable > > for use as a real U-Boot driver: > > > > - The operations do not provide a udevice > > efi_bl_bind() creates a udevice by calling blk_create_device() when an > EFI application calls ConnectController() for a handle with an > EFI_BLOCK_IO_PROTOCOL. > > Please, explain in some detail what you think is wrong with the existing > code. See below: > > > - The code is designed for running as part of EFI loader, so uses > > EFI_PRINT() and EFI_CALL(). > > - It creates block devices for all the partitions too, which is not > > somthing we want to support in this way > > - The bind method probes the device, which is not permitted > > - It uses 'EFI' as its parent device > > > > The new driver is more 'normal', just requiring its platform data be set > > up in advance. > > > > Signed-off-by: Simon Glass > > Please, separate this series in two. One for U-Boot on EFI and one for > U-Boot's UEFI implementation. Again I'm not sure what you mean here. Please point to something you don't want in this series, which is focussed on the app. > > Best regardss > > Heinrich > > > --- > > > > drivers/block/Kconfig | 10 ++++ > > drivers/block/Makefile | 1 + > > drivers/block/efi_blk.c | 115 ++++++++++++++++++++++++++++++++++++++++ > > include/efi.h | 11 ++++ > > 4 files changed, 137 insertions(+) > > create mode 100644 drivers/block/efi_blk.c > > Regards, Simon