From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web11.96833.1670998535019567468 for ; Tue, 13 Dec 2022 22:15:35 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=SpvfQjqX; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1670998534; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=z66bcuaCuW2/sVjMC0atlyNTsXKrrqEJ0hjka6SIaBw=; b=SpvfQjqXdvpRdWunazSe1NVNXC0CIJfv8bg2lT1Uq4vccKtf7QGtcVwqq365Z43BtYrbop 36dC5n0fbodqnk9Sq9gBps6DAogF/vAej0CTesqawG5pO/0mIVg0q4geq/uNIhKmnEV7+r AhmZ5PX3R0SuZvWq7FTGd1w732PJ3wM= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-125-Ri_0sG_SOmOKaMQvhzbIIQ-1; Wed, 14 Dec 2022 01:15:32 -0500 X-MC-Unique: Ri_0sG_SOmOKaMQvhzbIIQ-1 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.rdu2.redhat.com [10.11.54.5]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 5C8A2101A52E; Wed, 14 Dec 2022 06:15:32 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.192.83]) by smtp.corp.redhat.com (Postfix) with ESMTPS id E940679A1; Wed, 14 Dec 2022 06:15:31 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 8174D1800613; Wed, 14 Dec 2022 07:15:28 +0100 (CET) Date: Wed, 14 Dec 2022 07:15:28 +0100 From: "Gerd Hoffmann" To: "Lee, Chun-Yi" Cc: devel@edk2.groups.io, Min M Xu , Jiewen Yao , Tom Lendacky , James Bottomley , Erdem Aktas , "Lee, Chun-Yi" Subject: Re: [PATCH] OvmfPkg/PlatformInitLib: Fix integrity checking failed of NvVarStore in some cases Message-ID: <20221214061528.zi627mkk4mumtdoo@sirius.home.kraxel.org> References: <20221213155502.29548-1-jlee@suse.com> MIME-Version: 1.0 In-Reply-To: <20221213155502.29548-1-jlee@suse.com> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.5 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, > When the variable store has those variables, then system booting/rebooting will > hangs in a ASSERT: > > NvVarStore Variable header State was invalid. > ASSERT > /mnt/working/source_code-git/edk2/OvmfPkg/Library/PlatformInitLib/Platform.c(819): > ((BOOLEAN)(0==1)) I'm wondering how you manage to trigger this assert? > Adding more log to UpdateVariable() and PlatformValidateNvVarStore(), we > can see there have some variables have 0x3C or 0x3D state in store. > e.g. PlatformValidateNvVarStore() validates the varstore in ROM before copying it to RAM. The normal UpdateVariable() cycle changes the copy in RAM ... take care, Gerd