From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-x22c.google.com (mail-wm0-x22c.google.com [IPv6:2a00:1450:400c:c09::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 3D9E581FF4 for ; Mon, 5 Dec 2016 02:30:29 -0800 (PST) Received: by mail-wm0-x22c.google.com with SMTP id a197so89876168wmd.0 for ; Mon, 05 Dec 2016 02:30:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=a5QCA3HgP01QgaVhVdqlnx2hDJLTEHIUnkvz0PsgrRs=; b=HNdHSQwh1di/e7ffKgTn1QcdJBRMnj4PwbVwKfUwxcFGslnC8++6lsPM5lOF0u9zDG skWy8fvja96QNW+HWCZZmo3/5m0RURYZopt/icIQHpCv/pBrLM+jcEvoHIvFf4uLb68z 66nYdRyG8jkPgzwwSAN3kMqt8a7nWzBuDWSiE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=a5QCA3HgP01QgaVhVdqlnx2hDJLTEHIUnkvz0PsgrRs=; b=PORFgiER9LT13If9my9Mz5GeL6QOzPRBRjQ/1YKwXctfw+kOSLhcNaIl+cy5LJRAO0 08JRUQfG6ZiNXtYTaX0OhLir//KbnwbukDhA+9HchKQYq6oxiIRNBVDoq52bpwA7UhX8 oo9LXtkTiti9NtcEHbfS44l6mfoQxNzN1u8vdTwetc4dkFRKVJhgVPHx36Zo8dBV0fnb dbLzIr+LjzsI0XPNxnaJfKql9OQzMqdSreXrvarunbQjW3Xg+k2neAYAb7ZifwkMvqV8 z3QqQUqYqEWKL8zO14op7oOLpVliBVRKbmjyxkirr9pQwSdx1JnLaWrjQvc4+o326NtO RUOg== X-Gm-Message-State: AKaTC03b/oMDhAzkow40uOxVYuwh5V1yg1D4l2e/ejr21QmQ0OJTJ/0K0oFVZSnYfNpt3hvH X-Received: by 10.28.22.193 with SMTP id 184mr8824719wmw.100.1480933827487; Mon, 05 Dec 2016 02:30:27 -0800 (PST) Received: from bivouac.eciton.net (bivouac.eciton.net. [2a00:1098:0:86:1000:23:0:2]) by smtp.gmail.com with ESMTPSA id bf2sm19599634wjc.48.2016.12.05.02.30.26 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 05 Dec 2016 02:30:26 -0800 (PST) Date: Mon, 5 Dec 2016 10:30:25 +0000 From: Leif Lindholm To: Laszlo Ersek Cc: edk2-devel-01 , Ard Biesheuvel , Jordan Justen Message-ID: <20161205103025.GG27069@bivouac.eciton.net> References: <20161202202059.5061-1-lersek@redhat.com> <20161202202059.5061-5-lersek@redhat.com> MIME-Version: 1.0 In-Reply-To: <20161202202059.5061-5-lersek@redhat.com> User-Agent: Mutt/1.5.23 (2014-03-12) Subject: Re: [PATCH v2 4/6] OvmfPkg/QemuFwCfgLib: extend lib class header with more definitions X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 05 Dec 2016 10:30:29 -0000 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Dec 02, 2016 at 09:20:57PM +0100, Laszlo Ersek wrote: > The last patch consists purely of code movement; going forward, we should > use a few more symbolic constants. > > Cc: Ard Biesheuvel > Cc: Jordan Justen > Cc: Leif Lindholm > Contributed-under: TianoCore Contribution Agreement 1.0 > Signed-off-by: Laszlo Ersek Reviewed-by: Leif Lindholm > --- > > Notes: > v2: > - split these out to a separate patch > > OvmfPkg/Include/Library/QemuFwCfgLib.h | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/OvmfPkg/Include/Library/QemuFwCfgLib.h b/OvmfPkg/Include/Library/QemuFwCfgLib.h > index 40a07456c530..3e017d53a97e 100644 > --- a/OvmfPkg/Include/Library/QemuFwCfgLib.h > +++ b/OvmfPkg/Include/Library/QemuFwCfgLib.h > @@ -24,12 +24,20 @@ > #define QEMU_FW_CFG_FNAME_SIZE 56 > > // > +// If the following bit is set in the UINT32 fw_cfg revision / feature bitmap > +// -- read from key 0x0001 with the basic IO Port or MMIO method --, then the > +// DMA interface is available. > +// > +#define FW_CFG_F_DMA BIT1 > + > +// > // Macros for the FW_CFG_DMA_ACCESS.Control bitmap (in native encoding). > // > #define FW_CFG_DMA_CTL_ERROR BIT0 > #define FW_CFG_DMA_CTL_READ BIT1 > #define FW_CFG_DMA_CTL_SKIP BIT2 > #define FW_CFG_DMA_CTL_SELECT BIT3 > +#define FW_CFG_DMA_CTL_WRITE BIT4 > > typedef enum { > QemuFwCfgItemSignature = 0x0000, > -- > 2.9.2 > >