From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.136; helo=mga12.intel.com; envelope-from=songpeng.li@intel.com; receiver=edk2-devel@lists.01.org Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id EF00221959CB2 for ; Wed, 15 Aug 2018 18:38:58 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 15 Aug 2018 18:38:58 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.53,245,1531810800"; d="scan'208";a="254456811" Received: from songpeng.ccr.corp.intel.com ([10.239.158.47]) by fmsmga005.fm.intel.com with ESMTP; 15 Aug 2018 18:38:57 -0700 From: Songpeng Li To: edk2-devel@lists.01.org Cc: Jiaxin Wu , Siyuan Fu , Laszlo Ersek Date: Thu, 16 Aug 2018 09:37:55 +0800 Message-Id: <20180816013757.9680-4-songpeng.li@intel.com> X-Mailer: git-send-email 2.18.0.windows.1 In-Reply-To: <20180816013757.9680-1-songpeng.li@intel.com> References: <20180816013757.9680-1-songpeng.li@intel.com> Subject: [PATCH 3/5] NetworkPkg: TcpDxe: Remove the redundant code. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 16 Aug 2018 01:38:59 -0000 The function TcpPawsOK that is never called have been removed. Cc: Jiaxin Wu Cc: Siyuan Fu Cc: Laszlo Ersek Ref: https://bugzilla.tianocore.org/show_bug.cgi?id=1064 Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Songpeng Li --- NetworkPkg/TcpDxe/TcpOption.c | 32 +------------------------------- NetworkPkg/TcpDxe/TcpOption.h | 18 +----------------- 2 files changed, 2 insertions(+), 48 deletions(-) diff --git a/NetworkPkg/TcpDxe/TcpOption.c b/NetworkPkg/TcpDxe/TcpOption.c index bacce1070d..bd1c2b9c27 100644 --- a/NetworkPkg/TcpDxe/TcpOption.c +++ b/NetworkPkg/TcpDxe/TcpOption.c @@ -1,7 +1,7 @@ /** @file Routines to process TCP option. - Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.
+ Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License @@ -342,33 +342,3 @@ TcpParseOption ( return 0; } - -/** - Check the segment against PAWS. - - @param[in] Tcb Pointer to the TCP_CB of this TCP instance. - @param[in] TSVal The timestamp value. - - @retval 1 The segment passed the PAWS check. - @retval 0 The segment failed to pass the PAWS check. - -**/ -UINT32 -TcpPawsOK ( - IN TCP_CB *Tcb, - IN UINT32 TSVal - ) -{ - // - // PAWS as defined in RFC1323, buggy... - // - if (TCP_TIME_LT (TSVal, Tcb->TsRecent) && - TCP_TIME_LT (Tcb->TsRecentAge + TCP_PAWS_24DAY, mTcpTick) - ) { - - return 0; - - } - - return 1; -} diff --git a/NetworkPkg/TcpDxe/TcpOption.h b/NetworkPkg/TcpDxe/TcpOption.h index 0ccadb9536..e50fb9b129 100644 --- a/NetworkPkg/TcpDxe/TcpOption.h +++ b/NetworkPkg/TcpDxe/TcpOption.h @@ -1,7 +1,7 @@ /** @file Tcp option's routine header file. - Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.
+ Copyright (c) 2009 - 2018, Intel Corporation. All rights reserved.
This program and the accompanying materials are licensed and made available under the terms and conditions of the BSD License @@ -126,20 +126,4 @@ TcpParseOption ( IN OUT TCP_OPTION *Option ); -/** - Check the segment against PAWS. - - @param[in] Tcb Pointer to the TCP_CB of this TCP instance. - @param[in] TSVal The timestamp value. - - @retval 1 The segment passed the PAWS check. - @retval 0 The segment failed to pass the PAWS check. - -**/ -UINT32 -TcpPawsOK ( - IN TCP_CB *Tcb, - IN UINT32 TSVal - ); - #endif -- 2.18.0.windows.1