public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* [Patch 0/2] Ignore duplicated DNS address check
@ 2017-02-23  5:30 Jiaxin Wu
  2017-02-23  5:30 ` [Patch 1/2] MdeModulePkg/Ip4Dxe: " Jiaxin Wu
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Jiaxin Wu @ 2017-02-23  5:30 UTC (permalink / raw)
  To: edk2-devel
  Cc: Hegde Nagaraj P, Subramanian Sriram, Ye Ting, Fu Siyuan,
	Wu Jiaxin

Having duplicated DNS server IPs specified is not an ideal
configuration, but not an error condition. This patch is to
remove the duplicated DNS address check to allow the same DNS
address setting in SetData().

Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>

Jiaxin Wu (2):
  MdeModulePkg/Ip4Dxe: Ignore duplicated DNS address check
  NetworkPkg/Ip6Dxe: Ignore duplicated DNS address check

 MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c | 10 ----------
 NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c                      | 10 ----------
 2 files changed, 20 deletions(-)

-- 
1.9.5.msysgit.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Patch 1/2] MdeModulePkg/Ip4Dxe: Ignore duplicated DNS address check
  2017-02-23  5:30 [Patch 0/2] Ignore duplicated DNS address check Jiaxin Wu
@ 2017-02-23  5:30 ` Jiaxin Wu
  2017-02-23  5:30 ` [Patch 2/2] NetworkPkg/Ip6Dxe: " Jiaxin Wu
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Jiaxin Wu @ 2017-02-23  5:30 UTC (permalink / raw)
  To: edk2-devel
  Cc: Hegde Nagaraj P, Subramanian Sriram, Ye Ting, Fu Siyuan,
	Wu Jiaxin

Having duplicated DNS server IPs specified is not an ideal
configuration, but not an error condition. This patch is to
remove the duplicated DNS address check to allow the same DNS
address setting in SetData().

Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>
---
 MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c b/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c
index a6a3da8..0b56d76 100644
--- a/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c
+++ b/MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c
@@ -703,11 +703,10 @@ Ip4Config2SetDnsServerWorker (
   IN VOID                    *Data
   )
 {
   UINTN                 OldIndex;
   UINTN                 NewIndex;
-  UINTN                 Index1;
   EFI_IPv4_ADDRESS      *OldDns;
   EFI_IPv4_ADDRESS      *NewDns;
   UINTN                 OldDnsCount;
   UINTN                 NewDnsCount;
   IP4_CONFIG2_DATA_ITEM *Item;
@@ -745,19 +744,10 @@ Ip4Config2SetDnsServerWorker (
         FreePool (Tmp);
       }
       return EFI_INVALID_PARAMETER;
     }
 
-    for (Index1 = NewIndex + 1; Index1 < NewDnsCount; Index1++) {
-      if (EFI_IP4_EQUAL (NewDns + NewIndex, NewDns + Index1)) {
-        if (Tmp != NULL) {
-          FreePool (Tmp);
-        }
-        return EFI_INVALID_PARAMETER;
-      }
-    }
-
     if (OneAdded) {
       //
       // If any address in the new setting is not in the old settings, skip the
       // comparision below.
       //
-- 
1.9.5.msysgit.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [Patch 2/2] NetworkPkg/Ip6Dxe: Ignore duplicated DNS address check
  2017-02-23  5:30 [Patch 0/2] Ignore duplicated DNS address check Jiaxin Wu
  2017-02-23  5:30 ` [Patch 1/2] MdeModulePkg/Ip4Dxe: " Jiaxin Wu
@ 2017-02-23  5:30 ` Jiaxin Wu
  2017-02-23 10:25 ` [Patch 0/2] " Subramanian, Sriram
  2017-02-27  6:37 ` Hegde, Nagaraj P
  3 siblings, 0 replies; 5+ messages in thread
From: Jiaxin Wu @ 2017-02-23  5:30 UTC (permalink / raw)
  To: edk2-devel
  Cc: Hegde Nagaraj P, Subramanian Sriram, Ye Ting, Fu Siyuan,
	Wu Jiaxin

Having duplicated DNS server IPs specified is not an ideal
configuration, but not an error condition. This patch is to
remove the duplicated DNS address check to allow the same DNS
address setting in SetData().

Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>
---
 NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c | 10 ----------
 1 file changed, 10 deletions(-)

diff --git a/NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c b/NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c
index e309b69..67037bb 100644
--- a/NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c
+++ b/NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c
@@ -1325,11 +1325,10 @@ Ip6ConfigSetDnsServer (
   IN VOID                 *Data
   )
 {
   UINTN                 OldIndex;
   UINTN                 NewIndex;
-  UINTN                 Index1;
   EFI_IPv6_ADDRESS      *OldDns;
   EFI_IPv6_ADDRESS      *NewDns;
   UINTN                 OldDnsCount;
   UINTN                 NewDnsCount;
   IP6_CONFIG_DATA_ITEM  *Item;
@@ -1370,19 +1369,10 @@ Ip6ConfigSetDnsServer (
         FreePool (Tmp);
       }
       return EFI_INVALID_PARAMETER;
     }
 
-    for (Index1 = NewIndex + 1; Index1 < NewDnsCount; Index1++) {
-      if (EFI_IP6_EQUAL (NewDns + NewIndex, NewDns + Index1)) {
-        if (Tmp != NULL) {
-          FreePool (Tmp);
-        }
-        return EFI_INVALID_PARAMETER;
-      }
-    }
-
     if (OneAdded) {
       //
       // If any address in the new setting is not in the old settings, skip the
       // comparision below.
       //
-- 
1.9.5.msysgit.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [Patch 0/2] Ignore duplicated DNS address check
  2017-02-23  5:30 [Patch 0/2] Ignore duplicated DNS address check Jiaxin Wu
  2017-02-23  5:30 ` [Patch 1/2] MdeModulePkg/Ip4Dxe: " Jiaxin Wu
  2017-02-23  5:30 ` [Patch 2/2] NetworkPkg/Ip6Dxe: " Jiaxin Wu
@ 2017-02-23 10:25 ` Subramanian, Sriram
  2017-02-27  6:37 ` Hegde, Nagaraj P
  3 siblings, 0 replies; 5+ messages in thread
From: Subramanian, Sriram @ 2017-02-23 10:25 UTC (permalink / raw)
  To: Jiaxin Wu, edk2-devel@lists.01.org; +Cc: Hegde, Nagaraj P, Ye Ting, Fu Siyuan

Looks ok to me. Nagaraj will also test with these changes and provide feedback.

Series Reviewed-by: Sriram Subramanian <sriram-s@hpe.com>

-----Original Message-----
From: Jiaxin Wu [mailto:jiaxin.wu@intel.com] 
Sent: Thursday, February 23, 2017 11:01 AM
To: edk2-devel@lists.01.org
Cc: Hegde, Nagaraj P <nagaraj-p.hegde@hpe.com>; Subramanian, Sriram <sriram-s@hpe.com>; Ye Ting <ting.ye@intel.com>; Fu Siyuan <siyuan.fu@intel.com>; Wu Jiaxin <jiaxin.wu@intel.com>
Subject: [Patch 0/2] Ignore duplicated DNS address check

Having duplicated DNS server IPs specified is not an ideal
configuration, but not an error condition. This patch is to
remove the duplicated DNS address check to allow the same DNS
address setting in SetData().

Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>

Jiaxin Wu (2):
  MdeModulePkg/Ip4Dxe: Ignore duplicated DNS address check
  NetworkPkg/Ip6Dxe: Ignore duplicated DNS address check

 MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c | 10 ----------
 NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c                      | 10 ----------
 2 files changed, 20 deletions(-)

-- 
1.9.5.msysgit.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Patch 0/2] Ignore duplicated DNS address check
  2017-02-23  5:30 [Patch 0/2] Ignore duplicated DNS address check Jiaxin Wu
                   ` (2 preceding siblings ...)
  2017-02-23 10:25 ` [Patch 0/2] " Subramanian, Sriram
@ 2017-02-27  6:37 ` Hegde, Nagaraj P
  3 siblings, 0 replies; 5+ messages in thread
From: Hegde, Nagaraj P @ 2017-02-27  6:37 UTC (permalink / raw)
  To: Jiaxin Wu, edk2-devel@lists.01.org
  Cc: Subramanian, Sriram, Ye Ting, Fu Siyuan

Series Reviewed-by: Hegde, Nagaraj P <nagaraj-p.hegde@hpe.com>
Series Tested-by: Hegde, Nagaraj P <nagaraj-p.hegde@hpe.com>

-----Original Message-----
From: Jiaxin Wu [mailto:jiaxin.wu@intel.com] 
Sent: Thursday, February 23, 2017 11:01 AM
To: edk2-devel@lists.01.org
Cc: Hegde, Nagaraj P <nagaraj-p.hegde@hpe.com>; Subramanian, Sriram <sriram-s@hpe.com>; Ye Ting <ting.ye@intel.com>; Fu Siyuan <siyuan.fu@intel.com>; Wu Jiaxin <jiaxin.wu@intel.com>
Subject: [Patch 0/2] Ignore duplicated DNS address check

Having duplicated DNS server IPs specified is not an ideal configuration, but not an error condition. This patch is to remove the duplicated DNS address check to allow the same DNS address setting in SetData().

Cc: Hegde Nagaraj P <nagaraj-p.hegde@hpe.com>
Cc: Subramanian Sriram <sriram-s@hpe.com>
Cc: Ye Ting <ting.ye@intel.com>
Cc: Fu Siyuan <siyuan.fu@intel.com>
Contributed-under: TianoCore Contribution Agreement 1.0
Signed-off-by: Wu Jiaxin <jiaxin.wu@intel.com>

Jiaxin Wu (2):
  MdeModulePkg/Ip4Dxe: Ignore duplicated DNS address check
  NetworkPkg/Ip6Dxe: Ignore duplicated DNS address check

 MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Config2Impl.c | 10 ----------
 NetworkPkg/Ip6Dxe/Ip6ConfigImpl.c                      | 10 ----------
 2 files changed, 20 deletions(-)

--
1.9.5.msysgit.1



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-02-27  6:37 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-23  5:30 [Patch 0/2] Ignore duplicated DNS address check Jiaxin Wu
2017-02-23  5:30 ` [Patch 1/2] MdeModulePkg/Ip4Dxe: " Jiaxin Wu
2017-02-23  5:30 ` [Patch 2/2] NetworkPkg/Ip6Dxe: " Jiaxin Wu
2017-02-23 10:25 ` [Patch 0/2] " Subramanian, Sriram
2017-02-27  6:37 ` Hegde, Nagaraj P

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox