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.web10.101786.1679665323482104944 for ; Fri, 24 Mar 2023 06:42:03 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=biIR1SBi; 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=1679665322; 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: content-transfer-encoding:content-transfer-encoding; bh=h3RdeaisfCnbaXjNbBRU0Z3+Ij/+pIw5vyGq0tDl3Is=; b=biIR1SBi918k+D68DTIr3d9HmQ5SM/5l9VUNrerIRvBtrFk42VEZu7PX9Jvzbaf+qnUj0z OQq6TsFHqiKs9yMqhRgCHppBHOkfOCuN7gCVjcGs+xd8gwxaK4y/B62bAg3McS8BSTXZF6 5Oux+dGTGMoxltj4InOF7bVkOT+lGnQ= Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-389--Du_dJezO_-j0apy-FfKXg-1; Fri, 24 Mar 2023 09:41:59 -0400 X-MC-Unique: -Du_dJezO_-j0apy-FfKXg-1 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B78F238149CA; Fri, 24 Mar 2023 13:41:58 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.193.62]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7847D492C3E; Fri, 24 Mar 2023 13:41:58 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 22D151800084; Fri, 24 Mar 2023 14:41:57 +0100 (CET) From: "Gerd Hoffmann" To: devel@edk2.groups.io Cc: Eric Dong , Gerd Hoffmann , Oliver Steffen , Rahul Kumar , Ray Ni , Pawel Polawski , Laszlo Ersek Subject: [PATCH 1/1] UefiCpuPkg/PiSmmCpuDxeSmm: fix format string Date: Fri, 24 Mar 2023 14:41:57 +0100 Message-Id: <20230324134157.118321-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true BufferPages is UINTN, so we need "%Lu" when printing it. Fixes: 4f441d024bee ("UefiCpuPkg/PiSmmCpuDxeSmm: fix error handling") Reported-by: Laszlo Ersek Signed-off-by: Gerd Hoffmann --- UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c index cf69161caa4b..08663b1b1ab4 100644 --- a/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c +++ b/UefiCpuPkg/PiSmmCpuDxeSmm/PiSmmCpuDxeSmm.c @@ -880,7 +880,7 @@ PiCpuSmmEntry ( BufferPages = EFI_SIZE_TO_PAGES (SIZE_32KB + TileSize * (mMaxNumberOfCpus - 1)); Buffer = AllocateAlignedCodePages (BufferPages, SIZE_4KB); if (Buffer == NULL) { - DEBUG ((DEBUG_ERROR, "Failed to allocate %d pages.\n", BufferPages)); + DEBUG ((DEBUG_ERROR, "Failed to allocate %Lu pages.\n", BufferPages)); CpuDeadLoop (); return EFI_OUT_OF_RESOURCES; } -- 2.39.2