From: "Eric Jin" <eric.jin@intel.com>
To: "Liu, XianhuiX" <xianhuix.liu@intel.com>,
"devel@edk2.groups.io" <devel@edk2.groups.io>
Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>,
Supreeth Venkatesh <supreeth.venkatesh@arm.com>
Subject: Re: [edk2-test][Patch] uefi-sct/SctPkg: Sync SNP ReceiveFilters change to IHV
Date: Fri, 11 Oct 2019 14:45:43 +0000 [thread overview]
Message-ID: <DA72DC7456565B47808A57108259571F6382D43F@SHSMSX103.ccr.corp.intel.com> (raw)
In-Reply-To: <20191011023747.10472-1-xianhuix.liu@intel.com>
Reviewed-by: Eric Jin <eric.jin@intel.com>
> -----Original Message-----
> From: Liu, XianhuiX <xianhuix.liu@intel.com>
> Sent: Friday, October 11, 2019 10:38 AM
> To: devel@edk2.groups.io
> Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>; Supreeth Venkatesh
> <supreeth.venkatesh@arm.com>; Jin, Eric <eric.jin@intel.com>; Liu,
> XianhuiX <xianhuix.liu@intel.com>
> Subject: [edk2-test][Patch] uefi-sct/SctPkg: Sync SNP ReceiveFilters change
> to IHV
>
> REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2197
> sync commit 3d98de052fcd47f187190802e6201ac6aaabfda7
> on file EFI/Protocol/SimpleNetwork/BlackBoxTest
> /SimpleNetworkBBTestConformance.c to IHV
>
> Cc: Heinrich Schuchardt <xypron.glpk@gmx.de>
> Cc: Supreeth Venkatesh <supreeth.venkatesh@arm.com>
> Cc: Eric Jin <eric.jin@intel.com>
>
> Signed-off-by: xianhui liu <xianhuix.liu@intel.com>
> ---
> .../BlackBoxTest/SimpleNetworkBBTestConformance.c | 223
> +++++++++++++--------
> 1 file changed, 138 insertions(+), 85 deletions(-)
>
> diff --git a/uefi-
> sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxTest/Simpl
> eNetworkBBTestConformance.c b/uefi-
> sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxTest/Simpl
> eNetworkBBTestConformance.c
> index c758f560..682076ea 100644
> --- a/uefi-
> sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxTest/Simpl
> eNetworkBBTestConformance.c
> +++ b/uefi-
> sct/SctPkg/TestCase/UEFI/IHV/Protocol/SimpleNetwork/BlackBoxT
> +++ est/SimpleNetworkBBTestConformance.c
> @@ -626,22 +626,31 @@ BBTestReceiveFilterConformanceTest (
> // Call ReceiveFilters() function if network interface not start.
> //
> Status = SnpInterface->ReceiveFilters (SnpInterface, 0, 0, FALSE, 0, NULL);
> - if ((Status == EFI_NOT_STARTED) && (SnpInterface->Mode->State ==
> EfiSimpleNetworkStopped)) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> - }
> + if ((Status == EFI_NOT_STARTED) && (SnpInterface->Mode->State ==
> EfiSimpleNetworkStopped)) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
>
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid006,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() when network interface not start.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid006,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() when network interface not start.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> + }
>
> //
> // Assertion Point 5.6.2.2
> @@ -653,22 +662,31 @@ BBTestReceiveFilterConformanceTest (
> }
>
> Status = SnpInterface->ReceiveFilters (SnpInterface, 0, 0, FALSE, 0, NULL);
> - if (Status == EFI_DEVICE_ERROR) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> - }
> + if (Status == EFI_DEVICE_ERROR) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
>
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid007,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() when network interface not initialized.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid007,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() when network interface not initialized.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> + }
>
> //
> // Assertion Point 5.6.2.3
> @@ -683,22 +701,31 @@ BBTestReceiveFilterConformanceTest (
> // Call ReceiveFilters with invalide Enable
> //
> Status = SnpInterface->ReceiveFilters (SnpInterface, ~(SnpInterface-
> >Mode->ReceiveFilterMask), 0, FALSE, 0, NULL);
> - if (Status == EFI_INVALID_PARAMETER) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> - }
> + if (Status == EFI_INVALID_PARAMETER) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
>
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid008,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid Enable.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid008,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid Enable.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> + }
>
> //
> // Call ReceiveFilters with invalide MCastFilterCnt @@ -713,59 +740,85 @@
> BBTestReceiveFilterConformanceTest (
> MAC.Addr[5] = 0x02;
>
> Status = SnpInterface->ReceiveFilters (SnpInterface,
> EFI_SIMPLE_NETWORK_RECEIVE_MULTICAST, 0, FALSE, SnpInterface-
> >Mode->MaxMCastFilterCount + 1, &MAC);
> - if (Status == EFI_INVALID_PARAMETER) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> + if (Status == EFI_INVALID_PARAMETER) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
> +
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid009,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid MCastFilterCnt is greater than Snp->Mode-
> >MaxMCastFilterCount.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> }
>
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid009,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid MCastFilterCnt is greater than Snp->Mode-
> >MaxMCastFilterCount.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> -
> Status = SnpInterface->ReceiveFilters (SnpInterface,
> EFI_SIMPLE_NETWORK_RECEIVE_MULTICAST, 0, FALSE, 0, &MAC);
> - if (Status == EFI_INVALID_PARAMETER) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> + if (Status == EFI_INVALID_PARAMETER) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
> +
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid043,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid MCastFilterCnt is 0.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> }
>
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid043,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with invalid MCastFilterCnt is 0.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> -
> Status = SnpInterface->ReceiveFilters (SnpInterface,
> EFI_SIMPLE_NETWORK_RECEIVE_MULTICAST, 0, FALSE, 1, NULL);
> - if (Status == EFI_INVALID_PARAMETER) {
> - AssertionType = EFI_TEST_ASSERTION_PASSED;
> + if (Status == EFI_UNSUPPORTED) {
> + StandardLib->RecordMessage(
> + StandardLib,
> + EFI_VERBOSE_LEVEL_QUIET,
> + L"ReceiveFilters isn't supported, Status - %r\n",
> + Status
> + );
> } else {
> - AssertionType = EFI_TEST_ASSERTION_FAILED;
> + if (Status == EFI_INVALID_PARAMETER) {
> + AssertionType = EFI_TEST_ASSERTION_PASSED;
> + } else {
> + AssertionType = EFI_TEST_ASSERTION_FAILED;
> + }
> +
> + StandardLib->RecordAssertion (
> + StandardLib,
> + AssertionType,
> + gSimpleNetworkBBTestConformanceAssertionGuid010,
> + L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with MCastFilterCnt not match MCastFilter.",
> + L"%a:%d:Status - %r",
> + __FILE__,
> + (UINTN)__LINE__,
> + Status
> + );
> }
> -
> - StandardLib->RecordAssertion (
> - StandardLib,
> - AssertionType,
> - gSimpleNetworkBBTestConformanceAssertionGuid010,
> - L"EFI_SIMPLE_NETWORK_PROTOCOL.ReceiveFilters - Invoke
> ReceiveFilters() with MCastFilterCnt not match MCastFilter.",
> - L"%a:%d:Status - %r",
> - __FILE__,
> - (UINTN)__LINE__,
> - Status
> - );
> -
> }
>
> //
> --
> 2.14.1.windows.1
next prev parent reply other threads:[~2019-10-11 14:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-11 2:37 [edk2-test][Patch] uefi-sct/SctPkg: Sync SNP ReceiveFilters change to IHV xianhui liu
2019-10-11 14:45 ` Eric Jin [this message]
[not found] ` <15CC9EF63907401C.5802@groups.io>
2019-10-12 8:19 ` [edk2-devel] " Eric Jin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=DA72DC7456565B47808A57108259571F6382D43F@SHSMSX103.ccr.corp.intel.com \
--to=devel@edk2.groups.io \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox