From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 76C5221A13493 for ; Wed, 3 May 2017 23:19:01 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D193A80F8E; Thu, 4 May 2017 06:19:00 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com D193A80F8E Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=kraxel@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com D193A80F8E Received: from nilsson.home.kraxel.org (ovpn-116-101.ams2.redhat.com [10.36.116.101]) by smtp.corp.redhat.com (Postfix) with ESMTP id 331DE19E2B; Thu, 4 May 2017 06:19:00 +0000 (UTC) Received: by nilsson.home.kraxel.org (Postfix, from userid 500) id 8AA0280DDC; Thu, 4 May 2017 08:18:55 +0200 (CEST) Message-ID: <1493878735.371.8.camel@redhat.com> From: Gerd Hoffmann To: Laszlo Ersek Cc: "Kinney, Michael D" , "Fan, Jeff" , "Yao, Jiewen" , edk2-devel-01 , Paolo Bonzini Date: Thu, 04 May 2017 08:18:55 +0200 In-Reply-To: References: <1382eb04-9646-133b-9ce5-8293cb54745f@redhat.com> <1493794647.8581.144.camel@redhat.com> <159c4eae-4e13-7958-59f4-dfab4c1bf16e@redhat.com> <1493819062.8581.177.camel@redhat.com> <64591d6f-b5d9-d73d-26a5-4c157b9bd541@redhat.com> Mime-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Thu, 04 May 2017 06:19:01 +0000 (UTC) Subject: Re: SMRAM sizes on large hosts X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 May 2017 06:19:01 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, > > The problem with this is that I need the TSEG size in another module as > > well, namely PlatformPei. The dispatch order between PlatformPei and > > SmmAccessPei is unspecified (they have both TRUE for DEPEX). If > > PlatformPei gets dispatched second, I really wouldn't want to write to > > MCH_ESMRAMC again, just to query MCH_TSEGMB. (I couldn't just read > > MCH_TSEGMB because if PlatformPei were dispatched first, then MCH_TSEGM= B > > would still be unset). > >=20 > > In other words, I wouldn't like to write a register just to receive the > > information; I need the information in two places whose relative > > ordering is unspecified, and one of those already writes the register i= n > > question, genuinely. I guess I could hack it around with another dynami= c > > PCD, but that's kind of ugly. Hmm, this unspecified ordering works nicely today because tseg size is a compile time constant. If we make this dynamic we either need a pcd or must probe tseg size twice (no matter whenever this is some pci cfg space register or fw_cfg file), which is kind of ugly too ... > > If we invented a read-only, side-effect-free PCI config space register > > that gave me this value plain and simple (similarly to how a new fw_cfg > > file would do), that would be a lot cleaner for me. That makes the "probe twice" thing easier indeed. > > I think this would > > match your earlier alternative where you wrote "Alternatively we could > > add some qemu-specific register". Yes. cheers, Gerd