Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F3063C433EF for ; Thu, 4 Nov 2021 03:16:39 +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 7658060F56 for ; Thu, 4 Nov 2021 03:16:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 7658060F56 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 0863883693; Thu, 4 Nov 2021 04:16:27 +0100 (CET) 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="F5RIYAX0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 22BA88364B; Thu, 4 Nov 2021 04:16:21 +0100 (CET) Received: from mail-ot1-x331.google.com (mail-ot1-x331.google.com [IPv6:2607:f8b0:4864:20::331]) (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 8F3898364D for ; Thu, 4 Nov 2021 04:10:09 +0100 (CET) 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@chromium.org Received: by mail-ot1-x331.google.com with SMTP id g91-20020a9d12e4000000b0055ae68cfc3dso3700408otg.9 for ; Wed, 03 Nov 2021 20:10:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=EHV1ICLJ9Js9AeLMupaqoMWlmIQ3J+3JZqnlx7xYNcE=; b=F5RIYAX0OkJ4OV2bFYgs1KpDhAxFRWKQACLcCwoHC3BBUgqdwzggq7aPZo2xaXdZeR +3OygSCtEpTtuuaL8o1nL1s/YEUoEA5N21J7cezmwB4GRIm48WbHC0yIsTVEZtgazkz1 YD+c08V6/KkO/3OL1XaOuGlO0OVGTrBMGZEbM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=EHV1ICLJ9Js9AeLMupaqoMWlmIQ3J+3JZqnlx7xYNcE=; b=A+VvIClhHwkys+CFKu7f8ygdrEHrSMWD7IwnN368Crx+9O8B+Hf0VZMT9Gs9X7itWm w817vpw8ckTjjzdbMhR7pq0VgMHg+BcmxJWLpy2W216LGCPbLvQ3a32v720tG5VjcBm5 DsTRQ2gGHoKI6ueiCFCY2dYRmXgtjQkirqeIAk+X8wooGdyFvAhx/mnIWq5GP+pU6ac1 NDlulxXTMcA1uW95/yn8v4D6h+2qwYG2mO3xZqWUb4vBXm4IDT5SjySy1UhbyBgoXCKF 51D+BdxqYvOo+PKwL4ZjmEulDhx9C/iplIVvABsV4n9Z0tOnhsUY7C8zNzexOGybdDnN vmNg== X-Gm-Message-State: AOAM531Yst1vu9XJM/3+zDlLsypevTNYeq4JIfo3Te+nLpV2MVYsaRbD ruLTMbyhaQbkilgqGR+DjnbHYbHSOgzQ1g== X-Google-Smtp-Source: ABdhPJzaNBNfyoDdsGXTeSkxhzTu8/1yBi3o+03ZZHzm4zSNVe7n/QFWiCw0eQTvLZVEWVz1d/T1MA== X-Received: by 2002:a9d:4b12:: with SMTP id q18mr6676286otf.364.1635995408085; Wed, 03 Nov 2021 20:10:08 -0700 (PDT) Received: from kiwi.bld.corp.google.com (c-67-190-101-114.hsd1.co.comcast.net. [67.190.101.114]) by smtp.gmail.com with ESMTPSA id j25sm1050197oos.23.2021.11.03.20.10.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 20:10:07 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Ilias Apalodimas , Tom Rini , Christian Melki , Heinrich Schuchardt , Bin Meng , Simon Glass , Alexander Graf Subject: [PATCH v4 23/34] efi: Add comments to struct efi_priv Date: Wed, 3 Nov 2021 21:09:25 -0600 Message-Id: <20211104030936.2446706-13-sjg@chromium.org> X-Mailer: git-send-email 2.34.0.rc0.344.g81b53c2807-goog In-Reply-To: <20211104030936.2446706-1-sjg@chromium.org> References: <20211104030936.2446706-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 This structure is uncommented. Fix it. Signed-off-by: Simon Glass --- (no changes since v3) Changes in v3: - Drop comments that confuse sphinx - Move device_path path change to its own patch include/efi.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/include/efi.h b/include/efi.h index 77e599c256e..6622a733e6e 100644 --- a/include/efi.h +++ b/include/efi.h @@ -400,14 +400,37 @@ static inline struct efi_mem_desc *efi_get_next_mem_desc( return (struct efi_mem_desc *)((ulong)desc + map->desc_size); } +/** + * struct efi_priv - Information about the environment provided by EFI + * + * @parent_image: image passed into the EFI app or stub + * @sys_table: Pointer to system table + * @boot: Pointer to boot-services table + * @run: Pointer to runtime-services table + * + * @use_pool_for_malloc: true if all allocation should go through the EFI 'pool' + * methods allocate_pool() and free_pool(); false to use 'pages' methods + * allocate_pages() and free_pages() + * @ram_base: Base address of RAM (size CONFIG_EFI_RAM_SIZE) + * @image_data_type: Type of the loaded image (e.g. EFI_LOADER_CODE) + * + * @info: Header of the info list, holding info collected by the stub and passed + * to U-Boot + * @info_size: Size of the info list, in bytes from @info + * @next_hdr: Pointer to where to put the next header when adding to the list + */ struct efi_priv { efi_handle_t parent_image; struct efi_system_table *sys_table; struct efi_boot_services *boot; struct efi_runtime_services *run; + + /* app: */ bool use_pool_for_malloc; unsigned long ram_base; unsigned int image_data_type; + + /* stub: */ struct efi_info_hdr *info; unsigned int info_size; void *next_hdr; -- 2.34.0.rc0.344.g81b53c2807-goog