From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail05.groups.io (mail05.groups.io [45.79.224.7]) by spool.mail.gandi.net (Postfix) with ESMTPS id E6C4BAC1014 for ; Thu, 25 Apr 2024 08:11:30 +0000 (UTC) DKIM-Signature: a=rsa-sha256; bh=Nt7QKoqI57Y1qSKITRwejpoiXMfRKKwk+B57RzvOAMI=; c=relaxed/simple; d=groups.io; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject:To:Cc:Precedence:List-Subscribe:List-Help:Sender:List-Id:Mailing-List:Delivered-To:Resent-Date:Resent-From:Reply-To:List-Unsubscribe-Post:List-Unsubscribe:Content-Type; s=20240206; t=1714032689; v=1; b=zgZ+vB2uzzrotb7X9OqF//GREjr7kyC2QPdFvQciFVxIveM3AA8lNmfyjwLUKNSXt0WUV8xL vnN/cwkzoLvuPqCzX2b9OV47m47le8FTZVUXfLP/3dNNhbRVgPnTtg0tDUgC0tgUBYRBBPMMJRq S/mCAv+CvQgp+Rj34iBJsyxjZGeBG/m515FmWCwey36T8qlary9wDRmYJD8sx2xOjPmxJ5xyZFO +7fdAWRgpwDdWAmNs8EUeKL7MBEqJyZPWzu7DFnP5uYgEXrKaEbvFv0jeBc8L3N3IhezFbhhrov COLOGP7xooPGGFUSH9kwO45bYw25LNgWXYg9IhiZYAimg== X-Received: by 127.0.0.2 with SMTP id ctMfYY7687511xenIZjRJ1KJ; Thu, 25 Apr 2024 01:11:29 -0700 X-Received: from sin.source.kernel.org (sin.source.kernel.org [145.40.73.55]) by mx.groups.io with SMTP id smtpd.web11.11916.1714032688570943763 for ; Thu, 25 Apr 2024 01:11:28 -0700 X-Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sin.source.kernel.org (Postfix) with ESMTP id 7801ACE177F for ; Thu, 25 Apr 2024 08:11:25 +0000 (UTC) X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9D4E3C2BBFC for ; Thu, 25 Apr 2024 08:11:24 +0000 (UTC) X-Received: by mail-lf1-f41.google.com with SMTP id 2adb3069b0e04-5196c755e82so822289e87.0 for ; Thu, 25 Apr 2024 01:11:24 -0700 (PDT) X-Gm-Message-State: PhgmZTgIBV28RYFjEJ4z56H9x7686176AA= X-Google-Smtp-Source: AGHT+IEoS5xZmDnZbRxVMmLGNjjZzBT6YNZ5mijqN49tiP0AitLEZ7E3DnIb0QvwNiV+JWrAD4GTeN5BDul7qDzYyBI= X-Received: by 2002:a05:6512:220b:b0:51c:17d5:b572 with SMTP id h11-20020a056512220b00b0051c17d5b572mr2290458lfu.6.1714032683023; Thu, 25 Apr 2024 01:11:23 -0700 (PDT) MIME-Version: 1.0 References: <20240425041728.1385891-1-lichao@loongson.cn> <20240425041816.1386268-1-lichao@loongson.cn> <5boqyu5erbhftofbobyknwg4i4ngbm4igybx554whbtqnn4hh6@3zl5bgcskxkj> In-Reply-To: From: "Ard Biesheuvel" Date: Thu, 25 Apr 2024 10:11:11 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [edk2-devel] [PATCH v2 2/7] OvmfPkg: Add the way of HOBs in QemuFwCfgLibMmio To: Chao Li Cc: devel@edk2.groups.io, kraxel@redhat.com, Ard Biesheuvel , Jiewen Yao , Leif Lindholm , Sami Mujawar , Sunil V L , Andrei Warkentin Precedence: Bulk List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Resent-Date: Thu, 25 Apr 2024 01:11:28 -0700 Resent-From: ardb@kernel.org Reply-To: devel@edk2.groups.io,ardb@kernel.org List-Unsubscribe-Post: List-Unsubscribe=One-Click List-Unsubscribe: Content-Type: text/plain; charset="UTF-8" X-GND-Status: LEGIT Authentication-Results: spool.mail.gandi.net; dkim=pass header.d=groups.io header.s=20240206 header.b=zgZ+vB2u; dmarc=fail reason="SPF not aligned (relaxed), DKIM not aligned (relaxed)" header.from=kernel.org (policy=none); spf=pass (spool.mail.gandi.net: domain of bounce@groups.io designates 45.79.224.7 as permitted sender) smtp.mailfrom=bounce@groups.io On Thu, 25 Apr 2024 at 10:10, Chao Li wrote: > > Hi Gerd, > > > Thanks, > Chao > On 2024/4/25 15:40, Gerd Hoffmann wrote: > > Hi, > > +EFI_GUID mFwCfgSelectorAddressGuid = FW_CONFIG_SELECTOR_ADDRESS_HOB_GUID; > +EFI_GUID mFwCfgDataAddressGuid = FW_CONFIG_DATA_ADDRESS_HOB_GUID; > +EFI_GUID mFwCfgDmaAddressGuid = FW_CONFIG_DMA_ADDRESS_HOB_GUID; > > Oh. I assumed that would be obvious (because it's common practice for > HOBs), but I was thinking about a single HOB containing a struct with > all three values instead of a separate HOB for each value. > > If uses a single HOB, it must define a structure in this library, and it may be more complicated to build and parse the HOB. > Please use a single HOB, and avoid global variables in PEI (PEI modules may execute in place from read-only NOR flash, so global variables are not allowed in PEI) -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#118280): https://edk2.groups.io/g/devel/message/118280 Mute This Topic: https://groups.io/mt/105724969/7686176 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io] -=-=-=-=-=-=-=-=-=-=-=-