From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) by mx.groups.io with SMTP id smtpd.web11.11150.1616412989146748622 for ; Mon, 22 Mar 2021 04:36:29 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=C6VpuWn5; spf=pass (domain: gmx.de, ip: 212.227.15.19, mailfrom: xypron.glpk@gmx.de) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1616412973; bh=JPzHWHdHGqXxHLM1QSlvAUxHFgpd43v1nj15mrd0zwY=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date; b=C6VpuWn5mgcNsaXua2ltvrNnS4xxj7oOTEzBsZC6kYOLofX5bj071M2gGtQ8Ngm/1 OQJWmNf59gfD6eQ0z1naXpzpRJ/TAJm8R9ePbUzWZYsxDLI1yCpNbvkiQGnuekqzNC hq9VleGG7uu0kGp2r7r9tFJz7YIiZOiyuexLz+9I= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from workstation4.fritz.box ([62.143.246.89]) by mail.gmx.net (mrgmx004 [212.227.17.184]) with ESMTPSA (Nemesis) id 1Mq2j2-1m2MpT2BEo-00n8Jh; Mon, 22 Mar 2021 12:36:13 +0100 From: "Heinrich Schuchardt" To: EDK II Development Cc: Eric Jin , G Edhaya Chandran , Barton Gao , Arvin Chen , Samer El-Haj-Mahmoud , Heinrich Schuchardt Subject: [PATCH edk2-test 1/1] uefi-sct/SctPkg: IHV: type mismatch in Simple Network test Date: Mon, 22 Mar 2021 12:36:05 +0100 Message-Id: <20210322113605.43169-1-xypron.glpk@gmx.de> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 X-Provags-ID: V03:K1:KbiHUEIe1SwRApyfVxhR0p9CHX9II8p2j0DJtN07F7hqKT5kY8M AZYUj7sGeQeZT3lgAA1iTyQ2yJDI32CKNNp4Bjy2+tOPT0eZxzr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7zYt8QjCeL1kDO1Ow== Content-Transfer-Encoding: quoted-printable REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3D3257 SctPrint() requires that %x and %d refers to an UINTN parameter. SimpleNetworkBBTestFunction.c tries to print INT32 using %x, %d without converting to UINTN resulting in corrupted output like: SimpleNetworkBBTestFunction.c:891: Status - Unsupported, Filter - AAAA00000000 Mode->ReceiveFilterSetting has only 32 bit. The true value is 0. Convert the parameters to UINTN. Signed-off-by: Heinrich Schuchardt =2D-- .../SimpleNetworkBBTestFunction.c | 50 +++++++++---------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/uefi-sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/Blac= kBoxTest/SimpleNetworkBBTestFunction.c b/uefi-sct/SctPkg/TestCase/UEFI/IHV= /Protocol/SimpleNetwork/BlackBoxTest/SimpleNetworkBBTestFunction.c index ca15df6303f6..06ad3163ef6b 100644 =2D-- a/uefi-sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxT= est/SimpleNetworkBBTestFunction.c +++ b/uefi-sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxTes= t/SimpleNetworkBBTestFunction.c @@ -775,7 +775,7 @@ BBTestReceiveFilterFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->ReceiveFilterSetting + (UINTN)SnpInterface->Mode->ReceiveFilterSetting ); // Check point A. Enable Specified bit. @@ -797,7 +797,7 @@ BBTestReceiveFilterFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->ReceiveFilterSetting + (UINTN)SnpInterface->Mode->ReceiveFilterSetting ); // Check point C. Enable and Disable Specified bit together. @@ -819,7 +819,7 @@ BBTestReceiveFilterFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->ReceiveFilterSetting + (UINTN)SnpInterface->Mode->ReceiveFilterSetting ); } @@ -856,12 +856,12 @@ BBTestReceiveFilterFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->ReceiveFilterSetting, - SnpInterface->Mode->ReceiveFilterMask, - SnpInterface->Mode->MCastFilterCount, - SnpInterface->Mode->MCastFilter[0].Addr[0], - SnpInterface->Mode->MCastFilter[0].Addr[5], - SnpInterface->Mode->MCastFilter[1].Addr[0] + (UINTN)SnpInterface->Mode->ReceiveFilterSetting, + (UINTN)SnpInterface->Mode->ReceiveFilterMask, + (UINTN)SnpInterface->Mode->MCastFilterCount, + (UINTN)SnpInterface->Mode->MCastFilter[0].Addr[0], + (UINTN)SnpInterface->Mode->MCastFilter[0].Addr[5], + (UINTN)SnpInterface->Mode->MCastFilter[1].Addr[0] ); } @@ -889,13 +889,13 @@ BBTestReceiveFilterFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->ReceiveFilterSetting, - SnpInterface->Mode->ReceiveFilterMask, - SnpInterface->Mode->MCastFilterCount, - Mode.MCastFilterCount, - SnpInterface->Mode->MCastFilter[0].Addr[0], - SnpInterface->Mode->MCastFilter[0].Addr[5], - SnpInterface->Mode->MCastFilter[1].Addr[0] + (UINTN)SnpInterface->Mode->ReceiveFilterSetting, + (UINTN)SnpInterface->Mode->ReceiveFilterMask, + (UINTN)SnpInterface->Mode->MCastFilterCount, + (UINTN)Mode.MCastFilterCount, + (UINTN)SnpInterface->Mode->MCastFilter[0].Addr[0], + (UINTN)SnpInterface->Mode->MCastFilter[0].Addr[5], + (UINTN)SnpInterface->Mode->MCastFilter[1].Addr[0] ); // // Restore SNP State @@ -1358,12 +1358,12 @@ BBTestMCastIpToMacFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - MAC1.Addr[0], - MAC1.Addr[1], - MAC1.Addr[2], - MAC1.Addr[3], - MAC1.Addr[4], - MAC1.Addr[5] + (UINTN)MAC1.Addr[0], + (UINTN)MAC1.Addr[1], + (UINTN)MAC1.Addr[2], + (UINTN)MAC1.Addr[3], + (UINTN)MAC1.Addr[4], + (UINTN)MAC1.Addr[5] ); // @@ -1510,8 +1510,8 @@ BBTestNVDataFunctionTest ( __FILE__, (UINTN)__LINE__, Status, - SnpInterface->Mode->NvRamSize, - SnpInterface->Mode->NvRamAccessSize + (UINTN)SnpInterface->Mode->NvRamSize, + (UINTN)SnpInterface->Mode->NvRamAccessSize ); } @@ -1919,7 +1919,7 @@ BBTestGetStatusFunctionTest ( (UINTN)__LINE__, Status, Status1, - InterruptStatus + (UINTN)InterruptStatus ); } =2D- 2.30.2